From 02db6518ad074fb53dfa976d6039c60f44397300 Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Tue, 2 May 2023 17:09:22 +0200 Subject: [PATCH 01/22] speed up ui tests by reducing number of pallets --- artifacts/polkadot_metadata_tiny.scale | Bin 0 -> 6580 bytes testing/ui-tests/src/lib.rs | 3 ++- .../src/utils/pallet_metadata_test_runner.rs | 19 ++++++++++++++---- 3 files changed, 17 insertions(+), 5 deletions(-) create mode 100644 artifacts/polkadot_metadata_tiny.scale diff --git a/artifacts/polkadot_metadata_tiny.scale b/artifacts/polkadot_metadata_tiny.scale new file mode 100644 index 0000000000000000000000000000000000000000..4dbe4d738144cfda8017d4860e180ff73683d1c3 GIT binary patch literal 6580 zcmai&d3+m38HQ)=b)vQ^6(GO`6;yCR1s7ync5K%TzLeVFtG1kmG(p*FC)Q$VSM07F zD-;@_lmGz=6bScy-}imr_gSFa_kG_t%7{1+2Zw^M5?c1E=J2K2f&RlnOshN8 zT?$tdIj>Q6o3?M&W$(OWHfyrzx{fQ<9cjxp<)*GBn!`d%%K)deQ(>9;i38>N#p%_# zV!61yytrI0E=(;>7pKcBvj>Z6gj##uT*+CNHp*%}8;wvhGEr=t7}q;{(TF;T~01N;kW>5q;Lg@U*pId6r{Owhl_yQL@5sfB2b_YuKJq@zo_pEh?AD z&jri0ER9N4c?ywPaOR9w`0T=Lzr8SRc@4v_RHHi!=|#V)u2XY{N1Jn;^=3oOSlfG)Dyc5`x;=qYYijiwhY+}R>G<+yIM5zLx6 zCsL}e zytd_XwN}Yx-BvoBq5mhNErVpFbSTz_}fXxphmu z9n$tJd!07&GB)&-QLCxZ#Lb=RX~)B-y{VHXEhEkT!NIeGW)Qj4Q{k5%l5<3JcY<5&oz`o+M#gJJB7 z<4_oP#c@v@av`wzw;@>@6MFrcNfa=%TR{j1#upL z-(4xg?{1Xgm!%B93n|0z?v&wo56bZCp$xx^D8uibl;L-;I2YiTqYS@`DZ}sHl;L+D z%JA!@48Kb#!|%S7;dejE@XJ$%UtgRD;nz&4)06=Q;z3))>IFPM{B_HUpSC3}D(|0Mmyu zfT_y>rXB;B`V3&&WB}6*1~5HFAUaew8Njr~0H((o!1Q4ZV0sM$m_D2VOdr7jrq?on z=?MlfeI$YCczF~9m_C{TOs``A)5kD?>Gcd?`d9`qJ;?y3k7EGS$1{NG69_~H%_#;j zeIf&xK8XQLpUeQJH!y(dQy9SXsSIHHGzKuekpWDfP9QpRp1}a7&tw48(+ptxECw)r zHUpSGhXG8V%K)a&V*u0VGl1y}2ta1fpZ;)eKC3}E_R1~7def#_&@KLeP4fB{TD$N;7v zVgS<*Gl1zw7{K(S3}E^(1~C0N1DJjy2K{;b@_&*6Oh3f{rk`d2)6Xz~>1P?h^m7bg z`gsO0{Q?7+evtu8zeFH9qrS`lre9$I)2}js=}in^`ZWeH{W=4feuDu_Z)O0~Z!&=C zw+KXM)VCSH^g9e-`dtPv{T>6DexCtMf4~5yKV$&YA2ERGj~T%9Cj_E1>Zc4~`ZESF z{W$}e{(=Eaf5`x*zhVH>Uo(K|Zy3Pzw+vwVI|9)e^?L>|{R0D-{*eJp|HJ^Me`WyF zzc7I5Um3vkZwz4icLp&12Z88}`X>XJ{)+)j|IGlV|6u^r|1yB-|AgqIMh(BKIxZ@pdnsXy`hHDs!Q8nnyMP^nhg8orOhS4aG->i^sUATEk9}04D}R? zN5@Kgg_cDH%e+pjV&t*560>G_*hO1(QP{-ZqYn5Ra-si>_zRcYVsB@OC#B~@P4j+`8IRgPWH*%jpF~gWnP*9 literal 0 HcmV?d00001 diff --git a/testing/ui-tests/src/lib.rs b/testing/ui-tests/src/lib.rs index 702577204b..232bcfe552 100644 --- a/testing/ui-tests/src/lib.rs +++ b/testing/ui-tests/src/lib.rs @@ -23,7 +23,8 @@ use crate::utils::{MetadataTestRunner, PalletMetadataTestRunner}; #[test] fn ui_tests() { let mut m = MetadataTestRunner::default(); - let mut p = PalletMetadataTestRunner::new(); + // specify pallets we want to test the metadata for (None => all pallets, but specifying only Some(..) speeds up test) + let mut p = PalletMetadataTestRunner::new(Some(&["Grandpa", "Claims", "Babe"])); let t = trybuild::TestCases::new(); t.pass("src/correct/*.rs"); diff --git a/testing/ui-tests/src/utils/pallet_metadata_test_runner.rs b/testing/ui-tests/src/utils/pallet_metadata_test_runner.rs index e87c755f23..735be020d0 100644 --- a/testing/ui-tests/src/utils/pallet_metadata_test_runner.rs +++ b/testing/ui-tests/src/utils/pallet_metadata_test_runner.rs @@ -13,10 +13,12 @@ static METADATA_FILE: &str = "../../artifacts/polkadot_metadata.scale"; pub struct PalletMetadataTestRunner { metadata: RuntimeMetadataV15, index: usize, + pallet_names: Option>, } impl PalletMetadataTestRunner { - pub fn new() -> PalletMetadataTestRunner { + /// if pallet_names is Some(..) only the provided pallets will be tested. + pub fn new(pallet_names: Option<&[&str]>) -> PalletMetadataTestRunner { let mut file = std::fs::File::open(METADATA_FILE).expect("Cannot open metadata.scale artifact"); @@ -32,8 +34,12 @@ impl PalletMetadataTestRunner { frame_metadata::RuntimeMetadata::V15(v15) => v15, _ => panic!("Unsupported metadata version {:?}", meta.1), }; - - PalletMetadataTestRunner { metadata, index: 0 } + let pallet_names = pallet_names.map(|v| v.iter().map(|e| e.to_string()).collect()); + PalletMetadataTestRunner { + metadata, + index: 0, + pallet_names, + } } pub fn path_to_next_ui_test(&mut self) -> Option { @@ -41,10 +47,15 @@ impl PalletMetadataTestRunner { return None }; let test_name = &pallet.name; - // Increment test index to avoid overlaps. let index = self.index; self.index += 1; + // if a pallet filter is set (pallet_names is Some), return the next pallet if this pallet is not in the filter. + if let Some(name_filter) = self.pallet_names.as_ref() { + if !name_filter.contains(test_name) { + return self.path_to_next_ui_test(); + } + } // Build custom metadata containing only this pallet. let mut metadata = self.metadata.clone(); From 2f4fc25f34a2730827cd4954361fdf09ceed9f72 Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Wed, 3 May 2023 09:14:47 +0200 Subject: [PATCH 02/22] add small and tiny versions of polkadot metadata --- artifacts/README.md | 18 + ...ata.scale => polkadot_metadata_full.scale} | Bin artifacts/polkadot_metadata_small.scale | Bin 0 -> 105358 bytes artifacts/polkadot_metadata_tiny.scale | Bin 6580 -> 6539 bytes codegen/src/lib.rs | 2 +- examples/examples/balance_transfer.rs | 2 +- .../examples/balance_transfer_with_params.rs | 2 +- .../examples/concurrent_storage_requests.rs | 2 +- examples/examples/custom_config.rs | 2 +- examples/examples/custom_rpc_client.rs | 2 +- examples/examples/custom_type_derives.rs | 2 +- examples/examples/fetch_all_accounts.rs | 2 +- examples/examples/fetch_constants.rs | 2 +- examples/examples/fetch_staking_details.rs | 2 +- examples/examples/metadata_compatibility.rs | 2 +- examples/examples/multisig.rs | 2 +- examples/examples/runtime_types_only.rs | 2 +- examples/examples/storage_iterating.rs | 2 +- examples/examples/submit_and_watch.rs | 2 +- examples/examples/subscribe_block_events.rs | 2 +- examples/examples/subscribe_blocks.rs | 2 +- metadata/benches/bench.rs | 2 +- metadata/src/retain.rs | 2 +- subxt/src/lib.rs | 2 +- subxt/src/rpc/mod.rs | 2 +- subxt/src/rpc/rpc.rs | 2 +- subxt/src/storage/storage_type.rs | 4 +- testing/integration-tests/src/codegen/mod.rs | 2 +- .../integration-tests/src/codegen/polkadot.rs | 1038 ++++++++++++++++- .../ui-tests/src/correct/generic_params.rs | 16 +- .../src/correct/rust_items_preserved.rs | 2 +- .../incorrect/substitute_path_not_absolute.rs | 2 +- .../src/incorrect/url_and_path_provided.rs | 2 +- .../incorrect/url_and_path_provided.stderr | 2 +- testing/ui-tests/src/lib.rs | 2 +- .../src/utils/pallet_metadata_test_runner.rs | 2 +- 36 files changed, 1092 insertions(+), 42 deletions(-) create mode 100644 artifacts/README.md rename artifacts/{polkadot_metadata.scale => polkadot_metadata_full.scale} (100%) create mode 100644 artifacts/polkadot_metadata_small.scale diff --git a/artifacts/README.md b/artifacts/README.md new file mode 100644 index 0000000000..60d0b8632d --- /dev/null +++ b/artifacts/README.md @@ -0,0 +1,18 @@ +The `polkadot_metadata_full.scale` can be obtained by pointing subxt to a polkadot node. For that just run this command in the root of the repository: + +``` +cargo run --bin subxt metadata --url wss://rpc.polkadot.io:443 > artifacts/polkadot_metadata_full.scale +``` + +It contains the full metadata including all pallets. From this file, two other stripped down versions are created that contain only a subset of pallets: + +- `polkadot_metadata_tiny.scale` contains no pallets at all. +- `polkadot_metadata_small.scale` contains only the pallets balances, staking, system and multisig. + +They are generated running the following commands from the root of the repository: + +``` +cargo run --bin subxt metadata --file artifacts/polkadot_metadata_full.scale --pallets "" > artifacts/polkadot_metadata_tiny.scale + +cargo run --bin subxt metadata --file artifacts/polkadot_metadata_full.scale --pallets "Balances,Staking,System,Multisig" > artifacts/polkadot_metadata_small.scale +``` diff --git a/artifacts/polkadot_metadata.scale b/artifacts/polkadot_metadata_full.scale similarity index 100% rename from artifacts/polkadot_metadata.scale rename to artifacts/polkadot_metadata_full.scale diff --git a/artifacts/polkadot_metadata_small.scale b/artifacts/polkadot_metadata_small.scale new file mode 100644 index 0000000000000000000000000000000000000000..05ab6bb5aa24581838a6ffd2e2f823cea0ee891b GIT binary patch literal 105358 zcmeFa4`^K3c{hBHbY+i|*=DxYw%YeoUT(fBZ$|mXcV$PLPpc@4WlJ0Ri)?ExdH-Z> zG^3d-YwFR=Wd7JzNg;(4QrJQY32Y&O22w~Ng%naqA%!jEg%q}sLJBFQkU|P6^o0~s zNFjyq_j}Htd++>_WpCo<{k|+|ZQr@~oaa2}InV#+Ifrqt@~(fH%qcZBsRE@YLnZ&^ zXS?m)YO52^R69rQUaPcPt+x8j-sRc{&MUka=r1XH+{KTi|^~adq|M+;6vAonBb0ciWX-_29x*+*z}KztpI7yFsv{=Tu(LG+Uj+N@Gq3J4%;Y z?YL9v)mu&XWbUxi1n8~Kk-VWw*wjw_u->cRjdy!T?YLXmIRESihX`RosR^YnfQ&#& z_;01a<#m8NEMWF_+>AT*>P)SEJMQ+1Yx2is?2*#b#jQ?!-Mp7mi+b%6@E>Cfy6er` z^=5pzrqqI-eJQT4^p~DjK%al%1g{6GupL(#CwOy8O<(IB#GN2Ln^H9k+IsVDz0+zQ zVxw=gfuOjiaB`Ng>Ls;!%vxv6T7fTJXtZv3SM&;(l3?I@rCu4giHn&XR60L%RW=X! zEnQ1?PH8oF#cdn6;pVsj3tN?=uF|>ut8o{Dwzj^uyM6g%>tI0#>2ZrYtvhkk46A2nueM(3H)~vK z_;Rb?sIApwEO_B!+-TjqQg7A|`-i~S!lg>H+3H>D#MoCgsTOWD?=)NYnycMz+ylp( zc|kakno^}3AWS)E*#A>XHPUmhtaj?XgTuI2uUY`|b2qT8&OT-%2-oh~ziYL$R=->C z;@n+4`dHj)ansuAu{L%(m1eh6HAmA9ms{B6NxU9cst1@~DXed^auj#CiRJX?emCrw zi-xxGiCybvt97T}#&>fUE46E#I!+p3m@&H&s4bn@ph+dCl3ek6d{_bEnzwWYuMw-fQd{|qe3&uPYI^-H4mH@L(lZy<@Ao?O zX18A5?pGnex`AGF9Cf#jL$Ij_&P4E;)n*vGufl5Uunh?q*TSwDV87pJ97QXB+!p{( zT+8VtKWt25FDD1cZJB>z)Vw;_%FMej!$ze`ty=8((?qaUUasOnIlNcthJC}fqT=y6!OzoTNn`f(7+K_ zuUWOJ~0*qXWP@yGkn9Y=krgZraC?6@zY*-MSM(i!#XM9>)ev>8^->rwDU{f;wd z&JaJZ0U^!at>Qti*X}Mq^GvN(?MB`HUbhGRIgaYBXDAoX^6@i!{d%MJjC{~NE9|}d z%zPL_bOU@2xOaqI1s*MX;-lB|OO}g36RJb>j6mF?*f7va>bJr3ayozSpf$ue9TVXZ zcKlp)D;4xsJu?<{OXv~Wn+z8fW%L(dmtk+lj-rEa436TD5pB8}v;l?{&j!zk|cn^9#JZ_BeO%v(s5KYz9;TsAhW9M!N-? zv5VIH-R@O-ed^!^q8hRU!q8a06h5Ev2gupb89IP4Qo&_dg0t(*S__;bH&%jc=sK{H z?Jx!CUywG&0*8S6`hZ}zqCLC^4c0JgejVDcqi_ux)@G~QJ7&I_${|hV>`XfMVLdPv zL^t?HEd=p){S1~%H_!eywBc~C4~|D2JzT$E$C-x_S!t}r?N+zmE8RB|2P$X?MF702 z)rZaoD>`hny4@%gy>UP8K(N7ca5!{8a=qb0GZOZRVAG9dw7IwjMpU#&+>U#Y)T2%y zrloHqjqtR4BmG>|EQ@480St~1+yQoek6Mx;j4>yDB+x#ffG;}isM_7?6_v-Dzhbs4~UJX-FkO;zZGD^8b`o4EiuO5VD z3}CFpN)1eo=aZXyXj~*9=4zu)Zw1FF-ShRFb>%3y=#$BE`I=NI8!tayJ*5zeq( zs8r3{-C5|!d$3Pw#W_>zOYpdUMtud|SEc?q=M*h)hCBFT>7`1eE-p_vBKP4d%IPA^ zcu){m{8{Y>)U%?6$F(K&frffcSG-Bzc4a%N`9QE&yXk|lFc++%n2K4pWI!sEJ4F})g3Ysm@ z9No{!0?f!DN~blONuz|D%y1`1_z=cSH34h>S`!>xz6y)*oQ7=}8KPx0jzpdGaCGMr zNVfU=Iq8u(O%9*<*Ej>+AUG*yC!lxTlw~N&HJ)Tqz0FgipnA}6-T?+cuaE*( zs+4P9vi6&FJn&6e-~Bk6`Dnc=e!Dq;LWaN{y^37$HBjF0@xCJiI!gEaDB9UJyCjs0 zvtwK`>P+wz@(H0;5lF`IiH#R`B{?7sYs4Sv7M#6wAg)Rnv?Edbj^I6mDD3uH@F{{L zR620v*P)hj^}uZmr3XHdO2RWk(2`$Kw74al7huzul+$DQ{EA;9RnuVx`Oe@CE)c(g zrFGwD8LJ`u+i_2zq1=tuUUC9M>>?ugZS+^LkL!<%2g?Q_CR*kuPAK^$tBT zu%cqdaUZ8>{~AJwh$`d1uX5xIkZll#( z&`a0a6_D-@9&FW3;1^tkObJ}qj9?iq_TB3I#vfMZuw_U9<7PJQIA~EBelBP0 zSzYA2XS?mVT1P~9USI%2ry-YRZRALa!cK-%>$e+XEf@g+gm2z_jl-4vN^ag7aJ7Bi zJB%zagUF$u-^!T>Ng$PbPUCHCzKAK2cy7(YQ|X%&S0ogDZ{ZjX!hHj1eeh#k0-RgJglh#>XFSM`b=W_j6-^Gytu``WB}6Jg=6t8e%nvLg)aP<{zG zU+wn}TF_(bF=I^?`>&&2oWpPEMfdB`Cfpzx{B`b-N=_p+md+zso&NVs3&*X~{f_<$ za}9!mW^8&#m3`l1}ot~MGUX|+hy-(D2~6(UUH zc(r9gWImpsQ&AQxjz0IOM28841!)37PcVJ{?fbeR_^DC#2hSFV(GGZV46FKi9EW** z%w*t)2ou0DgcxEe13&7&x$yaexnCXe_>j zf9|+{!GW-~-G>Q%rSen7^R)@U#U^Ti|5a zbquG}PshCE5~cWVDpgG9LMT*-h;^V*$!Pzo&3LfJjW;`$7^c+pHkcq3p*+$eQa|W? zvvQRFw^BbI24tALmqH{s;5<^FTLMn-SGZtA)aCUYf5YKo-pZ^M=tGt{!zG6;CL|h#=dI`=Bj zLB*Ic*&h)yW&Eq-lR|RA4+h5fFvBc@y#RM>AN~n5DM{X^7e+HL#l04@4MsXQ7v1*l zV)K#qVR8)hG}8hb!jXWwNMru~DhsX)uI@Z5chuJA!W})Faa;G`^R79)dl( z(0epZE`_yB6Q9GmE5}l+;bK41E`5eWtym!}?%e0qJBK_6oTnz?uJl3KmJkG~1bQ8# z5hGw>&S={m%M{1T2d@w8C5DhO5YzCd>B5#hR))HX#c=~Z5tI`=hPPqk7~*)m+TxVX zuURFq+QMN%0^Qwg4uT7z&U)4kxnR9Cg9mDu=Px>hShhAuQ$AlwCk!u-WV)CcJ|>k| zITndZLx%(;$7j1I-$WZLA07?mG-e703UM^<`Pm$&mFtb_?##u*BIw0!MOIjrx~ zXWWT<{SMq@LQ@PHNUln>WGLxv!7~+*$dT4`8@W!0LjCa6+B`6m*7^vL&0Io=pNw}r z@t%xYPX#vso;hZS+KRCtL#JHo^jWww#ut#g$P_+0{VMxl`w}Op^-cP`4AE~tPA&h; zFIgSbgI}^bP_bCuW6#7dS=}#L-T&UK?kQx(!827*PvS2VTB|2?9v)fdcJI1KPH*JD;+?^l^tpk>Dsa7WmGZj*Ka?cBvHZ{ zpH|c7;V_$ChZMnpA;iI<(aciATfaZN1wIo9KBKtV>fb(~atwJW2|}^txJl9l>ZNXI zsvmAu&Y_-sh@_S{u~6hasMrWGAfkboSBI{sK4dNu_UL|!?^h5}k8A7Nq{cHi*6+}z z5rwN^+2W;m^R=6|=Ajp4VeK-LECngGdO(NZ5JRFjvas74WNMsxmCBut*u2=Wyr=H}2iKWYfS&<-=c z-7YY0j#!T*i88$Tt%0>i;WqMPhrC ziROfDv2h}<9D{X^7(0Z$4dW3|9r|sJ7L1N%qN#zNF%+58Z=8%2)nsm!`kqm&d@ih%4v6v#5IxP2Ezn>SSZX*i*d|ud z*d1%_^;l<8fn^O^#R@F0Tb&{fDbCqhXnX1ha3+yx@Cws6%sa+pF>iJ8n#n3?pz^?j z(T&znme||CM{&omyTrM6>7S(`e^OEyxAIfLvsk%+Z-yMRc3@#I=Bh!V)mZA4uw4Tg zkqAdUPTltDM7Om#J*c-ceBGJxGuALg;R+&HD)>Gbp)r~5j)`^0Uq1w7m=m7KiUUJI z`dYMjMGn(-vvLF)emHU@i<#rcvKCZ#`yLqr18d*ix!3aKAzZR+emj03%O<+lktN$h zQPxwMKqV-VErpT79Is;*Cv1&!3NIq=9Th(sA6+`AG;ag8AovuMp={XO4*kCHP7I!b zS}VR2O|SJ2506lT)!4$59#THddyq~@*y)6fH$G1Cc(?Yc0X>*y2*w?aB#zMgc!CGI za#XMgVd!l_hyzrX)o?BXePOR(gS&MXdk>y~M+Kes*p!6v5((JhlR2S=yV)11d{(BCv&;j5$OALqlG2tFa%!X|x6 z05mmE76!@LGcN5BF^<9cXD#m>0l{SO)d7>*xynCebGHoLn7Sd|JQ{ZA9HK}|U+N-JHtaiIA(g~sdIunzb{RjmK z|DzsYWrJ{cj%wNtEt^}3N(V$E7bntnb0BERlY}n*+p67X}^^?;QAAGOQ-)y%UcPh0O4jgff zehv)ewwg02HLo9bSJtsPow$E!YZVz;d`jE=jq?kr2!D?*JYb9rw~#<~fEqE3J~l#e zA-1#bB0mruxBIl#Ly(LU#i(p^%8;x9?4e85dhOcIW6iBPt9?q!T`7^cJ&cIl(o5zi zTSk0L#Se}GhhfP^HknuDB+1I1AoG%(G+{li64~TMN#?4zJis@N)M2#4rhK{@?&!TD z{%qXWO8M+zHRy9nX&jj*5?8GY{^l*a z5>O>MINjA|g^%;doJ+Q{4}OH8eP%0J%YKo4K*T~}Njw#6SJfv4#me( z1jsd(b|P@S(|t={HkK_V?q=yxD3K7pYZApaKxms7VOyu_f zQuJG+rgl>zbS>y+dMoWmGe|i*2=i&zSySJI-u1QPhhw1`%@Y}@8!fUWNdnCzN?*Ja zyN;j4C>5(<)UX^Vfiw$akt3TFR)`6iZV2%~@Z{T^&fvp$C_srmlFG(bXiuR$A0`R* zgetPzug9y&J)3B9Xs!cpKS0OAn~SB(_P6aA8pEgvvI_ncVhttf#>ioEJ98YU?-mVD z5ar8g@6^A--=a>(svHzXt+?@Ro$#2j`?w?z9lVvA+!ham;-USK)QvUbxRwjLL`!Z` z(@o(a=bT{J+Ar8zC1a+vI$N~y|F|{#V(Kxou5{poVQF*6DWXf)-4he}oTMJ%aVS_v zNj(Icq>fjBdpkh1fI?S8^}kXmJeAF)J(6AXQd=g;HGppbTIbYZ){=ZHf_L)HXJ%?DLEU7$HK^mH7R zo(_HtX4c<3TepWPnbD+#g#HIdxmG0ghHP&TFh|mco|@x< zVJ3p(CXrdc)ifTb zKJj6lyD+GCGhO8V(GD6rAi*ua+B|}Wj-Efw9hNr2m5MyT;zww9HJQ4E96%<6A#MG( zLc<_O!2T$r_^t$BA99>zSTqNkUF}PQBXwG-RhR%%fqG8o7p!9+rttl&QX|4(nkMP} zBNv@MM!qTL-pMFJ=`JD;8I4u}RkYB6hnk9n=h0DV3u(Qk4HV0e;V6%Xj@KyZBS|s$ zkEB1^SuL$}1W1FrEr{02;a>fA-&7>S$sXT7hjhvQxevmv{XGDQiCh9;q9(hVd^qUn zyRj=F#KM6-lO2{CbbMbVfO%8ui|1C+*-G5FD2Iouq%pLfX?c6-F?_I%hRw!WyoA4R zAVtNLn@$AZXX=n0SgM_=K%nLZ-eS`8Axc-k97VMN$rHc(eWV)15qiC0?}Von^qfr; zYmLaDa@lCZ_-FpnSX58ryUNjU!q{Z6ktPM0a9|k=0*qy4j}@E%-J9Hg0&|wtJTt>+Z_c+R(s?Ab&mic7vJK??q<$G}ShSw#a&F9wO(Ms) zP=c53ik%WUv?enKJY$Fg5yCQn4gHePW}wjz$X zX<*~W!!SqpgW%*jt!o}ZD?{y(9u`;_Itbs`1r7m%JJZ6&258`2*`Rx!wiH+m;pPA7=CUWF&X^v@gQ5E9bUD-P z85q+l;>Mpm((k)r0K16N<->SYlK93zJ%KJYL*v7>L$44H29;D6K*Q!^LfPFoS~Npj zZ~D099OoUKq_%IDgqg(IZe&^ob9tw#o5{Njons}7IBc0Im5|b!&_oMdYl65MV;SqiMjNa{Iq43n0_0=8=-9+%EVd%yXWU4daL!)StbT){E{}Rr711+L0 zouMbnXs$aw18%xgZ$taQJ61{dNxF(WgbF);gIOnau9@;56h*K$y@(N*&kAujdLXIg z88L`UL`~9D$qI2Ut7fzanw*SG6L=JaBRy!^)5j3Enqbq25rBv@pOaFV#+=t<>wp=( zo=KE7j2#AUG3&e`UTjLl81QEhuNzhCka#|ZmLP7UaZ7OivB%i%@0QMeW*~uW7lw^= z7~d7W5b11{ZoJ}Bj_8#}A4cfhv)7u4-J@TxQZw7qx({|Zx>T4pez3yB7oZaFq3{J} zI1;F0lnOPgN36fA=-e7Ao14%TlDs*e)wIo~?KS>0O3q0C2ani(sL*S z9{=l_|8=+f@je?bju=C|s`Dp8K}PWr20y#B-D)7}(Q0m^Qw#$ev-G-5>~ zmkmuSQ1om?mY;}rx~pGvhB|u9p&K0B<+2Fc8EX!O($fsx<{yON=`KmsmL$FnQ(TXc2YoOW;o>O~6;Fmnd7>S{wgH*QZ^8%R$7Rq7Ob9ioNXUX+g_c&3 z9za*vWs55GcSWGb!~ra&K#i1d7-pn{!fp?n?it~mj(eUs70V?6WJT;`@Lo-iiS_s~ zP9z)YI~y77Gq2JR6up7A{}kSYfIw`G%?N<6RNJE@AwTL!nzrCMNu`Y-~Igyh)m{p9+_A*+<5+E-wqIfd5Ee z-Yv)7jv4k;@GTDO&QW-xfgdBskCXD~y~^$GE~^qVtj*bUIglXUK;9J)Hm1L1>u^?w za6%ZCt55doVy7I@i5s2Sm>Al)`=tUjT96@ptbgQ$bI@jX@L<=Oy#ncrWU;~dGJ7pztTby~&B%DQ zfrAmQ&{;x@J_@*efe=go1XwA2ny^#rDt4{A3Q0ooK;`i8XnMx9w;Igh&@;aUUtrSg zPE)NlX@7QJF}=;l45 zI&@7x%#=y{fb5*mgXsh94&ft@-csp~eUqg(G6-?4wtT>cJ(P$M1U1fvWgGt$F-?IZ zQHX9Et`+ik7ahj=;g7a&4*q3;!9%1NJHc^7hwvHONGcCAm-JXEI9UtQ4;M1j>LvMVu@0Kf)v#<-0ZIO&y)M6%Jl7$sfd z9_lPVEKvtDbl4_U1XO;rja@wvzen!??S_#jsPJ@>q-3VI8Wh12Q;G#o5fLVg-N+GSc@js^T9Dcc_zXvsV{0?1vq|P7 z2Oq;VPv^7T#ww7hG=0l|txX^?B^0JuHTW(pohGy?R8}W@3_+Ff4av2eXW9&uyX0-t zo^L){K#FbLwE~~9M0BXGXuaibgh9zIw1*xbYn>r4jB1luz#7Cv};6-$zM0SgYYl6(&Q(P+?#R7>rC*3oDSoM z_Pj|*6k-~OL`aB@O@D-d?xa$uk)K$`PoNbB=nvH72L^oUl7G-hTaPP z#FRw*Ww;6A_@p((q#5}bWgEbzog{4+jT_RapF?sTHfm->w>31%EPtki=913Z*(irt z*=B4rIL5^Vh8DlbIuu{}$VE-$)-}_BDFTnF8bgCTayU#Wqey9==}hWUVz6wq&N4E0 z0X;jqlp+vy$X~Q03nZu)`Qa*UwUM($p}#@QNgh5d`C!A z)6WzZ8gH@M09znPYz8EM{XMc5R~eAP+1>NJ;m8!zLh4KDW~&nf8@iq}-J%?td1V^}JlECt8`){^VGxIJlndkR_<5Af9-LWW2 zsw|~VUmN$G5kF{k4#mf!?Dw^PWdtTyHXzV1z-@;6Yb0MbvsCrP2kmQ!4uQ2bAdS1Z zklf^`{$wn)bCB*Bw|w}scgGT6(az&+& z0@GvU7k{Y>`TNzw9By<*U>kRVO>DA0*enDz$h6chI7migH!F&hUmHgvXk?>u^Nj zKI}~v3WG4=gRc4Cb`bdD6%+nPAvN`Yxkj4{hzy1r*uXsjFX4 zDRc=I3UDJJCwmb$&BZ-@^#W34YPjxr#{}PYT9N>c10ye}Gin7dy=+}aY%z+PSU222 zkXty->~w$|S$Ed&SCOsXy;8Y<1^zJH54eq>mddMF=&#|;A6P1Mb$`e16KYN-<7(Bf zC|*$oi6C>l%iq&0X;`?5e96JLhHi+pSUssOU?Ov&wq2h3RkZ|Q2@dENH|})Ruc-xG zT#L5LxTy_UWNKO!Fl9SXv*z0Er_|<+Cj53aL>OPG9==4K5c~1#YQv12zLS?9xvP{M4qj74%zaqOUug7P#aJ+fgRx#T}fxtZgy#m;LKJxo?>F=pu0U zT!!W3Wm7X(j?|YuqUuO=7h0A(?pe4#nu#&mV#VrccOmf)zrQrcPk=*Ej{ zT?L|4G1#or8Zp}cJf3NI;D#AT;ewsuvaMwBy2N3aB$Xy&< zn3CGqnptjQ#d=ecDi+S6aenf5T&(8aZdl9V<}EirS{fSH(a8D#8X(#EJtp2-^~2GG zMy$aMAnFT!6Xrq)_$WLS(bvj1UlY5RGS5FA01jbx;QHpRvRktAAO#~(Gm-mY77p(k z!p%vN3xZoI`ups7LuN%TWN+?jHKX2ma46sN4=&qRVECNni>5~bngcOmmG2wJzjL?gStxq2Ifv>^m0DQCR~(ri zGi6}-O#PAsT z#u8$2*my7)x$}A`+`AyRC+&_22Itu`k()2f_8yNW^&Yvi3{FGvxfZJNntk4L!R8_` zM`bOx%^O^1%!A?p=IpHN7v%D2m#)M}WfS@mVRY@09H<#az*uaj@;(+@fhuX0*u;hC ztLEAV#3OOZVO8$2BaE`F!66^#+5N}yimezqOPvhBp>c=g{x5vxo!%X5%uN0UGg5bm8VKS)U&LmQr zkpWbf(k2kZp|g)<@7*f9+v}lN?ekJzxNVuPGb}sCF}yKQ2D!duiZEZhf(y*hKiLEd z3{?>o=qQ2z2d*CW?!i@IV(8kaQz!NHg4CjXKu{FT96~ZYmWRd4>=Va>K#ntC>qzhQ4Y|6s~#W?2u8oJinf+c3SspjaFquFZH6!S|6z; zp$UUYYKIi$M)`qw`jIe>PC~bvQ3(g8hv*k>Y#ule!DGJ^UK|c2>=oHohWk zphN)FCZaDy4=jT_ax-#Ng48$`x&Tcb@a1^maJibS4N12SxRJ}83N~KgvcQh~Dx#GQ ziL8LpTo;pYv~E4NE*JueAq5g`c^ie;RL-KbkOC_jeSMzPBRa@4I|nevAgnzr&4kDzE-i7iLj~ zO25!7%j}V3a^YTFxg#b0_{Z+uxVrQ*9rmsR)BJJQGwfcL2~jrK*Ec?Je&qw_ap@;Y zX}7HB3L)2-kM<#GD=4H@dcp>DlgVZ-wrWS5X|{kkF7D@54>{Ge=(K_Q2W?8@Ce)k> zXE6?m;@zFNdeFq>5sc-QHff(Cbiv=IREWM>?C{$_A1yUC3|mOp$bL{UjO*&4BG8`& z>cl-{XbL$k29%o@i++LC*NAJPF&`?I{10fTl=|m{T3hXH!a(dnWoAhBK_5)2jVsvZ z9XNnb_ywwz|IKadIlrw~t=V6t=jN~~V_hYPLtirJDGWwku6^J%jQuDN=9_6uJgJtp zgza2r`ZLr`ELP|GOW56okHCf8sWdD>yrm2MbLW?^&qezKraB=7pHg$znho@Khi?f{ z{JE_Lco!SQqG+vN`)6byIkGK)L-hUyd260lP{sDYJoXo*4&AvC=iC-_u?K|>NF5MV z?v--^zR;=t!L#$Z?6d5@Ch*1w^4Vv{{c95MFBXn_YJxA&r6TRNHchGL1jD{nhG<0QJsIo zQBFuuy~nY_o%Upf?Sgegbf6f`46nhZ$*B;-<+Dz83@$VK=Z_z z3H8*d0ZYk%U5flCCiDtre)1T?|2d2hOheCR9jq=f3BN<(bo&onYBNrC|+F|wE-(HLw1az z7%YH2KpmkFv6n}UvBWVFJc8)*FeC8wH2%1@KblU?VyB1ZR%(6J1g4Xp?AiG|%jV^%IKbd?< zw$L$dyr6U)+6YpZ*`HA9HoOp~v{C>b1>O#bi!N(_QHeUEeP5T{>(b6lQm|0G+!rKcNpY$7m(BrO!j}t}zh+ zhLp`XU>bnU3&BcEYJyj!FA$mOOb!3bLOQj>Jw2^9Q&|RJ0pf#0{*=!Rac}0-M(Ry^ zkKt-TV@(?)Zgt#?Lm&;0bp{=J;riAK{k3MU*xXydkVlPGXRm?gP9LvwN#gyKAjJUgLBFaRN0LqmSq$CKg{YSWINrbHB7 zn^8_a&A7D3Qg2OtOo3X?g( zSt_UtZVtz29x(VxQShW%5Z+_6a0{ck(zwx%-I-%3=~val#lGzuEp}^RAL+kmz!=g} zYQZo(v}Zw<=5tU5($e79)S_{fZQ}~XM!$<(;g#*UCnRtDSjf2rKe|AElwlT6sS;j9 z&soN%?vHut*HuxDpNyw|ga5*nG(z{|IqeK`9qz;cA=_xzU(E z28sVoNiMG~UT}KN|Dm9xL81HbggWD;Ar+LY6oe|bI-z@1aEoGbetkW*-gDW zB_ld-LuSMmVM1rMq*F4mdwImb!=Id17Y4x<+bIQti;6i@J_nGjdm}XkdMymXPVb8G zL=Ic~XVe7;r(2ZFI}G9A^zTrc?#mI=kNEx=DBh{mElQRf6YAB89CfKJD|F(NaY<)U z?xlqQ@90g6m%9tg%ZXHnP*J&;;Hi8P=H=aU>7Quct3xyLE7_5~YHP;^;A?(d|Dzol zVrtEg?0>}A|E%*x+Y|%959hzE&8@lsf1psUvW2&nmsz3E?JY06Vjz|OviCtS%7w@i zs$hKGjnwM7VIsB2+ z7x2JQQZtsV4Ywawc&RP^SFONZ5>{?#`G7%aF@PmrZ+gEZX@7{Qa^TFDc!F?c1$n0J zhTP)qK|?)9r|l*{6xI&xQ&S^V^GM>Yb5h!dDOe8$Ez%g=*OAwG#5xaejKjs2vcV?{ zw+1odV|gAm%oPQYC>W|8N%n!cgvAs!mDy*-+g4@b2iU^thC&IvIeXwR2=Fi+8If%HI~H?67ISp%t}F7H9>1tmHCO7d zQ`41`ZO_9k6|tp8ZB>)bLBy%`rpe7cc4cM2<86=tE1P_mF__i$!#=L96OYyp%!vgG zK;m+vEl!P8c5n}jx606ur)F$DRJuq#tt~B#Lnm^g(nUnU$X+whh0Xd|B`~`hMYJfStMn~$uGm0+*~Zf zB)4_h;x_fJ!J}6)S@bEM*=sd$hBLexCk3FhaZsebI$B1Qz}D;%o#+6=g3l+5Mys$q zNUolld+`xa<{=owoxSL(-n^n+>e?U|ah<2x2TJO{g^?L5Jsz78ZUS>Xo%-mjWU){* z>6w*e2R#%%e@+soQZpOL0Mfpq9e1-87_uXknj9fiCLv)DDKTb$DZimR%}Y9Ojb1tw zoU_q4vqMQq@I`h}K!5bAmc2-%<2~CMs)p1ET>2h`SEQ;myv;z4+>i#z0~%oqHTa(> zvQgc)2Oy5{jxZwTWg>MgZqT>cb9Xdz01SUVV5+{#)0b%H#;vO7GO+VDB)9PTNl` zQoc~zMEtt&p>qj&X})y+*$=8wirX#3z_J>%c&fVUo%ydzeX$s8NIgxm*vt)K+$a2x zfdlpmfq$0l zBPEVwWO=<)SUq+!`L-YwqwrFf%P6|w9LzYwp+r!QsW8k_l4%U2Cjs$^!gHW?OyNdI zSGlK1-NR-U0Me2Z;yF7mf@t+`Lmh6uS?Tv$;9&J?c9l#?g-B+VbA|{b)xg3Wiz$h= z@33|A)|L@(JLo1G_h3cTDB>Q-y3unW#6B1&=C42*T(vD3-88m~>jA0Iuh{O5?TgZu z6GG{2PgB@J!mVvwZRGeTurci6AcqoSDiPl}%XR21pUAAt9EQtl;H+$ofQ@4}n)?2c zS=|-WbPsV&EHMYigC1uMrcc|uer~J#TG9oOOvj@RYisp8l3Ggx5V^+K?MR`<&A(H! zob2)%7HJQ(IFcXvKo|0Fjy}-vCrFbfcSmP(rjI+)k1^wLbNEur1?!hzCm&Y&k7u@z zQ1x{fsG4r?caSN#+m#2)%kqZvPSb}l=lUYS%YR>g(wgOM}{nLJQn~XgC{*>Bq zu~9I?t;!Lb&IIap{bf55cyY4}GX_zct^dl2D6VmqLrw@<4OS@&#B z2@t=mU$GM*XI`G!_t9Bqb{m!(<_*+Ww7cf1YaY3m&Zyas0Ki(i5~w%*OXx$zNA9I} zs_^n5oY_dn3Dgh#7S#`TTk>!S!n{JK;KNoGsX)lD`?3F`<{l1x@hfWf5)uuo^+uq6 zqJL_a#1?{3NfF2!_`q49NOw)%VDy9ef9IZ8@4~LQEKl@%LC~oe1NNW3&5_SPkA658 zwhmBOfNge{X9Vhu)?cz9yUR1WxM{|`HURqbXrQy{fwQTj2e|e~J)u2#NK$4-DIO1e z?H8VYBen2fWvCvhr2P&M|D^Wx+p`Y`hI<};dS--;ft22jPKCmIhN*mp2{=+Phaj8w z6nfV@8yfU!HG2bz@yL!0)O!)!wzxsE51-lB)qew7*-MiHHJ`wWqA}=l{=I}(%&KYR zyWYp3&uZPagF@T8?}kiXeYXn5!a;Ay0GG^oJRCBXf`>yO|96~wX1e0;GsM%9512~L zheIFyp9(z@kouB*wXXGN9pUm9f0^3QxBmk{L|lUvsLNV6>?gQJX?T*~R0odAuyVP_ zNR}lxb_8hDs=sYNcXT)MzM~-k=G5FvsORr&q6!lJU9Ep?hw+za41D70F7-l+?B2^} zRnk9}Oc3pmv9?(2&)ZQ4Z*3SD{CV|0ReAyW&$gdzpboWu-F};HdOY-9Q7tlW8NHhj zHx^F!1+8)akxgapg3a4shCY23#Dw<%=ohuVnfio(bvvP!RQ|>x&gP#975ib))X5I0 zKBNlF6baCDid5!bIl#lANmmTKUAk)6b0I(j1g_M7MLz<682a*gHFw<=X$R_W>|CkJ z?V>P}5SB5vacf@T?6R9`z$Cv;~p?Oj3n^g6Kw{5ss4D$c|l->0!;aI<*|yEY~Mc1W`hxf@!(h=5Rv0*{5T% zDJOKWu5i_Tt6i^lKR%&-ox~c3#~eqT=0N=}{+OCjzca9uS2jV`RyVp~`a523?zfnd zyU>Ldj;ahXZ;)5B$rQut@-pNV8q)MukO7Ipi8*y7NUT}6;-pdiCVs5D|T=ztx_`ImH-4@g}p`T~mV+z7+mn;r6^-A_fm?`BE7b?#5fi$^Op1mFcpI^=4Sdb5HAW`zg+Cd>q!qp~O}L zW*F!2G^B2}F|+xvo4r4F-`^g_Z#*i-kH_VP9O@`c9kmj1X(y|%Ny{Qmco{?O_i2h*^RR7)wcJ?Ns;(a_KhO2^G&soBK7HUa-k5V0tr>19G`=ebaTKG?;r_C5j8=G0 z%npj?9OHfqBpdX^C(m;EyOmD8!X`jqp-vQ-PzlioE<{f>xsHi_;os~$AVNF(VkYx! zZYc3=PV&yaFes)ZRj_M2Lv|sJV5W3YxKPkbd+ep+CrFwb;)+dVy!s#h2r20{+VQf4 z>L^b6hBWmU^()=Z(%)pnkLr&m@{3kWF`h+_i3@;k%?95DO2}3H1r!tLnI>IHjW0ln z*ilHG2L422@s9vc6RpTwog?#(`rK$dETAT(ddDmSNPtsTkRYctg#cOJ&_m3+3&XD4 z{o;iF)F7;b7=}ycPakfj`DCH_p>>)k$ui~N>Q6?mvLvhA6u}6^L+7zue~OsZ5X_<* zsXv>@6(QryvFJMEZ*9+@i8@vRVxnf10X;3^%>GOL71X03_n$hi{*sE)UreaKmaHM!gEN;rbn)a%V?e@$|b!8LX)5VHhu@M+{Z%(@T6*&0!<7i z8$58+2?ETOKJ7k29=HnZ5*BTWi%|YE6?~f;YQv#0Dwu0w#}bTk9mFyuj1xT=Bxpz| z#Aj9*f3r!OYl9^4YpiFs3xX@&*tS8%XMuy$J`HKohKX)rNt2~patsa1Xf z-`ep(%I4A^#+CTF1V|g$*%ImRaDV-D2SHPUL3?(=5tq}i} zLFU(*s3co8pDr&W1Oqm_YlkXZu43SfZpr-D5u%X99du}5^cTnm;(RF1@=$Ao)^VRO zF22G%Yaki#2LllLUVJyJce+ z3(gSSub~|ZHU;NE?9cCUm4Xf&P0t3*VWb?Sv4r0}bG7S+jsKwko&-r-wDDG&{@%=yhYMkyU0GfMzu9mj9Cvembh4t7AH_%&@X5_pJE_(mkcP&s`LV% zI~9H4x9~I0dbg9kAr{(H+ zGlrlaH#Z^;0Qa^^|3Js~B=MP$i{ofkdjI3ZSOST8t%Td6w+ z+=64dV(F(AIQi7*BX;E!+mO`7a@x=8Z6d@;o;RPa9ni2sK zQf|=Dp9&7Y>rOBPxv-zZm@Uc3xhtC9MB4VT$q5(t12eW@Rj_exM(ye1p4kIfQsrcs zB5<*}eVpG?!ut1ciLL{NY5Xpg(18v>V7G|;cKZ%$b-$8-z%;O3(#%LXP$g=!-dm_twLcqgT-`lAF?IJcD6dN zVo+6~VXoOxrS3`LE(8BO|XzBwk@+rc zR5H72C}+Slom8fB5BB3Z7{L>NJE5MP%rC+Uh6lHI0One+7D2(gLPlLi`Ot{~^}P7N zl$$)q&vNR+lZ648t?_C9U?(70DA(F_mlbp#)3(|GHxD%|fRmPfBXey48mqyPw)!yR zK|#!pXS|5%@zx(^ynmb+91u?iA-w!BBYtLZz|RbgH~)a~k_c=KlB$W8od~qK9UiYk zIU_#XftPX5qd5Ni3H^y7(&BZRmRc^?;ND%UXr?&JG0nOCk}Ai;@-L%D>M`mhY| z9|R298=E=XQzh5tIe?81;FCB=X|^ZEiCq<>334jWYB!i;;4mck5xFn;Mj5P^)it|z z5;Sskni@|oZLLeviMD!#Dv9^#9egt=Cvdzm)}Wx+HIf3tm{A|FJ+n-6j3Trng3SyC z^CGqaHh)?z{5I@sJoFa6kqh3+M@~8dq>R|4&DmMYEo)~XkLXMhFCk4OoHyKG){S6B zTczS2@=vXs#CEN&`;!by} z7r>_3U-}Fg5jNHXA|yka#jfo4Z8V)RLYwj)(ONM2Xk*w|Oov#DgiV4jl|U~syprh3 zZ|MOlU8!hzybNzP_^{2Cg-|4?ojLMY7X1dPZGznr#|cfqr(mw7cMQJYUf`}{Pnj|q zsTcLzB#e@{7l^~;P;$p^bV;nBEu$R(|J;LQ$<|>2;Grc6Ks-xM%F}fr8Zz$S7Ha^w zi*9H(L&AZ4txQ~&ZxxeGpQk4HTG?DQ?|(7>oHu}YrOmtD;Z{P=N$z{$XswHv`SyoI1Q9r>W8ew@J7U^C~i&stAP*Gob`Us#}qH2B5kiWJ{`&qF}K9 z_UJPq$b?9RnMG<{U!$4N1sl}Z8x-g|s3DMB66)i&iw<3OZo6HxA@p?uS|Gq&+{OaZ zZ*VZ9&=RBIQwUii$A)P#BhVhHbNXs4Oqlv8Z=`{Zs$%t^--H9K*ad?uU#Z;3Nx+8U zmrL?PdHy*q(6-JB)510xU01wiG&r%38a~(Nb!t4s~l7XdRfCDE%sv4=dWjsU7u)?)8xaS5_fV^aHBDH4a z*Nvum4(a$=dX2?RbqrRbwINgmdIO$g^oz$q1IW9m3~sutipiCEEsjo%45Q8;K#MIO z?gGoQJ6UGs1ga$EC-TIEen>1kJcBr4#?r;9Bd70D>yTY_4Bl)TtO{$(4#;m}r`FoI z2ST7U6fYfY9SGT{FvFv&2+2uiW$Wo~0>Mai89=Z(N99|Y0Kt@IfX=3LF+~ej z8RKc&JeDN2#82;V4y{LA1dcM#SXIG^E3T;9xPiTevF+z>@@cR2~97{(v22bN&I@ zluSGFig7AZhAgJi6MFRG-AM4!n}KjnMcwpX_5_Sb{bHdZEzr-xn&-g~1Dz7D)r7g8 z$Ze7)J=CThH9XrmU?c;%loUcBS$^^A{FHXdgkW>5apX>u<}onRE1?)rS|F)-^YWF; zJ0Wd$@cJZUygMI#=PdH?k(I?cD9kC4eXwdDRxg5qtffAzgCY^;h10ErD-TlnY16_s z)v3}q-OeF0kx;F@Oi}U}sH$Vr++O}7@6)3zUR!5rqbE6B#A@`-v*F7o0LXLg;)Hf@ zy|v)4GlB=neJTy(fxL8g5*#S@|N_Wdi2fuY-+PcX-sk? z9%1+9yz#b#otG@QW%1%IAZC5hJ=tI&@oab<6tWy{#x+DW?IR(U<#3D6h4f*Qyz2xh z!HIkqxeKpn2qF2Ng1|Z+ej&GC)azvD6TmZa{ugiii+=mhE~IzAnC$(J+`dy|We~#b ze|Qy<$V=WIgEERC1;Ve75ZW!2N;stOpza#vC zq^^nh6XrJ_a;UuE!*HNTbD7ru>*c}HuZys7L~`v&{{U(9tcN{nE) z+1iC(+Ew|Lue`u$H}{YVv81CxzhJzcFTh(R{pyih(>OZOw#@xz_;RJg``ge5h$QPO z_^5WVxmXBB9RWN%X zuBc&>A{D@Ld|f=PHp5BM#qnti9i3pJLHjn{sZPF$7wjg6qxNu(Jf_~f+i$R46r$lM zzFExt`=8JPkfvBROz|uEZ*5zJ(K8>IlLtst^Sy7xT85%mgpUT^2yOYvkZanT?hggzvvghE-hGeNS}50M07Gk#70>6Xx- zWUK*mh(04btg8xh`XLU1rTt$F{`6l($~&N#YTVcbhen$cT!kfcgAg;&ik|B0EFea* zuhNV1gX;}ZM?x;?Qi=_poc`=383o>Bh%NDciqh%^#a)kZmm!4;uYqe=rs{%Cj9YE< z1vAJs$*qI@Mr+Cn+hfp)xJ*eRW-o*Zn^QR6E+gZgpa*bWnAUs`=aoL62vJ%@6j+%B za_)3<=*8*$IDFPU7$WV#W&i5V6MzCWO>~&sj6pjZ*&l!r%e#3SGRTiDz|bI<#{eio zF*_0~{0nAsNl&3oFQE89h!tA?W#+}urD-kl7IQcR{OT0-SLTvFn%I zQV|*x871CM+ZT)y3S)L8)ZUde*)jkvL&uVCl=NQ`ldd$N{F*(^6gDu2;FyGla|E(! z_YOYf&N_d*g`K+rVe5T9vK}i*eP)UaI70AXCTCNF7KJtd9X@b|D-vIjJddCf8Xr)Y zGJTVUR~AurJ2H~>r*PmfCmD^;MDi zK*7~iWi2Vu(P^4kiqM)HxLVC7hxmP;pS4!Wr)Y&RB?6h$>@#6}o7<#mn55U>V*ui1;Rz4V(~D%&}QDV;(cZ5AVM(jV-+cdmG#fE(72QJ&7ww{ zF8p!Pv0t0}-gS8ar*dRy%(c#O`G(F%AF1z{-Oy8!RFGB~i+I|0jPIdk`}D#s?V=mtge-``yv$KVqB~tnkRzhAlOqblea6s< zWY?Ob3#yVI;bSy7!DAfyDNUh(>ycm;F}z)7a2@Q?N4XjG3QdvIg;uR3D!Ysg<&*{s8@vIcak&^%@Y_$fgAi56AvUiXNG4mb>V`UE! z&kW)th0`V>HhCfCE=NcM>tw^pl%o-mJ$tEDRJemHB;dk;%6fdT;i=O1EzJ=Gldx_D zA-wWnr=8ZJOinwEi16(57tV3b1nM#tj3mrekN~U{P^K5^JTjn9D+!Gq$phv-*p$m_~;O5?eqpV0^Jl1-mmxoGM{q(ln^%JRAg;DN8pr6S4b;x_x23BBltH(f;JwPe(BudPT3 z1-XG>b_cCS?SH{C^CQ_*LBP1gB|+^#V+l6h`L}_$*f!*O_3LY2F*o)K>9T-aI)2)- zY|vw`|Lukm+C;rya=!*pWwUuPp?Jlhc_TGLBHt3t2OovN1~ITM(V{r=LnR9))=xf^ z{|?fgP$8$uk8b>5ZY;E8PMnZTdG!|R08rG-C?n8y0sQX`P_%J5lu>#SLwO}-GgXJo zJ4S;TIvUI8^?E8+@TpLp=- zV*{&V3u1=LM915qc8>o^X#@Zir9+s#E*gu?*$HC5N%ug)C+;a`-k9jDUkQdaV zPmx-gNsyu^)AU?GmSG0@$z~BkETokBITQIAG&O(YVAY4w(LfuA-X<_hnh_MbHWYB& zcU-L_piA^YDBCzKdYC%fE)}X}<>jNs)K~Qmc>AFCYv_#|P5I!$1kQ9bdF|A1sJzMQ z#dR&ZM1;m^l0;^ILe`1VA|yEpOQASV){G&zL=*L7panlSdGMVqu{~uV5x?tL02;u< z`p(b*hW~es`cf5*DHW-1)36eMaGkz?rtJB|Kz1H{tn9j%4lg^b&lAgyb**OTN(LGhu2K z0FNpWe&=GmBt{XbnY`Y->I5A_Zf@>+)6Z=lr>9O~&lQCD$-6HCS#X~Uje&k)Q$mVK zdmHe{)X^tKzz0+1ZbzmGHCYbGA`9<@&6q=A5N&N$e~_Y1elT z>PR971FnI_6e4*7@F?}C!cLIY_hiE{h z(hYq7ZbJXX&vSOGyu(}R=buXT^8NP-{pUZ=>9>tGotpi0y6@?K{G3-WJv87pO3nY@ zmHL|?eR1@2!#52+hYOtWzyBHd{uUDA#6Y&TD5;DoY*o6u@@rz0?4HZ%HPH)q>9S(; zBvez34kDq=8|dUeQ5AEsb$?}LhYH3evAmx54HQX9Ae##>>dQ%dCeahn;hjBW&zia5 z1~Ny>RPw>W0Vx4J3XBE4zi=)y#yVUp>aCrJ);c1HMA*?oYqaXEx1Wph1{kju?52>9 z*`q{Y5bSF=v}qd) zE#Ge`bzbZMB?@hFNG7&TSOBGX;Sd2S%Je_{rsLcmN8aUhC8=uw0K z$~kci$&BI*A|;`kNVL_66S$~8V^df(2A4biplET4PAlvH!(15KcLu6C2ucd4 z)0zya#rSpH!qLPS8~tH4u1T~^ZU{VqcGMSOW41al=-@#F5qDzved!bz_pYc&9y;Uj zM2xPpXw(`+7-<|m+JV2p1D}9pYM2dH698!>nf=yt#AwGLi zQ@b1cE#C28@_%f8N5Pao$;Mf`fb~?Nng;&V3YHnJT<2*`&P>Ct`!|wnjUm z9Hw+Ay?AzSaT{sMaYQvtTAxby1SprV6P`vxW)Up$uH!H!|fBvC=G#lJrH3-R)p*_ZzXYpr1U)y5y@(wQ6ndj5QddDWeA;Ip+ts2 zUbl3PLL0Uo%LtS$94ORUK%|IR!Bn_b>#eil4HTB3+!C=>TUv6~G7q{LeEoS+<{wcO zU&HHdL=J%y=?dhV05BRwnF;pOgGhxyc1?Iq?1%k)fe)g=pW}5{Tq(^3Wwhocn>uep zWZQ{u;|SV>6M-07rs?GT=sgxjVieqz4SU1?A#`AYGCnX@g95~SEa^%6F$3cLvyimW zH_T#BGzNMNGjBhIQ3P%~C}u(dC-0Gzy(4DOcjj8L(Ynpuz(@1ZPf$+y%(Z3o4Tc$x z4P{XbRw*HWJUnFgDfj^8ag>_CSbx!i1yVM>VG0>6a_k8mKv@5OuYUJs{8y>n~^^3P6+-|n=z)NRev9=HUoJmoKlXIwd@A9haoG^ z#UzIGx-qIvN}&nMLwZa`XwMm;{r_P}{lA}l{e_mHpB`o7XP;%n=+_f5dJ>^%rLHXt zd9c(?I}TQ0Ix*|iQGDTT`48s2B?FIIZD*XzK@g^!8Q2PM6-w|)BKN6cy<^TVZE&K9)Ym;Ow5G1dTvSw&!Sc9dV zGDFOx#0-H;;er2Uc-T)Kj)%cJZ#n^3)8MBm%ittDaPa#ykNa76NvoXB4fea9y^a)5 zgokhyRQ`n+ZRb_t3NEuj^dP^AtBKH7?AGu{B^#94L?e-4*8W2ma7jU~Ui(k2m-xeF zxnpj>9(T~*-ZW(?X!kO%5`kIDiO)=G4}*$NqchqQlj_yeg;~V1aD!AlYt6v(MU-lgS-Yha+4Y{YeHT#bQT>YOO zOspwq*EIazsAZ{-a|LLQULRgT$*zRJ7qfsrZ2^CG3h@3g;2<;hB8;(HxtW*F?Jn#t zV8do!Ixl}iz~|_+5BONuOV=3;X6 z)I@OK!XyAlgYxwJ(T3#dU?lV^x7NOz41V|$flGhF++{d8Y$OMLwj|;>D6Wd<}CS zMVH1^_KHRy{?~VGZ=+|Bwk{PY_gZ}f!ln0z9qXpc6tWm|eU#8=|68lLmB6GaxfF5a zy3+xJItV5(r7ST!T4@cxTHN7so=;zlo49(XTBn!C0WZE+uTre+v|3k?YikL&t4;@B zG2sk4S9xEAgnvlkbof;n)<@=qdp-CI{f;wd&Rjx<29jQ1a}o@78n|A#d#iZR>*1Qj zXP&9Gs@;g!8bk2);;7zwhS^(Z`S_W=J}zH;MmDs2)_nNPJVzDZ5WI1w7h}XnUpPJ3 znz3YZ(|zQ_}Hc2fP(L!Gd*_Jo~Fov=T7s1fpp zx1eOn-%t0sp`|U_c=4uWeFtcOsHVr&zfDWK`TiV79tL9vR30*V!_TF{`N(n7^nthAz{pwMEARV%irV6ke&)*t-jTjy&cR75%#D8Y z9K@YH)<@P(I%;s4>5fe=CJ_--FYErj_*VR-Uj|Hwv<|uyX;3xDY=szy{(Yk zv7}f&8E4DZPpwY26knRQ6t|}(OlM~nAmu+k2gG{3UP1c(baytI@|$Ab5`UG__S{V{ z(nDp0OktG*@7;4=yaG`nLtrQPPTNkKnD(V4(e6~FHGulC zl4P8FKhE5w?N;c~_DX!s{d4N<+BObr)$Y-H&Gzs$ofqPj2F%7Vi9$puhf>plA!%u1 z&v;(HSZ<#C#$qhxxWlk5$2V?*Sp{}kiLA=Vzk_%zuqYQ5HojNKb2dxg6$ZRs%YAPO zNj_TJaX=${%Ratzb@ENN#zlqX(K-E@Q&l=TrK}gEBO&ZJc?Z=t!vItsCr~NA6 z*IN5k#INJ+*JAuS!G0ZrUtRWV34WbuziosUM6}z1dE3X$YI1hege`kLcIlyXAX>u6yx1&Fp0HC9n{@_6+$b#ZhaX-s2iHrko z@ECV(oWZaf!W1r6TU_i86fJnOjsEN@?j+J(hZHY1=7kQ&V_bEkZC}Lf>Z^iRmKF6=Ew6Peu_Y40K|rLn92OdXJe^}z5=WYdNjRokFAI^`=oGNq3cTI9sI561TC0HN>t5XkX5GIkLxqnd)? zIW|PTW*w(ZoQg$?Cf1~-_!fM=0wobkTbsdymZnitH)39yiZKI&<>u_<(BgIeDQ!!% zhT&FWJx0*($&O97$4`Bo90q+;nellGU}L@+W+<=Q1!Qsf+UmuSN84hR^|{W5tQf=z zRFw3|(&8D8>i0cQ*@X<;U|%iua_g?#M4gn1d;LSf@9JZMIT>et92^v`wVv_Xws9;A z>dE27eVcizrNyL>Pa1ZEIWlMLmaNMS865LR6(#wN;-RT<=9K3;whxQNoOZpF$DcW^ z#+-&0?hv{x8$^AY6w>w$`-I%90Me}Ce5)BrFZs85dvLZv4u|)#QarM=iO?>TIKH0LQOb*Ca=_oXU5(aH#16 znge&BpRHN_{?Hdkfy2mXL>M6CuV#5c*!t)w?n3)0V&}Q9!Y;df|5j{NcQLv`J3rj{ zXaU!DufsHwr?*%e9EdA$Ex- z7w(5MqWd8qt_ZW4a}?xtw3UuFf%EBN?NDxm|M&7jdRcB66%e%3Fc1JhZQO8ZFd+Fa zYBC^kd6sr{qo281aL@<&p+PSUg%B#XhVo$8>@ZW=dMDQPHpum~xSs(PdEG{MF~BjZ zO@8|rp4n{UX%hh_PpmX$>RPLSNx8X=-S#g~#I}}}95rm%ZL06d#rr_Ny1rQ& z?84?O|2hOaduhNOwppJOC;1AB#r@3{m~>sJhQZvUTW6-X?%K+P!>||~ZUQj>*dEF# zKTUX*%kmT3Chw5Q7z59!klR}ZV4tf`Z643P1-2wtw_P(a%?ScF95k?#btbIypZ!7x zyJ<@bn{+33Q)2jTqQVC=(}SM5b8`L@N@3Lsq!}y+VW2>dLR27>An&-dPqw|@2m*Aw zXF_#x^318?RIa9w0x0WxIZmk`j#VE9*gc2@4I91YzQgn{eAGN|uxS#n3Ds}ehOAjQ za{;q?e8DbRPm+sC*Z;f*6>ln82KmiC`#yOl* zBE`C2hzvjl!YDhucpdm$c^c66;5zC?WTCi(5#`q|$Y%?s;3cTn)~sE-`oxtQ0oX$T zk(A8BaA@a!9^ZLRl6<9*B!wOO-|gwfVVs75sB+@!XY%*cr%f4(~dZ zk&*E=5beEscQJWKA?IYY zxM4<@wsz!CmTN;oXY8-1rafr;_OO9^e22^gHsbqE8L1DQ2LlX`nw5Ys<64r8EnHQf zs^Wnl{;1q;t7ia|?J$$zeXf@C7p|pSwM_5zb#z%BgL|86m|3`nPSwDW-NtC6!ybRJ z3hwn6Ep5%6JiEezdq;;X@e-Cc$of<)W3vfX7uDV9@D*64;n!-M!9$atE3UC3PWsW+ zI_EemDgJ2I4o@9Ci|e9s7F z;aeWc!uQNj7QWvMW#M~PC=1_;P!_)5^5x@%@7bX&e9sAG;VXx-@I5z_h3}|P7QW|& zvhb}8W#KzIl!foNLs|Hq@5`OS*A~jcw!gp*a z3tvYl3*TyAUMqZSLRt8Z3uWQ!3}xY48_L3Wd?*Xw385@}U7;*|Cx)`{tqW!0d!a8M zFMR7mS@<@DvhbZ0%EI@eP!_)KP!_(PP!_(ELs|Gv31#8i7|O!e>&qty-=U-^)W;_|6Dr;XBipPZYl24Q1gwE0l%r>`)fIb3$48UJ=T|wu|DksyTiND#zbksyr2ksy#Gksy?#ksz4oMuKpj7YPEo zI}(I+ED%-;>3Adv=|m(5>0~4b>G_c$q*IX~q>V@r(&mxx(FNp*py)+Vp^bL_9q;CuaH_==c2}1g&ND$ILj07Qlb0i4q zTOvV7FOLKveQP8L=^sUckX{i9LV9H&xGCq4BSA>7iUc9OIueBRnn)1Rw?%@GzC99z z^x8-e(sx9Hkp4*|2u2mha~@}BSA>-iUcA3 zOe6^DXCpyKKNkr?dUqrU>E|OsNWTyXLV8am2AyvSkUksN8wo=C?}6avsK+8fNWT{eLi!((Af(@q1R?!FBnasbBSA?2GZKXKN0A_;k4J)# z{x}fa9Q9w3Af*2t2}1glND$JWMuL$3EE0tD=LpVR*xZ4vfUwo<7&GetLMLS}kur*+ znLLWg#|vqRwvFU93)h6iVXO(ZprLx3nN45;8mhY*7)ghyDf#%5*DYL4hpLgyu-)pB zZP8g@E?wF(;-X%1aq&F3h(VJ`G(}Ie#ZoewZDQOd7jQ5RjBQKaw6t{gYl+uOIQF@|xA@^hPM9gHlI$M{(tig_{ev6mBcrQMj{kSK;o$y@jMY zuZ3vK%(#6U0>r`*fqmONt=FF#*t!Czs4`kCy?c=*OG$saC>jaV8w$&KYc;*U06Qb2 za4%mvH)GEVm$HV&6rZmrb$NTb{qfRiT3pn!yeH*NzskSj!*=?Z&ct+<_Pp_zzDaCU zvE*Htj z_=)L>;W``*NX6@4;NPnktu%;zh(SV*@tt7 zI|F>im|NwTt>IEf8pF_d@aZB+uk#Q$0fPstItlZ-Ikt6*CE`#<;hoq^Hv{)W^Wjz5 za_3%5O09&BNQtJ_&4YyHo>3w&`6JURVj#2f0DL0ci|uj(?6A9WDsz98$?U9El7ncH z$ue*Cc^w$$Z7~#9Tef`T=rG1=nsnpyA1kZm?``^Kq#@hgm@t0y*Ikn$J{nnmmiIDz zypblei(rzyuB@UD;#N?Ad6k-K&5%j2eA?E*UZwlso^(1c7!3q(jKvtZ1Z?CJ9s6R3 zJ=4*_xNUB$Lb`0Eth|RAOTh4m29Gfg7*I&M%q(*Ca{t73ZFC2FAmu%|pLtb0QWp`0 zkv7b92FHxmA@1SL8+|35Y{;Etbtt5oolL*lFtRAjOdm6`%ia7FWh4aOGXu08rOF*J z3h^OYaN-EQ&~nT$y2`oveE30|HJS}+?C%iEU{nKpjNowy+>;eG^ZLP)DhTX{E41AR zgA0sF7 z#@_YD75sewi1h)5hk=vk%8(N79jXMG3X!!D9FfngL)R3J(uHRWA#ik-kYnHyZX1jNY19_AYu9+^I72w^c`I`+qIV6vL{h)bZ3&10kThw&Ad4(wcA1U2yb zXk(1u_z-=q)?N56{~U4|AbSIA@)?}n7h5|3KgJA?!nVG_v^S%WAVWJliL?zo-|=K} zm;^w(n9SyNWS#IC1d;b+k44vzjp0~j@CqtrHR@P<0GUFWAI8JPL-ro)J;*aFS-wrW zkF7ae!`ab4#^+Eg;GhJ{+UeBhTeOrb7({3yotJ}p{K-kS5oC-l%wdMql5nwaK>)0q zF1Jk%Phrd_$?L#d2obUr3~b;~9Q zG6X3ic(Dps;VRaGmdPsdg@aS0$P?n9O%uGc<(z|fr;po!3)iAiA(q%Gh!`&ujh$vv z@zr`HeRH8;dUq+*`_aK@=rK05W@gO>7%AmRUTc!YS&CePwdEbgd79Z9?_G3hx}@vX zA3Qrv;J5}A<)6bn=l=SO9&TRLT?WIV$lAGhDJs?@fP9n8&!dbJ1QH4DK4X1)Y zff$}1xp5J+wDqW}-~KILZ)3|l$DK-n;pZeb4m|SOMb>4nrqnVXf#8JbBwxbgZaK4~ z^t937r77Lz9HR_v8$tA)2}lzr7AV$+44W9|n3880l3^K<5Ujd!r&{*rMcrMW=`ywO z>i7TH9CChscUlwBdiJI|V2u#s8Z=z|b%ab{fL}0iUOijkoUnH+y0L)MEu?f~TOiIX zojt~v(MHKDR`S0{+xOLTKRa^GlFHkO;e>Bo^^*%P|KUT#)%~+|_oa_t`L;vw`x)=M z{qSVx2R}mk7jM7%s_)+O<|7OE{i8QN|Bc^#QSTObu#*q9FS_d8Cyj03@6F%-(6a{L zP`ZitUw;2rm*4coFPy>Ok6v@<{tv(6(I4{J&wl3UZ@hEa^Ip&UM_zf~OTP5#!Y6sp z2i7m1TJ@aoypg|ef5)Y7*?QJnU&P-heEMTY^xyFA>v{k8f4=Pg51c-ECVy+9ySV&f z7X)JSIgjFXM@vDl)32Si4GgU9!a8Hu=-$<73;dtr5p5@u<5Qtt=Pb_#+^KIP8SUT}I!KFAejXHZdm`y9S1Oh9 z2`oA%M|an6D&r`z$=$A6e+meWS3bp3TbkN_y7HlxU-isIW&GKE;3V__LuASuY~q4y z0NrR{WOQu(fF)^l_pEo%pM=#3&!^gQ8D)EzCv4+ zQPG*=222d4Cwb#4RPLG3x0}xZjRA=12(2m|6kGsROEm_T)Jo3OGo%s>OBFN#{!vDJ zEY^GnnI7rH0#KC-UY41epB^6kAltiTno%|0jBt#@@dU` zRTsq3m-rUP=LtRxnND!k#*SMWiI~l`t+WO zDQw6{k;M3t(mXqhA@CkrI>!cXHDRS%GE+rzJqe7*)Jq)(#ZD z9|Qz3q6;87U>~tTqCA-oPr9lQb26tZu&sfi@mF+h_hIhMOU`TUl^A(2CPmeWhC(dg zoRJR!`PrZgGhUz?3>SApt`;Bk9`fyS`Q|cr)^U;&;>3m!VTug~qgoDPBBrQEdVB1_ z!iJW3h-R969cnSQG})kuxF9buFEf8)uoSqBbBuRJ%MXq2M6d7+2%1?oPeawH@|Z)c z^)Zc7+{`|Is*Xhl=6aJcU?y&7hb6#<4n;9E1=NI?VmvT{m|QUN7BK%rHAJe34lriw$ASn%Y=$ByP>}zl(J+W zH>WxARO!ecQ=@zV*>Y_qPiQ6HK(PrM1!j`iO>NpG#*=i9ihVM-zi9h~b~=m=UtTS8 zgC$!A^L)KdGiA&DTnRqJBXo?dXaut}1D$0*cU%Fp8E55})@Q*ZFe4h5WNo24DCifr zTnjathzG$iSO5ui8`71HS9c;rKeUJ*hwQZRU;_YJHZV{lm0ZV|3%6(eCQ<5B(5-WC z^fs;i?y8AFRyI|qm5yf!LTAJOIjPfR14w<4iLnZM(9F#xDBwb^HC}kPD)BM}V-b}> zz4j-1aAFDf+F&^syR)<89y^u@jDV4h>$EOt3k*6x9!>;Ffp+%-J;U~DjC$r@XNrx* zExllX?imlvHD?$Pa~d%o_i5|-*rIqLrd|jsHclQbB-E9PZ^# zuVPdA(+G2iXhTI~_T2`yk^(YTJE0{Sbr|w+QI=5~Nm%;u?GC3sf#xB@p>nsO&!jIh zQp2iu0Z%}H5g-GPS2(O_YuSO@E9a-E2ZzVnjx3uBti9|dIHZwNFbJqyy^N6#>kqXi zJCubp!k{-b8;a%@LaW5DKqt_tVJ8h?ZbW~fD&-YJCReQGcB`+DY)okn+?%-~^kb(n zW0ppYp3!MYczkTmFl<(E*NJGp`X0Q3!f2s>$&xCW50!9r#BDOx0F`y?U|FAH^EBF4 zWj4y%V27j-ch~Y{@rN>h$4wRZa%-{NE>8?kXik{mxD`*0#W{g>hIar9W==a-Q;P*~ zG-pme5Scu$Xc*rbZtJrw!JBD)+&ycVlDUHj!W(^Z zdog!5oQthzo3Qm38Ccpm$m)Bu1S44tCxaH{IBjOIRnTaL8{3;L`rIqaz8k;_#iSnE z9vqF$$1}#RIeE8_ypBGHGUsj4P6>q`hmn?HGaYqO19>V$Z|ehw(%mGGrlnDpw2FA7 z9~Yza)RFr!D^hkshs2e_FkS3X)Vh4 z+V_NM)hz6lzRd%JTTef8$Hw0N!9L^($7@VZaJHb^4Uo+>qA#`@sDSu4Nyhq;-fQd1 z_&&9eT5r{3;q`nIWqReT$W2Jd+=QpS9IxR_>GobV0?+Zru_=oezpU^;2|C>Jy)Xn} z5x~Po(9WUZxVIIr$;rJ2=L~S364={DMNHUe8X?DwX{rF`f!*hUGr@c0Lh=H*((N#A zN)eGV&)cj$si})hjg1Yp zXd_u?yC9qhsLYpu`R6=aXqM*s5?UUyNm5OzgpnG~GG~!j7H&g~cPym!>_N-L4%IKI z#vg9Fqo>rTtCvhJbObbUyr<$D=s3ly*;8e0Lr`U#T zmqZJzddQ&pY%ncw5DcO{T`L2h)DM`(bT~G|TmVE6?wD}}W;mSyn}#2u@{1kbfCiC9 z&ukSwC>>ETG&(gjGX{BVOZc{WHk=`#1&X{S@mZC1H)s5Um|aa(oIv*_N<$n1csmuZU$}50<9$zzI{}!NHmH;scVV(dscnp17=R zKumLFIyGx}a2H0D^W8Ku%cy3zk(ag=W()gF?mfYOS~jGRiOg|DRWf#Kbgzy%BfWjA z8w>VYw~ls0!vkx-mARt!;G`=4pR18EuE3)lm43#wY7Fkm2AzJ|uNBRJ^l!i7bGAkF zQC#zQM)es+UAhd&m!>68mYg4T55xw*V!`AJw1Lcy4>`{oWB|!zm9r{7jh(8&{&W36 zu2BfFsdejMAK2mEf%U|et*}d2AXQ*pjJ?;OuU3vi7}G=|(;d243Hx#r9NLi&gI9rv zl0COHB3EJo0IDffNbo~5kJgL3XWJ+^xoE~YV0e$|2Vx@UFrj~nRx4Xu>xMtI{5#BO+Pg{esJZ5)6M3bQY4 znh!STYJZ|;ai2|b)ef^D)+gjMoc;?dBWRqtI3=+icfl@LnWs-eUKWc{LX;rFpJjw% z@EvQYT3$x1YbHZJE+6Ft^Crz3&_!x!5Z^0RH%r6@;<^KhoXc1rdsk;T?$nH+LyPDU zDI+cyRyQ;^!yvfY>#{cDCxI;**&L7G>k7rgT0a-UvYhKKu6IIwmI*z4l=BH@zl4|Y zg!#RM2+D^6Cp0G#O3*#@GR>rn!U6+gmBD$y)~{GEV3Ee=gP7up$6z(~UL|h`vfGu0 zCA4Ovd@PnzQIML&5bfjNfUkpT6&^0fVj4b3=$Ttv+Eh@pG#6R#?0UVi1qQSpEWg94AbrID7TF6YO|#TaqCZM&Cnwh;1n z2ddOWPgY6Vd8K{7YKY3QzYVW$w$xPGFJ>r#xmM*9%3QuXpT!r)lRp%aaz(!&#cN!2 zTXVoJ0gsRTHWKpLC_OOaMNnGxjm8vMEy ze2GPtKUw#{C~2wK1Xk0$rx~@Us%U#~3@{eR#!UiYk0V^Lu6B z&}rCcXf_7Añg(gJ+c0{#4g5Msq1%Vk?D`tWL1{@@915LfSqq>tB2rF!BL`Yk+ z%QpdWEiP*G*QYQbO05hDEKcTzu+tkf^1*}IdTQ)=$3~|Pms*i*nXbnJhdtNC5TJBL zTLw$nK4qyvpO_MXPRaUA@!LqxN38Q%sIxUiFVBqaL^B6jVwFQdSV{Rh? z8xhO^M-j_I@*uCWAkvKTxG)Sl@*C+!#+cYZC->l_H%xJU#%kFG}2rDM^!h4Gq8DOCbcPB4nji z%TUPe17cL;#NxD4wk!oDG=r$~WDK$2G>5F1BpU!Lp9}{A(VMMuoD5G)m8O%;1}B;H zVy8L%G8Q)aZq=Jc&H3Q`1_Q8;srPgkDR-&n8fc$n*D1W2(NbNw=-Gpg;K#klnG5`21P_=wFM8$` zJn{RC4^6t-a5b5Nc8Nmgmyg)6zByu#k;)(8yJnkT^;LcGo ztuv8fxw@=+X9gDYf6JYJ$0D%jv8lx608}^*WE*dm=8i&x?i@jd3B?8G)0jU!aj{KR zT+m?cFL|6C@On~@jghp;&f>5f~6yOA<(9L$@6dYU*N4e$}JC)NS zjVqlvN0Y^gU2Sa^?Jj}Y?qh-5{i&CmYpb}ygxl`a?>D}TN7*R(au9W z=AOzrT~q2HXf)!L9rg6J)J909nY((#SmDm*SCv4CxIeNa9LNlQUfLNbo zS`(x#yf|FXgfqNCBU;O4RC<-)4Kc=bD7`fRFUo%DE}}coGji3iVIXqZhsOAMoxp63oTR8{T{0`@V0!ueGyS}Z z0|KCx0n}R^&M(lqYSl=!&Ty-F)6JM^+)8?(@B(gHQJ07Jk|at1l}eAJ`@PUf6}a4t zdcL#a@!`)$SHPdXkq%l#vHXlyQ2Xo`x`xn!G_=~)q6T1?umpe!Tt`ZEcC0$5$tPL^ znR2A{v)^&19!GwcIgyYhQplcM0F^~$Zy@XB1|A_9k?Q3iicM>b=O>0dC5w1u$ZupH zdsH^{O&n19N#DTFs65x}xJTupaR&Gz2~A=ZWM z1GKcpd=}b#>*-x<1>hac?o9qT3A$xRK@f!n+h<;oKHN_DbLM*$hY8*gf~O)KvjK3b zI4e7C$Bp}YheyDuJTA0n-z%Y8DvcqX$}d-((>{=jTqrtgeY3jma=Y8)UdI)C=6_uu NniKUY@gwsX{s579rKbP@ delta 686 zcmZuvL2DC16n-%b>YwoFp$Cs1{2$I{D|qPT&3hm3d+&Si&Bx;RV!BTSnK?=V7zUWi zYM=vX836Sb#_5HrhbmN%3Y~FdyX>0Tf!_{>T(CaPw!9wY^&s#9Kv&lv4Y@sd!O0$B zE_vlr#VRzoJ8A~r9Oul0 z93_x-Wggu}LVBoz?BlO!9-)2t6BjQ&#Q+I_5&+g=qyp{yMCuUB%UTtI>}X+e8k?Iv zCb|yg1IBy*#OI#HL)3`t0s{D@Df;?^ej-hM38!_rs^_NrhQg~8oEg&BZ(wT3FZw%t z#ge}-%*i`O0bh&V_r^`U7`s1=1-ulyQ;B)JVjbrb-;#Jaf*#|$mRz1)ohhJ9Yi(_V z+cX5Y7iS;NUVpoyJ(77&RqDV(}hRE;ZV=WKPh`rWOFr# Tc6-~D?K&dNo~ijD`x*WM-gvvb diff --git a/codegen/src/lib.rs b/codegen/src/lib.rs index fde77ceb9c..39d0f826b5 100644 --- a/codegen/src/lib.rs +++ b/codegen/src/lib.rs @@ -23,7 +23,7 @@ //! use frame_metadata::RuntimeMetadataPrefixed; //! use subxt_codegen::{CratePath, DerivesRegistry, TypeSubstitutes}; //! -//! let encoded = fs::read("../artifacts/polkadot_metadata.scale").unwrap(); +//! let encoded = fs::read("../artifacts/polkadot_metadata_full.scale").unwrap(); //! //! // Runtime metadata obtained from a node. //! let metadata = ::decode(&mut &*encoded).unwrap(); diff --git a/examples/examples/balance_transfer.rs b/examples/examples/balance_transfer.rs index 6392c686bc..1ef07256d0 100644 --- a/examples/examples/balance_transfer.rs +++ b/examples/examples/balance_transfer.rs @@ -13,7 +13,7 @@ use sp_keyring::AccountKeyring; use subxt::{tx::PairSigner, OnlineClient, PolkadotConfig}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/balance_transfer_with_params.rs b/examples/examples/balance_transfer_with_params.rs index ee9bde04ce..ce79ef00ab 100644 --- a/examples/examples/balance_transfer_with_params.rs +++ b/examples/examples/balance_transfer_with_params.rs @@ -20,7 +20,7 @@ use subxt::{ OnlineClient, }; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/concurrent_storage_requests.rs b/examples/examples/concurrent_storage_requests.rs index ccfc673f89..acaee188d3 100644 --- a/examples/examples/concurrent_storage_requests.rs +++ b/examples/examples/concurrent_storage_requests.rs @@ -14,7 +14,7 @@ use futures::join; use sp_keyring::AccountKeyring; use subxt::{OnlineClient, PolkadotConfig}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/custom_config.rs b/examples/examples/custom_config.rs index 7c784d1503..e12977c223 100644 --- a/examples/examples/custom_config.rs +++ b/examples/examples/custom_config.rs @@ -12,7 +12,7 @@ use subxt::{ OnlineClient, }; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} /// Custom [`Config`] impl where the default types for the target chain differ from the diff --git a/examples/examples/custom_rpc_client.rs b/examples/examples/custom_rpc_client.rs index a5fe4e0d98..474e7a71d6 100644 --- a/examples/examples/custom_rpc_client.rs +++ b/examples/examples/custom_rpc_client.rs @@ -64,7 +64,7 @@ impl RpcClientT for MyLoggingClient { } } -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/custom_type_derives.rs b/examples/examples/custom_type_derives.rs index baa7562e9d..b6e146a601 100644 --- a/examples/examples/custom_type_derives.rs +++ b/examples/examples/custom_type_derives.rs @@ -6,7 +6,7 @@ #![allow(clippy::redundant_clone)] #[subxt::subxt( - runtime_metadata_path = "../artifacts/polkadot_metadata.scale", + runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale", // We can add (certain) custom derives to the generated types by providing // a comma separated list to the below attribute. Most useful for adding `Clone`. // The derives that we can add ultimately is limited to the traits that the base diff --git a/examples/examples/fetch_all_accounts.rs b/examples/examples/fetch_all_accounts.rs index 2bc140aa06..7d51a1205e 100644 --- a/examples/examples/fetch_all_accounts.rs +++ b/examples/examples/fetch_all_accounts.rs @@ -12,7 +12,7 @@ use subxt::{OnlineClient, PolkadotConfig}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/fetch_constants.rs b/examples/examples/fetch_constants.rs index 38762d29be..379fefeb8e 100644 --- a/examples/examples/fetch_constants.rs +++ b/examples/examples/fetch_constants.rs @@ -13,7 +13,7 @@ use subxt::{OnlineClient, PolkadotConfig}; // Generate the API from a static metadata path. -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/fetch_staking_details.rs b/examples/examples/fetch_staking_details.rs index 980b430528..f1a59d8e93 100644 --- a/examples/examples/fetch_staking_details.rs +++ b/examples/examples/fetch_staking_details.rs @@ -14,7 +14,7 @@ use sp_core::{sr25519, Pair}; use sp_keyring::AccountKeyring; use subxt::{utils::AccountId32, OnlineClient, PolkadotConfig}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/metadata_compatibility.rs b/examples/examples/metadata_compatibility.rs index fab4f770c5..352ed4c02a 100644 --- a/examples/examples/metadata_compatibility.rs +++ b/examples/examples/metadata_compatibility.rs @@ -12,7 +12,7 @@ use subxt::{OnlineClient, PolkadotConfig}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_tiny.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/multisig.rs b/examples/examples/multisig.rs index c9d0f6c660..718ac4759a 100644 --- a/examples/examples/multisig.rs +++ b/examples/examples/multisig.rs @@ -13,7 +13,7 @@ use sp_keyring::AccountKeyring; use subxt::{tx::PairSigner, OnlineClient, PolkadotConfig}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/runtime_types_only.rs b/examples/examples/runtime_types_only.rs index 20ceb838c3..a12365b961 100644 --- a/examples/examples/runtime_types_only.rs +++ b/examples/examples/runtime_types_only.rs @@ -17,7 +17,7 @@ use sp_runtime::{ use subxt::PolkadotConfig; #[subxt::subxt( - runtime_metadata_path = "../artifacts/polkadot_metadata.scale", + runtime_metadata_path = "../artifacts/polkadot_metadata_tiny.scale", derive_for_all_types = "Clone, PartialEq, Eq", runtime_types_only )] diff --git a/examples/examples/storage_iterating.rs b/examples/examples/storage_iterating.rs index ae439e0510..f15c3c65eb 100644 --- a/examples/examples/storage_iterating.rs +++ b/examples/examples/storage_iterating.rs @@ -13,7 +13,7 @@ use codec::{Decode, Encode}; use subxt::{OnlineClient, PolkadotConfig}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/submit_and_watch.rs b/examples/examples/submit_and_watch.rs index d45d629604..ede993df53 100644 --- a/examples/examples/submit_and_watch.rs +++ b/examples/examples/submit_and_watch.rs @@ -14,7 +14,7 @@ use futures::StreamExt; use sp_keyring::AccountKeyring; use subxt::{tx::PairSigner, OnlineClient, PolkadotConfig}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/subscribe_block_events.rs b/examples/examples/subscribe_block_events.rs index 02452cd4bc..ad2dd07dbb 100644 --- a/examples/examples/subscribe_block_events.rs +++ b/examples/examples/subscribe_block_events.rs @@ -15,7 +15,7 @@ use sp_keyring::AccountKeyring; use std::time::Duration; use subxt::{tx::PairSigner, OnlineClient, PolkadotConfig}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} /// Subscribe to all events, and then manually look through them and diff --git a/examples/examples/subscribe_blocks.rs b/examples/examples/subscribe_blocks.rs index 81a88f09b5..a842e15487 100644 --- a/examples/examples/subscribe_blocks.rs +++ b/examples/examples/subscribe_blocks.rs @@ -13,7 +13,7 @@ use futures::StreamExt; use subxt::{OnlineClient, PolkadotConfig}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/metadata/benches/bench.rs b/metadata/benches/bench.rs index d264fbe5f3..12dd1fa6a8 100644 --- a/metadata/benches/bench.rs +++ b/metadata/benches/bench.rs @@ -13,7 +13,7 @@ use subxt_metadata::{ }; fn load_metadata() -> RuntimeMetadataV15 { - let bytes = fs::read(Path::new("../artifacts/polkadot_metadata.scale")) + let bytes = fs::read(Path::new("../artifacts/polkadot_metadata_full.scale")) .expect("Cannot read metadata blob"); let meta: RuntimeMetadataPrefixed = Decode::decode(&mut &*bytes).expect("Cannot decode scale metadata"); diff --git a/metadata/src/retain.rs b/metadata/src/retain.rs index e0550643c3..e34e516894 100644 --- a/metadata/src/retain.rs +++ b/metadata/src/retain.rs @@ -222,7 +222,7 @@ mod tests { use std::{fs, path::Path}; fn load_metadata() -> RuntimeMetadataV15 { - let bytes = fs::read(Path::new("../artifacts/polkadot_metadata.scale")) + let bytes = fs::read(Path::new("../artifacts/polkadot_metadata_full.scale")) .expect("Cannot read metadata blob"); let meta: RuntimeMetadataPrefixed = Decode::decode(&mut &*bytes).expect("Cannot decode scale metadata"); diff --git a/subxt/src/lib.rs b/subxt/src/lib.rs index 3b41f95963..fe7f227a26 100644 --- a/subxt/src/lib.rs +++ b/subxt/src/lib.rs @@ -80,7 +80,7 @@ //! ```no_run //! use subxt::{OnlineClient, PolkadotConfig}; //! -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] //! pub mod polkadot {} //! //! # #[tokio::main] diff --git a/subxt/src/rpc/mod.rs b/subxt/src/rpc/mod.rs index 98c76e7998..2254db313c 100644 --- a/subxt/src/rpc/mod.rs +++ b/subxt/src/rpc/mod.rs @@ -25,7 +25,7 @@ //! # async fn main() { //! use subxt::{ PolkadotConfig, OnlineClient, storage::StorageKey }; //! -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] //! pub mod polkadot {} //! //! let api = OnlineClient::::new().await.unwrap(); diff --git a/subxt/src/rpc/rpc.rs b/subxt/src/rpc/rpc.rs index b21b9d4311..60c33656f3 100644 --- a/subxt/src/rpc/rpc.rs +++ b/subxt/src/rpc/rpc.rs @@ -16,7 +16,7 @@ //! # async fn main() { //! use subxt::{ PolkadotConfig, OnlineClient, storage::StorageKey }; //! -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] //! pub mod polkadot {} //! //! let api = OnlineClient::::new().await.unwrap(); diff --git a/subxt/src/storage/storage_type.rs b/subxt/src/storage/storage_type.rs index 84c554af6c..51d2e978b5 100644 --- a/subxt/src/storage/storage_type.rs +++ b/subxt/src/storage/storage_type.rs @@ -62,7 +62,7 @@ where /// ```no_run /// use subxt::{ PolkadotConfig, OnlineClient }; /// - /// #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] + /// #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] /// pub mod polkadot {} /// /// # #[tokio::main] @@ -172,7 +172,7 @@ where /// ```no_run /// use subxt::{ PolkadotConfig, OnlineClient }; /// - /// #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] + /// #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] /// pub mod polkadot {} /// /// # #[tokio::main] diff --git a/testing/integration-tests/src/codegen/mod.rs b/testing/integration-tests/src/codegen/mod.rs index 91b043b98d..786c0df00f 100644 --- a/testing/integration-tests/src/codegen/mod.rs +++ b/testing/integration-tests/src/codegen/mod.rs @@ -8,7 +8,7 @@ /// Generate by running this at the root of the repository: /// /// ``` -/// cargo run --bin subxt -- codegen --file artifacts/polkadot_metadata.scale | rustfmt > testing/integration-tests/src/codegen/polkadot.rs +/// cargo run --bin subxt -- codegen --file artifacts/polkadot_metadata_full.scale | rustfmt > testing/integration-tests/src/codegen/polkadot.rs /// ``` #[rustfmt::skip] #[allow(clippy::all)] diff --git a/testing/integration-tests/src/codegen/polkadot.rs b/testing/integration-tests/src/codegen/polkadot.rs index 062e6f1c45..bc21338433 100644 --- a/testing/integration-tests/src/codegen/polkadot.rs +++ b/testing/integration-tests/src/codegen/polkadot.rs @@ -60,11 +60,100 @@ pub mod api { "Crowdloan", "XcmPallet", ]; - #[doc = r" The statically generated runtime call type."] - pub type Call = runtime_types::polkadot_runtime::RuntimeCall; #[doc = r" The error type returned when there is a runtime issue."] pub type DispatchError = runtime_types::sp_runtime::DispatchError; - pub type Event = runtime_types::polkadot_runtime::RuntimeEvent; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Event { + #[codec(index = 0)] + System(system::Event), + #[codec(index = 1)] + Scheduler(scheduler::Event), + #[codec(index = 10)] + Preimage(preimage::Event), + #[codec(index = 4)] + Indices(indices::Event), + #[codec(index = 5)] + Balances(balances::Event), + #[codec(index = 32)] + TransactionPayment(transaction_payment::Event), + #[codec(index = 7)] + Staking(staking::Event), + #[codec(index = 8)] + Offences(offences::Event), + #[codec(index = 9)] + Session(session::Event), + #[codec(index = 11)] + Grandpa(grandpa::Event), + #[codec(index = 12)] + ImOnline(im_online::Event), + #[codec(index = 14)] + Democracy(democracy::Event), + #[codec(index = 15)] + Council(council::Event), + #[codec(index = 16)] + TechnicalCommittee(technical_committee::Event), + #[codec(index = 17)] + PhragmenElection(phragmen_election::Event), + #[codec(index = 18)] + TechnicalMembership(technical_membership::Event), + #[codec(index = 19)] + Treasury(treasury::Event), + #[codec(index = 24)] + Claims(claims::Event), + #[codec(index = 25)] + Vesting(vesting::Event), + #[codec(index = 26)] + Utility(utility::Event), + #[codec(index = 28)] + Identity(identity::Event), + #[codec(index = 29)] + Proxy(proxy::Event), + #[codec(index = 30)] + Multisig(multisig::Event), + #[codec(index = 34)] + Bounties(bounties::Event), + #[codec(index = 38)] + ChildBounties(child_bounties::Event), + #[codec(index = 35)] + Tips(tips::Event), + #[codec(index = 36)] + ElectionProviderMultiPhase(election_provider_multi_phase::Event), + #[codec(index = 37)] + VoterList(voter_list::Event), + #[codec(index = 39)] + NominationPools(nomination_pools::Event), + #[codec(index = 40)] + FastUnstake(fast_unstake::Event), + #[codec(index = 53)] + ParaInclusion(para_inclusion::Event), + #[codec(index = 56)] + Paras(paras::Event), + #[codec(index = 59)] + Ump(ump::Event), + #[codec(index = 60)] + Hrmp(hrmp::Event), + #[codec(index = 62)] + ParasDisputes(paras_disputes::Event), + #[codec(index = 70)] + Registrar(registrar::Event), + #[codec(index = 71)] + Slots(slots::Event), + #[codec(index = 72)] + Auctions(auctions::Event), + #[codec(index = 73)] + Crowdloan(crowdloan::Event), + #[codec(index = 99)] + XcmPallet(xcm_pallet::Event), + } impl ::subxt::events::RootEvent for Event { fn root_event( pallet_bytes: &[u8], @@ -814,6 +903,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct FillBlock { @@ -826,6 +916,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Remark { @@ -839,6 +930,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetHeapPages { @@ -851,6 +943,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetCode { @@ -863,6 +956,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetCodeWithoutChecks { @@ -875,6 +969,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetStorage { @@ -890,6 +985,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct KillStorage { @@ -902,6 +998,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct KillPrefix { @@ -915,6 +1012,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RemarkWithEvent { @@ -1114,6 +1212,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An extrinsic completed successfully."] @@ -1131,6 +1230,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An extrinsic failed."] @@ -1149,6 +1249,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "`:code` was updated."] @@ -1164,6 +1265,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A new account was created."] @@ -1181,6 +1283,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An account was reaped."] @@ -1198,6 +1301,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "On on-chain remark happened."] @@ -1811,6 +1915,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Schedule { @@ -1827,6 +1932,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Cancel { @@ -1840,6 +1946,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ScheduleNamed { @@ -1857,6 +1964,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CancelNamed { @@ -1869,6 +1977,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ScheduleAfter { @@ -1885,6 +1994,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ScheduleNamedAfter { @@ -2065,6 +2175,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Scheduled some task."] @@ -2083,6 +2194,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Canceled some task."] @@ -2101,6 +2213,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Dispatched some task."] @@ -2120,6 +2233,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The call for the provided hash was not found so the task has been aborted."] @@ -2138,6 +2252,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The given task was unable to be renewed since the agenda is full at that block."] @@ -2156,6 +2271,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The given task can never be executed since it is overweight."] @@ -2370,6 +2486,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct NotePreimage { @@ -2382,6 +2499,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct UnnotePreimage { @@ -2394,6 +2512,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RequestPreimage { @@ -2406,6 +2525,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct UnrequestPreimage { @@ -2503,6 +2623,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A preimage has been noted."] @@ -2520,6 +2641,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A preimage has been requested."] @@ -2537,6 +2659,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A preimage has ben cleared."] @@ -2666,6 +2789,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReportEquivocation { @@ -2687,6 +2811,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReportEquivocationUnsigned { @@ -2708,6 +2833,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PlanConfigChange { @@ -3291,6 +3417,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Set { @@ -3418,6 +3545,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Claim { @@ -3430,6 +3558,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Transfer { @@ -3444,6 +3573,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Free { @@ -3456,6 +3586,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceTransfer { @@ -3471,6 +3602,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Freeze { @@ -3660,6 +3792,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A account index was assigned."] @@ -3679,6 +3812,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A account index has been freed up (unassigned)."] @@ -3696,6 +3830,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A account index has been frozen to its current account ID."] @@ -3803,6 +3938,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Transfer { @@ -3817,6 +3953,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetBalance { @@ -3833,6 +3970,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceTransfer { @@ -3848,6 +3986,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct TransferKeepAlive { @@ -3862,6 +4001,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct TransferAll { @@ -3875,6 +4015,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceUnreserve { @@ -4073,6 +4214,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An account was created with some free balance."] @@ -4091,6 +4233,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An account was removed whose balance was non-zero but below ExistentialDeposit,"] @@ -4110,6 +4253,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Transfer succeeded."] @@ -4129,6 +4273,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A balance was set by root."] @@ -4148,6 +4293,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Some balance was reserved (moved from free to reserved)."] @@ -4166,6 +4312,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Some balance was unreserved (moved from reserved to free)."] @@ -4184,6 +4331,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Some balance was moved from the reserve of the first account to the second account."] @@ -4206,6 +4354,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Some amount was deposited (e.g. for transaction fees)."] @@ -4224,6 +4373,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Some amount was withdrawn from the account (e.g. for transaction fees)."] @@ -4242,6 +4392,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Some amount was removed from the account (e.g. for misbehavior)."] @@ -4564,6 +4715,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A transaction fee `actual_fee`, of which `tip` was added to the minimum inclusion fee,"] @@ -4682,6 +4834,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetUncles { @@ -4834,6 +4987,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Bond { @@ -4850,6 +5004,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BondExtra { @@ -4863,6 +5018,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Unbond { @@ -4877,6 +5033,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct WithdrawUnbonded { @@ -4889,6 +5046,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Validate { @@ -4901,6 +5059,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Nominate { @@ -4914,6 +5073,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Chill; @@ -4924,6 +5084,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetPayee { @@ -4937,6 +5098,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetController { @@ -4949,6 +5111,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetValidatorCount { @@ -4962,6 +5125,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct IncreaseValidatorCount { @@ -4975,6 +5139,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ScaleValidatorCount { @@ -4987,6 +5152,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceNoEras; @@ -4997,6 +5163,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceNewEra; @@ -5007,6 +5174,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetInvulnerables { @@ -5019,6 +5187,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceUnstake { @@ -5032,6 +5201,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceNewEraAlways; @@ -5042,6 +5212,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CancelDeferredSlash { @@ -5055,6 +5226,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PayoutStakers { @@ -5068,6 +5240,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Rebond { @@ -5081,6 +5254,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReapStash { @@ -5094,6 +5268,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Kick { @@ -5107,6 +5282,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetStakingConfigs { @@ -5134,6 +5310,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ChillOther { @@ -5146,6 +5323,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceApplyMinCommission { @@ -5892,6 +6070,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The era payout has been set; the first balance is the validator-payout; the second is"] @@ -5912,6 +6091,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The nominator has been rewarded by this amount."] @@ -5930,6 +6110,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "One staker (and potentially its nominators) has been slashed by the given amount."] @@ -5949,6 +6130,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An old slashing report from a prior era was discarded because it could"] @@ -5967,6 +6149,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A new set of stakers was elected."] @@ -5982,6 +6165,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An account has bonded this amount. \\[stash, amount\\]"] @@ -6003,6 +6187,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An account has unbonded this amount."] @@ -6021,6 +6206,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An account has called `withdraw_unbonded` and removed unbonding chunks worth `Balance`"] @@ -6040,6 +6226,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A nominator has been kicked from a validator."] @@ -6058,6 +6245,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The election failed. No new era is planned."] @@ -6073,6 +6261,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An account has stopped participating as either a validator or nominator."] @@ -6090,6 +6279,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The stakers' rewards are getting paid."] @@ -6108,6 +6298,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A validator has set their preferences."] @@ -7651,6 +7842,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "There is an offence reported of the given `kind` happened at the `session_index` and"] @@ -7858,6 +8050,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetKeys { @@ -7871,6 +8064,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PurgeKeys; @@ -7948,6 +8142,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "New session has happened. Note that the argument is the session index, not the"] @@ -8194,6 +8389,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReportEquivocation { @@ -8212,6 +8408,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReportEquivocationUnsigned { @@ -8230,6 +8427,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct NoteStalled { @@ -8341,6 +8539,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "New authority set has been applied."] @@ -8361,6 +8560,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Current authority set has been paused."] @@ -8376,6 +8576,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Current authority set has been resumed."] @@ -8590,6 +8791,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Heartbeat { @@ -8640,6 +8842,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A new heartbeat was received from `AuthorityId`."] @@ -8657,6 +8860,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "At the end of the session, no offence was committed."] @@ -8672,6 +8876,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "At the end of the session, at least one validator was found to be offline."] @@ -8901,6 +9106,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Propose { @@ -8917,6 +9123,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Second { @@ -8930,6 +9137,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Vote { @@ -8946,6 +9154,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct EmergencyCancel { @@ -8958,6 +9167,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ExternalPropose { @@ -8972,6 +9182,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ExternalProposeMajority { @@ -8986,6 +9197,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ExternalProposeDefault { @@ -9000,6 +9212,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct FastTrack { @@ -9014,6 +9227,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct VetoExternal { @@ -9026,6 +9240,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CancelReferendum { @@ -9039,6 +9254,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Delegate { @@ -9053,6 +9269,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Undelegate; @@ -9063,6 +9280,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ClearPublicProposals; @@ -9073,6 +9291,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Unlock { @@ -9086,6 +9305,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RemoveVote { @@ -9098,6 +9318,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RemoveOtherVote { @@ -9111,6 +9332,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Blacklist { @@ -9124,6 +9346,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CancelProposal { @@ -9646,6 +9869,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A motion has been proposed by a public account."] @@ -9664,6 +9888,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A public proposal has been tabled for referendum vote."] @@ -9682,6 +9907,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An external proposal has been tabled."] @@ -9697,6 +9923,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A referendum has begun."] @@ -9716,6 +9943,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A proposal has been approved by referendum."] @@ -9734,6 +9962,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A proposal has been rejected by referendum."] @@ -9752,6 +9981,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A referendum has been cancelled."] @@ -9769,6 +9999,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An account has delegated their vote to another account."] @@ -9787,6 +10018,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An account has cancelled a previous delegation operation."] @@ -9804,6 +10036,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An external proposal has been vetoed."] @@ -9823,6 +10056,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A proposal_hash has been blacklisted permanently."] @@ -9840,6 +10074,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An account has voted in a referendum"] @@ -9860,6 +10095,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An account has secconded a proposal"] @@ -9879,6 +10115,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A proposal got canceled."] @@ -10531,6 +10768,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMembers { @@ -10545,6 +10783,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Execute { @@ -10559,6 +10798,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Propose { @@ -10575,6 +10815,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Vote { @@ -10590,6 +10831,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CloseOldWeight { @@ -10608,6 +10850,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct DisapproveProposal { @@ -10620,6 +10863,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Close { @@ -10954,6 +11198,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A motion (given hash) has been proposed (by given account) with a threshold (given"] @@ -10975,6 +11220,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A motion (given hash) has been voted on by given account, leaving"] @@ -10997,6 +11243,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A motion was approved by the required threshold."] @@ -11014,6 +11261,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A motion was not approved by the required threshold."] @@ -11031,6 +11279,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A motion was executed; result will be `Ok` if it returned without error."] @@ -11049,6 +11298,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A single member did some action; result will be `Ok` if it returned without error."] @@ -11067,6 +11317,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A proposal was closed because its threshold was reached or after its duration was up."] @@ -11290,6 +11541,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMembers { @@ -11304,6 +11556,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Execute { @@ -11318,6 +11571,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Propose { @@ -11334,6 +11588,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Vote { @@ -11349,6 +11604,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CloseOldWeight { @@ -11367,6 +11623,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct DisapproveProposal { @@ -11379,6 +11636,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Close { @@ -11713,6 +11971,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A motion (given hash) has been proposed (by given account) with a threshold (given"] @@ -11734,6 +11993,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A motion (given hash) has been voted on by given account, leaving"] @@ -11756,6 +12016,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A motion was approved by the required threshold."] @@ -11773,6 +12034,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A motion was not approved by the required threshold."] @@ -11790,6 +12052,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A motion was executed; result will be `Ok` if it returned without error."] @@ -11808,6 +12071,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A single member did some action; result will be `Ok` if it returned without error."] @@ -11826,6 +12090,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A proposal was closed because its threshold was reached or after its duration was up."] @@ -12049,6 +12314,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Vote { @@ -12063,6 +12329,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RemoveVoter; @@ -12073,6 +12340,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SubmitCandidacy { @@ -12086,6 +12354,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RenounceCandidacy { @@ -12098,6 +12367,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RemoveMember { @@ -12112,6 +12382,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CleanDefunctVoters { @@ -12322,6 +12593,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A new term with new_members. This indicates that enough candidates existed to run"] @@ -12344,6 +12616,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "No (or not enough) candidates existed for this round. This is different from"] @@ -12360,6 +12633,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Internal error happened while trying to perform election."] @@ -12375,6 +12649,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A member has been removed. This should always be followed by either `NewTerm` or"] @@ -12393,6 +12668,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Someone has renounced their candidacy."] @@ -12410,6 +12686,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A candidate was slashed by amount due to failing to obtain a seat as member or"] @@ -12431,6 +12708,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A seat holder was slashed by amount by being forcefully removed from the set."] @@ -12774,6 +13052,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AddMember { @@ -12786,6 +13065,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RemoveMember { @@ -12798,6 +13078,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SwapMember { @@ -12811,6 +13092,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ResetMembers { @@ -12823,6 +13105,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ChangeKey { @@ -12835,6 +13118,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetPrime { @@ -12847,6 +13131,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ClearPrime; @@ -12997,6 +13282,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The given member was added; see the transaction for who."] @@ -13012,6 +13298,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The given member was removed; see the transaction for who."] @@ -13027,6 +13314,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Two members were swapped; see the transaction for who."] @@ -13042,6 +13330,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The membership was reset; see the transaction for who the new set is."] @@ -13057,6 +13346,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "One of the members' keys changed."] @@ -13072,6 +13362,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Phantom member, never used."] @@ -13148,6 +13439,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ProposeSpend { @@ -13162,6 +13454,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RejectProposal { @@ -13175,6 +13468,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ApproveProposal { @@ -13188,6 +13482,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Spend { @@ -13202,6 +13497,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RemoveApproval { @@ -13356,6 +13652,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "New proposal."] @@ -13374,6 +13671,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "We have ended a spend period and will now allocate funds."] @@ -13391,6 +13689,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Some funds have been allocated."] @@ -13410,6 +13709,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A proposal was rejected; funds were slashed."] @@ -13429,6 +13729,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Some of our funds have been burnt."] @@ -13447,6 +13748,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Spending has finished; this is the amount that rolls over until next spend."] @@ -13465,6 +13767,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Some funds have been deposited."] @@ -13482,6 +13785,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A new spend proposal has been approved."] @@ -13724,6 +14028,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Claim { @@ -13738,6 +14043,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct MintClaim { @@ -13759,6 +14065,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ClaimAttest { @@ -13774,6 +14081,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Attest { @@ -13786,6 +14094,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct MoveClaim { @@ -13997,6 +14306,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Someone claimed some DOTs."] @@ -14275,6 +14585,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Vest; @@ -14285,6 +14596,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct VestOther { @@ -14297,6 +14609,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct VestedTransfer { @@ -14313,6 +14626,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceVestedTransfer { @@ -14330,6 +14644,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct MergeSchedules { @@ -14526,6 +14841,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The amount vested has been updated. This could indicate a change in funds available."] @@ -14545,6 +14861,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An \\[account\\] has become fully vested."] @@ -14690,6 +15007,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Batch { @@ -14702,6 +15020,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AsDerivative { @@ -14715,6 +15034,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BatchAll { @@ -14727,6 +15047,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct DispatchAs { @@ -14740,6 +15061,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceBatch { @@ -14918,6 +15240,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Batch of dispatches did not complete fully. Index of first failing dispatch given, as"] @@ -14937,6 +15260,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Batch of dispatches completed fully with no error."] @@ -14952,6 +15276,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Batch of dispatches completed but has errors."] @@ -14967,6 +15292,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A single item within a Batch of dispatches has completed with no error."] @@ -14982,6 +15308,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A single item within a Batch of dispatches has completed with error."] @@ -14999,6 +15326,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A call was dispatched."] @@ -15047,6 +15375,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AddRegistrar { @@ -15059,6 +15388,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetIdentity { @@ -15071,6 +15401,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetSubs { @@ -15086,6 +15417,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ClearIdentity; @@ -15096,6 +15428,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RequestJudgement { @@ -15112,6 +15445,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CancelRequest { @@ -15124,6 +15458,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetFee { @@ -15139,6 +15474,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetAccountId { @@ -15153,6 +15489,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetFields { @@ -15169,6 +15506,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ProvideJudgement { @@ -15186,6 +15524,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct KillIdentity { @@ -15198,6 +15537,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AddSub { @@ -15211,6 +15551,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RenameSub { @@ -15224,6 +15565,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RemoveSub { @@ -15236,6 +15578,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct QuitSub; @@ -15719,6 +16062,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A name was set or reset (which will remove all judgements)."] @@ -15736,6 +16080,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A name was cleared, and the given balance returned."] @@ -15754,6 +16099,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A name was removed and the given balance slashed."] @@ -15772,6 +16118,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A judgement was asked from a registrar."] @@ -15790,6 +16137,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A judgement request was retracted."] @@ -15808,6 +16156,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A judgement was given by a registrar."] @@ -15827,6 +16176,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A registrar was added."] @@ -15844,6 +16194,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A sub-identity was added to an identity and the deposit paid."] @@ -15863,6 +16214,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A sub-identity was removed from an identity and the deposit freed."] @@ -15882,6 +16234,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A sub-identity was cleared, and the given deposit repatriated from the"] @@ -16215,6 +16568,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Proxy { @@ -16230,6 +16584,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AddProxy { @@ -16244,6 +16599,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RemoveProxy { @@ -16258,6 +16614,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RemoveProxies; @@ -16268,6 +16625,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CreatePure { @@ -16282,6 +16640,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct KillPure { @@ -16300,6 +16659,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Announce { @@ -16313,6 +16673,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RemoveAnnouncement { @@ -16326,6 +16687,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RejectAnnouncement { @@ -16339,6 +16701,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ProxyAnnounced { @@ -16682,6 +17045,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A proxy was executed correctly, with the given."] @@ -16699,6 +17063,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A pure account has been created by new proxy with given"] @@ -16720,6 +17085,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An announcement was placed to make a call in the future."] @@ -16739,6 +17105,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A proxy was added."] @@ -16759,6 +17126,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A proxy was removed."] @@ -17026,6 +17394,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AsMultiThreshold1 { @@ -17039,6 +17408,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AsMulti { @@ -17057,6 +17427,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ApproveAsMulti { @@ -17075,6 +17446,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CancelAsMulti { @@ -17318,6 +17690,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A new multisig operation has begun."] @@ -17337,6 +17710,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A multisig operation has been approved by someone."] @@ -17357,6 +17731,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A multisig operation has been executed."] @@ -17378,6 +17753,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A multisig operation has been cancelled."] @@ -17523,6 +17899,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ProposeBounty { @@ -17537,6 +17914,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ApproveBounty { @@ -17550,6 +17928,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ProposeCurator { @@ -17566,6 +17945,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct UnassignCurator { @@ -17579,6 +17959,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AcceptCurator { @@ -17592,6 +17973,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AwardBounty { @@ -17606,6 +17988,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ClaimBounty { @@ -17619,6 +18002,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CloseBounty { @@ -17632,6 +18016,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ExtendBountyExpiry { @@ -17900,6 +18285,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "New bounty proposal."] @@ -17917,6 +18303,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A bounty proposal was rejected; funds were slashed."] @@ -17936,6 +18323,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A bounty proposal is funded and became active."] @@ -17953,6 +18341,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A bounty is awarded to a beneficiary."] @@ -17971,6 +18360,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A bounty is claimed by beneficiary."] @@ -17991,6 +18381,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A bounty is cancelled."] @@ -18009,6 +18400,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A bounty expiry is extended."] @@ -18331,6 +18723,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AddChildBounty { @@ -18347,6 +18740,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ProposeCurator { @@ -18365,6 +18759,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AcceptCurator { @@ -18380,6 +18775,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct UnassignCurator { @@ -18395,6 +18791,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AwardChildBounty { @@ -18411,6 +18808,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ClaimChildBounty { @@ -18426,6 +18824,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CloseChildBounty { @@ -18736,6 +19135,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A child-bounty is added."] @@ -18754,6 +19154,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A child-bounty is awarded to a beneficiary."] @@ -18773,6 +19174,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A child-bounty is claimed by beneficiary."] @@ -18793,6 +19195,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A child-bounty is cancelled."] @@ -19081,6 +19484,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReportAwesome { @@ -19094,6 +19498,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RetractTip { @@ -19106,6 +19511,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct TipNew { @@ -19121,6 +19527,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Tip { @@ -19135,6 +19542,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CloseTip { @@ -19147,6 +19555,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SlashTip { @@ -19379,6 +19788,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A new tip suggestion has been opened."] @@ -19396,6 +19806,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A tip suggestion has reached threshold and is closing."] @@ -19413,6 +19824,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A tip suggestion has been closed."] @@ -19432,6 +19844,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A tip suggestion has been retracted."] @@ -19449,6 +19862,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A tip suggestion has been slashed."] @@ -19670,6 +20084,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SubmitUnsigned { @@ -19688,6 +20103,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMinimumUntrustedScore { @@ -19701,6 +20117,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetEmergencyElectionResult { @@ -19716,6 +20133,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Submit { @@ -19732,6 +20150,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct GovernanceFallback { @@ -19888,6 +20307,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A solution was stored with the given compute."] @@ -19911,6 +20331,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The election has been finalized, with the given computation and score."] @@ -19929,6 +20350,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An election failed."] @@ -19946,6 +20368,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An account has been rewarded for their signed submission being finalized."] @@ -19964,6 +20387,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An account has been slashed for submitting an invalid signed submission."] @@ -19983,6 +20407,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The signed phase of the given round has started."] @@ -20001,6 +20426,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The unsigned phase of the given round has started."] @@ -20627,6 +21053,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Rebag { @@ -20639,6 +21066,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PutInFrontOf { @@ -20709,6 +21137,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Moved an account from one bag to another."] @@ -20728,6 +21157,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Updated the score of some account to the given amount."] @@ -20944,6 +21374,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Join { @@ -20958,6 +21389,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BondExtra { @@ -20971,6 +21403,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ClaimPayout; @@ -20981,6 +21414,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Unbond { @@ -20995,6 +21429,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PoolWithdrawUnbonded { @@ -21008,6 +21443,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct WithdrawUnbonded { @@ -21021,6 +21457,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Create { @@ -21037,6 +21474,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CreateWithPoolId { @@ -21054,6 +21492,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Nominate { @@ -21067,6 +21506,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetState { @@ -21080,6 +21520,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMetadata { @@ -21093,6 +21534,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetConfigs { @@ -21114,6 +21556,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct UpdateRoles { @@ -21133,6 +21576,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Chill { @@ -21581,6 +22025,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A pool has been created."] @@ -21599,6 +22044,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A member has became bonded in a pool."] @@ -21619,6 +22065,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A payout has been made to a member."] @@ -21638,6 +22085,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A member has unbonded from their pool."] @@ -21669,6 +22117,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A member has withdrawn from their pool."] @@ -21695,6 +22144,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A pool has been destroyed."] @@ -21712,6 +22162,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The state of a pool has changed"] @@ -21730,6 +22181,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A member has been removed from a pool."] @@ -21750,6 +22202,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The roles of a pool have been updated to the given new roles. Note that the depositor"] @@ -21770,6 +22223,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The active balance of pool `pool_id` has been slashed to `balance`."] @@ -21788,6 +22242,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The unbond pool at `era` of pool `pool_id` has been slashed to `balance`."] @@ -22424,6 +22879,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RegisterFastUnstake; @@ -22434,6 +22890,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Deregister; @@ -22445,6 +22902,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Control { @@ -22536,6 +22994,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A staker was unstaked."] @@ -22554,6 +23013,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A staker was slashed for requesting fast-unstake whilst being exposed."] @@ -22572,6 +23032,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Some internal error happened while migrating stash. They are removed as head as a"] @@ -22590,6 +23051,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An internal error happened. Operations will be paused now."] @@ -22605,6 +23067,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A batch was partially checked for the given eras, but the process did not finish."] @@ -22622,6 +23085,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A batch was terminated."] @@ -22778,6 +23242,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetValidationUpgradeCooldown { @@ -22791,6 +23256,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetValidationUpgradeDelay { @@ -22804,6 +23270,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetCodeRetentionPeriod { @@ -22817,6 +23284,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMaxCodeSize { @@ -22830,6 +23298,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMaxPovSize { @@ -22843,6 +23312,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMaxHeadDataSize { @@ -22856,6 +23326,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetParathreadCores { @@ -22869,6 +23340,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetParathreadRetries { @@ -22882,6 +23354,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetGroupRotationFrequency { @@ -22895,6 +23368,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetChainAvailabilityPeriod { @@ -22908,6 +23382,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetThreadAvailabilityPeriod { @@ -22921,6 +23396,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetSchedulingLookahead { @@ -22933,6 +23409,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMaxValidatorsPerCore { @@ -22945,6 +23422,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMaxValidators { @@ -22958,6 +23436,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetDisputePeriod { @@ -22971,6 +23450,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetDisputePostConclusionAcceptancePeriod { @@ -22984,6 +23464,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetDisputeMaxSpamSlots { @@ -22997,6 +23478,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetDisputeConclusionByTimeOutPeriod { @@ -23010,6 +23492,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetNoShowSlots { @@ -23023,6 +23506,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetNDelayTranches { @@ -23036,6 +23520,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetZerothDelayTrancheWidth { @@ -23049,6 +23534,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetNeededApprovals { @@ -23062,6 +23548,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetRelayVrfModuloSamples { @@ -23075,6 +23562,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMaxUpwardQueueCount { @@ -23088,6 +23576,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMaxUpwardQueueSize { @@ -23101,6 +23590,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMaxDownwardMessageSize { @@ -23113,6 +23603,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetUmpServiceTotalWeight { @@ -23126,6 +23617,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMaxUpwardMessageSize { @@ -23139,6 +23631,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMaxUpwardMessageNumPerCandidate { @@ -23152,6 +23645,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetHrmpOpenRequestTtl { @@ -23165,6 +23659,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetHrmpSenderDeposit { @@ -23178,6 +23673,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetHrmpRecipientDeposit { @@ -23191,6 +23687,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetHrmpChannelMaxCapacity { @@ -23204,6 +23701,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetHrmpChannelMaxTotalSize { @@ -23217,6 +23715,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetHrmpMaxParachainInboundChannels { @@ -23230,6 +23729,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetHrmpMaxParathreadInboundChannels { @@ -23243,6 +23743,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetHrmpChannelMaxMessageSize { @@ -23256,6 +23757,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetHrmpMaxParachainOutboundChannels { @@ -23269,6 +23771,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetHrmpMaxParathreadOutboundChannels { @@ -23282,6 +23785,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetHrmpMaxMessageNumPerCandidate { @@ -23294,6 +23798,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetUmpMaxIndividualWeight { @@ -23306,6 +23811,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetPvfCheckingEnabled { @@ -23319,6 +23825,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetPvfVotingTtl { @@ -23332,6 +23839,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetMinimumValidationUpgradeDelay { @@ -23344,6 +23852,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetBypassConsistencyCheck { @@ -24277,6 +24786,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A candidate was backed. `[candidate, head_data]`"] @@ -24297,6 +24807,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A candidate was included. `[candidate, head_data]`"] @@ -24317,6 +24828,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A candidate timed out. `[candidate, head_data]`"] @@ -24457,6 +24969,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Enter { @@ -24739,6 +25252,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceSetCurrentCode { @@ -24752,6 +25266,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceSetCurrentHead { @@ -24765,6 +25280,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceScheduleCodeUpgrade { @@ -24779,6 +25295,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceNoteNewHead { @@ -24792,6 +25309,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceQueueAction { @@ -24804,6 +25322,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AddTrustedValidationCode { @@ -24816,6 +25335,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PokeUnusedValidationCode { @@ -24829,6 +25349,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct IncludePvfCheckStatement { @@ -25011,6 +25532,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Current code has been updated for a Para. `para_id`"] @@ -25026,6 +25548,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Current head has been updated for a Para. `para_id`"] @@ -25041,6 +25564,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A code upgrade has been scheduled for a Para. `para_id`"] @@ -25056,6 +25580,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A new head has been noted for a Para. `para_id`"] @@ -25071,6 +25596,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A para has been queued to execute pending actions. `para_id`"] @@ -25089,6 +25615,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The given para either initiated or subscribed to a PVF check for the given validation"] @@ -25108,6 +25635,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The given validation code was accepted by the PVF pre-checking vote."] @@ -25127,6 +25655,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The given validation code was rejected by the PVF pre-checking vote."] @@ -26049,6 +26578,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceApprove { @@ -26276,6 +26806,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ServiceOverweight { @@ -26329,6 +26860,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Upward message is invalid XCM."] @@ -26345,6 +26877,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Upward message is unsupported version of XCM."] @@ -26361,6 +26894,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Upward message executed with the given outcome."] @@ -26380,6 +26914,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The weight limit for handling upward messages was reached."] @@ -26400,6 +26935,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Some upward messages have been received and will be processed."] @@ -26420,6 +26956,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The weight budget was exceeded for an individual upward message."] @@ -26445,6 +26982,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Upward message from the overweight queue was executed with the given actual weight"] @@ -26731,6 +27269,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct HrmpInitOpenChannel { @@ -26745,6 +27284,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct HrmpAcceptOpenChannel { @@ -26757,6 +27297,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct HrmpCloseChannel { @@ -26769,6 +27310,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceCleanHrmp { @@ -26784,6 +27326,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceProcessHrmpOpen { @@ -26797,6 +27340,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceProcessHrmpClose { @@ -26809,6 +27353,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct HrmpCancelOpenRequest { @@ -26822,6 +27367,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceOpenHrmpChannel { @@ -27044,6 +27590,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Open HRMP channel requested."] @@ -27065,6 +27612,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An HRMP channel request sent by the receiver was canceled by either party."] @@ -27084,6 +27632,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Open HRMP channel accepted. `[sender, recipient]`"] @@ -27102,6 +27651,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "HRMP channel closed. `[by_parachain, channel_id]`"] @@ -27120,6 +27670,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An HRMP channel was opened via Root origin."] @@ -27902,6 +28453,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceUnfreeze; @@ -27933,6 +28485,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A dispute has been initiated. \\[candidate hash, dispute location\\]"] @@ -27951,6 +28504,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A dispute has concluded for or against a candidate."] @@ -27970,6 +28524,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A dispute has timed out due to insufficient participation."] @@ -27987,6 +28542,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A dispute has concluded with supermajority against a candidate."] @@ -28227,6 +28783,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Register { @@ -28241,6 +28798,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceRegister { @@ -28257,6 +28815,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Deregister { @@ -28269,6 +28828,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Swap { @@ -28282,6 +28842,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RemoveLock { @@ -28294,6 +28855,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Reserve; @@ -28304,6 +28866,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AddLock { @@ -28316,6 +28879,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ScheduleCodeUpgrade { @@ -28329,6 +28893,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SetCurrentHead { @@ -28565,6 +29130,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Registered { @@ -28582,6 +29148,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Deregistered { @@ -28598,6 +29165,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Reserved { @@ -28789,6 +29357,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceLease { @@ -28805,6 +29374,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ClearAllLeases { @@ -28817,6 +29387,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct TriggerOnboard { @@ -28907,6 +29478,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A new `[lease_period]` is beginning."] @@ -28924,6 +29496,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A para has won the right to a continuous set of lease periods as a parachain."] @@ -29081,6 +29654,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct NewAuction { @@ -29096,6 +29670,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Bid { @@ -29117,6 +29692,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CancelAuction; @@ -29217,6 +29793,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An auction started. Provides its index and the block number where it will begin to"] @@ -29238,6 +29815,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An auction ended. All funds become unreserved."] @@ -29255,6 +29833,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Funds were reserved for a winning bid. First balance is the extra amount reserved."] @@ -29275,6 +29854,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Funds were unreserved since bidder is no longer active. `[bidder, amount]`"] @@ -29293,6 +29873,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Someone attempted to lease the same slot twice for a parachain. The amount is held in reserve"] @@ -29313,6 +29894,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A new bid has been accepted as the current winner."] @@ -29334,6 +29916,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The winning offset was chosen for an auction. This will map into the `Winning` storage map."] @@ -29584,6 +30167,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Create { @@ -29606,6 +30190,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Contribute { @@ -29622,6 +30207,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Withdraw { @@ -29636,6 +30222,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Refund { @@ -29649,6 +30236,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Dissolve { @@ -29662,6 +30250,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Edit { @@ -29684,6 +30273,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AddMemo { @@ -29697,6 +30287,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Poke { @@ -29709,6 +30300,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ContributeAll { @@ -29944,6 +30536,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Create a new crowdloaning campaign."] @@ -29961,6 +30554,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contributed to a crowd sale."] @@ -29980,6 +30574,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Withdrew full balance of a contributor."] @@ -29999,6 +30594,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The loans in a fund have been partially dissolved, i.e. there are some left"] @@ -30017,6 +30613,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "All loans in a fund have been refunded."] @@ -30034,6 +30631,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Fund is dissolved."] @@ -30051,6 +30649,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The result of trying to submit a new bid to the Slots pallet."] @@ -30069,6 +30668,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The configuration to a crowdloan has been edited."] @@ -30086,6 +30686,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A memo has been updated."] @@ -30105,6 +30706,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A parachain has been moved to `NewRaise`"] @@ -30309,6 +30911,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Send { @@ -30322,6 +30925,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct TeleportAssets { @@ -30337,6 +30941,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReserveTransferAssets { @@ -30352,6 +30957,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Execute { @@ -30365,6 +30971,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceXcmVersion { @@ -30379,6 +30986,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceDefaultXcmVersion { @@ -30391,6 +30999,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceSubscribeVersionNotify { @@ -30403,6 +31012,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ForceUnsubscribeVersionNotify { @@ -30415,6 +31025,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct LimitedReserveTransferAssets { @@ -30431,6 +31042,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct LimitedTeleportAssets { @@ -30758,6 +31370,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Execution of an XCM message was attempted."] @@ -30775,6 +31388,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A XCM message was sent."] @@ -30796,6 +31410,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Query response received which does not match a registered query. This may be because a"] @@ -30818,6 +31433,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Query response has been received and is ready for taking with `take_response`. There is"] @@ -30839,6 +31455,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Query response has been received and query is removed. The registered notification has"] @@ -30861,6 +31478,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Query response has been received and query is removed. The registered notification could"] @@ -30886,6 +31504,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Query response has been received and query is removed. There was a general error with"] @@ -30908,6 +31527,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Query response has been received and query is removed. The dispatch was unable to be"] @@ -30931,6 +31551,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Expected query response has been received but the origin location of the response does"] @@ -30954,6 +31575,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Expected query response has been received but the expected origin location placed in"] @@ -30981,6 +31603,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Received query response has been read and removed."] @@ -30998,6 +31621,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Some assets have been placed in an asset trap."] @@ -31019,6 +31643,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "An XCM version change notification message has been attempted to be sent."] @@ -31039,6 +31664,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The supported version of a location has been changed. This might be through an"] @@ -31060,6 +31686,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A given location which had a version change subscription was dropped owing to an error"] @@ -31082,6 +31709,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "A given location which had a version change subscription was dropped owing to an error"] @@ -31103,6 +31731,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Some assets have been claimed from an asset trap"] @@ -31480,6 +32109,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Equivocation<_0, _1, _2> { @@ -31495,6 +32125,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Precommit<_0, _1> { @@ -31508,6 +32139,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Prevote<_0, _1> { @@ -31526,6 +32158,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum DispatchClass { @@ -31543,6 +32176,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct DispatchInfo { @@ -31557,6 +32191,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Pays { @@ -31572,6 +32207,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PerDispatchClass<_0> { @@ -31586,6 +32222,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum RawOrigin<_0> { @@ -31608,6 +32245,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct WrapperOpaque<_0>( @@ -31624,6 +32262,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Bounded<_0> { @@ -31656,6 +32295,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum BalanceStatus { @@ -31674,6 +32314,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PalletId(pub [::core::primitive::u8; 8usize]); @@ -31691,6 +32332,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CheckGenesis; @@ -31704,6 +32346,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CheckMortality(pub runtime_types::sp_runtime::generic::era::Era); @@ -31717,6 +32360,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CheckNonZeroSender; @@ -31730,6 +32374,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CheckNonce(#[codec(compact)] pub ::core::primitive::u32); @@ -31743,6 +32388,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CheckSpecVersion; @@ -31756,6 +32402,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CheckTxVersion; @@ -31769,6 +32416,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CheckWeight; @@ -31783,6 +32431,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BlockLength { @@ -31797,6 +32446,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BlockWeights { @@ -31813,6 +32463,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct WeightsPerClass { @@ -31834,6 +32485,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -31919,6 +32571,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Error for the System pallet"] @@ -31953,6 +32606,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Event for the System pallet."] @@ -31996,6 +32650,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AccountInfo<_0, _1> { @@ -32012,6 +32667,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct EventRecord<_0, _1> { @@ -32026,6 +32682,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct LastRuntimeUpgradeInfo { @@ -32040,6 +32697,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Phase { @@ -32062,6 +32720,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -32084,6 +32743,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -32118,6 +32778,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum UncleEntryItem<_0, _1, _2> { @@ -32138,6 +32799,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -32196,6 +32858,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -32226,6 +32889,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Bag { @@ -32239,6 +32903,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum ListError { @@ -32258,6 +32923,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Node { @@ -32277,6 +32943,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -32315,6 +32982,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -32330,6 +32998,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -32361,6 +33030,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -32475,6 +33145,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -32511,6 +33182,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -32591,6 +33263,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AccountData<_0> { @@ -32606,6 +33279,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BalanceLock<_0> { @@ -32620,6 +33294,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Reasons { @@ -32637,6 +33312,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Releases { @@ -32652,6 +33328,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReserveData<_0, _1> { @@ -32670,6 +33347,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -32826,6 +33504,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -32872,6 +33551,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -32916,6 +33596,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Bounty<_0, _1, _2> { @@ -32933,6 +33614,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum BountyStatus<_0, _1> { @@ -32965,6 +33647,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -33173,6 +33856,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -33194,6 +33878,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -33234,6 +33919,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ChildBounty<_0, _1, _2> { @@ -33250,6 +33936,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum ChildBountyStatus<_0, _1> { @@ -33278,6 +33965,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -33501,6 +34189,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -33543,6 +34232,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -33602,6 +34292,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum RawOrigin<_0> { @@ -33619,6 +34310,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Votes<_0, _1> { @@ -33640,6 +34332,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Conviction { @@ -33668,6 +34361,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -33963,6 +34657,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -34045,6 +34740,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -34129,6 +34825,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Delegations<_0> { @@ -34142,6 +34839,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum ReferendumInfo<_0, _1, _2> { @@ -34160,6 +34858,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReferendumStatus<_0, _1, _2> { @@ -34176,6 +34875,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Tally<_0> { @@ -34193,6 +34893,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum AccountVote<_0> { @@ -34211,6 +34912,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PriorLock<_0, _1>(pub _0, pub _1); @@ -34222,6 +34924,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Vote(pub ::core::primitive::u8); @@ -34232,6 +34935,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Voting<_0, _1, _2> { @@ -34263,6 +34967,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum VoteThreshold { @@ -34286,6 +34991,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -34298,6 +35004,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Error of the pallet that can be returned in response to dispatches."] @@ -34352,6 +35059,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -34409,6 +35117,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SignedSubmission<_0, _1, _2> { @@ -34426,6 +35135,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum ElectionCompute { @@ -34447,6 +35157,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Phase<_0> { @@ -34466,6 +35177,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RawSolution<_0> { @@ -34480,6 +35192,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReadySolution { @@ -34497,6 +35210,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RoundSnapshot { @@ -34516,6 +35230,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SolutionOrSnapshotSize { @@ -34536,6 +35251,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -34665,6 +35381,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -34728,6 +35445,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -34782,6 +35500,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Renouncing { @@ -34799,6 +35518,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SeatHolder<_0, _1> { @@ -34813,6 +35533,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Voter<_0, _1> { @@ -34832,6 +35553,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -34880,6 +35602,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -34912,6 +35635,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "The events of this pallet."] @@ -34958,6 +35682,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct UnstakeRequest { @@ -34982,6 +35707,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -35044,6 +35770,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -35079,6 +35806,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -35106,6 +35834,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct StoredPendingChange<_0> { @@ -35125,6 +35854,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum StoredState<_0> { @@ -35149,6 +35879,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Identity pallet declaration."] @@ -35456,6 +36187,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -35522,6 +36254,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -35598,6 +36331,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BitFlags<_0>( @@ -35611,6 +36345,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Data { @@ -35698,6 +36433,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum IdentityField { @@ -35725,6 +36461,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct IdentityInfo { @@ -35748,6 +36485,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Judgement<_0> { @@ -35773,6 +36511,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RegistrarInfo<_0, _1> { @@ -35789,6 +36528,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Registration<_0> { @@ -35812,6 +36552,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -35839,6 +36580,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -35857,6 +36599,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -35893,6 +36636,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Public(pub runtime_types::sp_core::sr25519::Public); @@ -35903,6 +36647,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); @@ -35915,6 +36660,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BoundedOpaqueNetworkState { @@ -35935,6 +36681,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Heartbeat<_0> { @@ -35956,6 +36703,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -36080,6 +36828,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -36107,6 +36856,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -36140,6 +36890,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -36205,6 +36956,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -36226,6 +36978,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -36262,6 +37015,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -36429,6 +37183,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -36483,6 +37238,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -36532,6 +37288,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Multisig<_0, _1, _2> { @@ -36547,6 +37304,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Timepoint<_0> { @@ -36565,6 +37323,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -36819,6 +37578,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum DefensiveError { @@ -36840,6 +37600,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -36929,6 +37690,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Events of this pallet."] @@ -37033,6 +37795,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum BondExtra<_0> { @@ -37048,6 +37811,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BondedPoolInner { @@ -37064,6 +37828,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum ConfigOp<_0> { @@ -37081,6 +37846,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PoolMember { @@ -37101,6 +37867,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PoolRoles<_0> { @@ -37116,6 +37883,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum PoolState { @@ -37133,6 +37901,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RewardPool { @@ -37148,6 +37917,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SubPools { @@ -37164,6 +37934,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct UnbondPool { @@ -37182,6 +37953,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Events type."] @@ -37208,6 +37980,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -37247,6 +38020,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -37277,6 +38051,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -37299,6 +38074,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum RequestStatus<_0, _1> { @@ -37326,6 +38102,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -37511,6 +38288,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -37547,6 +38325,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -37598,6 +38377,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Announcement<_0, _1, _2> { @@ -37612,6 +38392,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ProxyDefinition<_0, _1, _2> { @@ -37631,6 +38412,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -37708,6 +38490,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -37735,6 +38518,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Events type."] @@ -37786,6 +38570,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Scheduled<_0, _1, _2, _3, _4> { @@ -37809,6 +38594,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -37858,6 +38644,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Error for the session pallet."] @@ -37885,6 +38672,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -37911,6 +38699,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -38358,6 +39147,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum ConfigOp<_0> { @@ -38375,6 +39165,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -38466,6 +39257,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -38557,6 +39349,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SlashingSpans { @@ -38572,6 +39365,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SpanRecord<_0> { @@ -38586,6 +39380,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ActiveEraInfo { @@ -38599,6 +39394,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct EraRewardPoints<_0> { @@ -38612,6 +39408,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Exposure<_0, _1> { @@ -38629,6 +39426,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Forcing { @@ -38648,6 +39446,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct IndividualExposure<_0, _1> { @@ -38662,6 +39461,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Nominations { @@ -38678,6 +39478,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Releases { @@ -38713,6 +39514,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum RewardDestination<_0> { @@ -38734,6 +39536,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct StakingLedger { @@ -38756,6 +39559,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct UnappliedSlash<_0, _1> { @@ -38772,6 +39576,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct UnlockChunk<_0> { @@ -38787,6 +39592,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ValidatorPrefs { @@ -38806,6 +39612,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -38845,6 +39652,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -38993,6 +39801,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -39023,6 +39832,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -39059,6 +39869,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct OpenTip<_0, _1, _2, _3> { @@ -39082,6 +39893,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -39103,6 +39915,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ChargeTransactionPayment(#[codec(compact)] pub ::core::primitive::u128); @@ -39113,6 +39926,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Releases { @@ -39133,6 +39947,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -39223,6 +40038,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Error for the treasury pallet."] @@ -39251,6 +40067,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -39307,6 +40124,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Proposal<_0, _1> { @@ -39327,6 +40145,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -39431,6 +40250,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -39446,6 +40266,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -39491,6 +40312,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -39615,6 +40437,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Error for the vesting pallet."] @@ -39643,6 +40466,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -39670,6 +40494,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct VestingInfo<_0, _1> { @@ -39685,6 +40510,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Releases { @@ -39705,6 +40531,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -39873,6 +40700,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -39927,6 +40755,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -40099,6 +40928,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Origin { @@ -40114,6 +40944,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum QueryStatus<_0> { @@ -40142,6 +40973,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum VersionMigrationStage { @@ -40167,6 +40999,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CandidateHash(pub ::subxt::utils::H256); @@ -40177,6 +41010,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct InboundDownwardMessage<_0> { @@ -40190,6 +41024,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct InboundHrmpMessage<_0> { @@ -40203,6 +41038,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct OutboundHrmpMessage<_0> { @@ -40221,6 +41057,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct HeadData(pub ::std::vec::Vec<::core::primitive::u8>); @@ -40231,6 +41068,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct HrmpChannelId { @@ -40245,6 +41083,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Id(pub ::core::primitive::u32); @@ -40255,6 +41094,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ValidationCode(pub ::std::vec::Vec<::core::primitive::u8>); @@ -40265,6 +41105,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ValidationCodeHash(pub ::subxt::utils::H256); @@ -40283,6 +41124,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Public(pub runtime_types::sp_core::sr25519::Public); @@ -40296,6 +41138,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Public(pub runtime_types::sp_core::sr25519::Public); @@ -40306,6 +41149,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); @@ -40319,6 +41163,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct UncheckedSigned<_0, _1> { @@ -40339,6 +41184,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Public(pub runtime_types::sp_core::sr25519::Public); @@ -40349,6 +41195,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); @@ -40360,6 +41207,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AvailabilityBitfield( @@ -40375,6 +41223,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BackedCandidate<_0> { @@ -40395,6 +41244,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CandidateCommitments<_0> { @@ -40418,6 +41268,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CandidateDescriptor<_0> { @@ -40439,6 +41290,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CandidateReceipt<_0> { @@ -40452,6 +41304,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CommittedCandidateReceipt<_0> { @@ -40468,6 +41321,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CoreIndex(pub ::core::primitive::u32); @@ -40478,6 +41332,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum CoreOccupied { @@ -40493,6 +41348,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct DisputeState<_0> { @@ -40514,6 +41370,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum DisputeStatement { @@ -40529,6 +41386,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct DisputeStatementSet { @@ -40548,6 +41406,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct GroupIndex(pub ::core::primitive::u32); @@ -40558,6 +41417,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct IndexedVec<_0, _1>( @@ -40571,6 +41431,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct InherentData<_0> { @@ -40597,6 +41458,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum InvalidDisputeStatementKind { @@ -40610,6 +41472,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ParathreadClaim( @@ -40623,6 +41486,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ParathreadEntry { @@ -40636,6 +41500,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PvfCheckStatement { @@ -40651,6 +41516,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ScrapedOnChainVotes<_0> { @@ -40673,6 +41539,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SessionInfo { @@ -40707,6 +41574,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum UpgradeGoAhead { @@ -40722,6 +41590,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum UpgradeRestriction { @@ -40735,6 +41604,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum ValidDisputeStatementKind { @@ -40755,6 +41625,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ValidatorIndex(pub ::core::primitive::u32); @@ -40765,6 +41636,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum ValidityAttestation { @@ -40784,6 +41656,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct NposCompactSolution16 { @@ -40949,6 +41822,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum OriginCaller { @@ -40978,6 +41852,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum ProxyType { @@ -41003,6 +41878,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Runtime; @@ -41013,6 +41889,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum RuntimeCall { @@ -41122,6 +41999,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum RuntimeEvent { @@ -41215,6 +42093,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SessionKeys { @@ -41239,6 +42118,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -41297,6 +42177,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -41330,6 +42211,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -41398,6 +42280,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -41528,6 +42411,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -41559,6 +42443,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -41580,6 +42465,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct EcdsaSignature(pub [::core::primitive::u8; 65usize]); @@ -41590,6 +42476,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct EthereumAddress(pub [::core::primitive::u8; 20usize]); @@ -41600,6 +42487,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PrevalidateAttests; @@ -41610,6 +42498,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum StatementKind { @@ -41630,6 +42519,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -41753,6 +42643,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -41834,6 +42725,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -41908,6 +42800,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct FundInfo<_0, _1, _2, _3> { @@ -41932,6 +42825,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum LastContribution<_0> { @@ -41954,6 +42848,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -42073,6 +42968,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -42128,6 +43024,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -42155,6 +43052,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ParaInfo<_0, _1> { @@ -42174,6 +43072,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -42216,6 +43115,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -42234,6 +43134,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -42272,6 +43173,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -42435,6 +43337,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -42451,6 +43354,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct HostConfiguration<_0> { @@ -42510,6 +43414,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -42524,6 +43429,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -42557,6 +43463,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -42593,6 +43500,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum DisputeLocation { @@ -42608,6 +43516,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum DisputeResult { @@ -42628,6 +43537,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -42645,6 +43555,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -42745,6 +43656,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -42814,6 +43726,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -42864,6 +43777,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct HrmpChannel { @@ -42883,6 +43797,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct HrmpOpenChannelRequest { @@ -42905,6 +43820,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -42916,6 +43832,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -43018,6 +43935,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -43060,6 +43978,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AvailabilityBitfieldRecord<_0> { @@ -43073,6 +43992,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CandidatePendingAvailability<_0, _1> { @@ -43103,6 +44023,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -43121,6 +44042,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BufferedSessionChange { @@ -43144,6 +44066,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Origin { @@ -43163,6 +44086,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -43243,6 +44167,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -43295,6 +44220,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -43347,6 +44273,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ParaGenesisArgs { @@ -43362,6 +44289,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum ParaLifecycle { @@ -43387,6 +44315,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ParaPastCodeMeta<_0> { @@ -43402,6 +44331,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PvfCheckActiveVoteState<_0> { @@ -43426,6 +44356,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum PvfCheckCause<_0> { @@ -43444,6 +44375,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReplacementTimes<_0> { @@ -43462,6 +44394,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -43484,6 +44417,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -43519,6 +44453,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum AssignmentKind { @@ -43537,6 +44472,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CoreAssignment { @@ -43552,6 +44488,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ParathreadClaimQueue { @@ -43567,6 +44504,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct QueuedParathread { @@ -43585,6 +44523,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -43602,6 +44541,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] @@ -43631,6 +44571,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] @@ -43649,6 +44590,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -43722,6 +44664,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct FixedU128(pub ::core::primitive::u128); @@ -43736,6 +44679,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PerU16(pub ::core::primitive::u16); @@ -43747,6 +44691,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Perbill(pub ::core::primitive::u32); @@ -43758,6 +44703,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Percent(pub ::core::primitive::u8); @@ -43769,6 +44715,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Permill(pub ::core::primitive::u32); @@ -43785,6 +44732,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Public(pub runtime_types::sp_core::sr25519::Public); @@ -43801,6 +44749,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Public(pub runtime_types::sp_core::sr25519::Public); @@ -43814,6 +44763,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum NextConfigDescriptor { @@ -43830,6 +44780,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum PreDigest { @@ -43849,6 +44800,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PrimaryPreDigest { @@ -43864,6 +44816,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SecondaryPlainPreDigest { @@ -43877,6 +44830,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SecondaryVRFPreDigest { @@ -43893,6 +44847,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum AllowedSlots { @@ -43910,6 +44865,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BabeEpochConfiguration { @@ -43926,6 +44882,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct EquivocationProof<_0, _1> { @@ -43942,6 +44899,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Slot(pub ::core::primitive::u64); @@ -43959,6 +44917,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BoundedBTreeMap<_0, _1>(pub ::subxt::utils::KeyedVec<_0, _1>); @@ -43972,6 +44931,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BoundedVec<_0>(pub ::std::vec::Vec<_0>); @@ -43985,6 +44945,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct WeakBoundedVec<_0>(pub ::std::vec::Vec<_0>); @@ -43999,6 +44960,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct KeyTypeId(pub [::core::primitive::u8; 4usize]); @@ -44012,6 +44974,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Public(pub [::core::primitive::u8; 33usize]); @@ -44022,6 +44985,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Signature(pub [::core::primitive::u8; 65usize]); @@ -44035,6 +44999,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Public(pub [::core::primitive::u8; 32usize]); @@ -44045,6 +45010,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Signature(pub [::core::primitive::u8; 64usize]); @@ -44058,6 +45024,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct OpaqueMultiaddr(pub ::std::vec::Vec<::core::primitive::u8>); @@ -44068,6 +45035,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct OpaqueNetworkState { @@ -44085,6 +45053,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Public(pub [::core::primitive::u8; 32usize]); @@ -44095,6 +45064,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Signature(pub [::core::primitive::u8; 64usize]); @@ -44106,6 +45076,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct OpaquePeerId(pub ::std::vec::Vec<::core::primitive::u8>); @@ -44116,6 +45087,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Void {} @@ -44131,6 +45103,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Public(pub runtime_types::sp_core::ed25519::Public); @@ -44141,6 +45114,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Signature(pub runtime_types::sp_core::ed25519::Signature); @@ -44152,6 +45126,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Equivocation<_0, _1> { @@ -44179,6 +45154,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct EquivocationProof<_0, _1> { @@ -44195,6 +45171,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ElectionScore { @@ -44209,6 +45186,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Support<_0> { @@ -44229,6 +45207,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Digest { @@ -44242,6 +45221,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum DigestItem { @@ -44275,6 +45255,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Era { @@ -44801,6 +45782,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Header<_0, _1> { @@ -44823,6 +45805,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct UncheckedExtrinsic<_0, _1, _2, _3>( @@ -44840,6 +45823,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BlakeTwo256; @@ -44851,6 +45835,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum ArithmeticError { @@ -44868,6 +45853,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum DispatchError { @@ -44905,6 +45891,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ModuleError { @@ -44918,6 +45905,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum MultiSignature { @@ -44935,6 +45923,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum MultiSigner { @@ -44952,6 +45941,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum TokenError { @@ -44977,6 +45967,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum TransactionalError { @@ -44995,6 +45986,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct MembershipProof { @@ -45014,6 +46006,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct OffenceDetails<_0, _1> { @@ -45031,6 +46024,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RuntimeVersion { @@ -45056,6 +46050,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Weight { @@ -45073,6 +46068,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct OldWeight(pub ::core::primitive::u64); @@ -45083,6 +46079,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct RuntimeDbWeight { @@ -45101,6 +46098,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct DoubleEncoded { @@ -45118,6 +46116,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum BodyId { @@ -45147,6 +46146,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum BodyPart { @@ -45186,6 +46186,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Junction { @@ -45234,6 +46235,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum NetworkId { @@ -45260,6 +46262,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum MultiAsset { @@ -45320,6 +46323,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum MultiLocation { @@ -45394,6 +46398,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Order { @@ -45457,6 +46462,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum OriginKind { @@ -45476,6 +46482,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Response { @@ -45489,6 +46496,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Xcm { @@ -45571,6 +46579,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Junction { @@ -45620,6 +46629,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum AssetId { @@ -45635,6 +46645,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum AssetInstance { @@ -45660,6 +46671,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Fungibility { @@ -45675,6 +46687,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct MultiAsset { @@ -45688,6 +46701,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum MultiAssetFilter { @@ -45703,6 +46717,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct MultiAssets( @@ -45715,6 +46730,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum WildFungibility { @@ -45730,6 +46746,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum WildMultiAsset { @@ -45751,6 +46768,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Junctions { @@ -45822,6 +46840,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct MultiLocation { @@ -45838,6 +46857,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Order { @@ -45897,6 +46917,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Response { @@ -45912,6 +46933,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Xcm { @@ -46003,6 +47025,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Error { @@ -46066,6 +47089,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Outcome { @@ -46087,6 +47111,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Instruction { @@ -46235,6 +47260,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Response { @@ -46259,6 +47285,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum WeightLimit { @@ -46274,6 +47301,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Xcm(pub ::std::vec::Vec); @@ -46285,6 +47313,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum VersionedMultiAssets { @@ -46300,6 +47329,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum VersionedMultiLocation { @@ -46315,6 +47345,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum VersionedResponse { @@ -46332,6 +47363,7 @@ pub mod api { :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] + # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum VersionedXcm { diff --git a/testing/ui-tests/src/correct/generic_params.rs b/testing/ui-tests/src/correct/generic_params.rs index 507571f035..00ae5b976f 100644 --- a/testing/ui-tests/src/correct/generic_params.rs +++ b/testing/ui-tests/src/correct/generic_params.rs @@ -20,7 +20,7 @@ pub struct Second(T, U); pub struct DoesntImplEncodeDecodeAsType(u16); #[subxt::subxt( - runtime_metadata_path = "../../../../artifacts/polkadot_metadata.scale", + runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( type = "sp_runtime::multiaddress::MultiAddress", // Discarding both params: @@ -30,7 +30,7 @@ pub struct DoesntImplEncodeDecodeAsType(u16); pub mod node_runtime {} #[subxt::subxt( - runtime_metadata_path = "../../../../artifacts/polkadot_metadata.scale", + runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( type = "sp_runtime::multiaddress::MultiAddress", // Discarding second param: @@ -40,7 +40,7 @@ pub mod node_runtime {} pub mod node_runtime2 {} #[subxt::subxt( - runtime_metadata_path = "../../../../artifacts/polkadot_metadata.scale", + runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( type = "sp_runtime::multiaddress::MultiAddress", // Discarding first param: @@ -50,7 +50,7 @@ pub mod node_runtime2 {} pub mod node_runtime3 {} #[subxt::subxt( - runtime_metadata_path = "../../../../artifacts/polkadot_metadata.scale", + runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( type = "sp_runtime::multiaddress::MultiAddress", // Swapping params: @@ -60,7 +60,7 @@ pub mod node_runtime3 {} pub mod node_runtime4 {} #[subxt::subxt( - runtime_metadata_path = "../../../../artifacts/polkadot_metadata.scale", + runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( type = "sp_runtime::multiaddress::MultiAddress", // Ignore input params and just use concrete types on output: @@ -70,7 +70,7 @@ pub mod node_runtime4 {} pub mod node_runtime5 {} #[subxt::subxt( - runtime_metadata_path = "../../../../artifacts/polkadot_metadata.scale", + runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( type = "sp_runtime::multiaddress::MultiAddress", // We can put a static type in, too: @@ -80,7 +80,7 @@ pub mod node_runtime5 {} pub mod node_runtime6 {} #[subxt::subxt( - runtime_metadata_path = "../../../../artifacts/polkadot_metadata.scale", + runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( type = "sp_runtime::multiaddress::MultiAddress", // Check that things can be wrapped in our Static type: @@ -90,7 +90,7 @@ pub mod node_runtime6 {} pub mod node_runtime7 {} #[subxt::subxt( - runtime_metadata_path = "../../../../artifacts/polkadot_metadata.scale", + runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( type = "sp_runtime::multiaddress::MultiAddress", // Recursive type param substitution should work too (swapping out nested A and B): diff --git a/testing/ui-tests/src/correct/rust_items_preserved.rs b/testing/ui-tests/src/correct/rust_items_preserved.rs index e8269e768b..f784e0dda6 100644 --- a/testing/ui-tests/src/correct/rust_items_preserved.rs +++ b/testing/ui-tests/src/correct/rust_items_preserved.rs @@ -1,4 +1,4 @@ -#[subxt::subxt(runtime_metadata_path = "../../../../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../../../../artifacts/polkadot_metadata_tiny.scale")] pub mod node_runtime { pub struct SomeStruct; pub enum SomeEnum { diff --git a/testing/ui-tests/src/incorrect/substitute_path_not_absolute.rs b/testing/ui-tests/src/incorrect/substitute_path_not_absolute.rs index 9ef7cbe610..154b857c9d 100644 --- a/testing/ui-tests/src/incorrect/substitute_path_not_absolute.rs +++ b/testing/ui-tests/src/incorrect/substitute_path_not_absolute.rs @@ -1,5 +1,5 @@ #[subxt::subxt( - runtime_metadata_path = "../../../../artifacts/polkadot_metadata.scale", + runtime_metadata_path = "../../../../artifacts/polkadot_metadata_tiny.scale", substitute_type( type = "sp_arithmetic::per_things::Perbill", with = "sp_runtime::Perbill" diff --git a/testing/ui-tests/src/incorrect/url_and_path_provided.rs b/testing/ui-tests/src/incorrect/url_and_path_provided.rs index 47fd5b5d26..90cc5cca57 100644 --- a/testing/ui-tests/src/incorrect/url_and_path_provided.rs +++ b/testing/ui-tests/src/incorrect/url_and_path_provided.rs @@ -1,5 +1,5 @@ #[subxt::subxt( - runtime_metadata_path = "../../../../artifacts/polkadot_metadata.scale", + runtime_metadata_path = "../../../../artifacts/polkadot_metadata_tiny.scale", runtime_metadata_url = "wss://rpc.polkadot.io:443" )] pub mod node_runtime {} diff --git a/testing/ui-tests/src/incorrect/url_and_path_provided.stderr b/testing/ui-tests/src/incorrect/url_and_path_provided.stderr index 5a98277e76..2c9d48feb8 100644 --- a/testing/ui-tests/src/incorrect/url_and_path_provided.stderr +++ b/testing/ui-tests/src/incorrect/url_and_path_provided.stderr @@ -2,7 +2,7 @@ error: Only one of 'runtime_metadata_path' or 'runtime_metadata_url' can be prov --> src/incorrect/url_and_path_provided.rs:1:1 | 1 | / #[subxt::subxt( -2 | | runtime_metadata_path = "../../../../artifacts/polkadot_metadata.scale", +2 | | runtime_metadata_path = "../../../../artifacts/polkadot_metadata_tiny.scale", 3 | | runtime_metadata_url = "wss://rpc.polkadot.io:443" 4 | | )] | |__^ diff --git a/testing/ui-tests/src/lib.rs b/testing/ui-tests/src/lib.rs index 232bcfe552..f9f20720d5 100644 --- a/testing/ui-tests/src/lib.rs +++ b/testing/ui-tests/src/lib.rs @@ -24,7 +24,7 @@ use crate::utils::{MetadataTestRunner, PalletMetadataTestRunner}; fn ui_tests() { let mut m = MetadataTestRunner::default(); // specify pallets we want to test the metadata for (None => all pallets, but specifying only Some(..) speeds up test) - let mut p = PalletMetadataTestRunner::new(Some(&["Grandpa", "Claims", "Babe"])); + let mut p = PalletMetadataTestRunner::new(Some(&["Babe", "Claims", "Grandpa", "Balances"])); let t = trybuild::TestCases::new(); t.pass("src/correct/*.rs"); diff --git a/testing/ui-tests/src/utils/pallet_metadata_test_runner.rs b/testing/ui-tests/src/utils/pallet_metadata_test_runner.rs index 735be020d0..a15378d79b 100644 --- a/testing/ui-tests/src/utils/pallet_metadata_test_runner.rs +++ b/testing/ui-tests/src/utils/pallet_metadata_test_runner.rs @@ -8,7 +8,7 @@ use std::io::Read; use subxt_metadata::{metadata_v14_to_latest, retain_metadata_pallets}; static TEST_DIR_PREFIX: &str = "subxt_generated_pallets_ui_tests_"; -static METADATA_FILE: &str = "../../artifacts/polkadot_metadata.scale"; +static METADATA_FILE: &str = "../../artifacts/polkadot_metadata_full.scale"; pub struct PalletMetadataTestRunner { metadata: RuntimeMetadataV15, From 9414fd89840c5c423413ab99746becb63726be81 Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Wed, 3 May 2023 10:33:45 +0200 Subject: [PATCH 03/22] change drop implementation fix test --- examples/examples/custom_type_derives.rs | 2 +- .../src/utils/pallet_metadata_test_runner.rs | 14 +++++++++++--- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/examples/examples/custom_type_derives.rs b/examples/examples/custom_type_derives.rs index b6e146a601..9e7a22a1c7 100644 --- a/examples/examples/custom_type_derives.rs +++ b/examples/examples/custom_type_derives.rs @@ -6,7 +6,7 @@ #![allow(clippy::redundant_clone)] #[subxt::subxt( - runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale", + runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale", // We can add (certain) custom derives to the generated types by providing // a comma separated list to the below attribute. Most useful for adding `Clone`. // The derives that we can add ultimately is limited to the traits that the base diff --git a/testing/ui-tests/src/utils/pallet_metadata_test_runner.rs b/testing/ui-tests/src/utils/pallet_metadata_test_runner.rs index a15378d79b..613a274507 100644 --- a/testing/ui-tests/src/utils/pallet_metadata_test_runner.rs +++ b/testing/ui-tests/src/utils/pallet_metadata_test_runner.rs @@ -103,9 +103,17 @@ impl PalletMetadataTestRunner { impl Drop for PalletMetadataTestRunner { fn drop(&mut self) { for i in 0..self.index { - let mut tmp_dir = std::env::temp_dir(); - tmp_dir.push(format!("{TEST_DIR_PREFIX}{i}")); - std::fs::remove_dir_all(tmp_dir).expect("cannot cleanup temp files"); + if let Some(pallet) = self.metadata.pallets.get(self.index) { + if let Some(name_filter) = self.pallet_names.as_ref() { + if !name_filter.contains(&pallet.name) { + continue; + } + } + + let mut tmp_dir = std::env::temp_dir(); + tmp_dir.push(format!("{TEST_DIR_PREFIX}{i}")); + std::fs::remove_dir_all(tmp_dir).expect("cannot cleanup temp files"); + }; } } } From 8a514eec2995c8c3b334e1e3c1b59da0217a0d92 Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Wed, 3 May 2023 13:42:16 +0200 Subject: [PATCH 04/22] rust yml add nextest and merge tests --- .github/workflows/rust.yml | 504 +++++++++++++++---------------------- 1 file changed, 207 insertions(+), 297 deletions(-) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index ca717ccf61..bf3307785d 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -1,306 +1,216 @@ name: Rust on: - push: - # Run jobs when commits are pushed to - # master or release-like branches: - branches: - - master - pull_request: - # Run jobs for any external PR that wants - # to merge to master, too: - branches: - - master + push: + # Run jobs when commits are pushed to + # master or release-like branches: + branches: + - master + pull_request: + # Run jobs for any external PR that wants + # to merge to master, too: + branches: + - master concurrency: - group: ${{ github.ref }}-${{ github.workflow }} - cancel-in-progress: true + group: ${{ github.ref }}-${{ github.workflow }} + cancel-in-progress: true env: - CARGO_TERM_COLOR: always - # TODO: Currently pointing at latest substrate; is there a suitable binary we can pin to here? - SUBSTRATE_URL: https://releases.parity.io/substrate/x86_64-debian:stretch/latest/substrate/substrate + CARGO_TERM_COLOR: always + # TODO: Currently pointing at latest substrate; is there a suitable binary we can pin to here? + SUBSTRATE_URL: https://releases.parity.io/substrate/x86_64-debian:stretch/latest/substrate/substrate jobs: - build: - name: Cargo check - runs-on: ubuntu-latest - steps: - - name: Checkout sources - uses: actions/checkout@v3 - - - name: Download Substrate - run: | - curl $SUBSTRATE_URL --output substrate --location - chmod +x substrate - ./substrate --version - mkdir -p ~/.local/bin - mv substrate ~/.local/bin - - - name: Install Rust stable toolchain - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - override: true - - - name: Rust Cache - uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 - - - name: Install cargo-hack - uses: baptiste0928/cargo-install@v2 - with: - crate: cargo-hack - version: 0.5 - - - name: Cargo check - run: cargo hack --exclude-all-features --each-feature check --all-targets --workspace - - fmt: - name: Cargo fmt - runs-on: ubuntu-latest - steps: - - name: Checkout sources - uses: actions/checkout@v3 - - - name: Install Rust nightly toolchain - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - override: true - components: rustfmt - - - name: Rust Cache - uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 - - - name: Cargo fmt - uses: actions-rs/cargo@v1.0.3 - with: - command: fmt - args: --all -- --check - - docs: - name: Check documentation - runs-on: ubuntu-latest - steps: - - name: Checkout sources - uses: actions/checkout@v3 - - - name: Download Substrate - run: | - curl $SUBSTRATE_URL --output substrate --location - chmod +x substrate - ./substrate --version - mkdir -p ~/.local/bin - mv substrate ~/.local/bin - - - name: Install Rust stable toolchain - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - override: true - - - name: Rust Cache - uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 - - - name: Check internal documentation links - run: RUSTDOCFLAGS="--deny rustdoc::broken_intra_doc_links" cargo doc -vv --workspace --no-deps --document-private-items - - - name: Run cargo test on documentation - uses: actions-rs/cargo@v1.0.3 - with: - command: test - args: --doc - - test-docs: - name: "Test: docs" - runs-on: ubuntu-latest-8-cores - steps: - - name: Checkout sources - uses: actions/checkout@v3 - - - name: Download Substrate - run: | - curl $SUBSTRATE_URL --output substrate --location - chmod +x substrate - ./substrate --version - mkdir -p ~/.local/bin - mv substrate ~/.local/bin - - - name: Install Rust stable toolchain - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - override: true - - - name: Rust Cache - uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 - - - name: Run tests - uses: actions-rs/cargo@v1.0.3 - with: - command: test - args: --doc - - test-integration: - name: "Test: integration tests" - runs-on: ubuntu-latest-16-cores - steps: - - name: Checkout sources - uses: actions/checkout@v3 - - - name: Download Substrate - run: | - curl $SUBSTRATE_URL --output substrate --location - chmod +x substrate - ./substrate --version - mkdir -p ~/.local/bin - mv substrate ~/.local/bin - - - name: Install Rust stable toolchain - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - override: true - - - name: Rust Cache - uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 - - - name: Run tests - uses: actions-rs/cargo@v1.0.3 - with: - command: test - args: --all-targets --package integration-tests - - test-ui: - name: "Test: UI tests" - runs-on: ubuntu-latest-16-cores - steps: - - name: Checkout sources - uses: actions/checkout@v3 - - - name: Download Substrate - run: | - curl $SUBSTRATE_URL --output substrate --location - chmod +x substrate - ./substrate --version - mkdir -p ~/.local/bin - mv substrate ~/.local/bin - - - name: Install Rust stable toolchain - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - override: true - - - name: Rust Cache - uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 - - - name: Run tests - uses: actions-rs/cargo@v1.0.3 - with: - command: test - args: --all-targets --package ui-tests - - tests-other: - name: "Test: other (mainly unit) tests" - runs-on: ubuntu-latest - steps: - - name: Checkout sources - uses: actions/checkout@v3 - - - name: Download Substrate - run: | - curl $SUBSTRATE_URL --output substrate --location - chmod +x substrate - ./substrate --version - mkdir -p ~/.local/bin - mv substrate ~/.local/bin - - - name: Install Rust stable toolchain - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - override: true - - - name: Rust Cache - uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 - - - name: Cargo test - uses: actions-rs/cargo@v1.0.3 - with: - command: test - args: --all-targets --workspace --exclude ui-tests --exclude integration-tests - - clippy: - name: Cargo clippy - runs-on: ubuntu-latest - steps: - - name: Checkout sources - uses: actions/checkout@v3 - - - name: Download Substrate - run: | - curl $SUBSTRATE_URL --output substrate --location - chmod +x substrate - ./substrate --version - mkdir -p ~/.local/bin - mv substrate ~/.local/bin - - - name: Install Rust stable toolchain - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - components: clippy - override: true - - - name: Rust Cache - uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 - - - name: Run clippy - uses: actions-rs/cargo@v1 - with: - command: clippy - args: --all-targets -- -D warnings - - wasm_tests: - name: Test wasm - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v3.1.0 - - - name: Install wasm-pack - run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh - - - name: Install firefox - uses: browser-actions/setup-firefox@latest - - - name: Install chrome - uses: browser-actions/setup-chrome@latest - - - name: Rust Cache - uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 - - - name: Download Substrate - run: | - curl $SUBSTRATE_URL --output substrate --location - chmod +x substrate - ./substrate --version - mkdir -p ~/.local/bin - mv substrate ~/.local/bin - - - name: Run WASM tests - run: | - substrate --dev --tmp > /dev/null 2>&1 & - wasm-pack test --headless --firefox - wasm-pack test --headless --chrome - pkill substrate - working-directory: testing/wasm-tests + build: + name: Cargo check + runs-on: ubuntu-latest + steps: + - name: Checkout sources + uses: actions/checkout@v3 + + - name: Download Substrate + run: | + curl $SUBSTRATE_URL --output substrate --location + chmod +x substrate + ./substrate --version + mkdir -p ~/.local/bin + mv substrate ~/.local/bin + + - name: Install Rust stable toolchain + uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: stable + override: true + + - name: Rust Cache + uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 + + - name: Install cargo-hack + uses: baptiste0928/cargo-install@v2 + with: + crate: cargo-hack + version: 0.5 + + - name: Cargo check + run: cargo hack --exclude-all-features --each-feature check --all-targets --workspace + + fmt: + name: Cargo fmt + runs-on: ubuntu-latest + steps: + - name: Checkout sources + uses: actions/checkout@v3 + + - name: Install Rust nightly toolchain + uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: stable + override: true + components: rustfmt + + - name: Rust Cache + uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 + + - name: Cargo fmt + uses: actions-rs/cargo@v1.0.3 + with: + command: fmt + args: --all -- --check + + docs: + name: Check documentation and run doc tests + runs-on: ubuntu-latest + steps: + - name: Checkout sources + uses: actions/checkout@v3 + + - name: Download Substrate + run: | + curl $SUBSTRATE_URL --output substrate --location + chmod +x substrate + ./substrate --version + mkdir -p ~/.local/bin + mv substrate ~/.local/bin + + - name: Install Rust stable toolchain + uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: stable + override: true + + - name: Rust Cache + uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 + + - name: Check internal documentation links + run: RUSTDOCFLAGS="--deny rustdoc::broken_intra_doc_links" cargo doc -vv --workspace --no-deps --document-private-items + + - name: Run cargo test on documentation + uses: actions-rs/cargo@v1.0.3 + with: + command: test + args: --doc + + nonwasm_tests: + name: "Test: UI tests" + runs-on: ubuntu-latest-16-cores + steps: + - name: Checkout sources + uses: actions/checkout@v3 + + - name: Download Substrate + run: | + curl $SUBSTRATE_URL --output substrate --location + chmod +x substrate + ./substrate --version + mkdir -p ~/.local/bin + mv substrate ~/.local/bin + + - name: Install Rust stable toolchain + uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: stable + override: true + + - name: Rust Cache + uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 + + - name: Install cargo-nextest + run: cargo install cargo-nextest + + - name: Run tests + uses: actions-rs/cargo@v1.0.3 + with: + command: nextest + args: run --workspace + + clippy: + name: Cargo clippy + runs-on: ubuntu-latest + steps: + - name: Checkout sources + uses: actions/checkout@v3 + + - name: Download Substrate + run: | + curl $SUBSTRATE_URL --output substrate --location + chmod +x substrate + ./substrate --version + mkdir -p ~/.local/bin + mv substrate ~/.local/bin + + - name: Install Rust stable toolchain + uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: stable + components: clippy + override: true + + - name: Rust Cache + uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 + + - name: Run clippy + uses: actions-rs/cargo@v1 + with: + command: clippy + args: --all-targets -- -D warnings + + wasm_tests: + name: Test wasm + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3.1.0 + + - name: Install wasm-pack + run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh + + - name: Install firefox + uses: browser-actions/setup-firefox@latest + + - name: Install chrome + uses: browser-actions/setup-chrome@latest + + - name: Rust Cache + uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f # v2.2.1 + + - name: Download Substrate + run: | + curl $SUBSTRATE_URL --output substrate --location + chmod +x substrate + ./substrate --version + mkdir -p ~/.local/bin + mv substrate ~/.local/bin + + - name: Run WASM tests + run: | + substrate --dev --tmp > /dev/null 2>&1 & + wasm-pack test --headless --firefox + wasm-pack test --headless --chrome + pkill substrate + working-directory: testing/wasm-tests From ed667dc612d79db1d68b17bb85dbd66381c7d8fd Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Wed, 3 May 2023 16:15:22 +0200 Subject: [PATCH 05/22] 2 --- difference | 1 + 1 file changed, 1 insertion(+) create mode 100644 difference diff --git a/difference b/difference new file mode 100644 index 0000000000..d8263ee986 --- /dev/null +++ b/difference @@ -0,0 +1 @@ +2 \ No newline at end of file From 7119c69af2dc222e36c7e27f7942ebe5b4cd8094 Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Wed, 3 May 2023 16:44:57 +0200 Subject: [PATCH 06/22] 3 --- difference | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/difference b/difference index d8263ee986..e440e5c842 100644 --- a/difference +++ b/difference @@ -1 +1 @@ -2 \ No newline at end of file +3 \ No newline at end of file From b7f98ec750cccf36372011772924599cacf399db Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Wed, 3 May 2023 18:08:07 +0200 Subject: [PATCH 07/22] 4 --- .github/workflows/rust.yml | 2 +- difference | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index bf3307785d..0e632a3ee7 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -115,7 +115,7 @@ jobs: args: --doc nonwasm_tests: - name: "Test: UI tests" + name: "Test nonwasm" runs-on: ubuntu-latest-16-cores steps: - name: Checkout sources diff --git a/difference b/difference index e440e5c842..bf0d87ab1b 100644 --- a/difference +++ b/difference @@ -1 +1 @@ -3 \ No newline at end of file +4 \ No newline at end of file From 779f628d4c9a69b8647b89d0f710b2d8bb09417a Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Thu, 4 May 2023 08:47:57 +0200 Subject: [PATCH 08/22] 5 --- difference | 1 - 1 file changed, 1 deletion(-) delete mode 100644 difference diff --git a/difference b/difference deleted file mode 100644 index bf0d87ab1b..0000000000 --- a/difference +++ /dev/null @@ -1 +0,0 @@ -4 \ No newline at end of file From a466d4dc7996e5a40343d543ac1e1be134ec11f1 Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Thu, 4 May 2023 10:00:55 +0200 Subject: [PATCH 09/22] 6 --- .github/workflows/rust.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 0e632a3ee7..803f2e72fd 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -115,7 +115,7 @@ jobs: args: --doc nonwasm_tests: - name: "Test nonwasm" + name: "Test non-wasm" runs-on: ubuntu-latest-16-cores steps: - name: Checkout sources From b9373984b3b41060eec2cb390edae6d7203e9cd5 Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Thu, 4 May 2023 13:35:50 +0200 Subject: [PATCH 10/22] add script for generating files --- artifacts/README.md | 18 - artifacts/polkadot_metadata_full.scale | Bin 356565 -> 385887 bytes artifacts/polkadot_metadata_small.scale | Bin 105358 -> 116061 bytes artifacts/polkadot_metadata_tiny.scale | Bin 6539 -> 6592 bytes scripts/artifacts.sh | 21 + .../integration-tests/src/codegen/polkadot.rs | 39386 +++++++++------- 6 files changed, 22029 insertions(+), 17396 deletions(-) delete mode 100644 artifacts/README.md create mode 100755 scripts/artifacts.sh diff --git a/artifacts/README.md b/artifacts/README.md deleted file mode 100644 index 60d0b8632d..0000000000 --- a/artifacts/README.md +++ /dev/null @@ -1,18 +0,0 @@ -The `polkadot_metadata_full.scale` can be obtained by pointing subxt to a polkadot node. For that just run this command in the root of the repository: - -``` -cargo run --bin subxt metadata --url wss://rpc.polkadot.io:443 > artifacts/polkadot_metadata_full.scale -``` - -It contains the full metadata including all pallets. From this file, two other stripped down versions are created that contain only a subset of pallets: - -- `polkadot_metadata_tiny.scale` contains no pallets at all. -- `polkadot_metadata_small.scale` contains only the pallets balances, staking, system and multisig. - -They are generated running the following commands from the root of the repository: - -``` -cargo run --bin subxt metadata --file artifacts/polkadot_metadata_full.scale --pallets "" > artifacts/polkadot_metadata_tiny.scale - -cargo run --bin subxt metadata --file artifacts/polkadot_metadata_full.scale --pallets "Balances,Staking,System,Multisig" > artifacts/polkadot_metadata_small.scale -``` diff --git a/artifacts/polkadot_metadata_full.scale b/artifacts/polkadot_metadata_full.scale index b0d3e7de879b563b10e38c65ea021b0e15d015bc..3ee2b601ed519fa5d819ae1043053fdb8f7d7044 100644 GIT binary patch delta 77889 zcmeFa3wTu3xi`Mwwf7_g1eicVCXkQ`B#>Y-BoHuQKmr6o2?PjUp~;X;$Vie2GZP@K zcBHLsX|>gE?W(OFrJuIiqZLc(XzPuhdcN9f#naN(R;%>XR;(AOda9n-dSn=l``Rw?7yQOnN8p`rO|Z<~0ol`uc*gjvax% zz(7|pS`Zr^y#7xsJG?!S@CSnfUMg8>ebK0(r!TNGT0&JV`(ly68ct}MSJPa%TFI#O z1fv;Q4b4lQq51`ln&vZeeq7s7q2-ZxAROrr^i`12u2D^RFc=BMLg4}DO+|lTpgRx? zM}}1nt-?G`^Qx*SZ)kCYMpc86aJZ)<8v0<+ex+4uT275tgI?umb>>_#H@894gj;Jg zza(augTg~i=6*3Xw+U}oXe;n`F|9U9FPz>$B^L&}nuZ#eYdKoQs_;NGI1n9*x;6E= zFzvIUdA0-tefAe>Fq`!P{ClB3FMqYB>4v6hZfz|ZSg)-&uh(ZTX*1fX4udTi>tc{Eojl8k&V5loPluKUjNBeS3YcpTc%O~9J-7*}F1^W%H-7GL_ zX`i{$sH1DlsNtvU%rE2L8_cJTC3Len!L@{LGh1AKy5EesD(O-4i>?a#p7{u#e{R0$ zs;57hMLF{+-#jnpQYys1E6iW#c#UGB+vTR?RBRUIR#TMSiZiXxuWR zFqe**^*t5l7sr)}%3Sk1w)gqK@zB*x^=+8Ba^L*59e*Gs!=JdVe z&CBx2>0>c!}zQH^|qf#GOJPcYa?o;Eyc+BWm1No~|=zC6i~ii;<&r(UyXa@)*4s%j7K z3J$bHBH@UZt5r2eLa|<8hESKG4VpihTtPAOoyjYay~#5lTcpo3x2exv6&>t|Sd*Jx zo+?(X85-!0ZXF2h355CrJNkmy1a%t+`i9#g;XR@5V8r~cXZ_+8s{#W9;n=E3Fc1r_ z4fl1U<%SL6Sj)aaULjn}t!abq1~d~$cE~KrKNr2(mcN|#eeQIz>D`-WKAL|UU10{M z%qqQ#R%{&P1=`dei0;}D;AKbNNH99o7yFob+msbnKDx>@rtVEX-#Yc9$>%i%o#U?1 zG{f!jXjhr{7F5)K%`oow5 z-`+sf*B=^)1-pItH|z@x_yS#B{K@ZKITRT%kM4mc=8J*3^VJnCX+28%%bGgOEM#&uGOs5wP&=<@HOV{c*=k=NsUDFSj&paRJg4tJA zO-+YCUv@3!l~S`W8Vl?SMtoIfpmLhIv3%~dhAlu;y_Ydbh zA&-$e)rM0qs!cR&=2R{5tqG$?7?MGr{&08jn^eMYu;{c&My%O45Zuc{z&hm~aSk=> z(V)5M!hRgr9bXmG&6>Fdbf@{~9RIw#(|}g8!|rxsi(Tx7Zzz7nr#1;vaR3~UL;+*E)DgOQ0u4bJP0 z{K9B*l0KEePaY6?y>(QFX%F>d<*h~1XmnCO{_3A({3Kb7mvX=dnszW81)@?Zrjz1K zJ`MGA0c%}GgE4=ywN-t=0C3dbxnGlw-z57LAFE^8{pzy1;$QC+ZI1*7q9Fg!zdWYa zgL^v00A44+vL_TC!ii?X+JRz0I6gYO*KfcU$1XDOeh(tBmY<`&rXy z95jDY7{c-}I~#_u|2r3X%~u<$vEhprt;N5ciz>xLl614~y)1J@Xq4vzuM~`coxx`E zffQ0R3;uyBIALKk(yAO9c?d*4IFwY<${{o@-`u_QO03G)mp(AHj!N2>F6Gq(N)Uv1 zu=|jCZ1Ior^|MWv;NL%=eQ7~@o+L5U*LcO~AO6(%VU+vOlDEJV{9kEDFQz>Kl5=;mcdFRjbXu^X5{; z;Tz6t(#x8*4q|TxyVniy`LQSHrWzdI{K#*;@`Y|OZDT4;O*Tinv8SoM#YPv+tDA2p=$J*R} zD!|U@+O>$N3A?##*Sc;8ZcOq3Z0fVG3Vb@#P(iHsfhef)6dvogc@!YD(9Y06wbe){ zisRL3CGH37V(*S6MC(_Ahy`u63b0SMb`>|~WJ;dysXF|caaD6#ovE!Ibq4EiUmffU zaqm{+WRHeoZGC|*Mon_o$H_Z=Y#@NtET}ZD;U3sv_F;y6gQ~b9Kf0|7{pP^=)4Pq2 zshk#-Zf62)VyWVOGH&2JAP`l5@Sr-B>a7(17V4K{{OSYu^F)?hM&nH zA8<)KKO6V+q;w78j0H=mKJy0SV<8HZhDB%XwDX+}Z5R)Z*e3nqJz#+ptHq0yS7kS| zKT2NZZ-fx2Clu+o;b|y%){MPdT$)p&d55C&trBy`E@27WxD8-RRek5!nMVV{AqGMZ zFnHe?K;S?i*C?lE`InE-v~xnSs1Kwox2)uj)`-Ck0~(B=0^P$3)dU8CdB9xwea-3# ze4py(uCcr6HYS2eN#Uo|*0w4Gz*RHoK@zK_D7>!TVE0fT^LLwrmj}D}1W^rc8@s{( zHeAM;|6Er)-q#LRpnKy`%xdt=N5hEK_%}_&c;n}zLx{PNZeMr^G7cZaQv9$Z$O}@f zOhBaqf~2k>PUim$V3}Zw`dM!81z<>>=Kd#vlE>WNXv=1o>VUr+XLnIQq!_7V?0@J` z*!DhfF+?}K_0$oox-=3oCy#{;HcGALGr{rwQ1X+Eo0F8h#iWb|xG~rzFurom$Eo1* zGi<5%(}~Gx?8MleP`nY7jpG)9q;(nE5|Y<{L7!&6`}1jYml5T8*Mm~*8iqK48N)jA zC;}fEmURPtp@E>G9nUe(e#Teqe4)I);D863kcA60FbK=Y9DK$%>CvRJpqc0%bN|V0 z=DW|78Jmb6P>JDRlpB{29Wk$edAs?aznEccC%Qv@+4IX%J z8Mkm5uI&%c7EUU`Nw5ps(a`R2^1SujOyhAU5&hLn<2fgB`d4MfL}8a6e7@YM6?R`v zKkqY^3Dw94%;*bqjTS-AsYc3vJG$H>KiQ-8}l657A9#{_`E?%`f^eDg0FO+e&el zZpKe`m|y;_&$vgoCu`R4{KkDcy{Djc=ywZ^TMQeht6r)y4jS~d`trk<<{3{KbW|m_ zo~$yPe;Y7=b#kupD!;t`%*!e_v)? z?XoM_`%3Y+t^I?BcECjkRh7G5Ei$fk*?s!;tL1c~`I(oy%$=`I%Wr54L;_Jo0jia9 z6MvbLe31sZb6H2U6WX3g0AlsKT=qatzBW_b!@c-`x%2f><35+YgnsjSx$%INX}j5T zs@!paST+`lBrnCov0rL2wx2!XfA|4D;WAR5z)W$Y;M_uDQ(e zry9Hsl!sgzl>q7P3JynY9FTLk|0#p=(z=>!UU_Wq^cLo%*O7)laMBG8S}VV3&^FQM zPG4wjWvT7KpL@-x-aK0Xhdlp>S>}_c9~$NT;Zfer(hcKI^VsPb=G-?Yo851294(J< z8D`B}mGX0&XnoaIs5LBgjRDol73B782oJEb$io6|LxUa$-MfUKP+0<<>bn0pMRkXl z{t?2~y2Izc?Zc0`>z$v9?PRWccdZDJdF{K4#4yQEZ=;!qfBmkY)Vsr_fBGGXE9r2~ zpFg5rf9fyuJA>q2*G;<#Viu6eJ*>Wn>?VGxk%tAKLqwh}_ywB{sxTVs=mil7#6aX- ztDZD!hz3D3c8~m`1?k3OS}-Lc?mMt2TQrdd=pMho)#P1MQ_JeW_-^hx>We3~h4 zBsp^m6;Xp+JcSli+(hKNY^d=Z--5dBtS!8er}UHBP599Zu=L&9EyUWv%Cd?!2QVF= ztiyXdx}k^ab(5zXOTr$-v;y!UL%~x};4WS27-wiD@^@3{?4m`~Ia&>}dMdq9b}{1} zTZM$0A&%{0(NrGgL6~9HULMb^m+GLT?SL{a7y*Zv_07ALwm>w-9AhN7bEq#6aTH|C zfd*`qj4d!Z2ZX#Y&=(DZLE8n^G=MTzt;s?=K<1yz{OT+HLs6#qRn<{wbXgMU=<5W* z))nkX1578_U|3rOx@B206+25OH+=>gN1FlR4p7TJh#C8axwoTF!!5I zt&>a2D{n5NK=BG&FWX_yVH9T-@*E`DyipXC=lBL~#V%Gx5;D$&`?Z)1EYl0dcWw#o zgwDFtf1Nz`X;EmaWs@pjZ7Zqi-V0U<>ax%t^K{G9co4E(tjCxS>ItkXUJAU_>gy^k zQDkymMIrVNvOYT&ZYIo7vR+@+MM0E~`J$|ThXsQr54M!TPA=c&ylNqG2}f{XaM#ox z_SG{}fYrMV6252%dd*NDhz;zJu3jkMp%HgxKXaeQN1O88yn1Tx3t@qArK3(B)YmMl zfXxLsXc%CqoCDZIwR=NY@m-*IAnM?5#D@JEr8Y|X-nb~#w-Qj|jm z3&uIazJ*Xq4#aw+{?#M)Q2O+jS7l-ici!D&APxCQ5f#ceyi_ZvoUgaKfgZuv+<{Z8 zoT>_Yq01a#EfS92SR@QyJYp}K8sOf6n6q$mV$mF$ zAs}ShR7JDumA*NGRfhit!oDG;uxDuo7Qn!+C=}T^g?&lOnHG{)RZ+<}8*K%<6Njq^ zCwyb#*VQyPdjLO|gHFP}t z1i!PE{&ieIS1&8wbE@P={q)`JEEw?qf(piz3a;Ev3cffeWnmpXSC|Q1uLU2;z>;Uz zQ&%aMPtBk)aypBIyGG7jKtG=XXnls+XIKD)B7STtt2YkySnk$bjqOwW%kyurPkS)16H_&_7|jh5FZr!1v%VPnd~x~23HaE|hc zCR$YX1<1j8oAUXFO=>F{I$6=w4bvbwXBmBlY7$45(bs57CP446^)<`*xpY<)Sfq^A zo3#U`mOQ&zWsq%iK%{-NnKosQ{`qFQIC0fVx=~~gMCOH`YcjqS~mi$7}^tp8jX?K?x7I)Ld+-A6#!u;Hv^KKr5e0GdqO)q zm3Y>+VzS`-L^gakDveergtVaJmBmw_Z?6u+JNb!Cbddn=d0`X9#^1xJ?0VAfBW1QB z_id)BxE=eR>5T``0hn? zfedV=c@`J(B+0f*XdWGtAG(B=iQOc>eF>dQ&&qc%p|#>^lB+MJ_2M|m&s|FG;u(@J zT}rF;r^#dPzG7N^LqiHJ;K=ei1}KI$8uxVEDg|2on#*YVs0`4M08=`hM!tS!JB3{F6Xeb?oaumB+d%hVV08-?=bkV~ za|n3b81`;sE!7zt$fLQ*%L_HsT|)(!e`Z?icr82GUnE+aUc6~-jc)@CiC-Mqmi(7) zno^vsn%pI9fdQ?Np`9dJB0FFMBWt_K50+YP@5X9AN%FlQRm6`O7t*U_Y@yT4Mb|}G zSKBe5_*zG3;sf;o3*gxBF^jVg0j9Z+wJk&$Qp3{_Rg(N>41bg@v$%zu#-M0={PnK$~T4R5>Y6m4AJHMt6xs_qFBhqm(%R^rGna+e%Lq|*gX_% zg-vZJ(A^!unkp7<2dH({*S26V!iEiomX0k-(P>dGv~nTuxSZxpO8-_VVEi>l{^fF- zB&vm+yo;vc*ZjeU%RHG=QY+-#T{L^z`VwFx(9tmRNNUZNkleJJrosTqCcZwji&}{K z6G!`K0)8b8(^UCFKjm2VTqOy80OAp0my_ED=?x?jsN_y^-XP6z&VftW>{kA9(zKU*gCG$Y2F)ne|$LSYh28-?&ELyBl z6Ij3rC zr_&XN&N(^=x|ew!X3skvWsEY2>+~-pAO44ejun)BUNTD}=Ragj+p-thJ*()JA(&{k z1};Y%v0+=u+PQ+u`;Y+*^+FQiza+cH)xn+s7G-wD?PFEEGr;Wq$ckICD|Wh)U2{CG z<`9dHos1*v{66;`qqlihrp}Z-F`I%at_;S0$~ZE)l>KjJ6#-zgW-T7Divm@KqRvVQrr-RgB51m}<{qm6;Ab-kkTQo}lee^^Y0iKxr4Qi#?9zMVGQkXH_2(UmQntmC$ ziKeGypcRQ*kIMY{v*{}(~1EI<1Q6(u2>)0sH*2;Hb>4NI>0D!pQzQ_aHs>7EMF@{c9)k0oI( z34NWgOi1P7$EeI^j|;t{3xl-v3Hn!>q03J_PLF~#xZnr$6v@gbXmw*I8*}@{s#Vy% zec_!|tE#K59qe1hqGND^-7IVfTCxVe9D0I$`K^Lry*mIJSefqYZHccuL1*jouvR5b~y{1aqjx+ec2zO=LUw}I=Iv~ zoxeAL&jn{_Bg}MJKg1))Xu>QT>2pj}{?hbbh_CoCm&bzAGFFSrr%Yh31>Bsa&U1sgq zIF*N@&{V*zunWQ-Ah!rAvf7i^ZK4gLRmj`!(PzlZk5k=5N1g+MbCY0e;py_|aV!l` zYxSQJUit2E+MXoKcK?)moJ39@Xj+S=E0U9bM&EXXE%H}CqeGl)(|(k{^XK%GU8E>+ z-7_?f#8zSUpXZf_e?b*=iY<)`On>JD&crQ3S~BIAbf_eAY_?FWDWVL!R9NjlJvq4@VN=#Xx{I$SDT8>Vc9fk(3 zC{gr081zvpHX7u^FVIgsnHAq%EC2Zf%}W@+rtK8JM2u|??X~QXJ#5hnpE}K0hXJbN z$_>8&NOLVZ7+_f4hLi$pU#l)YKtlG!5${7Q6 zv-|rvm{scG0h(^8r(X}ye4!P}!7HhH4ZpGUOKOQJLp^?C`MDp<%`(0A*j|^gglU2*ud6)4A{tq57T909LeiGOp7O}2^tJUp_cG# zE%L+%X@Q(yD8|dd8^km@BThw4r~WDsEmWm=54)!f5cY+Xb#d~(UkI!k3j$CHuoo7X zw=qT!hi_%yZ{wYSUa_4lDW2*S7si=0Wcwz9zQyvvss!CW-{~+&c=$wj^(ue__YFd( z+3jQggq1aE(DbS<$o&Jfc;0P)6*5-G{rAiKx2ag3yoxr*ol%4YwcAYQD)u;bwg78e z6nWWtZ&mKG=4CEpJ`V(!p9aWZnkK$qh%XW!zcAy0lu~EM_j%SFALf zdErm{Qsoj)@266lcHO$38ecEOy?cUi0d$Hb#($LlKxN=a*vtqtIhUXDK zdsdcTO4Bf! z{j7a{%9orpxRfNhI7SZGjj5p*p)iK)sKS*4D7x7qJFljCmqHoxi&s-{0)i-{uO#or zF<0Cf=E${T%sG_LEmGa~#=$w2t#wsv3HdwQv zTJf>5)?X4-BZjy|Nrg+cpW%ElUur0wn&*REBHYL$aE4PyMnIU}MQbM2Z5f2Jvv~*P z`=Nn6vuROzXGy?HrNy@Z)etyC3#vj7A1^H6f;*2EJVS2z=WFQlcu1rhI{^V^TRX8S zDE|7zNJpK~PRt6g<;s#rO-VKj@)9`J>=v|bWq4mx8|#5$QH#%w^Y&bhy_u9REE(Om zMxzx$c79@oNJqc2^|=qHtrJ{;4Z@q)*o1MCWxxdaU&SGdV1ZsUO^|@?$*4!ET9!c9 z0wZ@tP5Pmf!OUB|#ePaHYvr6{GvwC@n^osaX-oaJTyGXQ z?4#3a&2n(J5T#mVHl5{zNNK1KN;A0FT0DQZzb~z>xLu1=x4)2E$_A93$$}cTtmRFd zgm`)*3}QaA*0#X+3ML|IcA%<_mf5_W?Yh}ICv3n$NqHGe-%7r_+rkjJarYhX z7Cb-@3e=UQJUV zpc~o17(igQhx2K(LrI2j~9*CIxIk7DP(Iqj>`ETr@ZrZZw%Ze zPEpLZb7ZE?${1tgN$j-B**ns2A#nMjVVW{mDVpu0Ikk+f{7^r4`aSHUV6E9Q!+Y#Z zJ&^xAR}{~^VKfMuNh@~%)MGMFw_ktWNJ-XJ&e0N zh*8kJM+Jk(!eLmJyhR7#&d9O=9PND^E+7{4`#7kHPmyIDdV_s?`(Q`Ih{HlR>B!Am z9=BVoBe)Nrcx-k@;_TC{*1s=c^`hIq7LroLZ-Kg6Epc|j!t|=mhvOsL15?YX7?(Bz zl?{{qK06bJIuniZZ0*n<5Ei9qPosU4#{ae*{s+f_zE+{WfXkiWsm(n@T} z9U%7xQWXcV)9}dwKSN)6t-`_@C!H{v$OfTF`3w}9nmSt zvq~ZF6i&)5sV8gCs&S^yG~mQ^1U?dJ{5P?ZqF+O@@@gtL15O&HKWD^BpG-fzMsq^y z^k-|YV24uqahkUMeW|P5C11!;SEV!$Y*L!q!!LjLXoqC~MSIQOv2* z#S9Gdio{B`)e_hFvQ%S9;yhK>KhehZYBwteT_ImfO|l@Bk?Upc3)-@(PYwj<_1{;2 zvRlY^Cy4UA5^vNF6gC8PX`ZMN!$NM&6PJlA)o=6K1o>pncSCdF@_N zV;v}cw$)KqPN2mr+Tp7ig*G3i^;**!cm{^|Mtehp)_0-Rofm{qG|(5fUg%m~^N_+< zR@%_2*0Y(Tm2zq8Hz##!&gmAxz*eMQs{@AvXVq*$_`1IK&>+;8U<)c%hIZPCaax`F zwnYU=ifH4thSo(0CN$LVyqTa?A-j{x(^e-Pi!9%F)HqRNaKG@Pm?>vX78R3WL%zQw}>SViuO&o22d z6-Vj!UoIEzH2O00hclD^6DcspHzikkmjIlW2yAeaFb*Bq3Sl z*$Q#8rj=_Yt>J+XLWLRHYAR8_GBCt~7u7n}g<#p3&mURdPy%BQ1Q!Vc>ozJ(t$YR< zm!VyseF6+~qjx16HLJemuXa`)X}&c$%(w(h)CXWuYMTmE0qoU~G~?eY_l$UX=v%Yu zvR~Q-4NbczWd{ZE5Dq}h;eA5+_Qrit+mF94U6x|hq)Af9gV2J_Fy-`6`fJQ)L30l% z^bsFW{gITs2x1K@RA#!o2)3eFrj2{!&c_b6Up1(Le{98kMpP=a2F_aP36m8DyZ>q_ z(z>1CE*;tBV9U@IAFDZ9p?VS==t5kx?v9irGp$!2_Nq9S9S~(>okvrFFNJpVm<@97 z-VVp=1a8z_0i&|8ve)5tU|FOT$kIPIJ;%&Pepa&pvd28H*P}h1flQ8%L?*{AWO7_p)*_w}^7tvLhO+f9r|1{{Of_E0 zFRyA3@IZ%Rli)dR6lvKXFN+ySfzFqz6f5VGxPcnBXXEs0mw{*iKR9c)GeH9~JpeBzJPGqyip;_-Lr zn86+T(x2&CaYD$W-_eWYFD8re`QCyZ97dIORampp7lqvR7dZc|OqqwdM$>Z%P6H2UP8ZYxwQGL!hS>xZkGd06&1?FbjIQS83$cV~G`DLu;lEI$DU#S(7CPpRsyKuRNPk+=R4R^04mJpM(j zen3n+Ddcx2i*u6t_$ul3h;L?F8U4&7E|{j6R>y1^*dsL16Mj|5efgp`r>UC#3uJwf zm?2B2h}^`J`67RW(bUN);)Xir`8ps6g?pQae};9-|Aw74lN3*lZ#8I)>gAefOw<>^ znK`>hHx-I2r!*?Q5l5|MO08jm&qEJJWN!0{$I4c-8kaZkT~o2ljDv;A|f!qdjq~SiDVHh6)Xk{A{e+3}cjwt2_NN;1vz>hhA~MJikQvsVOmB zB38cNGWjJ87_<#lqGFi)xl2VO+^uqI5|_^uWux!n%}zJGja-}UNeBpKR9fHy0=BiP zBDW^d>JyXxN__=Ys&}DaUpF?N)4>z7MZpZ%K;q?oof_BK6R}3U(cCqOqFJK;uhd+& z8tMaf#!F2Mg8!vW3>ukkBQ$Rw*f4wc4(PJHLS)$Aja!}ATp?DA_d84H&J{&=%|&AT z+Qja;;xD5v9#09(UwF}iD8j!ss)frd7U?@8F?F6OC#Q?fTeV;WC5HPQ@s7~mu?HBh6Gid&)Cud^9M}uqm~nvMnfw`Vw_4WF|<-7 z#%l%KX1vbO%8{I4CDDgUr1Gp3I#G?(L@R|})FL&>N}(I|NKLj<=*S|ZJXQ)lc@VKC ztps|q1fQl@DRgBSQd6ze5+klPBUzx53(yz#W-qi-=t~Q}O|w$y%Q~crtQ7jvij>z% zp)Z?|Dz;MS%T}bOTPgJA5~OBWDRgE#QYBUjov8^RS!yK#nIKX#RcawR6GE!YN})6T zx;%G*xJb}FiJo1d_r>Pt z16zlQ6N)ix^+NT?fYqm|M~13iq#hZhIxc2FUWTV$tR63k^Ye7|%%Id~s7D5)UZNfu zhI*-bWB}?j)nh+DmZ`_xcof(VLwdSi8$@b0E6a-kf5V*rN?pSrwonfCkG5Y|IAV?u zT%)=|g8kaA*0Duus38NxLhz;XdSzFG=n_DP3b{Pr09hiUt{M%w-?QrA3KLnnXy?sHXZxIEmnlZ;OQY4Yv;u^5qWdoJ*32Uc{V6@cw@3 zSpflEf5N{)RHW+YSR=;6%Vh5=@gtF}*nWBW8i4>NPN(gc`D?|YtYvtsPqOddxm(_~hz$G5+j|EyU7`2T0E5$9k z?A-`Cvqk!PS$(jtBbzFvn-f3UC|)zNNT|gBZWmt`<5t+Q_Bx~oQ3l?Bqm}aJi^Z(G z6!9zeNi-u9W}Eml+!ZbpS7$eP#Wr{X$+aD#~{pHEeI z?uEMh<>cPf#w^ZL6lb=*rUrxBOMAr})nvu{X;MDXD@sT7Twk5|&t5S_AB!WZ=@T=i zW)IgWxj|mL57x4K`otAumCWzQ#PrLv`bCMo`HFHd!qx3`DXh2_5>pxIjMoIblqI z9V29_kr-U-gF9JpPN~{E2K^11U4xaNgjPfiH@Rnf3(_qt*_Gqx>(4BWGH)_vz;Ro?7{fo5ei$ z5uFaP4V--RmsknDTOc$!U?f)DB7P{uwT7H{oA|A`-blQ4n|OjoW-d(p;mbl2JE490 zcKEBpCG+dI3!U^My4$Slsg%z^l3n_Mj%%C{1*UI^g~$)+aD&D{AB8Jq@M=Tmd_|Or z2Xs02D`H{%Ax6bswj+-&cs%vI@VV4;!^zb1qPJ4diwSaNyX@H$Q_qdXspln?{9K~y zudf4@n@rR%<3!y4v|wG@r-fV75)Fa0#G?MR#NuHjG#-FBs%!WI_0~_1=^FmD92hO~ zc*K*shCc`-`{`*NU!GR^9@CHO8vb&%oM&|H8J!~@RK}gtUgOb=6S{^!Rq{nH`63cJ zli;X=K_Xt&HT>Py#swm_POy(m4!&#Jq-?B55bB1!xz{Ec?Fz`h+xGXzEEoZ3Z z49pTB15b!x=1OIV_tO&20Y*hroC0$2EQw}A!=LJA3ukEI49q_u15cc21;1ox*u)t& zaR%lpkbx&tTmm-9&aj;`Z08JlR)zp)2!c7}bzW%K z8tI(F)y4<{=4w<80`z)r_C`a)AJ(3B6ZlI*{^wm{J(bF}UlVi0Erwa%S1b>F4OyXSJKtWusZiDh3Gr%2pk z$oYpLVk=2pa7fIe_HmH=!8C}YqjbO&EE2F}_2Xp6&14)j2Vsmg;geV1C+-rVh^+dCIMJsqvzkcHl-5WWil!<@sFy%*ps$Bz zrz#Sa)7Bv9a=Sq%7Ll78tsXdHGKV`j=dj2hA$HTRNPOV1Xd~J#@BOA|n#trx7yNv! z=xMOIvJ6{b*%=Gh`4W?lh@TN{lE3?w*xJa^R)W6EI&G7Tb!-*agSh%jms(Mg5O7Sz z<6>{=P*;cpq$!!PeCb=l2P=CR%ETfN>V{#c3uxOxkziau5X6Oq(Ez?xgp zt3s-0hij@q^o{}Bgue?mBeFXoYH-3`p8#9el(;t`UU3$oH*w?vaR<>v1=R5lP_-|} z?;HW;`{Z}9bWh2S2N89_nVru(D8@U9@g;T%>tj*knFkSsW5S>2@rqRQBR4*busW|j zEb?9IjU4}o_~GABrB`lxR6OZ;yCoWq3WLO5hFtnx@mSHb^?o07Wten3?v2$($-f}5 zMuVL4JqUrf%jWNiM!Ru*m{C!{YtgSfwyiiiQ7<)c03Y6Ppl=7d?=h@sK+kD%P`XuF# zZcm8yt~jybf5SDfWJNaO0K%~bWKXxdKw%XN?M#nPs@O`Mmb#G`Vj**S$!Amf)xr=wJN*%xZRN2 zhOlN(hOuZY8_6llPP-!CvSlR}!h>rHt+Q-7d0Q}!a`Kcf^I3UnoL8Md0c@8HT#)KS zd_+s(ov%MZxgKN;)9G(xjX-wwh*t(PFT0+H3~E}%xII<1Ho0yc;`6cbnGaqNDXgrt zS6EhT8_p;_RSSQC3XIKT;}IW}fL0=vfxFwuK;khowquoDcO+wm6Wvt{JwQ;jG0~> zu?2fkGRoK1^adHjBM<}zta=m+V_m19l$?O%&;tVqjnNgie4p_)y=~`c<)Nq63WE&| zS=dIaneA(i>>OgXS5(`Fz3ptGT3@T$7nXS@ci4XnpTXvZv7`_I&2lK^+PeDUsl(Rq zn?K(NctLl=QAk74wW>?@Deh><3)Ip?45oDDp62mT<~FmZToC{a{ZV$WswmzG2a6p+ zKH>dZfZEcQPjVA*;1zWjQ6PPilMu~b($VNe_G)3wfEAC(lvgkUQS+jXVGMl-yKZ!K z6=9|I4E6byaxH~Q-JgpT#2dlfrlHrP23=v>X;ooj`LezmzLF%V;)HTDzaYk#lowj6 zvb2f7(#5cOOC%92?+cEy2PKYL>d9|$a9eP_Lp;Z%=a8*eQ;{jTjZXW(?%YnXA^5@i zeHQ_5uy<1Oi^54(FcNGMrvlbKW5L?TeOhM})dJYSGA5370Phrb^iWIR4rzi~qC&yfaHXZ_tM`OHkN3T}ZszThQzVkr_gE(HRkfnKG?};bV6EWhAnMYh&1iUE) zH#ne1o=`tb+fx;$fn0e8t+QNsK?Lnn+mvUY=LvWSaNvE)(}~XWj#IcI$|kP3hK_?w zLdnci3MmI$C;1lvBCEy*or=5%;IRH4bEK|2=0LyzTrZ^Iu*O&6_X42xaF<(PUxP2L zr~M~e6$u?~h*e!pfBW%164iUNdKsm`63 z3S;|yZC07>lq$p%G8hP1cdqcfLnCah>6p4SRdot4QY8@d(7I1`WDl_Bv1g{)i|T{H zNZ6kmqC9Bk|N0E>7V_?Z;MbFuvT55z<{_ybrogX(kM)QKah#Kg+? z5zr8%m{WM7%=sazd&qhdA8~4vr!I9m1-rr6UYtrZZe3-Q1z=6HzBuR=+TYcgWk3c% z3#=W@;CLSc$6KBi^8PW4<>ep4eY>VTZgq2Y8(OtVjnrz+vK>T3z&geX&ONqiIDsla zCCS^~)u)Lk4f)z>y(Dqo55-qOXUlh<634{ThWSFgRDSqPeNy5-j$tNP^mXvK2(swQ z{Zp}m5>tN;*(y~ehJPvixv(9(^Veb@9r|kdzY9T!eu-mF5HwL-lwhPzTKAlXy@+S^rW`ztnZb*7r6mIkFfkPJzi*}CI zLBMrA!xdzV9rOjF%UG{{)dI1bEyvIAU=kUdc{t64QG3QvaVXDgXv*q#V^(LO^n4ER z;qZDHU*KH(92SE(VQ43;y5b}1YRD)7*|6ma0DjFxIlo-MpYDCxI=(3@7lHA z@?t}--er`?fj>kb+TXG-wsP`N-!5x#kSn4k zp24E}hSAz1H}2WAx{iHZvOYKv0y1Wq(#iB<*^MIprM*N^%4fx&!>yet_Nu||7a!qU zQh2{S@}8bA-}q19uD7fg?%#nYe8-TDzk@*xez|Lv4Rz}V_(T|pvF(eIw|4br3Uav2 ziXEYtWm5E>As4?SmWpDRjJyP2o$W4p+e>0zK@h?-WY@I!cny$CBbQoF*tc)JB+Acm zxoS2;+1nNv?h6OH$>oAXx&)*Vr(7-sDz+XGWDuvd9UWO|qVrvH(@E&E3SBaMQcM#r zm+C9(z4atCUE}12ImYZtZ5*r~a@`YM+C*2L7rosR>?%-nqi20|M;)M}p&}k63KqXC zX6S{<{%v>})!T6##}}g>QR>o4t=yFj&;as{)vKH>WpG$ibRJg8_9iQL$?v}`=8LT^ z`OeFbE?8ZH5V^7KV6#2Ws+Ca+?56GV8S?gOxwWlR1#$a@0Aj8rgDb!4p72q#=$A1gGgUFMoAYnO4zMz&-p zoSl1Y(`oxnT@XQ@;c{eM;^E}0uoT&NU+XdtU0H?;OO9PxD(YSG^gGr`jTC+zg1?3zxX4aqA$9CtGon zF>cUkeJ>cK55iM4&<6>N^>&$y)~-#yPRq+gt-X{$g@YdJ4z6>_t6mWmVv|dLL-q34et_Zs1=U&4h9CFFWUlZqYn#XQl^SLR$V#o%z%KuWZi(8SVJ3j$@uFKr4J>$f-L7u zcbX#&LGjgDU{_KnC!d0T4aICsaMkN#rpLf_$Ciwj(FCrLdLcef-g-*Ro0f80BPR9L zB5HNX=T9NHvyhuki>bVpdQOYzSXo~`E&f+p);s^8N=|7CG@!;cEzh z=y2SR@FXz?an9o+&kj3l2SPo@I)-q~FAIm=)Zn}aM;-3D1^5538rEKdZTt?>+$MNo zS(ksqM+2{hiB>>h;DHC0iWaN#VbxfE8n>w4j?y{hNQ3U$*>RxqU6CDpg~CA>IqN>k zGzMR81gm^dFx_{!XuS#tfZ=WATc5guiqsh8j7*>KIqZFeV?u2bUII8fo`yX}YDoaF z2US<+jD+LJ&S-9VcZhryjmZ;FohU&UWZ%vis7@R04pr&-BP$(!81AYyygpSw0mHgx zE6lCxCu6g_T$bBQhgl@`3Ho%b!I=~EBHnZRrx+!?gSJl4Z{@X_{k~?BUP^d>{$%|- zQ`45FCHp!c5?+rUL&3zgQ*$BM4tm?pSkJA zsR>^x`YVpOw~?&Dr{kQ`2j(<59|2 zD)i~%N!RCV^;>v$TBQERU5*3hLU>0#ju!QDENr*-WJd3v zPWBE~vi1#fPg~u4+9emy*Q@Lp@Z~mHT3C_l)N$YoyHi_~@gZn7?$>dbd~m*A>dExb zdd4MB;_c)b4?H|Mz!YD}^_)xYuG7oLm)JzqdoH=WPOlf%`?L7>L<835eL3>r3S2n$ zZk>L=KE~IDiKay`Wx&lIVu`*&hv{Kr?GmgRalMe;=V19it3n*iV!esw5tH(^fqqUo zL~c|cWI>aDH*@pfZPNegZzwjrO#hJGxtX$HxxVFZD0|g%{pw`d%5(MJzoG0`&ed-p z11Qbno}9#QR_HzO+fuO3hN+dIMfV#!S3s`KcX% z7TT~L+=ynqgHRCq3uTIz`<%mwG zghl=J@S5JUF#98fPbXZq`~L!V|1W;gmEr#XV(ROE9;%9;#GcFc@6ULrWu$EX{)~5- zIWkkWd;ggEY~|m7h8$-qo%zjn@6W6&bNrbF-haw=@6W9IeWh5%aYhJa zcEa}We_vIwm*&ZC z8OST&{erAdNuT}VQ=|Fp8`^1?dEb%Q=EuJ|^Q^aUUT65`zk`LG=9{m*>dLc%U@S17 z|7M9$MJvr&M~aG0kHLp-`hs3z4j##^Z%DDAZzXFAZq&SZ4DR*@oQJv@O<*O~ULOImNXyxLr{wDi^i(sE@+MOY)0SQ~0DqH;sTqMkmj}(=a=TL*yBrXbJ z`92f7<*A%kKT>~|gOo_~Hb)|XVRr3H#jOzbTX?Az>*k3^rr}zsw;!qTq{)de+R7aB z+(#>UUH3dXOH}8WpL(>hp*kmBJXM=BLOfNAlIRcr7;aB}j#i&@xc6QAxb@~# z>E9onzhJ~9wP1$1RQg1rSWBwd`tL5qqBB4FU4Pu#)sh@qzd8)ID%fJh(`b_OL;6{NFXVTlaFE}mVne$n zhgK^L?jY=S@RQf_j8qKbn#v?8@q*5IDgAmVYQV?YcO7;p~9ELON7deFjN$>9R` zO<$Qu9uBNLdUc+?fq__R{%q95uI;#Prq8DH<)K}`W2pS8@4$H{2}^}AGn)JWPPh_2 z-KyAPMQhlsBwcH9*APTS5N$>5a|s&Op77{{PYq?{=*{OIED`}5%id#Q**R#kf}6BX z+Cqd73&x;vVy!$>aL!k`zh9p>eZ)X*9E>q#;o$PP_afzC2nX7=TL;(>0j@baf*0b_ z93}u~AT}B9n;o$MEC7~hP^Gf9;27UawL0s&#bUx9d&IJiTUXXChaaw8S4$)kjzHoJ zBEm5if@x=sPrV1c%d|GD(smB_0R+wR>LKVZuLs&`z-7tR;43bv)^~I!3a!taBmfi{B4zM z6WhDmUqS=nBxNy6YqQo@_IO8MShKbDs}P(rl9^kp(3%i72@&&PDwv!NLB1790=`m% zdYC1)wiX8p!T~Fq*1?RZRLXw~=1I!8)7t07aVC}1H^m&S0{rGKwJs1FL2cVW4ppT# zx<>Y$wz!g4WFNnCwVJIe68;%0aAM5}if0|)Ra)Z)_|RB&1c2nm>O+CLzG`F#s(Dib z7e`}O9b=XEa&+rpBtEi+d1{BQ2?nFBScwMJT^@?5XhUp;=?E6i(%5deJvh}PnopXZm2aV!--_AZP(EVtK=z7Rr3--E-;+Un~$2?4dz z)Y}1LMs7@JU(VNX?m6)Q$0E??;lSNK8ilrBaL10 zdNvHf(gz_8)B*?c!imll-4IiBXUB1eo(jp%=OiL-=Fk^bS~g=$(OBR3Q;iSy7in3S zV;UM+g~DNpHbXYl2kLbcvbep;Ez=ipBj(}+m56#fp4}beWBgJh?jzVpPg|!vhSi=%5#CmA7I*+}&hR26^ z4|N-Wnp;CK9>fq3@nOAv60HN3V%h=Z|j1X}BXX${UWK0|=Qtd7ml z8aKy-pvIxNUW33OFw!c~yc@!+VF`gK5LLW6(R6DthSNvkE2~@?dJ#_9W#JU5+RA}O zQ4OjnSGdIv!^^luo29MaIsntbZnS_S+BrLCYilnGnuVX9a#@P_s?cCD5@8BYtJKz8 z`w?AWQ?a3#s%(z7x@BJ%Zj_HIGaGBO&egC8M%R{~_=R2)&#{!>*XE=o4_7DGT~%tq zV8M-gY8}X-tI}53P-EK4;t7F4jPk8Wot_ybwzIx`)FK7ykV~F%1vukUCmUY|j#+lT zY6r#`B1c(~lfS6v#?vG#*D_|gItRTy(|zD+_hNjepBfZpzq;Ky}#;`q!gIY{grWLmh>hhD{7R zRyzmtNQ9Zmom7F(Py&@v<0EJXlY8A{Rxg{NOtN}+jLPcWkt+TBqa|@q9-B3CY(hk5 z??J>&L^jGk0PY%<`>R3;6~de4WX?K4oCsBs{UPtK)mNG1`w^%OXeQ=V1aZ_|sh)zn z9Dh#|!sd0~t(xM{#(@2OIZC>29=mtiQp8?l>H0);IVoMY@Hl2k$<_g{rlf4${)E%S+*4IfxjX}d;APivJh_@PMI%q1K{WCtucfDRw5OA0|0dCh8B5Iie_Jr} z*gpg#Fbw{GNH79Cc?Q9V^YtHsk$(tA{vjCA{vjCodkRL5k51*+*bZKZODv!LlI|J7 zyF8OK_NAuAbw?2Tt7zhlfB}>?`5d3d4 zgZ5mGeM?*%(kCafw{5Ih(6R?szACguo{}qHxBCc7;)7O%>s1BCQdpgv;%PEsEt;D>iXMTJWwX+woRe-&v(=YV2-Z~axPW&h3 z2cIgzSNh@d#Hy4NbY~61o1j+Qt;3g&I^|US5-4aOyv19~H+H!bYhw^0zJlt0A|FI7 z!H5-Gn``MzR@~{Yq>XqLf!lphdEA@#_7qOE?!NMM4pG!WItJrE%|S%y?fA zD)Sfn{!edj10O|o?vKxzIm5mJ8%Rh332Y!pg2|d-Vu=DKK!7N30Ro~#vLp*^$s5@O z34#kPRH)EGS3J^!N)Zt&6^gi}Ev;JZ6$L9OR&L9!s9eR$t=txsR@&e9IWx1n2?4qH z{`=<>c6MjZocEXK?fX2>Xt}nSpP*iBMC8SWoow&^g^d|HfRT}Jg}yXB`KQHvvKUh; z-G#6bq(EtEF>a*p|FHD|mOO(%+n9wWezU3>zLX=+hf>2CCeHj?0Q4^YY?*}Y!Yu$M zxtSM%wI!q+odo1Qf~*<9@$RM!0(FtaOVZVR8zF1^C&f{|=lu`-syA+{C76Sm5E%M`K zGp;ph>Af?}q@K>XMqa*mH=aotkXlqKn*XFGUjd*Od1ZN09Hmxbypvv(SgjZ|6%~|O z_ASa8j|JasRy+Q@j2c}5yui?vRrp-Fauz<{Sveh_d8=;6=h9V+EIg1#fwC^G+SK9q zliyg@;rEDd9#_k40P_5|T49UuHH`_*UzP00eQWMRrkB>N?HjkPhng?j)UXo5CNJ{B z{k>WC{{7$TPUblBN94r)|K+T(SxUFa(Y2Z5<0=G2$uX26h}j!J>@a3YDWRZYmP#fj z?~dPt40)0<=l~YEBdZ?B?w(L9YV4Zy$ZHRT6Yl~aG;96$67L}0XX_^?-a(qm4R
>lZu~gY2jo)3A(#4b6w#a{dw>5HlV?Ryx zd>LUI)Apxsn$6TIoACct%Z&Wydj;xj^Lt9<2DRE|;a3Kxd2*)3!g$lh2Be0BbVjyB zMqr5Ejtp?dJ0p_RH{~W($(Vi*Ae6>FWTlUTJPhYV1}@Y>erS>gRsA*sr{qL_^k5rP z_h)VXBU1xLUH11Ap8@t_;#E>3w|_s1Uw3UAxPR~u9$;!vrWzXg!&U;de7W^*`LJGo zW<}0!8;@^=k8H!|Zy%X}&$LHN645m#p}aa$_h>DizVc`=Dc&e%U^*hBA1lSPZ$9?u z4GlJTPBVyiVDX{7znmwSlU)Wc_zle%DR^VIMJl)7nRB^Xf$YdTY2RUu5_xlbb#fO^ z^7fDYp~iaT#qFb@AdOV*cmi|(*yCxDZ*){%(rygf7g@wtm~?5-Tg7;djF4R_b&hvcUbXF@F944Yxcn)=$X_=%G0&njpva8 zdj|AQumv+rVcf})ZBI{}`7S6D?Emn$L*DktIHz#|xh~0>*VNJ|2{fX~aP$NlbIE-M zTrkwP0cqe;df1=o{Dxkdi@bbm5P8nEZ>uWIm$ZjnAeevxnwNw@HH z75mGDA3t3(!-RQ}U>dqdQ$uO*sEXP4+$acf^R6|)vUYTIn`6mc0=JBoZk-hYKz>2x)}1#`mSD{*{lpB(g1c`(h6qa z6ddT=pUw(PPiyc*0TnO;)fldp7Q#6Nk?+A)9|8t@p`s>(DhxOPCuj(LH}O9-4=`1v zGaWRpL1sgNgylTyFiBQ+oFs@cOudE(fpVI(qK&Y5lm!`WG;LUDtG$L+_I8)CS!VTP z4Mcwm`gQO{|D46?E%vcH}dW?-B_Qq`VBTlk>&Ex1x63VZe=%M!4MbJZlqB*7)5nIJ_tn>9#2!xc8lD8JcBO5$J6Q3?adl>i!HM7&B1A==?P1|rv*H-`AgYmi|l-JD4O`jn;G~# z_vW4Ic3Y(4tr5A~ZQMPk=^hF$vC{?%7JMKSA$8Agn}R>^h3T3{*<;)PAF9yG#;v5M@9pbr6mD-B7iJMN;3%?6+9Wj-595)A zO5*RR?5_euox4gmNy#W&&c}Q_oUlcDewG$}X0e7iL?^HCCIM|mo-#Z5bV3K8l4UMt zdCF;OA%32@LKZYeW4SRzXA^QbOYcEC*rAck7rtl(~MeSxkOHF@x>y5hf9AIxh{81YRtW6uRNi=vaZX+K~qsz)<9M=c6fkbYdaUbmRv=M zN0)0U&T=Zd%&t_};SYeN3Fiu}M{>^anUaWIU{)AIwN>P;(5~y}n=vuCxGh*0Y;B*0 zB+{211(as|6;Z!JD`Y;gZG|?GeIhcvHw18V2W?VjHaeZ@K=cP11<1bs@V8X z#o7BbZ@2~$FzYU2(VOYW$Pkfh_}a;B1urZ0CPIThfUfdb&_3tE36IUm3I5WNO!%jcss0l)hfGq{u|n8 zU>f00MNWb#^J#?uK_I;Wek%HX6HvF=cJZ}uYE#vKU99`2mYX{JDl?)_wK*gF2{WSF zEoO@#y{9H&W2vPJ%gQn|zcm zrmWRQ_ufu9@3brUql)fTcH1NM1H93|I_+bdy2mamH)$o+A7O=KrorC`;DsMCuXH_v zuL`*@idDfV$p8ifTF?voWTw9;QV!sYdeE-mj~aB8DTm~@7wko_5c_bGHlRlW>`Zyt z9%;%+kLG_*t6(_x?}=y+v7@5LgIXOsCPEKtL#_i6kZpGOWE6Dl3Ij%4Z1NFfvhHsUk(j8c9k=BqA8U# z;*E#3CG4yizeT&1ofG$O(JE8VUZo6z=MGFDH_lxpZRS~Xk(^Jc(0QuRS-WyUw0&Ru zIQ8Nc-luJT!X@*42IZD@s$HU?aC=J72!`NqDt_y@a=XKkrZ^l|JR>_Uh3*c)wrZt) zOJYlvrNI~7l*R>cm%adCNr$*=t5%U^Ei$ZQ(wcM#6^$Ao8L~+er?x`>QNn~{8?Zwl zC*cdP37SRnWS8B#uq6tWn7ag~M2eZwu5H?FYPuuhFHRNC zN3`*3rbA4BM4L1)*TJTa4NxdYVthmKSBXdoHnrqCMBq_vp!nbsZOo`bmF2(-`x0_? z3J4OJwZ`7Owu}a+W?s1~`{iUgjF~n#VPLZ4D0pP zPA!y4(N9b%Hr{eLloChe+rEBIiCrRgrzU#zF^%g(OW{`#5VHjVFy!*wQc`&{35lRo zl=r=LO*k1K-Vk#`+C8ZwuTt@p0;Aq-2?T4IL#%#6YwU-e5+`r%h#0GY140@HV7KbN z3y9xxhuFA*^^H#1rTtV*t@s}nGb!>6i06|7v$!I1-Z#sTGgtu znPwY)Zn;XM#Q8_HaT(jLmg4ruwDDitew7q*Y!f=#-En*~#a|xLibe&lvO8UKZ|uBE zZ-jT7y|E{uH+IY3C_97mDb2)VJq^!$2+gB)d=NM*97UObdEE>trhI9Z){n83+VLr_*_=Fn6g95_7s^hKDIKln?#__&snWGz52Zp0wK z$HbjGwSnP0$j?Hd$spfx&&f-q0f!V}#hk>)yt6|*R~s-rk5e~+1q>qiL>>7BCIvpg zKSq=d66!;N+Y0~jqy2TV1jWTy(>`xxT`|`5`K|`)#ObBl^6&wNX_(bI*9emXR>!dY z8a^#BAM(V;y0!)~_3>uFf}(a2n6YA3WV+ih1UYQ6nl=fxBaN-hBSk%9evg|xBS%6_1Gnf;2 z^vBQkJZJ1A%JW)DS^p$N28!;p*>i$=a(iAT_E3AX4=POIe0P4qu+`u#xWY6>Bkktl2w8 zR~T;ZZ&+jqV!-kP#Vxn=&a4n@dK%{kX-i)K2Y7eGwy;7u+MzbbF0aioqc(H_GrwFp zakVr3q8+ou6M-H6QAMwY*Knv!xxiu1=c1a2Yct$ui^HgpLI^L>Ps z@bX8)&0f6x$yD_0+}H}c{CNRAhph#U1AqNF2MZ@7I>-{(+vU*%(=r$L&D+YkEB1=@ zqPuh=%pmZD;q5#iqm^Lx12){$l6c1h-%0i1ggc5dc6w`o z>_Fmqd06s1n3FUnB$F(5;%`p~ZzbMHGx{>|mIA93IHYcY7PlVtL;O1^!_K4q-f_XD zfw~I#%xB)Eb0G|Z5gqO)-iBY?%WuQR=e)yR1eJjwDzAkIU=Xa$n@@SoZH8!|HJ$;) zUl$zA9YhiM0!5!&xftu!aGWIRl9Vj!NJ;`~ZV@b<3Cf%a{*bvffTH|qJRz(Tt(k-` za^IwP{gNUKw@YQJB&OsvhfZcI5mR!T_X0i&BWXCqZ!xVq$pAEHII{J5B>Y_Cg+$m< zBp>>3(3#L;BT|vH&qJsm+U!Z9+hSJUPt+;KVnIs)F}=)~V5pKT)0YF&iMBvFtYJtL zy^<;;cT&osHC{8wcqxgm2xMTqv5-uEKyO$@!9X%dmV2>iLezA#0aS~y5oign))8mT zmj|MpTrAIM8ruY6_R~hYsLh~B=>bLIi4)iUx+O$~Q1g5llbekGv+>6!Q^Z7^l8{0p zypYvE5=0on9vJ-wF{gdNx`*cn8!0qb9c15(l_9{7HAL`1OoTA3E6^4h#RgtHT7&go z8Q4emL~K~mCXjb6op=Waf0DYw%FxWF#hN(Omvv&w0o4)CCZxWc8KBdTB)-%|Eeuk< z5k|(+9Js+>7w~0c5R8)m#P}POLBarpByF46@uaGk9dBr=eK^v6my2)QR}k?xywNi59ZQoQ`eg(NyNC0|(DQu0^$DFhjTCO!vk7KwZIkSO-5|t!{S5DY(RIyp= z$b?dHFTp0E#CaKUR)R`^I4hBDt?$1|W5X-t{@dC~MPhEB8>MrE(3SK8eg}es4vWI3Fe($@is=CyO2+|nk z9x!L^!Gu|RKxVRrdpycP$^^d;Ie}^#A}0P`8%}}azx8{pmjjykA)5II z?Ilfp*(u)tqjswWL$P@pK~I<%6fx&r%`vb8y2a@J#9PW?r?~%JXorlK(rlhq_|Y*z zD^BGoRVYt6<^)ovpXhNK0{0V6k$oDD#Bn`-TB}h{I)x0VHt9X>PEv61eh&^;PdUZw z?`b1aPhHj0X^;PsLAy}lbeR6N*t7O#w_Yb?`tXj zlUV{#Y_u*0hMSR#O(p~5R*3Ac6U%)1bEC}p|Aq^ophw!1$rH}~@$QXwW{XAb=^m+3Az?Q>u( zBR)Hfm?-5RVA^3StoT41FuV-T#LYUyWIVxmP{&5FkkYieGXkfJl#suYq^xsF<&rsDcAY^;3+58fpV9j2 zx(ix8@y2@y40Z7gHfh|KvvQc zp7=nV`Vk)!0k)bUCO0>LMtoEPXNT*MqG~tc4j>HHJG2B?Z7i(#oo+t7xo(dZeG2@@H)*%Mi={ ztmV#}I2u8s5iPI9pD;5r`ImH?SW6rjE#QnPHm5als9Myafu)dF#H!sQm$26_ZO6pv zCT%gml(DI46UCou52#r#@#3dii8|ONE`6$vR&!mV?7WtfI`}Fx{`xFtEG|nAsusGU01JJaT|c#}_>)~no)l*mKqEzzG@LG4 z0VSimKG%9OqNRTN1-3C<-}yodiia+0Paq!V$iE?E&0bOcH*I!uF|GX)mx4c9`-LuL zq)X!RD8Qz;@Hg%CUS)E7(3Nt!9%D*{OKf-X{^I#dkgtCEcP&rT5wZ%w`1**lFL3}* zN_>9bms(a?0iO)nr&F@n1r>Fs!fRFYq9KsA!4kH4^Z1& zBH-e~oNe^5-KDh4hojXME^)@ihtQRRk!2Rats>0RVeR6tD{n+_PQ;CYyD(aPt6XBV zn-5ZPHRG0r-8`kj2%3e^d}OU+g#RNz-x?}tol9BgN@T1yxGpJZJ$*kuArL9-TA;?n`G|LiPLq9OW9(!wW&K#8`^1X<0!W{YE1^V z+U64by7P?7h7b2KwT6gpJ$PP5=XP0=VvyS|iMJEYNxYj_+=GA3oD)3?q_F^Ghoo*Z z=gE0IS9iL^(4Ksdb0^h$w@cZbn8UK3JbzFer-lG?Rm}@pAl#6Kt_aj;qU*#z&#P&o zJ;-{v6=e_QRH!Ta5_1~h;XiO6z!Pp?r-EFLKeLICJ^VWLkW2JR;yLM^EZPoHW-qvu z7ve9Bb-qkDk=fzcsK1?r`EoS&Gqo2Vs2+>I(oNjmi)ST7#}bbsN>ixEHB3$8 z<=!GTVl154CWLAP!HR^`2Sv&`7r?1QqfeyqK1@AtmI3@HqF<)-!Pthn_2u_DFHpvt zbmd}Vg1vqDH`NkV6!+s5&P$Ynxe?onik_2y#gK`RBO{`NTfrZy;K6+D?v^_mfli|} z8T^mkoJo}C1XEJn)`Id6;<;G5V*Ma~mzwStX9w|{)l9b-oXzvqB)6E6jnT_;i{;t; zHF{3#u%HMySO`%AbzsZLtTRamH-H_IW3Mz$3St>Dsj!nw!Q1rKu+DFdwBar68sPU6 z-WqIFKcFkQu}YpF%(F4oCtt_2#m(38-p2Ql*LRvt`EHZi!vRe=k0c#=qX0!Ilsy43 zY%e(j)a+JK@ef2;{_pGfSe7zjI?mhrz;tk)()$OzQ^4?HQx3l|JYo`}FxCbU>{v!a zZGjYcYnc`1%}cA!FhlTzj4~6-sK^k$PJ}O2Qh!*H7|EOmX3y_}Y?x;RXO!<-5GI53 zB{@7yLaY*ehHV2$ltVsv2{-jT@oL)n-h{gk4dGd0`rox?wOBUzCM%zKw7}seH6+99 zp+eYeJqYy|Dsi(1EuK$Y7{mumziK2trNruM)3P@{1x8{375Y%i+zS5Wv4P1^4xlC? z820Q`C$asYmJ&|0M59)GL4-DJhBTmQKHgtXR3Iwpl`f;{35m`jq>an&eG^U5>U2m` zAwD($=*$pghKzfr)pX3dqAup6 zmm8vWyx-w<%d8Pol6(*l!I+Sw&NpXl8%6y@6RjAF(=s6KZ)t_Hq`RcJO^*d;fJw1( zsa7an7noKRZt(n$QXqMGa$ffLzHr&9EFtx#`Smd>> zPH}f3uQ3DswW^EV;-+CdL|3Z0Oz`?J>~(E2qoL8N8#!3EcDK0mWPRIQ{ZX~18|;=FxN)x zlllPE!f@e45+*b3WSSY!iWv^;%}L=f-Ormp2Pd}y*Ag-*HRZrnx@r7DvzrbjbkjlE zO=;-sL)1<9`9fD!HhfHwpoUG2E*{Ctc(}mawq$FS?tG>B+e=({Yiy^9K|p;u6Pxa_ zP$oTinOyI3UyYeV(>CkP0SBFHDWZ(LBpeyLNjvmT(1}UaXIO48vD{(K7=!RozlM~a z{CV2FjU0?}h(o3w7#P%c!rDT10Jtt~Q!Us> zVA!yt1kTq|O-s|jko6v*=+g19i3XPCNlSQNq7U*Uo@?|23!xX-%JxzD?mqi%8E7@jU(8qEvTW9E;ZWBB#z3G+wQ7!dI%<&Rs`Q|8UL z#_;Q0r`-&$;rtLXyQBJ8zSpCkF(1D%gZK9k3<}~^<6u?Jy2U?c@DhH`Z9=uGs<^jz zXNZ<^Uhel^@njY6n{~l$FNHDfB7a>IY(5P?ZyBa-8XBd1Al|RyO>Cu@K9he3#@z4C z_3anyN zt9c6u{BKwD5HA0y=BsdX<=uQpxC~T5T7eW48~WeS8rvnNDX&aCqPP_AZM%=L-v2cJ zy*K~*z6x_q_-w|;J6P`>%_E(^+tGZ8xs-=LA5|So_A6|TR?7Q!{q0CBT*L3ab(`&!2I-{HV?b%bq@_LI`c3b? zNGCY{js4@-Ut74vR`UanA76W4e7Stng%4D*uZH)tr~Ubk9namnt698K!?O{KNKq<2 zex~1yZ@c%xSVq}&;*V*2kN@@#Rp@>`K8YUx<)6tXel)FlHg;^KkEr(ZVXRne^z(D- z9-9cy<0a}ooA}v0UdNV;0kwR0ZY5(&?M0@*)9BFbQkSx_@%~oU`-u4uYuhW>5v{lQ zXDzQ}$)d83SA>-`@8l^n%5Sb@-s`jTUc>IrH+7cW*QE8f-AI^o2<_dqHfiyLr$L5qbH`OkbD}pI`;<^C$v6G?-7qyLv zH37aH*C@iUma6IsCdwD`pR$>Rz_44J)#8U%bxWtN6-L0OijE<_7-6nWx63wFP~;(QAq)_WZo{Gv%X z_MlyW3JsnP@}f6|_#CFD+r@*edoso0X_m`gV%r#dFj;h8#s{n3GV$9lc#4>?j1LM|O`qW%UG5z}t-NeT`84m0 z31ySLca~3^lBLXM-irC&_NF%PP)I;wH9XXqad2H^kR8hcEeJP532@Lu=OPIlnkweb z;jO{!4%A`~nM+CM2I{b>G__z6OOq_*#OY zMK>F-+(YC72#iK(YA_FFAQA7_rs;5{LuQgbsxpxsATp?0Qt{IOk4Zt;_95FgxUH09 z1twi;^Sv!$!_p7;jpD&ALC}F3U>RX-Ek8o*vF#!^h+Dvz8=XQ#tZWB5gPP}4K1HzD z*4Cy5Y&wmBn^7;>hESlM*35kW5_*{yM}vQnM3A77^$u8~64oY=C4$TNfAk`Zm>hcO z_VJIWGqLIrPvr!+6gl_u{#n#FM4u8L?js8eb2^wW_>C9(&|*g$$=lI<2{o6KLuTRW zkOc!)|F(M}bcbqn-MxH}y%G};+xyn&v-k4D8sp-@Fjf%NM*L(Ye~Z9;Ygh3+JXjsQP&GA3E@>I zu;d9bSC}MZLSLCyZ&F()iOEn1Mw?zhK#?H`ds_Q(T^Lgymwo5{NWAd{PZbZ{#ysN0 zH+dPs=F?VlzrLGsL>jzrHNW}lwNJ^3NjO4SZMyO#pt^2xbTyxT^%sSA4gXvZq9Z3n zGrq-7X;)7ky||8VVd`Rg^uY)C38uB%KZ(|F;3>wp)!*SoD(*cQ{rN^7Vd@Hdbn5pw zfDO-z`y>1Y_INZJ;iH+l!7l#(ARhyY?$*uxHQsLDY!^Kq;_KCRyV&{=U#tR?-c#^m zzRnH^I+2jkpx{%Py4@cA`NN>KdW~6#^#yIJf$jx&%EYc8@PFViW{*X8Z{_Rl*X_33 z4D>lxjEO_XH#=Nmker4*H|Pa>?BcGSJjD0e+ic?aPCi9b*iXg6UHnFxJKJ{gh1j^e zJ;}eV9^}n4x?FtwM^G~4i5GvwpV0F>T*(m)PxDq*e(fi5pD-Q6lNiqZ|4$C$gk!iITU?h1 z@%U+FlgCai!->}l7P0QDj^f0FxQx#E|HDyioy1f$pl8S{WrpeDx5Ftc{`fQ>rk`T$ zCA;Xehx@Ycz#aqIv7&CeK~j(^EJ*w1le8z`Um9@Yv`K|Qr_vKT9u@@x%@7(QXKcLG zSO^ZWvv-hpHo&}}C{v}7c_HYom7Jj$uCL-{)nKzkKE#IuWCunOd@pDclV0gWXoW#b z(T)rP1_|0w@IuM{wgl>N5>xq9n|Y=d8w7|!ond#m2jmJJL2|#LTtn@!Lxn|l2*ldF z0Ns&g=V0&0-ka;Ald%JdN1?uM#J&&Deg@-j9EWJNK{w*AtW%LZE5Sm`BZHlYj@!eR zs34IKJp+1n`Dx+V%O9c@`{Z8!jZ}Ehe21695iA4^fx4*#iwD1xC(8EmU$P4i{e%|~ z=l2sHU>Ak>37@Izj_99%f@Pq>9YEk&zFJFnyd#ok@|&Uq4{#g9x*Pf&Z&M2$(e2N1 z9n4{|L+p<7C)9$yqVlJFiZ=(5&-}#jPnnOktafJwKzn`S9go=4EjUVoV$rj_Zy4vN zbOu0j>bU*1FK7@(H85WelKCpa`pl%BarAfb{?S z^SoHC_{u7kt1RXJmny-1z#m@ZH>i~k(f!xFny&S~1~-@)&3TF6!L-?q)iiUn#N#jX zx+JL95hxsLQ{sXv;Oi)w{u`dFsc9d`tw-E-m=9vrBK#^JH_JO_VG}4oa%m3GDfI-C zo4heE76N|^5>}FuL4*&4y$bm>H#(lcwKv~v5f*cs7q<8pK*v=>dz5$=WeEN%xc#&* zsMLPq&R3!SGfJ)cmy{}AewBai)>2FmX(9pUhOR9hN$hzx617N7kGD}eBa*bORJg+g z2fHLC^(p_tUSZV^@y}N=ulx>i(`&q;f2GO>Glc~ly}WR)2zJN5+gn@7Cx8lOr| z9C{xC=RppcEH0@_KI>D-W*OE)1P_3ClO(j#CpWNY|yhpUY z4r`QlNA$JVIcK-5aP%(4K4W?#!H8hrXP4cvXB$t(HMPJap02NQtT8v^9(HV0Wmvfw zA-pPXIKWdg>9q7i%+msVRvY#i^PvG27vm1_{^70WIMcpGgG7uM$ep091~a{)HTlTwOVJgzaByh8cRALamX9fxM@C#IB-^y*v7|Z zt1O?{X_BKS10hU$$mcwt$`w!eOt6+@^=9@3P790eB`%JbKc7;?#50F@PN}hR8)N}( zl?aC{DH5_}1D6`CMN>%nEz>=3!CheAhJ%cF4AK3UynpIgst5HeM$Hg3cs$RqVF4pcQ3;F5$fuH0KN&4wH~V0TRkaEO5Y+PCP`L=tl3vj&#%m zC%;9mpazy_U79a}mPR7cXv$gr*VfRHYzhAh>6U9DTf+ZBx+Q^ZX;4`qOCCF&;OkOQ zXu|5!#7{2qUZVczd`faQ7M`4pbskS0=zRWxchcrEt+zAYcVcB7PtJllXze23SP46m zNOS_pLmuYwtn95RcC5kewHR3g4;Tl>(_As!2*;qJQZOoUw4ElwymsFQ-YEu;fFYKq zykJ2vl34YP?S%28MUSNoXA7MN7_LJAXb;Q43D^QW9){Mqv92m1(in!ZZkr^7u|yz2Zfo?zqZ~QG@TJN18anORoiYMDEKFEh zsf(1Azj^$=4H|uu|Mrp;Xh=7ubU1W0_^)pK-Kg&LWY(Dfkh+^0=2cN%{r)ZTmB7(V zrcA&Q(;5gH;J&#;vj$pdLMf%oJb$@Urjs9eR4DSNXY^nFL=2XqoO@@DNTn2`OK#{z zSG9+-ny$**|2aTbv}9g8scsafQbZynGrdALJw{NHl#p%j^W?6ucBe8uUa&i>(F zCjOxbHM=8C0+uUJg70*=+%gD^j755W}uh-QALDN2KZ z6JPnC&7BlwED+?e5*Cs76f^tUX}|i7oWgQI{&!>DUn!6~$y^A!LHNHyS$*J|A-hy& zOA7<@pDIo>NKW61O%*AzNq_NYX)@u^Nrm#dX!eJ4(hpE_<^>m+`O3-n(UJ*rDVq7x zJ<9eD6egc{$Tm3TR++B&p%upZJ5%(6%-4%`N_*ejkkoIs45MVk@yg`JM-445>;~Qp zW4BSRX_;mz!vXCHwl#Ffn)J=#csDCn-qud0+{HdCi1kL2|M#*AzdH7me8($>%32Rp z@~Afw>sovcGM4YkX0y(6BQ&;_@GWZDh`lnyw(27JQu(pKKPYGZF7y^xBvtBy z*rz3-8=s{HZXfc8i;k4+Sr&Af#lP|qvAcmff>XmcJY=(LIYj#hRCcPH!Y(;d)4(YN z8xT#hxx%dh7zt4CGQ{|$Z`-%hAPJI2Q#P@I@>j92zJsIv2jWJjwf zxU@*@ItJ|$kk+ps<6c#FicgR6+tuz)G4ePM=_gfop_@2xoUiDWlK<9^A`V=n(Gw&1gv}uo#NODeoQ~BvP<2fyWWO; zOD%JX{D0>eYPnO~{_p(PYL!!Xe$PwY8#KmjX{BK7mbQyY|H1o5m;IjK$JKyS{OylC zn+Ki1@(z5L57oD5Ot(cV-{rNc+U69`y~l%u%*}cq_QtE6qWXP)Q+LTheggdtXx(;E zd4%VSqwjOOzEfikTlC-G=Q+&1*x~VRhukI|6sbsRR(p%AGyEyyB9ESdSy`JSI^jS0 z%S>J46g@xUf6tFkHu0yk{Ac|(Ij{4~2sVe9{IttYDO=y{ z6wiOm|DYBWiAVm#f1>ZvSduMT^$Fj|REX<8JjeI(EzUs;BYQvW8-4D-V4I|7+QivE zLw~;w<$lWNsym(0=1)07&aC6n*7JO$s_t_}yZx1KXX+tmboT|`fI4!K_BnsJ+dhq@ z*rtl-KIix8QmZ14e8FdljbA|c{&@72FZd)xONsXR8y}_if`P*XpZ%p-F+-0-QU8~` zS%cRaJEk}@gv8NL|H)I?ZI>rjWe!bIJO$ zZWob(y-hTv=y&O;3w!|{P0^q0c8PAMi*&W(=Z%X3NZ7cBN6nm>j^MnuE|IQ^X>Ycmx|rG-l@IW7|2) zwb^50#de3cx&4O5rsnz(UoE9i(e`xxbyZDwiHZz;Ac55yGW5}~)!Cb&f8#5(dc!jH zVJv)<@dj-&{2M4)a5-d>h}#gSk>SS>d>XoT zXjI4)S~4tn9TFtT-O~%TWN7%jx3v(wE(MK|vO%yFmJ%E)^u`2Ts!Lf9cr;F`ilYjNYX3(&8x4s9i!7_q)Tkb z(i;f7@nx3&Z9=ZB9jNb6&vB7INFTwIbl}w*2I==`1WfyIkY1&!#k#mPTOaQ@&sm{O zVU;fN-E2LFt&RRPTQ5L3FPHduus+Lnf$|T!#DwegLbbsaz4tnO2lS?{s5b|3NYyp2 zXm+mtAyYTGqTR38-&57iuITxEy^8TdeY;ECc7wi8-2% zyTa%zWAuqEJQhwlVH?xZj`%j?AaW(SCfC=&aG(^#->&`7y(^hPBAxh4a`l+(G0k7Y z3IlQ~%*T0TpaI5KW(HmvciMgQ+Rg4NstGc#1F-bWmrs5>#T?@YuY zg6rQW={GTLlfE`uG)2FYsTW*g<5WEr^?7otz884_MKz~V|CvTJGkuy~uMWgFWH)g_ zOG7hZj2i=p@(JHgfYVSTH|dvLV%H3sp1M0au}Tjy#|E8ELdCkf#Va%Qfqj#wmO*f{ zppk^Lz@~(tCG^jST}6^R%4g|=VJqbp*WaOkLdvG}*}8w)3`>72wL%s!l}J6$N!m_d zg4lrcMVQKvLL>e$vG;Yv5 z;SjOw>R>nUPl|mjtgWQv)Rfnnv1}=KC;}E*=o{a9Q|4$2Pay4y>3!vHhbQA}S#q9hkohpu0>p4!KTObG4p)(NP4>9{{YIKLlyj%YW6Rg`@ z-K+1`86q2AKUe?UJIOsRS;kjk#)YR%B=Lf|bSmA^(KULxrti_2-zL`A>JO<^Fto1I z=fcu*b)AmbiL>3}j{&_=t#*qk^Yy>$`*aqtMW-y#(-4i&ErJX6ftrN1EYx#pJ|A4D zk7G#(br!U_6Hd~o=j-|`mfPm8$VMP5LvhFAUkeJbrd!(01xl-L<08F8%LCr!$RaH6 zg6M@sI!MwDZt-w~K11_sUS;t74#GmyV1R&0Rx-VnJ zk)$tX5Ov3xNv4h$wr?zaQfCdA=P$TxUv~5C31b!p$k@N}PN;JzoLHdcsC#XxygMDy z@n(X?Lz&0ip5gM|jHTwC6K+p|yhBR=P%w1TU0|e`1Puh%Kx_LccR`Modu`y1du<;5 oaxOA-sAt`4#r9@Bz27*xdk8 zFyKp-Dk@xYsue3%Td`2Zh$}y(g;x60s;#ueRx1_ys8uUfTWPh5eZF(=-QBxMc(MKc zpa1ju|LZ5R_s*TyGiT16bLN~gZ~Qdl=!x{WE;Z;LzJ1u%xVJ|*YP#K>oocXUxx3Tt zZPO^3F~!y83ADAW@cXV-y-t!dL;s>mq`hhYBj>rv&u=1$k|ghU9wAsGkxBG>J9V+9FqPy-SSzMk{77%PV);X z*Sc96{=JcnOR1G4CQFj!kY=Hg2B|?i$nvH($_t4LAV}-(a0k@Yl%zF_2Z^MqYgBKr zk;wHDaRz_B~HH-MhYQnNNwE+s*2wOmea)*g_{$gSED z{CmeX+f?#Rts4K{s|9UkOtew)E;^NHv+z?-G=KaA+C;SP#8=Am2)UCNG_Z8-!}u(^h-irk)8wUuyv#pr zWQE%5gnX(JZCk=Z*+a;^{D_BUXk=Ic?IBv>uqwKNXkQ&xLH7`C>#)&uFVXhl+X15e zc334nOtj&NmGmf@O?1&$(QIN7J%$b@me3PKdp2<#eT!%xCMu*^OG%nR7HSKV7L!(O zcTzr{UrahhT-uL^e+AFLPi^!F=SYP(7ptC?9YM@UTcveYU`L=p)=;+wVPQ5AsIj8Rqi z_nJ}F`1i?C8o9Oq(u@Oy+@XDbuTxVphm+#|37Iz%?w-Ulv=_2c6Nuth1FC+AA(1+55Zg%^y~QpR3HnAS9Q6_K_5W3M2# z{k;J0+5{ywlgVN^Rdwl9&5@os#q*h|t5*!&=F2 z^Ry>i$#J_ujwIWkrfzmrzhCkveFNbbh{JX-QCXS zp5>jMHZfZ-k{Y#r;^fH{Q>&}PsV{1aD@w5PH&t9heyu%MaSwT2Yn%8RJRkV;1&Nlz zztxVskxG86ZJJav;&rrrTskh=mfn=!)b>xBTKJBInumRczP>}-#>kS zs*B_-tgdcw2Rg8f*8pYOcWa#&{|aAgYnS5Rdup#pv*vLEOR*X@YL2?~Lx1>Y-L)u} zG2;}C|3BFpOCpK2SB=)%Yz2i2b@R7HXwCoZ> zlq-9xE>b3zFO#GaRL#Slu+1(=brdqZ|{H}b76!YnI z>^d?{J9I3SJN`ftNe)l{1Nmx#REK`pWT~F;+fw8#{(2odL}wFT@iEEe&&*&utS=Rg z@LUS|*kk=v&Uhr6yI?v%ST5K zT*?~oW50|o!B5L&Yz=;1xeO3+@w`U%bGnq=RU}W~xlJtolANjqzRn)O$}9jyQrjIQ zr_I;Z-4j%o5mHm%skVu4GmRvPlz02pH7)AbkZhqNPQImyP3W6OX0K4No|J%DrQ!)F z0nbXW+U`O+Ub7vUWnRC?8*vRqZY3b>>;H4sqS%M_y`8?n~Z<2`#_ zPQ~3B@C~d=0<4~!!|H%933FLl?vTSu3$$VIZW3BFmoeJcut4v$&gLu#y8RfdOw#;5 zY=X&P=_XCY+#Xyg2CC;%bjC>W8G~Qx0av8xnZ*djRv;=UYhGmb|18zo<>yeXO9>D4 zJZk3dD(0oj2;X=Sy?|dcpUt6e!v9)LZvl(K>ld)5lwzWQv@8%ql!znfE9T!>z*Jyw z{6h99^I*B|TuGh$;#wNVUt7qA0Z-mu$Q~lQL$@wsIX2ow_#;=a&*^Hy=cW^9awUco zR9k|+l`A_{zmb|bEV8W`2^k^VRqPhRceXI6sNw#Vv_aHxZ4oI1pTz$>UCv7p{G%*5 zYNrC|V9(S}jLnHNDH~5}WxMS;*x7x4ZO^!@1nQ_K3w&Lw;?XuKeJzGxT_bq2dbQ9r!YGb+iI|)%5(1}^@pj(n2A_UC2U)5`sq+NuQHn#A*Giz<^ z@^I$lfi-hyJKH6`uHHs7#!jrAiJeyP2I_pZP4#pG&>#zvgA})`fi^!9eEu8JzRJcA zbCG0y=aG;gN|TA)y@fg_x}-vq)9v=VTRiQX331E@KTz&hJKeo4NX6v2h}<9%rOnsb zDL9%fgnxevEu9vwkAV4E(}Gpd5lJbBX-3vWOtR6DmRSBmXAvl>7TGYkpWQ~Y z>2|_@e+wOjUv1b2`Pp}4qV$bqN+mXuyD_hWsC4rwSq0i&mAimxD5X0 z3U(QO%2#41j1GC`{^+Lp@;p9?j!t}uQ4y=imQInY%{yuhqp06IYecs!r_fLx1C2y4at+`$%%) zy0$LInu*S!-wj?jXKqgr+X=`{q9XPX2pH{YHFnSU>D1B+XcyL^2*^ zDVjzlyo9zgc8GwCEwHgl{M>9~WstIrfsgaZ!+DyIjfQyWYz77cb*0VvP&4^eKGtVV zKScODKDN!8gseApvpLozHj`sPHq2Pboj3Q?tz_Qs`IPJl!6w4|CB-hY7FU z3;NvcXCq6JYiD@^VvC*a^*}Db=HQT?2gQjjSYs`|gvI1%tI~(~bcFEn0T%3oWB#*#nh(*w*IIvQY034NaMaT;|+R|>}Au9I{5 z?Q7+Det8cYOVRyk%0oTu0*J%BU=zvY2lvtpe!7PZb0!wgS66zVIWU+K(FvUhab*pw z0iG^fqc58cYnY<#oUsa$v{A#xAJHVzF6S@;$i=J5)J8eI2XC*Xh@@Z$s$kN7jYi~MTdI@)iIb-cIk=^iH1qp^L(}*# zZe#6`B;LhxxP#@}6BEI&d-?60DSXTAteCX(4{v9qc;X!_ml~N~Iaf#b6Fzz?`!VaH zgm3x_byBIAlWlBwd1W0~(_lc?DXHy=lGvcm*+VKN^X|LZ{)BhKq_Kh@{|l|kJPAhN z(jKqQT|=>QGWxmVue7-DBWy{FESa2kwjAgG&4#+BI0xj99shujXMsa(PCKf;Fef(c{NDP&Y@8JWvDL((p(-Ud z?caKv7@7OCRpSs{GLBS9SSEY2^l7+D<^0k0Bt0!TvCi8IMk;NN8~ctd#Z)_-U-EaFnR=Qe z=Riv&B$S-xLd;UzdHKVvaHd0EAoN4!QLQqe=7`IcubJy7(yg52Mc7f#*w!$x5;`*@ zOQ-JogiZ%HAE}H_zm}8%d|lT$=Ep zA-I4--=7DDw~!zD2PPPKU(I9LAZmBTvvToT@fl4MH10$JOQ&eMB_0GZ*xRj6qdaRY z8=GVtMI^UD4_Qa~5AxXz4ELjamWiK~1W@Huyg*?k_?ef$iVGv-a^fVRUG+!aqs+}I ze*fpRn4W}oNnsVK)_x~L#t5P}!%st7Q^>~`usm8%`O~LqenzAw*K*aX3ckbb??v8C z1#Ch%Qxw?Yn!@8EU(f=PD|Al= zd(F;;tNd&xnnQCbKR6C^F%MhZ7&b`&|Ih!V zW5jPlA-gau9eToOCjt<5!CmP~?hJRnrMhK<@}(H)ln>)-xacoQI__l`se^J zwX<=e>DFwPq0FYFYO$xYJvvpQ?%C1Yd+cmN>YzDl0!^^9^n|8p#^G^LeFC>Gjbmj{ zKpV?gk`~1b2i(`d;k=9X@VAummvdNtU%4zTqoh%2HP)0@S4aB=6p|d5SIEFNQnRMQ z`U$uyp%n1TO(l1@OXaRE!GE^si=jAL5mWpTrnnI) zb;|>g7TbamR3Z*fy9LIww8WCjQXV=v{k+SP*QVEq1${3Vv3h)!yOF| zOK*5^7YDYVAT`eP^%)QuqWvK%I7>H%Ns<~tgen6OaH^zBA_JgH3X|vb01tp(ODg(g z$wLS8v@vP1IZU4REIDHHn>_6q@*5o889oYb&*W*(k|Vacv%Q%-t+lQ`>1+kg|C`Cv zTB|;l<~a3QD?z`EIK<(EJsT+KX46kx@=PU zSHQLS-JK>U8D8afso4B*nc6#$%dLx(3g>z|duMiFOTb1|*xcEJDzFRdYxwM}b-W~X zQNI2!wBRBTaV*za5dt2eWF`s6HZUtf!XqC+#8*>3{vNhygrMavsaO20lQvL(`#o$5 zIKH3W!^Qws@7=@l9QbCV(v1|>2kCvuGu@q?x`w{6cm)oTTl6DjaTp?2{KL`1Wl6RX zL(L>~E8_nHH>D^Q~kHtm}{!_U(=jq z*)LeRmb^ZDn59;2>iRi-^`um(fWAv~-KVrd@zo;g73$~KYSHR~l2)Zyd=DtC5L`UI z>S|$RR9$V_LbO188UR^oRn~TR01r=~Qc=`(-7w0*@lZ+G4Wj-4H0J1}vexejs;CaN zw~5MUjxK2}DXSG(+I7nx9G0nFWyK;vH@PWm!uj9z1f~?%I{L&RTf2&yA*%!xpI3*f z*$tPn9BRIm2ExMpKtF^-e)O*QsYrLql*Qzs%JFtrHu zEQdfHFpmr4`rp_flSB)c9NGuhuFcvk7UC8v;SW4#dAYPzB$P|rp^y6(t8hhiZv+-* z>x|WBP3%_vEjkZ$H|1U50_%G>jo7VC-9e*bjsGOp2#%C*@7|Lgd2ls(V>>%}y}9276tzSU)xZU%4}eM^y%~sEW>^K4iAH z_g=c%Epu*HRS6@21tI7xkBC!~TSl>dDv%grWo zVO?9BU=C-ugDR&HrOVyBT!mtLJ)iIZo1A@w5}o8qq{{e$3HJEfJ#EJ*?|XoirxTe} zHiPa!44v!utn@%lb%bhfx?N+BQj+LwR9Cv&dS#MqJ#&*J=WK7M#|s$;21OSxS281q zYl)qz*Thkb`6$)8mn*}cikR%(NXZ^8W#v`cKbGgquTrvKf9Y*2kWWyuPum$>rhV3y zEx$#{L;9CB?YVLiGqe4*U7;yV+q&YbT0qU0a~VpAy8fc3rxe%q1Up~>)#2%ec^)GN z#FsJAM3*w(Fe($~j5!N%GK_Ox$e5zK7R|pRmo|yV_0(-N(6usO-V$!${gnlD7t=;` zTub*EpHFs_$cGp?rnmpCuf=P9o)UVPY0ay?syV(kNq&iu6Xv(^@{w>o7pzK8ir5ey zWdOz2j%C`^t{nQ2QSH92Jo>5eILV6<%H{|k_vX?AvUbFKjeIzqw%e!3FNI%R-9_>d znLMvo_;|M>AC*lAPF!6kzbcc{dT$P{o+KZ#nc!UDFP0D6$PxX^@BHKBS8e2w{-Oqo z=`ovjd*JKx36ZvQty{Y~IEKDu)4mejzv0&QzEWYunVc>US}>VdWD+I7PVjT0Nc z8>V<&cJ0x1>*;FI+*h?*dUNF-y9ph~)dlhfJ4Pj-`3=165HA8VhFz0EU!|}eyj(s; z$^CrO1I($FU3Vcp3Qpw(GDe%T@tHwiw3bc%LnV%8a@xaM^TurLd)JL9lPp{O!UfPo z3gdt)TLWz!YI{$o+PW-egVUb8ZtjqEQd^pK?e#^MTC00@aCI$Sq3dj2R=hy%Tv1&e zZpBD0iD`!|V=s%01f^j=(zTe+w-Z7Y1wz=_TdTHZ)TF_{t4SRlXG^r-RM=grZ3Z9 z3@F;){|Be2YK70=1|uwUq7ubKG0c>fvNIFYq$KP%t$f+S{_lSC$LH?*x>9A4 zE|ozk`mZ2a%%pw%k=8KgXwU5U zYoB#Lb3^!@Wfdsh{*^s~umyB!((4NvMnQ&ytay3kyO5RF#CI#75Xfk;7h z;5N8@)8-ZCc<6KxiU1h4V6cFXDR{TJdjjflQq{nM_p@>xV~U@H4NWCgj>wI zT1CCfRkNpM%k&P+7Z#7AahzB7tn3glZ3q1QzAiv2+>5Y`?^(GLlO-CO)e{KnMctix zGd*6j^X;u>#fu|&(y~fbyIY{NTBAa%ffHphD44(sUJ9TS{8S`wtD$(%p@!z$+kq~+ zvlQ5^wpFiVnA-ZC*?r2YuyV*)z~PQUJ#w!9Qh+0d02D4{Od=E*?Qpa3!qm76-dHY( z>jF=(okaFa1256{(Oof|n63pd#}9J4w!@dsxO*#Hitc#WF)el(k#aF3FjUnYMFxCR z?htwc0h}-@Xa^ro@5?0%g$=Z>XmN{^NTu}>zpBnK(4|#J>DKvXm622o#neoc37ctA zx`OD2&PE-gnV>HS(&-5VdIaKy4Uq%7-<49_x=?(cJ5)0NZOwT%d%hJPU z+ZYm11}hWGHaxWO5VWNG3TC=KH+!IeHil?oC4elNE^b}n2ST(MZC6(tNF2nmLz@bn zmh>3^=wmWE9$;t{>|Cp++@C2ZUdm2qoP}sz5DQW2Y$EmRa6}{)z6H&+NA9oc6CyO$ z100cHbhp9-OKS@w)dVyNv*%%gXW*stdRusefU9X@Q0g%LY zK)yz-MNE>I2N)guVH+ERRgK|hE$hc&96=idIwf|j%-N*X?#$5Ic2;Ib)lFOv>l8CiXr{6IB;$_su$GSi}~Hp~#nv--OpNMmu&DT?^WSHA+? z>b(yo^$C@jsYabDmKSuZWzf8XRCRh*0n1DxXTVPYO%NP0ZqP3OSdarVgL`>r1off+ zg{V+gt|((7I@%h8b?Nb%NCqZTEH-#S9eSu&qq`bc6|lrvrXQy}q9|}0DN&WQTrBi< zFaqfmir!+eB8`_K2FEDjg$RclbW`<1dnC6u`#~bxF_{XAiAADk=9_Mya}tWMmC}<` zC>Y?+l^<=R9j;Q|_Cx~htT*U~b+PIs%k0IUf4B;%czIX~6Rj6VrJN7L?asi=34a-*ePs@4vS1Po)Qcp~?QFLse~dv1X|5Xf zSVNSae~#kT5j6_1nv>{*ZdvFmp}EG|3ZJmWi|tKQo+;2CeY)r(3ueR&ZHd_-=*|uQ zM06KbS)0=S`1Az{;aU?EE#sN%VxafEXU4{e%-YYN$sazM>1R%DLe3thXrDc^Wnh_H zYa5jYsqy++gxi6XSkwRW1FqOr)ULvHbdcS+9NyJNl9VNZmtv{Ju^cal3quiXbT%6IUI&Zc>$RGIHrgmz_ ze{vgH*zbGx5u#WC{&}e)48JYxXtmGE^*r z7-A{GBs{_!g%>hdfnpCRY)^#PN06f=$HZlv>daTyy8Z1C8v=01(Yb$RL7(t}ZLh{Y zGN`!uo3S$PoNDm}Pz6HMSj4v2dTomoCtGo#Pe^ zs_qfg*Adybi-iVRZ7(TX1a29tSm%_5o0c0#XW0Cs#9aUeOsZRmGsa$6y4Dj=^&_Qr zpKw=e2UqXy1qWpC*l-_JV>W!8T^iKaX_DUo`$TG?w)UspF<5)*r%Pso00<8}aUO^x zZ7?!GsF2Ii@pd zGJ~gZY5Y|2DoNACRykh##&5@nD)7j!?10r9>cR6^tkXnT1Npjftdh7ug=Yd%gr}DT zH*VpbC90UM=Pi18VAh8RvHP z4N*9fabu(rMPL(-1K~x1_AXOr_RbY*j#ez3a8(1dm^rLusJOewzfuJoDF$ELf93Bq zVjZgx+pS~$=j)f*9#pWjwYkTNVn=+|@nNh3AQC&`$oK|lJo9+c)FB3B=s@Q&?Z?N) zk>|9N$EFE=t?Ty}!^gYx_YHIr)1Lf&BVEcg`Hh8i8Pl$KV<`WcbvLtPF|6=-Zv0oq zvw84%EJ@OhO#AFT<;>$r+N^iwM$wfm3~>fBHQ%2K=vJm}`_owZ5YwLi)1>S|3pE+I z!pQrVCH_`XaD=)t2uG(&nMhm~~jjVH()O*y%gZfDvxC%-0s z{&=#2-p#bEKaZh1n0E1>ofGe7j<6Me`P^H`4zU63WYSKiZT|BG zvCfYS(HSb~cGI;Ir?Ax@jHzhI5&8ySKy|<&RDW`J;-tHF23SHcyTZmOEJI;Y3yI~n z59$dy)&J`chv7#%{!u3Ry#KS0S}9J_`d%l8}U9>xpP$a=b$@dwi2+Psg6$PQWjhead_;Q(GN zB3UNiH!2P)mo9a+?nOP3Yz$RhKypa>!uf(!Koo}0ICO&s?G0@nOP+$SWmFpxKP-c|!ZAJ-scjuL%}O;0GW%z=CKFUe*eUphVZfigdy9gjJ~q0|h^G z{0BW5j@tt73&|&Hk|au4ERvdGniEr#;2py=8K_4m`k-2EZVj_2N|&jM4Ol8c4~3ij=D~5gCnK|FLBhoER&Q+1QVEWG>s!)D;aVs7Gbdi+)c`O1t5a07nnir z&LRb}fHkikPxAVp`aq8a`nx+@f343N06hS}I&8)ZH6`?EpcaB7kCrNoSboKH-dt3P zq%hb4{OQ2pAx^oP^cmH~Er}=z;kE}3jCS&u#*-I^#<9>x*`$f|8A$fT5V+Cm3A7lf zBMjlfmTO`d9}bnf*#y8`oQ4Z#Tby|aPR3eTOzFd-a0CiO<@e=~?7r%FV3_z)KYL+A z{rm`)8L$HSfHQ~2sn-HBXd)v(QEHTlttC$xRm`0q!7-scQ{n9j${dq>n#c~qZWO3c zV7qNF=3%S`s+;2pSO?HN5hDo74&o~@x~;?i{LcZ$1nNmle+u_km;85wydB6Z~i zGRwrD-LZqxQNPu|(ir%O{$ZAe2HnuZ8G2>Zwsm5&Y4N!_+gl7FE}2w@*MVtvV2QS4 zjxMQ!6ko8PkwPd}49OO3oUysL=qEp6U4^_cv{ND5+0aXe|D%$;Z;m{PU^EjW_$o#Y ziWnJtH3U!7<`ZKFyEV+Bf8QLz$ZU$1gl*qT} zU;^dJ5RDxT;vi`_hRChI@^(SP`(|L{jaE9>$f{z!-!|KX4R!yo;JKN1|Y zDGmJJ&j1Vlh#h8TM9jHUNWQ5J${uvYFI^SdF@NbYcgP^w3YW*L^3G0veiem!z2KhQ`r(g3Q;aLL(1 zyDK3EM`a`FJV(!89IEGf(?;#E3hUOjLpbv@jpJHh9&!L@D3lg1WnC?NUn9vMqR+IL zztc$eTKn8M7}{mGp0U$)!WIx(_dx5CNGAd0XtK2zX)v<$B1UW^!az(iBBOvE zp%YEy5i&$Ss}uE{Ojay_;-Zv z`UdF`1@78HGDNw|Eo8JA=`@2c+(PDvGJ3e-XSa~lzGEyLC2}&NL>`0S%j$5%?T}6| zYj}~j*dQ04w~!Y;JmN=AbUKrzcVkMN99-h0QQ{;^ysF#Rxys${3-Wtz!>~SL9HEUf z_@8fs{;iUe+sSKI1b|Wu+#*=!vY`3cFe?``jpQ)V1hesKAO@#cR-fiyn;|?%&4IqfU{Wq(%%d zhflwQe0UzCoD?4ABy*I|M}L`7F4Rvw!-Eul3;_FR5WAjKB9j<80IP;HNRY+x0I zhbgR#3+O4vFVl#N(pjO$w*p81mBCIm73HSR?8|mHW{%yk*IG8stS|zBb79E<0L0WN zDzt)xzrD@aHx50N$rX)=gE=cKN=ZYgS0gLV2Nadzd9O5QtK#1T#R9|hw@&OM%e=wK z|1Kb`^~D;(h5mjgd07_o|NPx#3p`5sl6y$OsI)Xa&M?dy^*{rs8CegbR;_$v9%&5y z;2yFi#{7fCnt$*^50J`X7FI2E?Y(3@Nv;zNLd6sW!4j1orSP5{9dg}AI%!5U>(}iunJywNYc9r2Fv=vRnYcP~D3IG#LJR z*5ITOTwtphZEIMOjRT+YA|$qvb+&f}!Z%E|^u9ROMbl*%5uRZ-a;aR!F&#>%xr_Kl(`l_6EaxUPi0Kx z2rf%0GA|C2afRtJX)uio5RDh^B!;7So0NRH&w~hjnKDU%zinNDcojE3pq)cOa)oH; zz8=yi+7Q1ah0nW*=5y~_QV1{8NEls7N|!~j(lM6~5%g2SIt=I`>*OHE-XmoNz_GcyOQy50 z)HutUTfAf}FbcgvkX&)1Q)-|kcHt#P`dNA@tkGK#E&?X($>L|1OxlIKA9gohTXf#hCbL~)diI2BQugwI0;Rgkl#u*qo0d(3PLiW*b`;!Pr&qx%!0m@kmNET8D!phA$&Q8Ab3Y`9 zM}X(Ve1;ueO8Lw0k+jC=0GNqUpojq)9BJzUfXnj5us=YE#xvs~FL{*Yl|kO9ia5xd z0!NMrsexOl23q^eSA}{WC7;CXdzCs@Hy^Dp0cRJBroh92X!=ydo>X}JhVfKK(F)`E z0aP)9pJ(Vi10Z?aUVCGUMOrkO}56%7jlqL?^<7av3wB6LafA&JjxlU~-Uh z^C)@M$R6SIo2AMO+!oLwA`w+97nV(`m<-_0 zSH>yjWs@dORern=_=u}~lmL`1m;eax?#|wTC)Sl(4@i`1igZ9ngnctl9)Gb95{Dsm z)40kId6EqO*E)JUrlVD5RTC#!I(nY{)O~4I4ELy=?byA;ee{J$R{CCl2TgjzRJxsDD zL`&oZ;QFj4A#3Pi1CXkL2{`qmCAhM&qxM${gh<% zRUn;6$@AT7@iZAP2&sXWiHIIS;SHj92tw5#ADwH*{ht-ja+r^kNy_ zh8u6_h8u4qj5l-y2FOyf@g`!hN>YmPf}VKrX{7Onu5{ro)p(mK_erbqnx?-_L|;n4 z-=!OG=t~d2jWXWQ7X-?aGK@F$Wdq)v#vA&w32&Lk8~So1-m;80^kp;NvW+)%W((eO zj5l<~wH2?q#w#GR9dCL1+az@6ZoK6iZ|KYpnZN(vWU)SDV8R7((Uio{V?3g;!~kSG zin(GUheMwo2A&y@Vs4mSe-tyr;`B!`6$~-^kYS#9Owb<}iAMy_MCwxUn5aJr=(8lm zhD5S}JsYk+3c#}w`lA3eOVJ+%l-WrAakY3%)gODrW4iv>D;`Jbj{=k|Lw^)-WKR82 z0FhI>?ka9%+u&Qi` z0%ZeAoC_k;P6Bz(43V!`Zu6nHhA{H)v6w-B_ajn4`)(d;dScUJ#%)^4ig8yfLyTg; zAWSgn!yYRC)PZoaPI?Ujalpe7Dx(%Xm~gVim^nJ|g zceb&3Uy}JtpO9(B`CA&#|C9{FfyVex$p|_U(xyweR|I=aQB&cKpOG7RCn6%$454bX z_M*l-ziMeikXo2N!@ykFzvA{zPx~o8;dA0N2~?&bbA=Cqgb#;HnGGdH4!`nXiq*(MzW@Jl&%6Ru683ptI=WE+Tj6!kd-@mXClqn zejQyu^&HifyMN5neb(hR_v> zRI|K}7(o#SG5nQVrYiK6bcE86dd=m4)l zesKxCY(yzelUf%79Sj!~es>9-E-vv*x`58+U%2RSUOtZAenkupS%!nhKr5IBi&cc4 zWJR1p!wCYz7>qV@ZRprIdTGpI#ZdiZ@Gs-Xil~eKrUVzWz2KtB^q|7YI69&4;Q^oy zBX=0&Xc&=1U|8XA{cTK7!*dZ{3&!sd#bQQdm;^;f6XR7-&c~I~eO8;A&lUby3EdcL zt)x?;S7qFOTgto3=s0>z=J%G-D!RuOdZmoMKT@%7BD#mgV1reiVJ4WP@O7rdOs!pC{)=pQn^WpD&yoeXgpDK2L2D&pCSi z73E7UFBPhI=`%k~Ty6O@X@ljZas6!}!fmrwP4C*{+Kj4wl>VJ9|;*!Za`TGSVonItiK8gG;Er0hk)cjxsJBV@(=*H#8D@(NLjFev0em{oCgD%d zut;QBBr@P~1Cc>Y2wi5A@P`b2r-)nRaEly5Z-5-C$lpuVRPDutQ`JS_)LLQ)GC^CgD%duuEjvB{B%z1v2chiCc*qF2{av+^3ae zSUd#63DRC@|Du=jxCgVkZiCg`Cz{%Clkg{W2M28U<9Ri-5oeUEYUl;@kd13KRD`_} zn{?>y8v3Lz*NgaVq0n^PK+F!?q8A;fBv&PW&FAq(O_@Tiwe&-h_q>fjzkXM`V-aCP#VGwCi0*H46#J;8rmk6Qyx3H{@Gnli}HlXZtO zE}^(bv7Uc1ht?G8;cZLJ>y*Vc#)v`UfoB{}Z4iPL;h7NEB=qC2(BBZUjNdbxF0$c% zY-lGoHqsKFbQ!%M|B2Q)z9yJ?&g|&%u0lyw+?i~I{}Z0Nq4}55_rn^5(2^$l5Ftf+ z+runv^NZ)wXCO?pF2F5DX8&(rKoiX80oOj8fbMR_wNWXhWE}26(4+Jk!{7z;aRsO) zh2J@!zVPKLck-hP=u2T+#L!aZKuWjxM64yX9QFgcle5p) zS*Aw@gxe}YSO(HaCC+?W1oG$xsxR3@bd_<`_{~bxZ&^ZfDSme^p%OX1= zp@bLA?=IMZ+Qc2(S=_ynP7}S^*n#_IlSN1tbU=U62Cu9v-rF(_OOI03QodRcwG6J+zjL?+{0G!gK;& z)Gb0I0~3(077;EQ=h-4`RI;)3ljSF1V?eW}n0XbEPto(0J!q{1U`Dhd5iX%+c`uk= z1QSGDBJK{*{E`&;sqo=*MnJy;p8mSu>$)orkH)Ca=wDCu7rU%JM z-o1@Fizb%O_6oOeZ%~|B$cYWJ=97~mh<4#}PY~e=vdLF^K-Cps~VHELU$&ks&6xiPT39JF1s*~7P5-*OAC(nfXW&DsZVfn02c ze@IBemPu3WQi_qgXd(!zKrh5KGHxa}t|W(k0a_p1AxshzL7m6n-ZViMBD zHQIDyJFmHwW~QI_N|mOh_jqU z-9pN5f?Yg`BAy>eoz%CWo#TCg}{Nx=pD+jl`lIWd^o3RDz5!b~* zS~)+_Av?zv*{z#oiG7eVw*>WKpDeK(7nR?-m8QmAQdcV4t*}cKVIVg0)wj}Ap1q9@ z7jp+xNawZNATOFPNjUbHEDBAvOH(7D+q{jA71ujIz703)O|$cNx6z9;ripBIb_suA z0_yEHd%Rt$kCeGhqd9E09rt7336lJrMiW^R-tN1T=7A-f9m$8!7l}{{cLMcYd<8z! zrpQO+cH!oN*qhTUaC36OcA82t>?zyn>QPY(C4!)aYxN-Xfc$~&G+@bk$zAk2XUh7| zyI}c?``S4@j9Nog-=s?zZdMO%`xXuZ=ps8maxa+pFu>w=(7%gB6S184(cILqTY`Q8 z%-7(mu!Hc1`)K{BA(o@G)EH6d;C-}}&}GIOO>F0N_hWK~-%OjR+Z;6Raff$0UwuCm zB1&l6{q$o(Rr4FJI#1-6-cJ+w(+|LcnS@R}fF+4>oPLmgj~*iYyARRdA^E!R(&G&8 zq4r1U4@rgvTvqf8P2EjjA-K{Za$$L#P}(H$dw)P%XqP>5Pj^L@rG|2G#}G^(!a(29 zBIgJYmOM_sP0u6ally2cL6`HMq)%Hf(oWMYf;W@U`%ls!#uRezhl&On|N9yG0e->= z@Ztfw>rAtH%Ma;mxQHThJ-7?i;AZeH(O&i;`V?M&eMm@mJ$7+NcnQDjCt&hU@%=xc z7vSXP_)h@(>|T4s{*6?+dvqTZgV3JhuEWq;o#Kxjq3L&B%M#2-e(hlzN8Sm2{V-i5 zC-h=@*f$etgV_&UH9kJYT4`dNyZaqp{WHKpuS(qID{8bQ!s_}IfBy*R>LxpX{AcvD zRBO4g>g?bPG>dMv^VeTM9MfKV=!F+)9up6L`UQ{z4}9bi>ibukO!y_eKE*QE=H=!0 z{gOTi2+sT!?R8o^6y0Qu-eiVO{)*<2ahqbO*o}j!*o^=YsMw8mKKUrR{35^dD9Zho zUwxG3WNfyRO0}&$;Krd_&+<-Bn}{E`+0OSIrCBq#*iEDSNt0ldzXkQM0&G$aX=_ZI z+XuI~-Dq>WohQ74t89(HRs7Od=rFN~Eq;aOXWeZlwPwrFAXjMoZacr@6`GqI>k+U6 zL;}~i^Os+t32DX2;_h5C+Al5?@0{UV$G6@hXC>sA8_P~i%Wr5!ob_X>^oun^jL^P4nH zo)7OQ&i)tOEx5kD|BK!i^Wp1n(rc`3XYzu#=mIl~U6d_b%0GG={wYV_qF2V|Y<`<| z#8mdd+w?(emaOxI0ndF0Ti84rDt(8pkpImpPSP?NtaK9r)9@)RXh?Ki4wHe0?4(&- zxCc1Zn3ocX127nX7}uum7vFJh>Y(q~*e{2T1Fiv{o69o$P*M0g*+k@(U6#ru;;LM1 zMx(D2cMJ=;RKII@*$`L$k{lKHv$O>RyX@pDohuQ%Sxo0d?;2r#N^*jSlOU!wAQO;A4Jq-c$(jVM?VGy$E|B)_OP} zKaj_=vWEnb9!y;2|8%g5OU{yk4!jc93R^vf^jsab#U<1EvV2_fJdN_J^Vvjk7x1~R z(1v2iRC^%Up3s9v-lO|%I4NENn~%`pYWpRK*$01cJ!m96Et0Yc!*c}%eZ>cO3j zmm1AVcuGD?@B5#b2AnQRmG$e47^!COlEo#GLsp-I>tIyl8;lzpFvVdBgwFw4Y(_X=Em$S&=Rkiy7XhWmq4pO=7sQT3q70zum!E>$rE0j-P@P!lUm z5DdD0Jxo0hoS7o=f`8D=X%Qm)FIDkO5zFfPx2h1Be%^HPc?(^HkzwUR5saVzG>@f- zJIPsKjPx;fQY5rJK&qb`v+Yk`u-#QJ^)-1FzTu5KWL*%xgYV3TRkqV;b?9nVIWgyBL zv`#eKiO&4~+=SkNFRN9AIx}#7ZqANoaw%mW8 zu$AMKHt4^~kop3LLE_Fx;SLMb+HaShkI*U$g>ytG+`#FP_%z0HZ4iH6GMLY=7|iF9 zb1{qvChK`rEQVL@(yL)QTYh#ri`%AwJ27-N zvVjiCr47mcfJ*#_^^DSK=%&vErttOxIdb6ka-Jl5Abb4(ChK_&bb0g{3G*?5i%0Cz z3I19ko7iWuLz3PK6UTG#l`(?(Knfn=o!&hwVMMfNAy@G6|DYqzgTXvYW&AuD%(GPS ze=CD|9u)3>oWI0QdTzRQp8Vyz0@qI3rITU0_aFWe=18X4JV>^Ph|T{$=Pyf5{_>-< z@s}S7)OyQ~Q{r#rvOJvM?#gAO<3AOtr|r^de(Y16%|XKZAdVG_-$#pBiTG{JVnatZ7{9U*d|~1C zYgr+xx~CA+Ws1Wm#ciNp=<<(T6zoE*!eK8`jhZRqno(N#ffc zWOL{1x+`-&9T#25w{Zct0^uFCg;R^-jM0_EMTb|Uw|I&cOC@5U zcr6{G_|}Kn=$Z;ku?mqHrh+l!ni@A~TvL$`KY{>l!**enP2*#Bv9a*!xoj76 zvHCc||M>{ZkYT?#&B(QP7fU6{{NYDfc}?`j_2M=D6~Yb%W;QVKzkL2BFhtO=OD_~3 z;IH9ZaW^3fKENf-w?dNYL~SdFMQV`hjq1^w)2x14)yBik6vEq*`FTEY2Z(1aZkj zixHE9U-B5sca&06CE`-?jeA)hzvVF&pXZJvIr9xWdr5K+D)!W4tT0;@Gq)^G@(j@h zOmlWom)V8YmM(M+s;h1<8=Y24bIcG~#0eV?ho`-i^0j+e@$}WAm999cXJA1D34od( zeN+PyaX2rpXen)ZV$ozy1ig5gMQ zzLnq6&&K3jRWI%$M$Kje3t$1(-qWcfCd_mE<$g9X*)ND2om&GM# zISsSDx-F1iJtFnMJPdPo^Fo*y!pIIG^}F>n{WfUx@>rZ`c)Vq`dWk??ryo%7g|!=| za-)%kFrRv&etoG~Xt@|oS*1A{i@bf}E>zH_TBP7gJOuRDn}Z+!R}2FUy(*YPFN}5t z)~2TQMp-$EHF#Eb7`bG5eN3((>g>Q*I4y`f>d@O}J)_xK0qvF^+~)(_Sr=0<+;N20 z#6^O*p;y5b3q~7u`3Y-Qao?Rdvhm`QY~v(d_(|4GABy8!pJXMecb@?bN9{1taHjoBD zkwn}G36?^^m63*#owQTn%8oecp)*vSo^0$xy)dZ|(kiZwm3GDPZ->};x+jjm7-9=^ z!bd97o-IENmO2^`O%YU)! z(gBxBF{Cg=F@O{Lr%XQLX*Q$pEm8BkaT5MSe|JkK;~Z7y4gu>}G0PSrTV81p**e6g z)fb_K);cerq*Gmrv`YPn;c2q|B;#p{{$#_`h5C~nPgTa}I6O|(6CF~{LpmRFp=P}8qKgB!H6K;Q&Fw z8Cydtxc3EiF`3MN@B*8cT5*Q@iv}}?lh2Sfufohb)zX)#qAwMQ_29r&aM}Fei|psA zbwgAj*o0a2W(Bh?71RsxCng_(ZP08{7v7shl4G93Da|`WP3c1{WJ{Bu^E z1+%XRlYyH7=XzJd@O&kFNF03I&)IAkGr#_Gh(Jq?B5A*1<8U<^uf=aBZdi+4i~^*J zT!-`tzu_0Gbks5jsagoesuxDNox%wl)4j~7=8a#lOR3wTeNmIaXS~e5LRAO9b8H1`pfHQ?juQJ6^e45J?FG2sVOhX^uwbYLZaE_Dg$ z;cd0io629ZTC}M5X3Ht#5YlzyFqbvq4d-1bUhr4~%=EKlQqM1;N_*D!YJgafEQe+b?PA)-O@} zcC%2z-C}Gz9MTSlh}yi4?$m#?`NZR>8ckeroK>-h97eqG(4)s$kDR*eObrczJ9``= z>houGuY-5I&2CQJcc!vK>_Yn;xZgF8FZv@(rUx8+=k9{>XAhfZsM~Nfl_x zVMpkxKQi3D_q=0Yfm}`hcVX88UR80e_sm|CbN1c|CJ-Qj1P+iu0!a)AN|Z-J0Erq6 zj{xC)AV+gFFA}1}E7DkKiv=YrE~uBQNU=tV0u{FisI*e0fST6S(iW9lxwqO1r99&sHp1dO(B-?>e9!FkhY_w)0T zGUW-s_GX*xelDq}lqdacD%vkk`L%1Hpgis8Au+T-y9$B@VS2CASE#D+(1YN#`-qT%n+$m+93DSIEn695?;fDyxf(F8aIgb>SuZ(!DNp6PlwG zR>Wh_`#vfia2W?%hC)7h(QjCmc8%DNQxsY5oqlRDQ{#|C{sb$@NU**=J?r_YPj4&I z@5$Yo*4yGxEM2Spnrw}wYxMC~u`u^f);0CEj8w1KK`3_6m5NP|7Mt0v*mR3;i=!M^ zZQma`w8qguJ5v{$ZW-B@`N0 z%|1R656Ei0$Nda#qkiw9GW z)p}#$0ZbceHFr?I+!DLAhX?S}Go!c0ebZ$muCN)K6Rt+A;d)GC9avN`dP>xb{>)_n zjbXc@Jum{mvrvd}9Z4F`j$7CfMS2oZH0wes9{3>y3-yO7rMHUE*k08|{tb~9-!OWH zZrRN0U@gKDuJD?UVd;e!sBg4{XWcVf2ORL?exhw1$iRpXn#5s7qb8tLmVuv^A7r%p zjHWAm)6BI|vRv1VEZ2I^1x0+ku}&9->kSr=zr%P@8jZC8)`jr}tn9dXAPv4Mw=M{5 zRZV4sjs^(K?|W&KBb%+4)9DLSZnF4%22G551yAzDS0fg5B#dV=S7(wnI74W6veDj* zbaVGx#uf_*ZyMfJ0sw8(VezGK_5&tKoFD++p#x!)d2Jelnbv$QBHctEnF^ z89`-wGrfNV4Uw%De>{T5^=iFLpX83D;k+=5e3N%uVr&QNKJMnMz-+AXyRC1s^YLKk zlQ1s#q7~jhxz952)68{}anRDJvSi+s1$kdQmz0@FV?an6>IVb*v=RW_X6g$=jEw|x z0PqE_LI4$t+CC;~G+q56i&L_xpK0I(Sh!X*C*&Y22 zu-oM`8Hc^z$rQ2t#0VOo`{&N9=?>F40!pj^#%5A3^^wOdo|jAgWShlz=h75??RDt~ zxiqO)+ZDQS@$o2GwO^(e+b`3L$1QZ@3EhqQpFC+9_~~v$!l}ztqG#&f(N(LP%=NU@ zg;Vu$>?m@?f}bRfBA@)!;(mE_q(_$S_M-Bl>eBj<(VNfSK*L2J?mvz)dCvfhC*!A;Q$b7ji?FGvP zv~anU7cDnfKo1H|Dx?yCSHguX$1NCUwgm)%HZi2`P@QrQN6`g2^g49kvyi8Qp43*R(*vN??o z^o;W|0Gmix|4^aD!{vO7RWwX+C#sYjb0PT?K1Xpl^|`R!R)T*r72!<3A4{UVvRfgj$y zNo3mwe%R;O27b7uVt@-96RF1q$njxm=jjaSiSgcR4&eQB$>RLEG*A}U9Gpv|>;j!* zifv5k%8@3EY(6!YhUue5M5T@zr#)2bT}QColhVOn9gl@jQrjrCyK`D)_P02#GGqj&Ro2;A=gKHmH!pr3 z4eq&67Xv^}P#;6K5$bvui|?8T*xe-`6R69&AS}|+t`1MwA|BF)^03XV^C;z8Uk~>| zJkkD>^C?Si5S%-ol4KS7v4B#!b^*n3)qJ`xN)J79J(mrOBY{LN@_X}XmRxT0&;>Na zUalM3U>glx4`0*2t1WPWSXz5WU9cQpav_Rd2dY~@xpt#|YAbL@T~GNrbs=quZ9)q9 z*FluCwks`$PcOtbTxWBSMU;_zi8NrHE^LEsZ0P<#-6EP`H|rFXxT&+Vf3*nZZ0Wr0 zwU`FWt=*rSw;1%gO>h({#!mn;cGXU7S<%fmqgxGQTL<~;Zu2uF6CSa*{=*n7b zqa|7#@N==evYgUog3V8sQ-6ItP)^s_tvcs!+t_VK0GGW&G$oKL#!ardr@9;H6YCx_ z>dweD_C+fN;?8lO3SoH3gVB0ExE=HCPL_Aj{q`YU@*!ayj;8(O4xojP*gUd=iuCcd zSIji~xX#pO8*S0*|D%E?0g2w0>&TrBAg8JQZi-sl0AaosTsAh%hd6Hu9}HN{fJY zHBkdjoW|4YDLLU1O1fxw!V4|lUr&}uaSzv1P|P1)0=BSvML1YF69{pLlHcnTWp_cw zbquF+4fw9F0pJ@!X_kd=4=)RJLZEY|&4iSsGBgwJzsn~_(CJ1D-_StUcq^n7j*jV) z%x~8z{(sy2$as0;p^j|k8AO&Ji%p<*V zW~O27Pj>L@J~gE}-3ILy6jkoH&kHuj2NP*I`!c%#U<{AM|$*om+@)159>r`Ri?O2!-0 zaVBwD>TuHrYLsOTf3*SIXB^*76lro{q^Dye8aq$@Guqw$FcnaQ)Pl~VgC0ucryr-0 zlX{!+8apQ1Wm+eeP;81x^t_FTkb?oH)qyxMC@t(%Im?{}r_pJ0);jB)4UQ4Uhi;){ z&SA=xRndz^rV(;^^x}2KwA&E95SuaSHbyTdY^I^kDo4aZux=QuyjHp2-Aw-;FPpq9 z*J;}by^o1Suds*y^=XlqBVP+P#Qt(fUnT-hE?N zzpy~S7jodHmNp@ceDT1U5?DYuPd#?Dd9HZp*k5pNZ2ocrqDUEM^_c8PPZ{vlF{F3RSxO0UxN+S92t?0dgu9RDUN;k+IXv|OPMcFF(iI-@Rxm&jKS1-|kF^lxf zfWQ2Y?mSwt#kb@M!o_ueS8>%{iwXVjMI^LReHmqx+BV93jK zMgrH|(*@gqSaPvTFPcdEa?0{vjXwahD2!SD9N z_m=xWYQo|-_feY6isR4rQQnB&zGNTXK%A1|2Zl)X+3}NtOGCo@pPw+R54jB<7V2zWy!x zOk}v}Z__FfDE7&;S#S=59c5Lm=sNYs-db~yZspI8&<&ude;uJwz2dMujxG*Y>&_`b z44Inp47c!?AX+)y$J>t5FiJ4RdOmiPiu#snvc;{!@^A8n@>&Azcoo({HN7;BMEDS^l(7oMPD!Q9E=a;Tp>a_GT#ATXyQv;xjf zqDo~%Ppm^I#Y?r)&?iUK(qa%gGNRDd+ULlJsfR!Yf3e4S`L(LgYP|u{K^Y+?YN#yN z0rTL;vqNe9Nu(#LLVz+w0wN-(7lyGMK2dPCq9T$tJEBgHW`b({vA`0q<=yHHj0lWe z5?C5SFdsPIM{LF=IieY=o(my+KZAKCH80<-EGLV@t@9aM%On)sZdP<5aovb)gEsPHZD zk?)SI;5powuLh0#Hq~Btd8!>-Sb?Ahv#>A3H?J&*qY;x6&(pskd=>xh_W1{`_YXbi z^F{Qb%R(4co@Nwhu`uuPM4zyUP+8EUzWpz%rwhIY$rHb(+g4ADCQoYA`-jK`gq$w{ z#GRA?6@4{gbb<(Bgo8C0W(HnaI#5(Fp!adOtAnX}R0S%BA5HLy?al^o+h zprG5MAT)5GP-lC*=<3dgP^72WT^7nQiUfRLBiw@*&r|1sjRIn`2DAaCuG{O%Dpa8L z*67tGTG-Msb^?4ub_60_8d?_AK}*5jHlXn}w}(ZbJPdWQHY@Q8!W%*8;8~N@M`Xch zQZN!Gs0u7Hvenn)^ZO&!&1tWyC}7%8!#;!PPM;R|QRRfOvb1%8~HVKHjhHmRKuZvek6CGLwCd zdR$ZVla6|z?*?P}S>2bhDi`cTMw|*^@p~vv&6dS} z_rKy4RY;G0n;frv0@MAV1l1rL{qE)jrND8l^7B(Y)iW|{Cr|68 zZd0Pg6n}R=OjPNn*y&P|T4u^7KZpCPfpV>%AMCHLGqc(yzu8|+GP9sTv{F>ab6A$5 z_S<_+0YI17;J@lo5$?rqsv0Dl|G%fKLnf3)hS=oiF9xcsn#Fvf_2rPfa@{2h61og^L&{^X&lrAA7C);$%=-e)#F@~UB|Qw$u8WVh5pX1LshcK z;cJGeA>zk8dzi}OUH=4Y8ov~i=+0p(4Fu3OOiks=4D^!N;pf$vYK(00^UIm4YQS+5 zaa#=0>hFme2L^Esb&cRXqi3;PFkF@Rcl$BJ-WMq0?CC1CM_OkHP+{!#^WYJxuy>mY z|L7^Xuz3VnJqY(2)#dyA?!6<_D9oLHej!UeE%*6(Mz$)2Cev-nRs=tQ{$A`%Q2k** z%o!8Z2s>Sz##|o1GBBIl)`~=4K0&=j>EevZ<0h&?ovmr2n%<+`L`)M(DuGwN@XB2N zc%n*&0+fCEDj<*hIWu3~ETPlH8eXr?nTRpQf6Z5`5>NP(Q%YBaD?zM=xL_h^4&B0H z2YiG)QlPHU`p&lsP|_(s|FuA^M}P#rZ<2alp7ZngLUmML@UuNxwW(ARV}$$hWRP*d zvQiT9&MO;5kvfPPF)ixnF zSnhu=Q&mC+1y2vD%`qoPl!;sT^N_kO$t4FZPiaS&>5Tv18-c>J9W$) zZ@=I^d8ev15fLK3T8$CkOyfB%de#Xg8Zfvo;F~|JrqD&}qV!l0{>j5?HpgsK{gmFSyv?Z_ zRgDz3`_M*(7!^DDShHI1I|=V|!m@esBdSWvyWV*O%TI#M^Bz^(;na zjg)z|Tg+;^kmGIlZ<{sAOt;;CY*GIW<*x01^o06PDTB8A^Z!t#g0_k(n^T@ryJe%z z?>+@WTWE9cHubbAR@vOXO-(QbB$|DmRt2Vj=dXEBt5wuwHp+u_jU4{5N|DXB`~4rQ(c1IXfoHI0dBy(X zC+a(<*krp!&#GJCV`_^{Mp~GQpH-vWcb-!x1Rmp-ovK+M$F-{Cx|z-ksvJ+-T=#-H z4~Z~`UsOx+M)02Y?u+V&>C_{ zrgyD*v6Hd2(*OJ{UQ+!{(Q5O+m(&~p0-_w~mY38mm=_o7?AOPZ>g@QJ1V=S+eWJy5 zI(jG&D&TVTOtwxmOSk%Ed_svm;AR&~x_*8NntFodLi;Lp@9lnhz$uYaaqH3cYV zp^SY&IabZX%_(8o39C zFv=-{b;h)#`PJGE@oZ&dwkME{>g4JhL?9GgR?#Jd)!giAY|H>l3FFIp{B3nkpi{nk zX#pN{S{JI)+;T^ufqN>#D6=AXcj(Q)?ICP9H6vXeShBS7-XNsJ)uF|mc5RUjUZ)JW zKF1g@=6Os`co;T{=+?T%2*(XpI`Wp#*7Gqo_{6>`tnc#5c2dY~3cK8n;sDG-47;#d#fB3C}{$h~B|2Uxrn*y@s z{=ZY1dS;vYJ2h1#tcnq*L~Qrjee3Vl9Fdvr6luR;5q{Eh5f(X3i}<7QhD)eUkFnH~ zD$mRq>2TRejMFUlfs=ZXEpRyfBaHk4Cxcgiq?S;DGsWRQeuQPd$l)~~t1o1!!;PoZ zh}B|ij5v)BT<9zdI+Ql8PZMkgzyqx5B=CTC3+uAF6eMdV*=oi$pvncRP!vt}B2 UyeJ8T3J@W#entHTXHB#7e^b9T(*OVf diff --git a/artifacts/polkadot_metadata_small.scale b/artifacts/polkadot_metadata_small.scale index 05ab6bb5aa24581838a6ffd2e2f823cea0ee891b..c3ba19af1d2cd3186897d52275b500c23bcfe6b7 100644 GIT binary patch delta 26506 zcmdsgeSB2Kx&J(8Pm%=|+`tAlB!Lsyzy`vSK)`?j2_!%?fdGl1g2`t0gsj=@hJ8th zRTpcmTG5Il9FRk3_tv1?dtM{tas<(QpRd4lvYOB4qt*y3tTYBxUdi(p%oU@zF z3zXiM-ygr!?(R7=^UTaM&ph+I4mS+vzWt@Vyk0%wKSNg!<(;#!*iqZ(4~O+cd#69_ zj|B9%D>2xo$Gr{v6EXkBuzzoyF_k&VnXFn?!O^ z;6JwcXcs=+e7@?Q?j`q5J+!ww0o(<`{&;*dZ&qhdZX#!ke-I1N&G)HGF}7ps!rHLi z8}Dn60e_)h-P;=N(IXA9STx4Svu$kEZQFm>M{Nw zYSYSf8~l+-G_fJ3`xE-+XgJ97SoM}@qG5lZ4xEW*cE7!aDf3GDXx-L6vE;R_{&>$8f3Lolkvk>3! z;!jPT#m~>5G4zG}5YaV5zn%UmsqW@bgdZy};y=C7&R?GHSUOofx+B`FYyMtA?b?7p zuJwi@2|cLcGphL`n%~?AKKJ@$EW-1Hg}lXCux!fscAY3kJ8ZSy>~@|V$+%dwbki1x zT0mp_jGJ}FH`lzOgciUsI&}?r!)8I9Fo+^n?$fX$c##IYa;kdoSh$%cV`rna_3e%M zgL+WqPfsnFKTYkZ%S=^bA!(KS+>P;gQq;?L&Ai|YbqTdb6aKIk!dtH;BXGbVs* za$BFfwc9_ChU#`rP%$AYP#|JE>geW^pP4-rD>#SfUjF1v-_!@dZEt1|f%7tUKmTN= zZ_ce$+@i-iL*X!^;!bn$N6Fb4jfNR}#MpNhZKu2V6Th6p2MeZ9?NDUa^)#=9>a=*m z-=oJgZ@)hrk_=ai#RlNf&t$VxP7mb1V9puT>wNqv5>ebe9&=_O{ z3ik)ZroK6AJf65{-wqD%Agv+hZ^WYRXEyu!qI*%Kb)iqNVr_4zUyo=R@D;LP<46fk ziGUtS`1k5sv`e%I#mos*Xnw458bT|&(y&`QbwG<*p@;e7LxortqASo5;a$EjfS2T~u>k8b2*Dy(`Y9a&?Y( zm9{a80bxoiIeVi){az{-Z$Q>;nwqH7BKm-s0(OEJk*FbQE3Wfn&An5ez&Yj=ERsFO z@19dR;{kG>3xWq0#nBKCM-$cjy*d9%PYpdax02{}{;^ix_==+id_542#PtX`LpyeA zB-rP7`1|_YEy>PsC?I(9V^pgLm#tV)wQBY1^xKyN>wZFGFW{VeiapCaOV6ffhwd)T zA$o`3Kd+pA%zrqqs^}%EjmO3`{Rs5tWS{Uk^V?>;J|ZZvKLFI5>;wMA`Kvrx@5vDz zh-5#zqgb0*{Kx#?<}W?tS7IFYci7L-_~-0RUh3IMukdcqZS*T{EBg^|S>WOymIbgF z+ZL2zt+p+2^BWeF(;xU_3pUYIJkRi(!cKKF1R@Zvf9pU*#{uflApPhu2ob=khC{P2 z8uy1)NE;sUVA35i?{>XQkAdwbdqr98$fH>UBF3jTE%eyyEfCzfu3)Hc;h97q4Gnrr z6&x{NSrnwon-*V2pYY2Ue~_w34`hd)u#*e3*JGd3=;5ig=}MX`_mQ(3v|mY;pr}wU zXnHdq)tdB^CQ5zN)Ymi3#4hn`5US*~#6IVEiR;vO zWH)WW)*D;-bP(=TA4m^x1fdYA(*qU9l-Snh8mh-=@}x=p)@?fF^QWsW18JPS?C}|u zR1Cf-))N9@e-vEvDA#tw{9Czf71aY0k%O8z$uweIUeQFF$tHf}yH2dvd63==Rz<3YGIG)-EK^(9hS_ z+ETS`eb|_KurVUegMQsk6*%z4Px01CwU)B6wX3$ZLTiNRR}nmAxm|s!75p8?l7y#q z2~pWP1vFC?!g}>XfDlYyO``jo0@30n;M(va73EgFtpUv1ajI&FaWei6gaFZ;ubgp@O*0xi~jK_fv)D zq=9sL{jnZZh|c0i^@!@joZbBPR|*S#ta|=@Z9}xTFRbqmB?h%6TE|vzRe1-Get(u- zv$QpS!}nXJX0=wF{5Rh(nl`#A&wptPzv1P%*%fV0{_U3=$5x#7&z^-9U_|Xg358_BoLg-gH{h)GM6_IAWU(0g%**~auSCa#^AkV~;ojv+s+<}oU zU&eBWuKR&Xj;x{P@vpox;5rPHeA!$$02n(&{DvRZLF;+tM{|@_#6SAcEU1b0 zHjx)frTkh?5c3*%ZK34RWB zDLu4w&p!4LulxPHP$;f-z%G#J@Ucm>vu^vA#x0vxYpnndT_!A)2d%!LWqZShy4HsJ zQmrknYaLRCYR^Je2N(hNgFoo2G0V~@hG8KdO+w-_v6q*%NHr5Jl4AE$!+!9T@SvE= z#7ouv)0*k^z5YQlap-G-P*(`jK41Gzkz#hUdLqy^_xZFV3q==B4E)$T)zG{T{@AUs zU-6ILnZGof$~yLBCdxiK34lfKuC|83FMoH+sUAwi4acnOTU;|OT*pk^I{#uxM`Yinrl#;2n}Ge(V_?iX+bII>MS|;A-BTI$9^RxX|liL@|#HQ}ayM(k>Q*4n-hf z!Q>*&d%5kkDj|P?)^|hviiecSxqoPaqY zT|h;Kq$jLCK`jaskgOR2IV~9oVM_$S&7nVwQ6vU^j7D}+_U73c3az z9X52ff4^jUT2B{8J5H{y_+9+*fB&6*8&Obj4ZiI?mx`m@%U}5Y8)N5i{~x|L$rb1p z=89Y|zw*R0V=J`$@d}qm(4s`5=plp5`4EH){^RX}(WrEr7~#MUKl777iD)~rQtG&6 zo2A$*_?$nzHe)mxr$DO(WS6H&Kmle=%Lw4X4hY_e6S)mECWMhmZod1^jS~WS=g$i! zr>jja=FU$)KX#J0f4Y#r^6A`ZAWvbvk)%GQn1A-^^%K<0uQoSmBq}T^aptHVdh4@_ zan#}b%iK&&2o9*qrq&Ey^q24iH8o>8QK`~E!z+kxQD~3xl8si(y%h##!8A-d5N11Z z!gq*cAPBpVu|TC8sABk0mHv*Vk4E2POSC#8l}n4g5JyK*<`~+ZQT*fWvI1}U&~034 zr)^`VZ2Z(tyM_-;qQlB4k{YgZ(Cs)5xdjWL!0k%Eb2r(=ewH89$gt z9;KItPfVlRC;2vurNrp5h`qfqP{KxKuH?-lma0N$nUI?x(HK|c(}ooI#)w=Zv};Iz zI1&0{q5cqLeZf}uB}0(A!J~v21hjRCZiGz@8%@w(S7>hsEWW|Coz}$ZOJi}m)jTj^ zwuNLQ>-xh3Huw&VtKGCmIcDR3*|vSr?KahI+RP#Q(;$%@Y%U_a1WsX;RM{Z7BmO&L zGcMXhZlk`4s zX0NmbhV(dK+2#Ptmyxk(4lNQe&znO&N0$HN=XR6Ci|#(%_(OvkxWA#VR7q=!V*5nm+qKjT;Zcx z)H-~`2bdFdG@XoJR#B62lbf29HDvt4O^a0Qp$Cop+1N$<3aLbCB;&?Hx=h(e#u>Bm zeT96!$oOD3&7Ac{uA`|F+ytjPs08d*>ZNhx&?+iQF?EMH@v6x!rLVP&ts-Z&r3NPZ zgc;TiStFE)d%$<4=_p>j-h?Iy<0>qmy9qjNU=VgmVMeMXr!+<|=5CCHLlKb5wa~+? zHs&jFJT^t6J;_ub1eokr;z}!NG~ZLW$Ir~)MO!d15lCa?SSYkW5BcI$t)N?rXHxvdLFSrK?OEv z>uart0wP9N4}y({5-nkWK&Xr)u`v7OSb#IfRi+*kL$Ksz4U)LlC)-OF4-Hg6^znbF zo86^;LDn>VUsffHZCTBIq~0v*zy%`*gdei~$f(U`zTIPnyj>U88!_nr*)d;m8e>+} zqo*D-R#XnoS7RYqdOzT*nRWWeYdejB*wntd@fef-5I?lb+BD8~z{Dg?X8-?CIrgJq z5Qm5~2o;i9sE>(NN!t!&vDjn6b{ZE-i!eTjjnQNo?tQBI#JHUzWP8gwo3Q9ICfUka2xlolp#c zL2H`5C!eNWojSf>X?QiEp?|?k#TYW&4r>6R61LfRpj!_npVi%MBgNYJ zJP^PGx=_NbVg7F-W(wb5K5w%7TU73%MwUzLhEyGa5yA=-GGnY@T7ko7Fy7v!>zN3v4|B7_s)A{dGO}tXHdzb$ z5%5)~_@vtj{dgd)T%2eR;l=GlvH(^axFccsqv}y07<(6!+Af2WM3mF*gfORLP{3rI z6QJSG40IBn1pN1QZbon&=!WAX9E$UO1v65PS|Jebv|fSrspJtlVY?}CkMacr=B})o zqM>QOI%Okb!7+`}Gr{(*KSgip;H&$Hy3w}Yii5wselCA(y~{bu zo5DWE!mba{gM8hFA>~Bw(1{H%lJciq{#3&z3J%#f?uUVhU$H4d`}s$k4lAGK4qd(Z z>Kx^;jXSr@A&oEHa?#A%EoKA?&aD=Nu*5|~8zMD~Ej4KM%9g9?X})Xg0xILFt;b;w zDsMT0H{Wf!L4KC=&u#m>l9MNt;Mu%)`_m+py6?!(t@ezsb$x46zS_cb+ip=N&5md|DUR_SGR(_C#lixdOz3YxscEqE zN8#ebD}>RRYRcRE%VD>hDxoFzw_8VT+C9LEZ)#tf+9uVXw7njJRxl(yP^M4E1d`UL z;?@9sT4Ptn!Y{lvGIq*aXNJNx2Fp7t+DM3BRzO<1of-Ke)fg$H35_GA3F87DrGzGQ zFGR^eJ&kDt*t1e6>Bs=?@RgAa*c1kEcwR*p)|gD#5;K~PmH-e;#>9~-Y9*n}W%U9s z+Bw)v!k#s4qX^E)7+?7J+UsaDw|Dr8Cq%0&9zcxUyF=SMR3%j}mlgUXpo@hO>WmZ7 zUA^xUwaPN#I9V@3v9=_8JM|d&mOT+YMX4($ba+eA&XE!^Ot&KJ5K$k3hD;BG>`gmE zSn@4Lo@mEQr}ipkd3;}>IbV}<^$syu*{8;T5YVx+Rs_GH9#`$V`LyR}@xKI@u6Pc1 zb=7{eojt8)v+O^Ow=Dh1WNR;4tuJZ;tyzck2H3s!>f1p!YDLy`$syd}z5e}Rux5x} zmZgn6!W0LOxqr|>*{v8W&vTdqjOx>=mVaKqkB$y`yNYw@1aIj1j3iM{MvxmO9nfR) z5dl7#khQmmz8t=XT&;p{j0{qSBk%(~vr@&DlJObQrPjIPwL<4AggTO;xAL`Yiuy>M z)(1esubG*!hT~R-E@nj9fJ8yi*C9G>_U|9luaK*X1(^0wkRR-slByAC83CAu7>D|L zrbko?^(K2ytLIBcPj_TZtT>F30l-7bzuaR_RhWZrN8Ghe3f(v|=8?wZD0r&+Qf7D~ zV05VlCFfmy)I;=NJR=H1!K&O4*YiLAL;)2YFSbP+5}4 zcSIIKn*Us+9B0FQkq4aBjR?{eQDE})XA1wfXv>T}R@^~@6@R#v+4#o3PA@EEB0$~R zb*l4d9URuu(lg>H7ZvzW-&3UUeX+Uac0@YDK4&#y{64VQk6CLDt5KltRV$$0jPUv8o&l zXk{v6-Yd&-oMb3XP$`1KjiJ{gtTq5P5`3iYASiePG#GJ?Yf_TxI^cV>HrQecfOrs-J3V%g1rnd{Xf2N+t zv@7F%iNY_B&&82?N4!KSRrouDGuN%iJK0P`_`5li?Rr4RM9gW}$%}XlYi4B%pOIKR zCEXX>Ch#C#y_>*;tpLNU232{y>gp0s$)yU` zc~^hQ+$C7&&4^p5m$?&F3T5}SLgA5Q>uFZKssB8yrgJP%epUZ*rOxcTd0??JRpFNm zw2H4+2F?>--u>If*QNW<5nnIt@3GJ>o|*>_Wj%c|cuCgN!ApKP`?6f8V}GF6-oM;3 zLc7duhVbJ3pF1zVvMCA)0_WkzB%FIHYaM$3b2XH*qKpdII+3OjNSIX+b)vJGtfmE` zt)4&*!$xrevRSNB#;6)XxMC4flgqtF$Y$}YPP3zXw==&*hVB)=s{M@+*_jcNDE;l%)3$73%-SX1p<512rGg2I_+wZ6Rykzu!RJ3;Se#}w z9>hC^`a<9`)*IGrj;`>^rPH#zmm@0V(JL<>^}1Q%f4=h2s8^_Y+ZUQgy+W-MU)VG1 z6>4={^=C!T;d{PV;mELwHb~r61I0I8J&Aw&iwkY%ryrLp+r+qP${p*3VgwPpF#;wJ zW{Q}>HifD)ENQa{`DEuS{HCjW3MMGoqwwk1B#NO)0)Gfha8S)?A(1IVrPszu*^>t) zs*r!k?FW`xLc>$Hc;<~}!-L>!zS z3S03`!~??k3a01Y9u44sNY8NZG=JqXtwHD|da@V5AQ(aX4Fx@B>}4LSSRYCR;C>Xx z4s_kjqadeAjNPtei|0w4(<6@GZPN3b#MXvTao>1cxYtL6gAx(WHc&05UECavgpl;1 zvKlIuQIL>1h`HoWR#_WAcw}vLaXli-kz|16vKs032L+lbdKjP9DpGoqu|YAo5vEDX`_`4fnphESQw4b4kwfy7TD$bv<1a=_k!uoz|ffQD0sRal~T~-NU zI${#oNg6v4uDXVIeP!i}*R2H19Oe~77(+m%K4>R5JgR#Whz=J)O^76gG>}DO{6}Az zyYn)z-}KTsA&VuhfaoAzV2%l_LG7k+6!DpGH<+0qDg#|)5k6Mta0XkR^v;O$rAKF{ zt^%kLv@!dxWp*~|-RLI;HI_R@zdO~F4fU&?C$Eu;u#*=?uz&2kR=7@8xMjQR^zxA{%v-YO~1C!gK3<2?h zJ8BBA1%aiTBCA!;NP_%@J4%)775y!e8%5{l#|{EpmI>u*Kl& zf;5E$WsCcyHw>Z?>S8hfU^TcD@4K_0@UUVrtC~H6*~-GIl`4CH-*IQzEEdWD_x2(c z6|t4j(kr-j_pBn7rGYY5fq)rg+3pP?O;%+`xOSIovOm+5uf40J`Vcy*6Ric)bif&W zyFwLa8yRiM*q&SjAs$oM`6CU#d{@y$_bFz^aI@%NLO|%oAnGDxwoYNmQD*T6M=^29 z!yhzx__cpqY{*r)4oe>QnqstRMt55rEX@W*utl%_s6q#RWn&XR ztfm$D+rm&9ly6mrrY)z{7E8P@Gb;E$<9&jE!(!{)BJ?H5B$99-svPHq$L7<+e9f_% zRE4=hap}QePb+k5);LF2J!>&#RgwK(lODfm%2(No3XR1EvPh4NBF^ha6K9c#ExX>N zP7D#%SET2#jDPW1ow6#Izj&-Fm91Ofp02UHep^zH4W_4RQYValB6~t4nSvLhyK1>< z(z+ufZJ%f)MWkZcUP>^+Y-Va5St`%*^e&|3+Yj2s&X3=-D0Li+a0G{Oh`-gN*48=kvcY9(lKIOJ zJJNIjX>Fp_q++q~P>f$ysMQkK(xky3dMt0Yja5sVJJJT_2q8=P1+$JH=gs#Pi$kdA z-b(k_k($XmDE!OU3g`{~;=Ni9A~b_<@!#INU|tq_oWd9Pwn9zyQRLF<4KO#rAz#Z^ z-?z9Zy+X833>*o%LLHX3TeR^5_Z3hZzvaGid_Hxb*ORI1hH!=~g3R-X%G<^rU-c^2 zDtzTv7gVY2T?nY7kSRBcgH>84hS8J#kiYY_f@u|<5GlJtfsj8oh`Igos|zN>x@)3C z)-cmwGSd!!t;h~1g~+m&#bwR`e8e0>`k!1v?p47*Clu6Sc0|^GxXT_Q*a?eTB&d#o)UoD%t5u9rxKyeDe9Fr zO5KDZ%!&vnns5we#`^dHl#5Lah8$0rFizIqEe2`MAeH9U@?>X=0l`1a| zCEA5^R~#{EU-V+8Vav8g`$B=yCYlQ7HJ4Hpu_dfRCQYSRZ~SsCY+H2&@%Rnm~h_D zvCMVL_&v9kPD-DQ(oCb|*!VAQJF_vzmTk#6O~;>?fzFF}l8GKRIcAVLv%(Va9%P ziW;YCJ-W=YpNxhzdj6vuoc@z#KN$`Bw4O}+$!S#;mKMu?a@zI(>J+lp#DWh$#e!~SKfSC7bqC}Q^WmP;9|wtxBPBB)bu=SZmF*V2V3 zq4GHopK%tT722pi11)oITJUhb)Mwyj3IVY`9_DMw$&a}f1U$Aie znFPgotai&j<1@c`k!ykiZRnbB+Gwgq8KsxK%x@j~8iIG$J@UHzbWdd?qABwZt$wtH z%mRMTw;nZr4ecAAO4>y5vjD$3bjM>zjhU#{&^wR+S^)k2cg~+9ykpB&tYj0-V}*^c zf8r9=finKo6LV*b6N4Qt{_Yb^XT8&kFsuMVFhww#(1=867H%Ct^c(I)OJ^8L!+p63 zDMQ3iI4L5b*`?g~kCeiDr~FZ$#@| z@DI<}R@sQ>Ka8w*ffsPctzOpZI6ZCr!^dm$AR~!ZLrcGX z9o5&22Ic%KFeWONf`~2OwFl6bS6k4LerUSZ(;<0jg-Q!X_4qc5AazhW%th22FMT|y zp{6iI2z)7!Y-FT}yWqhC&e#nDB|~$jsUi zPyiy0t;7XO)fR*S+L4z9V1nWzy>yy`$k)%NnghEpM3{EQzGNXT6^&#FDa{Sc=~_ar zaOY02-eV^`!%;^&t>KT%73rV2lOT-;Nz0Pd<6_1V5&Sn#%udC9Y~s;n4X(qYK67ww zxU<1R=xGhlsDY`y^83hD^r!drxSmH9}2D^evFHPisU4xb8qSz@j6d zQHbZ(O^72DE#t~@r#A&I zixXY!-cv2LrMQeTLr^9=H3OqG;ipfVJZVj0Gx_4D9>>*}?>$vICUCiSDunf<&N^tB?3c z&laRy%!8~7EC&)QRd$%@fK@e}nc-i(x&fE*C2F_Bo{4BXVOa5G0?TpOjx-raN3)M> zGK;z8GGNvZ6Yav)sG;7tsKsA=wvZm>|Mskp9_Q1aTR>0pRnIM<=lEWHzQ_+hS4l7P z?>)DIUge)Yw+t4$rQcf%gHz;t8|h>I==a)`9ECfcU#(11_~z$plvN7<{PR`H8ihal z{5+*m;cq=(s%%sEr_Wa_euXc4p<2-qYVbmZ5>ogrFO(_03V-s2a%G>wfAzv5WsQxy zUMxj?`N|jDQi$GGDp`|#)V)g;5*G+KLu!B>q5pL@Bmq<+e8VLJa~o`AMtO_;0fDtT z8xjOy)yMt{1>%iRFVZfI%>dtQV}qibFuMX@ISRWhFVh{L{7*uEtNEvS%K0|F`=91u zSgT*HDH=KRsan_{k)($hEuX3wBi=U;o3ZimcvIWq-R2jmUn9Fu-;!FZPa&-}%Eb<*@9P|Ne)| zl|y;l`&xNPuMJ_*dMxdZ0A0l6wYWk78uO7n9(k?oY|V^@AlCqHt<|k3b{r^D?T2yc z$9)24gEn?7PjzgF4v19e%WP1_@qrMDJpRMi$_36od#y-(&3^p?YfjPm%;Q$)4`y}V zXct#%EpT~j&XWi7Uh9$+4DzV46D8y`E?Yr`^nzimpej7Qu!5TC1EXLit)Af%CON^Q z%!_WAs@`bqS&3T=e8z#5R75WsM_1Cad|w5E`GQu62Fq0s8b4V{^Je;LTcgote?&N+ z#5GxQmZv_p#n=s8M!T$`NaY}Ze!=4VgVLEZY{u*Sqq?_qCtVfq!t86XBbqQ-8fi7>*;ml2Q@US zc-*Blp3FruPaC*YZ5usjw63B>vwBb7&%9|3SsjGz2F}XG^s@2cDr&1r8v$9;o*m?* zWyd&4_qZk_oc7s`_-Z=qoHw9oTK*wiHZC0PKoA`5c6P1&VMn}*K-s%Cc7WF6-FWUS>ZW|dS4&<67hdeDrLq~< z3s4{1*kK9#W+yvhH*Tz@&lijjD`&UMqC#Wc8d^W&KH0!=lpPZga&T_i#Vx$Ut!wFn zJS{X?jM=WTeUm3-A!1LDMqck^Sr3Zp>zh{TM-ve>jf^U?i!#7s0K!n_@ zIYz7rXed>UqfNL~#SA>3tCXw8J54lGdD&rnznKb+{AQ|DUbP-}H`8L}4eR0VW{mDF z`EZuycvT=7iX|RTjzA%Y>?2t)m#))>CUG$;@6Y^B4E7Vo$8nr=fRGZapY8#yO4r5UV zHI&zpbb8{xj1e5r64fQI(5LfZie}Zo*a?SmYX{ZZitEUDw}UnsA9c_qI$$jHi)(O< zZ~5sSrSgC%(u~h_(pgk(40qC_nRhn?Xd%@b-wIHpvduP(+tCk_t+LHFe4|bmD9Rq2 z@xfk-(NUwl8~3stHD2qc14@IOay%qj9eU%Z?uUN(gI$X8uRXLWUljlTFRnMfzP;~!v2SM@%fhsb$_zbBAG)u_ zE6qAt;xOG>|0Y7Qad9u5GihD=7E+_Hmr7bEfwEwaNXWa&lkld?dqk0j9Z!hV0_YT3 zSCOW#FElS9K+2ia1boHTVS|gs6uX-wWt>e1hSdlyv(XXb%zaqp`;2GzkuT+vhlQ;9 zF#h2JHLS@OxYjLm5eEYKM9O#ES8SaSBekzV7^OHzgrb96yC!NxjYJ1sn;Z6vC}BwJ z{;=gVcCKSTpJMdIXsS&E^`>HUW~yyRtG2#D+qAs_7c6eqS~u5i(JpA%zO@v$9f{Pw z!Dv!jgz!$>J+MgLqbCeC<_&q5=rLS*Dk=nU)sY?%E+v^^*M%D~!9cVQNTl$)Ak{-u zZO4UwLVxq)LThn-gVZom2_L3E04X_Uf(k~F#wTv|1KgOnR#%IK;ytU)CIjLEKq!R~ z+~KDoH&6r_Y4y<^uoDE3jp7qSj$ky%jT6I?7KL6Beub+}0ajcDDHm57W3PAOmwyK!%u}k9~xA%tQh< z4RNK;YK%+HA+Co->QI-zUo;j*ieB8SDX@r1h9}9p3z05ZYCIC7pX7`9D@hIxc@?-? zXl#Lavc6ji9MYyBaV?fsuKftj2y;UOcXL5G^LYWqq8tm3U&7gdAO~Dl6%@9fu52UwPefI)`r#Ej=GHvNaX|tYgzf4!X|?& zA|*ix!%(+zBuVdpRt1B7SaKWJrWbsu4JQ69atPNr}8`t$ylwLIc+)tf3&4i$PqjP{(pZi~$g3o(i z`Z~Bc_Gpg%E}ZKQ-pHxGa1i;(x|gz=NBX@k;c zGv;4I-$(sF86RIm*VEfZ>ROynpBevtEv?LX7rLW)*bO&-iCRdRqz>PC9ZrPl8^m>f zt=%y_E{GRd5M*3;1O2DEkLdp4>%U9~?aEZuD7ux()O@v2HR^B0rCC=Hy*M1Zm4ZsD zM4iL-sH$i42H}xKoaP1CWWwg7$EwuCI{9`7a)&JA*b3EABj2^|x8AH$9hLHp74E-A ztu$*iBNqs(mKbbME4^vx0liU8RLCcJvf2{Os&Nd0L-95>vAG2))8<0!!pI*_#M@NF HXtVzdNlC}) delta 18821 zcmch93wTu3wf|n{Ovpe6oJax_GJzAAKmwC6i2*_knDEd96B0-WpkOkYIZ38WW`=nX zVx{p>TWtlwEj`dHE!=8b+ghb5johpEQ>$&gMGLL=N?Y4{|FwVLt!=%vE$IKZ&p9)h z2?4$Le&3%@=bW=2Yp=cb+UvE~&dZ<6-Zwfadq9nQFMCBkkiE{HXRV8PgF!Xk)#D9% zL%svrs&e;0Am;1pjfQVjLw0hm(koO(rM;?pLGghPub@1B1$7nWk-Nd?3nxPHHQuAQZ_q`S z4o2>9M2&jmfp92U;u`RV{N8vtI;6K?Zr&*^$n`KLF;>r*Y+>SG9p5J{9j>M|tHYs~ z8j2-iYeRj3klN&D%tOvj)mN9OS;>H3s)3b#WOEC%x2xXZ$7q?w@>=7Q`qij~d3ck& zFuMi_*05@zRmcy@_WU}k6G*HH^r^9UQ(PTb$=DV_1PA}ATtnN8*Ljv1)M31Cv^Xwz zkz=zO=J2yZ%dPK`n_DMeGkG^-7OTz1ZsJ=eyDC48FUD@RI5w)WL@;i( zbWp^ymb%GmZQWsE5wYYpz_hS##)z>ve`xYE)X(?j%%vbdo-=(iIih;kIRDO+`t%xJ zmg7(RzAf#2I^SVyp*#3VTP3i1(^i9D*VJ14c1`7U*T|ozK2CHmKYm#w?dK0~aPX7Q zPovV2V*BkxHvaBoGx+1V)2EPvk=5uf)j#r7?jX^pM{1{^BVJsvgAR@CE$AisI=|zF z*+o5pU{FlchFx++6=U~f=j>n`I=`&(N492gZ!gdb2I50qeNo^a@!GtRh@&mh6AbtSr5>R= z)nBz_N#*j|+GOd|f^WX-WKUqfJ<1;Azngy*JvQQ6kVW(oUszg3FYu1i%EG6qE*2fv z^)(RO&i=@cmTsDUYE162w*cxi`yIEIEqA4rlPx?LO8<6* zQdHhf^xDYIied@;#yx)gzVF#Xf8@I=-{SXbS02uyf|1X!nJrNf|Hjn|aulU48jgfxs^7wMmlThjzdBbI6q#Cv zu5un2jjk2Ls4k$ed#Gb50=?+umZxr* z!WuAomW3@RzWb>ffH?ltXQ`Yo|NeZc zN^6P#_L*POa=z#2Z2pTM97(-ZT2pKFlOHBh#U9Ro^aZJfMixD5m!%Cfvf@;)ByA%8 z!1GHm(l4KH#INfoTkyN*C%f?bm!DjN-@4P!%iFPwANgqsuR60{@)H00na@jGi9h_) znyZ~P?crcTDBE@j1=VjQr!PDZNyOC_qPn#~)hFs!8%2yfk*K<>OZ^0j)8vqYum9QN z;T6=>t6)1QF%zN^h$*o^Ur6=4QI3xR)fw#vJZIg-SCBROy z{0LwdDajdqG-Q5YU070y&v>aN*GUTYeY+2<#mE{DJ9+#i6%6@{mmZb|h=2ZUqqLLw zt!G?PfcPhWu?Q^iwO>2{z0>kbXBKVepZM*0^77d~E4Zv0NXON#c(|`G2#ZUU<+xG` z!aMTqSH42L=T%3}5ZGL@u>{$gwO3kcy3=78ka=rCgt$c*Z4Lz!7kbCf=~D$`41D~l z>HL*f4^MLH+Mj#o&az6@wbULSQ2D;!J2onV{ehsW36mL|8 zA{_`rk1C*Xzv|VWUXM>$csmnn$fs6RH-+MA6iUOeFJ%6?-?vQ<5LF9XYi-oq6!NRP zS27EK`}aLLEX%&FLFp0Z2p{~vPe2$?eRB@q{Mu!+_L99hwc{hvz(635C5~BlRq>l& za}-acJPv~_a=k8l4iZ24+MLoMGG))wYRH}g7X^9G>xHxS5H+Uskzhq{Jb@);M+}@g zUY|M7P4-41-`VY;{6&!4_qwCX&0OS+c%$B~fPW{E6&5dfqH54P)P+(kk((@yj1*ru z7!B0+hyk50SncR-pg}IN6Ld6hAz@}4(8h2lmyU#3 zr&OP|U51eWDbnQ&`&E4$7)y_b?l))3d&thO`oPJbd2_L}m$>uoqB#e!rj3}9 z;o%%4g8L9vb*^IUF!8FlIzDdGr{C%{o7%@iZ_(;*)BzSAil zZ@sfoJnH|jPCV}V!w%_o;0GQbkk9uJT z=9$KLKd<{!XW^O_7}$a4uuu28u1>%xwXlA@aO5k0sv)b>@Z$3Mzx`!K`3%-*cqGkY zlWbJIzJ5qf=1e&%GZ`GnXf&WknS;}NGo}_Wb|QrVU;bWE<5*)jjZGn;a^R4v)-)(s zNlK#0j2BB<8C<{PCb|CQy%(hii68i{kZsIcVlJNZ*F7N4J^v`+U-@fjF*b&y4SPhm zgBEhNK-GBrbm!1Xb*;P9=%DUqnG5S0segYe;rIW(cv|}S0xK<}62>aNhaUVvW-C*q1f zp(^pP5`eqj+Z*r+;wca!a4Z9G8X+_);@#V>7h**Tz>M%Eu@hkWw{7n}=%GScwx8oa z`OtBqm$s7hB56+&UFoouZdCgMG3W-}s?jBr5RY1(L|1|@v<(u?7SEj$tOIy0(ph0E z7HHSXbekxD(n@nj|0L7nB)v?d$FpdfY!?4PJg3-D{laAWJV~#R=FK6YceQWk&~~$S zhxshl4%z5x@$p+5-6x)(no8G*=MSe+O;uq;9_`&} zbd{*Dx{SU&>pke9Nj7$#>`pjP!Z2|52rEYQYxkAWqS+pD2wm8LaKqn{+t8zYA`#MU zJMC9x4czk5Yt#^QWAIvaC^_|c+JCue_M%rIUy?+!3l@GIibE8%;hk9- zdwUG!tIDZ#_-)j$GZz5?4C|IEE83)$WqwI$afL0j>{4Gc+E?2z-eNc;P`c=F7Ia^d zcc~U1zb*@~mO93@&z%3b%1a=Y*>Vy2$xGzAQMbB2C7jq%l=niRjIYV z6d3T$>tlR#a52>sybBgi_C-9eIJw^{wcjtMV(C57CVQx8UYb!vjFm%Q$^eFcWn&#y zdZ=<$lDUaF8lq9}P_+e7QK#-g!-|#6(i#f{j9FZ>oyp9pH?CZ2VfSmtJ>+(z4LAwj z_}D0q&7_iL$x*OD*M~!hMfL@Hf~tj)MAZ%O`r=K(e}F+RVtGYloi|icQT5+2ve5{8 z*4CQ{Wg$XhzzB$75n~0IpEOxw`C~l;4k{d;Dj7jn-I&oqKngBLV?-JsAhtxZI9ek@ z&%leJe2J`fUc*O>$C$)F5e1PO6-dMnBdvHjTeKsdh@!*!RjJa+X+a z4f@D=c(nFf$r|uqK%;VPxQOy|*xIqa9~9BT<>QgWTsH@TkmQvT)rhyT8HlymkVLmi z^UkLE4QBWrHMyx8w^+PrLf0o2_eLWCy&6GBMv>~x2o?LI-a(y6ppo|UY$~H%?VZ`Q z5RZa6H0LTCDRAeaLvUaea&8c>LOhEws!r@8iP8vPI^f;iWteLQHrkOnGz+jEodZ>d z4e;|h%!;ADWg81lwa49%s&YAe}A zkY!@roG`Uj)Q($Y?dNmJMN71Q%%vj7MOWH0j}{D14EK_FN#xw(8>lNSTgh^nM`zN; zaL|vag?(c7y%;o*y;+cBVjM29fR{7Rs>IOR-KtLy*?~kjpNmb_KAcBRTCO==R9%hW zalJq@Z5OU&`OMv}#v39L@LXWG1xh2Mk+#dF@5N&-n(4fdZVqPehpsX_p+kl5suP_O}uOkn`8vO%J_FhJ5Y}EXBMRwGA_DLda5!8OFJy3JOpwcGIlR zamJx(I2wMj%sl2XD9pktPrB8a0a>>wDJ?v0(GIxDu`r8yOtVt=J}oS%EGJE9Zw_ZO zS8FIZv>Kr^KP*dETQC8W6rx5~1eZ2MCo`s|2v;*89RDsHE9t)0c){pODmd$wN(*$7 zX)NlNlWDM~3UzBL;JH~4r@4R{f(nQ=0K*w`o9_IBI68a4wU%?8`GQOFSo&8x|S&&(=dom zCe19}jv;K!U@&PD!sM*MXPT7=YqJ?84LvY2yuSEwvZY1XJ!xhW&Z5(rr2#-(Uq3rf zYn!EmL?(bQiojC_#0@Y>b!1Z}!XzDVvhnZ)kT2|$&FYf~C!y=xGYtpm%>j`-k=*W9 z;AGA*Z3ydl8NH5H7$xSaB7Vx&H(r8flp*XwBOY&U}WRZEt# ziDtH4(z;jBjTS2^wO_BGInd>reI+$7^>4dg5!SQF9e{*$3&R|$L)o@{TYDlB35&C@ zP8@`zZgsym)F+~eCJgP}l{8xX5tDd;v}doPr(~~0+Ttp5NXQQQdOdxs!tf1atAkz< zGPJReMt>&RwV91{lA5(MjZ~a-)X_eKDBysF`L*+nR8G6KMNQxf%(%N?mS$f^MRZiFScj^wYunc$eDy8uwso+5p3uH7zJ8}Yzm6*DFB)A- zi{V5+tVnKkfNZfd5IDGq&d z@E(h__7<8?#oCQ67`8-vP<)kXr(1yZ672)=SfRPs1NR1P`+8b}Y#5}XTy-j6`{sJM zKTX;X*3(MMCZf~)_)lG$yOrk9R;{^}Hd$1n`}p3oGquNB5h55M?KiDdBOM{Fpp7b} zW27~=(Ol^v(jslBKS3IAqiX3HtcrL(OWKERXhc zbj^^*&on!)DxIg)86Z|FSIbbs2vE` z){1<=+S;h$>38AuL~Q+TahmJv$GLyCqNuy!Y{cNBl~sINz>nel4oE74NF7rF4$yr9 z`09CO-DMT^qKRM6j6-gKI#5w63Um&sXrT^X)HZ8aA`72 zpAnozu9Kc`fcC&_=+P7^70PBHpf6EWMHYhI3Mb26r5BMLMPIXubOLWn5~6D`z~%MR zFH57Q#Z`abQ9YPj^2KWfICKE{kMJ(osfE=n4+xW!z|RRE_5D#!N1 z)Dc=3ehZSh66#8%v-GzkBO`|Bm%>l4FPU~gBE@WiF(SS=?j}EUt7>l^T?%L+fD^-h({U0xw_5z z*&OU1q=N27#zNd1JUl^dD(!B9N_JS%6Hb>OksyuCjMF2KKI2kO&7!fKQ=@<#H1J#8 zLCzUt>f1m_C$>xTc2J&lOwtBBAS55uhwGLe5dF%;=b}wiAUz~$S8t+{tIR!0dHQ}Z zzu4otz&cMhc2Y>H6B0WiS!}DrgCabMBAl+FoE?|6Zvf~Vh`;Jgkw>loj#9fqkZrd} z+MhPjb<*RKw!V|=c~OMr%lwVD24s7>H_V>(tVBs4);IwrX4~i; z6sfHK4ON%tXLzj$(8@@DESc_5V33Dmy=oMp2w@*QC-Dv2X4_98U$nM1nMI5o)#8oI za`jF7^=KvFtHJPKMI{hu zLLdIv&f;N3WKQbq5(6wFy96>tl!n59D~8-%qv&r5W8ezbxN!`&0lJp8kRs%^NJd63 zg%GTRW-zo{2s3YR5IMZM&XgXxHh)ix3 z$yH&+Yh+}biB>qw1=4YdW1NLzvY?MC0)5^@Og*LGUpE%3HMCwGG@=;8@!DEsYlPIn zE)!O_fZL;*m{x4p5!fg)bHv~{#!K||3!3^t|7dssluBZel(vDsJ}j0PXiXx9qycpG z2K8YQArpCjw+VQ2ich+BsA{AOp^aTCbPJC0#H5gr1@2ZrI*}BVYTIq70G(OZ z-4LFFPu8qbQkm=qUjp~J0~z{7m&xY*Aw>uK!`MN$v=W%((Vo+uA9u-?lJ`#z1X`^k#rCos>n~K4PuJm z9&A$VV0&_|$vN>SHWt^r&zTtLa^9G;IX@6w3|-otZr0V-8VntWH|tZo%XoLk;#oD= z0X}5CncD}dAQn!bL?^r>J57wu&m^?uXrZ;c5q}V(AdT_(_Dwaz$^h80M@9ZUazJ_m z$OKH2Zm`^ycEPjgmK@jM)-*O1Tr?(l088JW2EXeFCOK6w9d`6h3c$r6B>kX&o!FgN zDzO?!my06xD}&FPlf$O%s0@)^nmJb)b4_6knAfMa8K2QvU6|TLb>lV>dz7o4^JaE$ z2QqNFy#5OIL|Wg`&RWT!Gtb$aGbNeGZdo&;Y|fLjf21g4!}CYB=JD3+rVb11#k6#n zi@gW)w*p7zkYmBX4zQiMga#=E{e(0UB!FOxE*PV=7w0xfMuLSNjm0ZGiZU-{M%NiE zkqDVwXEk;riLL11cU|Y@ZTB}z8}Gep~_&nX0g)L-8nb@zkiHeUYu;F}H7PugLlkUcr#6z9{jBLvtmzX5>(J3E9&4 z^E4mcsqnYFFVAVbPzI)(!~EGE=j9iGuN(Pm&qI`90)J{}Eq}{zb*6WAK+*$an4S>* z3H8*7MJ<$&-K_M@wF%CJJ?=w>t()K2?{p|3RrSB0u62xs8#&ZhfyCsIANDUGN7@v! zNaQF(Eki*n{CwcX+37b5atjm%|Ig@pz7vtZK&EZ?3C0C|#LdHC{n4`nFF>a~=H~6d>aQ8>&Pf5a^qVOl8 zw`P#3Ew;dx(S9&CXBzgexR>LD-N|wket&H5_&!DHeX0!s6AE{Uyjo_f8yQ4aZAO>l zi8+hcq^NbZ&{0TUo(Kpm0YG6>>qlNm1TO$m1W#I@v@#J4e&gU==@n_@OM_pKD8QH8 zxP%_zJ8mq7^C zzmX!BRXlM|#FcJ8SGdPGth|8M3*{vw^!mg=4@?jkD%dAT1WXx7$*l?_pfnKj1rsTu zZtmf5w9IL;DxB<%>Yz93hwqSzO)BlfdLFviLhH+(n6Swh-zuf6p*Te5d705cx7pXX zcC4*6gEuh3VKM8f)=)2)bP{J#GvM{>DU7<6s;93H_oq~KX}gX~S;Z!p%-Ep1xh!rD zcoE5fz8{m_f-taDy~3w4bYA&jAg1bGzCSE3O88;ghlXJK7=||P9jO^Q9#JGizB)_+ zJ5CKucX4G;B!lU`v}a2b_P4nDAwn}aFGc7!R;z#!Fd)be+ThNEX#lzrbAj!HxQ$U9 zh-ZvH@?U!nN|31|dvBg9Nv}%$zFW(U$1MKpt$EVx6931oB_*%JX9fM?nzcsikO&C< zRHsYVu6RH6Z$D1d-r3}9lnzS#-|xT4az>&P{M7y1 z_*Wm8V|h=aWk!zF3R&2<=A8V19pMJ2w=SAJ0&x$U0Kmh|-= zdF>1TEDe7Y;u%`!u`#U!zR(Y9a0wvEF>d90F&VI|X=rbM!f3Bcpou$FjO+0cRNTB^5n*T~8*eofAp>7S2OO2c}kNmX9Y+ z`fAr98USI71RG<~?GrD0evV5dOGmKfD#EQ|C!Ly_L#K zC(Go7T@*uF9`Vj@@EC&sj-wAF{KUxe zwAQeVDz(@)96P02YlvN#w zj1PDQfXvS7L+rP+m$NnUBS-Z%9|iI+yg0{R(d(}teqHZiJH%cU5cbII?QCm} z`IjV+i?Bo3He>AUsW#ZTA*5gG$lz*6=M_4CBe%G-T7Q%AwnTrk;BBe?mW8)v`r9PD z)fm;;cwMd+;;v9+>jsL>!-J}os~#^!gXU@*PVQU zWDt8ce}Z*hGFf{zNSnYRa|URGbU@ak1GGR|F&PHKtkDw#big7F$y#HS<}?n0!S$?Z z{qo<-SQxnh)5aySNw(z0j6Bunk9l2VSLU#U$K+(cCAc(raFX_L6w7r)*3L$87Q2VE zbAUeU0h#Lc&ba%TyoD#i27w%{;dZRv`WShn0rTTyB&u9ojF#%ub@!-4L+ui z4+yZmIk<_fXjPw~S%oT=!Qy&IJ}#e-Ps&fq&&bcp&&g+G=FQRiK0|BEo|E)rS2{0^ zk%bU_syb0 z(H^~nt|X84mpkZ0s_e&i(gLd2{(L7jNkh`;%FoeVB)j)WqtAUFCnVDCl2*2lqI5{R zZy&|*u-{ELO9PU2&)rBBJ%~eQhi6p~e|*8P+F}n#cT#rE@VB=S%VEm82hWhi>gm?E z+wvIY9KH9)2e#1jr{2OlJM`C;+fn&PVP+=lowLuKLVX>fKGm7B*&Q1{5tmq-(GF9# zoL0o3+NS-uu=Eg+*-sBkIQm(AfNr?zN$DXO_co0y>iB~$@Un->liz~tZosjc_*eg% zPyD$5aCY}US@5y!|7hoKI`H1_a2M$S6>8b{kWwHHl$zdnxUl1Mwnu;^JMiLf9FP1I z_sF&Sd+3^6QT^u+^IrVs#>iIjZr2XoLsif!KfZ_Fc07Y3#neYJ+;=h0A@a1-oYvW$ zrXnG-NY*^kSFV2ag?p(=#!+APA*@2NcJCpo=&dn*5HpE{SPA~Bi|wYQp()OB#R+pV zwrq%<3U(A1h2c2iKZIPwA;qq$3J-#N@V5~`8pQwl?Vnf$&b{akn^txh^3n2ww&5@> z)9n95zmkw(@tynV=R!Pw?g+g}7H!v;z+LZriGG_~-4YO2-*MJ0#wNC3YdK0`Bw;*$ zlzOsWlq}4mxsFk-cJDE=XWfU?H;eY*F>2SU{+a%owH7m|AFcQby)2J5e2oqhwT%Aq z>-2MyH^?uIe)k*5*U{fjeG@4bc)M>@{x<%I3VBDhhmqkRsj~L`Bea zVR<$?D_dNRtHmh~ysYcgXt-URBSs&RBlUV|J7V%CUmcfi7!oZzcAF(9WSd7X5gE9# zKs1mSp6nmSiSR)@QV5ESa3oXvdhc zc^#t?BV)(pi%iB+QyCc;*fbbS7#NsX7-j-F%pzc?PGp=c$GnTlmT~eeW+mRAAPEPs z#8<}2oGdy_noN_;S#)?0G65wV!4g+lCl|12FP$BwOl~$MriVP6_1QKEFx>?SxpU?MEn{O~c*--`P~3&-B}Cl>aW#$) zK=B5Kw>*>giTg5r`qxGMFZEPyQis0su0LSK0so diff --git a/scripts/artifacts.sh b/scripts/artifacts.sh new file mode 100755 index 0000000000..509f6e425f --- /dev/null +++ b/scripts/artifacts.sh @@ -0,0 +1,21 @@ +# # Generates the 3 metadata files in `/artifacts` and the polkadot.rs file for integration tests +# +# This script is to be run from the root of the repository: `scripts/artifacts.sh` +# +# It expects a local polkadot node to be running a JSON-RPC HTTP server at 127.0.0.1:9933 +# A local polkadot node can be run via: +# ``` +# git clone https://github.com/paritytech/polkadot.git +# cd polkadot +# cargo build --release +# ./target/release/polkadot --dev --tmp +# ``` + +# get the full metadata +cargo run --bin subxt metadata > artifacts/polkadot_metadata_full.scale +# use it to generate polkadot.rs +cargo run --bin subxt codegen --file artifacts/polkadot_metadata_full.scale | rustfmt > testing/integration-tests/src/codegen/polkadot.rs +# generate a metadata file that only contains the pallets Balances, Staking, System and Multisig +cargo run --bin subxt metadata --file artifacts/polkadot_metadata_full.scale --pallets "Balances,Staking,System,Multisig" > artifacts/polkadot_metadata_small.scale +# generate a metadata file that only contains no pallets +cargo run --bin subxt metadata --file artifacts/polkadot_metadata_full.scale --pallets "" > artifacts/polkadot_metadata_tiny.scale \ No newline at end of file diff --git a/testing/integration-tests/src/codegen/polkadot.rs b/testing/integration-tests/src/codegen/polkadot.rs index 4a8bb5020f..0063171055 100644 --- a/testing/integration-tests/src/codegen/polkadot.rs +++ b/testing/integration-tests/src/codegen/polkadot.rs @@ -5,7 +5,7 @@ pub mod api { mod root_mod { pub use super::*; } - pub static PALLETS: [&str; 53usize] = [ + pub static PALLETS: [&str; 57usize] = [ "System", "Scheduler", "Preimage", @@ -28,6 +28,9 @@ pub mod api { "PhragmenElection", "TechnicalMembership", "Treasury", + "ConvictionVoting", + "Referenda", + "Whitelist", "Claims", "Vesting", "Utility", @@ -54,6 +57,7 @@ pub mod api { "Hrmp", "ParaSessionInfo", "ParasDisputes", + "ParasSlashing", "Registrar", "Slots", "Auctions", @@ -107,6 +111,12 @@ pub mod api { TechnicalMembership(technical_membership::Event), #[codec(index = 19)] Treasury(treasury::Event), + #[codec(index = 20)] + ConvictionVoting(conviction_voting::Event), + #[codec(index = 21)] + Referenda(referenda::Event), + #[codec(index = 23)] + Whitelist(whitelist::Event), #[codec(index = 24)] Claims(claims::Event), #[codec(index = 25)] @@ -289,6 +299,29 @@ pub mod api { metadata, )?)); } + if pallet_name == "ConvictionVoting" { + return Ok(Event::ConvictionVoting( + conviction_voting::Event::decode_with_metadata( + &mut &*pallet_bytes, + pallet_ty, + metadata, + )?, + )); + } + if pallet_name == "Referenda" { + return Ok(Event::Referenda(referenda::Event::decode_with_metadata( + &mut &*pallet_bytes, + pallet_ty, + metadata, + )?)); + } + if pallet_name == "Whitelist" { + return Ok(Event::Whitelist(whitelist::Event::decode_with_metadata( + &mut &*pallet_bytes, + pallet_ty, + metadata, + )?)); + } if pallet_name == "Claims" { return Ok(Event::Claims(claims::Event::decode_with_metadata( &mut &*pallet_bytes, @@ -492,8 +525,6 @@ pub mod api { Indices(indices::Error), #[codec(index = 5)] Balances(balances::Error), - #[codec(index = 6)] - Authorship(authorship::Error), #[codec(index = 7)] Staking(staking::Error), #[codec(index = 9)] @@ -514,6 +545,12 @@ pub mod api { TechnicalMembership(technical_membership::Error), #[codec(index = 19)] Treasury(treasury::Error), + #[codec(index = 20)] + ConvictionVoting(conviction_voting::Error), + #[codec(index = 21)] + Referenda(referenda::Error), + #[codec(index = 23)] + Whitelist(whitelist::Error), #[codec(index = 24)] Claims(claims::Error), #[codec(index = 25)] @@ -554,6 +591,8 @@ pub mod api { Hrmp(hrmp::Error), #[codec(index = 62)] ParasDisputes(paras_disputes::Error), + #[codec(index = 63)] + ParasSlashing(paras_slashing::Error), #[codec(index = 70)] Registrar(registrar::Error), #[codec(index = 71)] @@ -574,198 +613,213 @@ pub mod api { use subxt::metadata::DecodeWithMetadata; let cursor = &mut &pallet_bytes[..]; if pallet_name == "System" { - let variant_error = system::Error::decode_with_metadata(cursor, 176u32, metadata)?; + let variant_error = system::Error::decode_with_metadata(cursor, 491u32, metadata)?; return Ok(Error::System(variant_error)); } if pallet_name == "Scheduler" { let variant_error = - scheduler::Error::decode_with_metadata(cursor, 450u32, metadata)?; + scheduler::Error::decode_with_metadata(cursor, 496u32, metadata)?; return Ok(Error::Scheduler(variant_error)); } if pallet_name == "Preimage" { let variant_error = - preimage::Error::decode_with_metadata(cursor, 455u32, metadata)?; + preimage::Error::decode_with_metadata(cursor, 501u32, metadata)?; return Ok(Error::Preimage(variant_error)); } if pallet_name == "Babe" { - let variant_error = babe::Error::decode_with_metadata(cursor, 467u32, metadata)?; + let variant_error = babe::Error::decode_with_metadata(cursor, 517u32, metadata)?; return Ok(Error::Babe(variant_error)); } if pallet_name == "Indices" { - let variant_error = indices::Error::decode_with_metadata(cursor, 469u32, metadata)?; + let variant_error = indices::Error::decode_with_metadata(cursor, 519u32, metadata)?; return Ok(Error::Indices(variant_error)); } if pallet_name == "Balances" { let variant_error = - balances::Error::decode_with_metadata(cursor, 478u32, metadata)?; + balances::Error::decode_with_metadata(cursor, 530u32, metadata)?; return Ok(Error::Balances(variant_error)); } - if pallet_name == "Authorship" { - let variant_error = - authorship::Error::decode_with_metadata(cursor, 484u32, metadata)?; - return Ok(Error::Authorship(variant_error)); - } if pallet_name == "Staking" { - let variant_error = staking::Error::decode_with_metadata(cursor, 508u32, metadata)?; + let variant_error = staking::Error::decode_with_metadata(cursor, 554u32, metadata)?; return Ok(Error::Staking(variant_error)); } if pallet_name == "Session" { - let variant_error = session::Error::decode_with_metadata(cursor, 515u32, metadata)?; + let variant_error = session::Error::decode_with_metadata(cursor, 561u32, metadata)?; return Ok(Error::Session(variant_error)); } if pallet_name == "Grandpa" { - let variant_error = grandpa::Error::decode_with_metadata(cursor, 519u32, metadata)?; + let variant_error = grandpa::Error::decode_with_metadata(cursor, 565u32, metadata)?; return Ok(Error::Grandpa(variant_error)); } if pallet_name == "ImOnline" { let variant_error = - im_online::Error::decode_with_metadata(cursor, 527u32, metadata)?; + im_online::Error::decode_with_metadata(cursor, 573u32, metadata)?; return Ok(Error::ImOnline(variant_error)); } if pallet_name == "Democracy" { let variant_error = - democracy::Error::decode_with_metadata(cursor, 544u32, metadata)?; + democracy::Error::decode_with_metadata(cursor, 590u32, metadata)?; return Ok(Error::Democracy(variant_error)); } if pallet_name == "Council" { - let variant_error = council::Error::decode_with_metadata(cursor, 547u32, metadata)?; + let variant_error = council::Error::decode_with_metadata(cursor, 593u32, metadata)?; return Ok(Error::Council(variant_error)); } if pallet_name == "TechnicalCommittee" { let variant_error = - technical_committee::Error::decode_with_metadata(cursor, 549u32, metadata)?; + technical_committee::Error::decode_with_metadata(cursor, 595u32, metadata)?; return Ok(Error::TechnicalCommittee(variant_error)); } if pallet_name == "PhragmenElection" { let variant_error = - phragmen_election::Error::decode_with_metadata(cursor, 553u32, metadata)?; + phragmen_election::Error::decode_with_metadata(cursor, 599u32, metadata)?; return Ok(Error::PhragmenElection(variant_error)); } if pallet_name == "TechnicalMembership" { let variant_error = - technical_membership::Error::decode_with_metadata(cursor, 555u32, metadata)?; + technical_membership::Error::decode_with_metadata(cursor, 601u32, metadata)?; return Ok(Error::TechnicalMembership(variant_error)); } if pallet_name == "Treasury" { let variant_error = - treasury::Error::decode_with_metadata(cursor, 561u32, metadata)?; + treasury::Error::decode_with_metadata(cursor, 607u32, metadata)?; return Ok(Error::Treasury(variant_error)); } + if pallet_name == "ConvictionVoting" { + let variant_error = + conviction_voting::Error::decode_with_metadata(cursor, 620u32, metadata)?; + return Ok(Error::ConvictionVoting(variant_error)); + } + if pallet_name == "Referenda" { + let variant_error = + referenda::Error::decode_with_metadata(cursor, 638u32, metadata)?; + return Ok(Error::Referenda(variant_error)); + } + if pallet_name == "Whitelist" { + let variant_error = + whitelist::Error::decode_with_metadata(cursor, 639u32, metadata)?; + return Ok(Error::Whitelist(variant_error)); + } if pallet_name == "Claims" { - let variant_error = claims::Error::decode_with_metadata(cursor, 562u32, metadata)?; + let variant_error = claims::Error::decode_with_metadata(cursor, 640u32, metadata)?; return Ok(Error::Claims(variant_error)); } if pallet_name == "Vesting" { - let variant_error = vesting::Error::decode_with_metadata(cursor, 566u32, metadata)?; + let variant_error = vesting::Error::decode_with_metadata(cursor, 644u32, metadata)?; return Ok(Error::Vesting(variant_error)); } if pallet_name == "Utility" { - let variant_error = utility::Error::decode_with_metadata(cursor, 567u32, metadata)?; + let variant_error = utility::Error::decode_with_metadata(cursor, 645u32, metadata)?; return Ok(Error::Utility(variant_error)); } if pallet_name == "Identity" { let variant_error = - identity::Error::decode_with_metadata(cursor, 578u32, metadata)?; + identity::Error::decode_with_metadata(cursor, 656u32, metadata)?; return Ok(Error::Identity(variant_error)); } if pallet_name == "Proxy" { - let variant_error = proxy::Error::decode_with_metadata(cursor, 587u32, metadata)?; + let variant_error = proxy::Error::decode_with_metadata(cursor, 665u32, metadata)?; return Ok(Error::Proxy(variant_error)); } if pallet_name == "Multisig" { let variant_error = - multisig::Error::decode_with_metadata(cursor, 591u32, metadata)?; + multisig::Error::decode_with_metadata(cursor, 669u32, metadata)?; return Ok(Error::Multisig(variant_error)); } if pallet_name == "Bounties" { let variant_error = - bounties::Error::decode_with_metadata(cursor, 595u32, metadata)?; + bounties::Error::decode_with_metadata(cursor, 673u32, metadata)?; return Ok(Error::Bounties(variant_error)); } if pallet_name == "ChildBounties" { let variant_error = - child_bounties::Error::decode_with_metadata(cursor, 598u32, metadata)?; + child_bounties::Error::decode_with_metadata(cursor, 676u32, metadata)?; return Ok(Error::ChildBounties(variant_error)); } if pallet_name == "Tips" { - let variant_error = tips::Error::decode_with_metadata(cursor, 600u32, metadata)?; + let variant_error = tips::Error::decode_with_metadata(cursor, 678u32, metadata)?; return Ok(Error::Tips(variant_error)); } if pallet_name == "ElectionProviderMultiPhase" { let variant_error = election_provider_multi_phase::Error::decode_with_metadata( - cursor, 612u32, metadata, + cursor, 688u32, metadata, )?; return Ok(Error::ElectionProviderMultiPhase(variant_error)); } if pallet_name == "VoterList" { let variant_error = - voter_list::Error::decode_with_metadata(cursor, 616u32, metadata)?; + voter_list::Error::decode_with_metadata(cursor, 692u32, metadata)?; return Ok(Error::VoterList(variant_error)); } if pallet_name == "NominationPools" { let variant_error = - nomination_pools::Error::decode_with_metadata(cursor, 633u32, metadata)?; + nomination_pools::Error::decode_with_metadata(cursor, 710u32, metadata)?; return Ok(Error::NominationPools(variant_error)); } if pallet_name == "FastUnstake" { let variant_error = - fast_unstake::Error::decode_with_metadata(cursor, 638u32, metadata)?; + fast_unstake::Error::decode_with_metadata(cursor, 715u32, metadata)?; return Ok(Error::FastUnstake(variant_error)); } if pallet_name == "Configuration" { let variant_error = - configuration::Error::decode_with_metadata(cursor, 642u32, metadata)?; + configuration::Error::decode_with_metadata(cursor, 719u32, metadata)?; return Ok(Error::Configuration(variant_error)); } if pallet_name == "ParaInclusion" { let variant_error = - para_inclusion::Error::decode_with_metadata(cursor, 647u32, metadata)?; + para_inclusion::Error::decode_with_metadata(cursor, 724u32, metadata)?; return Ok(Error::ParaInclusion(variant_error)); } if pallet_name == "ParaInherent" { let variant_error = - para_inherent::Error::decode_with_metadata(cursor, 653u32, metadata)?; + para_inherent::Error::decode_with_metadata(cursor, 730u32, metadata)?; return Ok(Error::ParaInherent(variant_error)); } if pallet_name == "Paras" { - let variant_error = paras::Error::decode_with_metadata(cursor, 680u32, metadata)?; + let variant_error = paras::Error::decode_with_metadata(cursor, 757u32, metadata)?; return Ok(Error::Paras(variant_error)); } if pallet_name == "Ump" { - let variant_error = ump::Error::decode_with_metadata(cursor, 686u32, metadata)?; + let variant_error = ump::Error::decode_with_metadata(cursor, 763u32, metadata)?; return Ok(Error::Ump(variant_error)); } if pallet_name == "Hrmp" { - let variant_error = hrmp::Error::decode_with_metadata(cursor, 695u32, metadata)?; + let variant_error = hrmp::Error::decode_with_metadata(cursor, 771u32, metadata)?; return Ok(Error::Hrmp(variant_error)); } if pallet_name == "ParasDisputes" { let variant_error = - paras_disputes::Error::decode_with_metadata(cursor, 703u32, metadata)?; + paras_disputes::Error::decode_with_metadata(cursor, 780u32, metadata)?; return Ok(Error::ParasDisputes(variant_error)); } + if pallet_name == "ParasSlashing" { + let variant_error = + paras_slashing::Error::decode_with_metadata(cursor, 785u32, metadata)?; + return Ok(Error::ParasSlashing(variant_error)); + } if pallet_name == "Registrar" { let variant_error = - registrar::Error::decode_with_metadata(cursor, 705u32, metadata)?; + registrar::Error::decode_with_metadata(cursor, 787u32, metadata)?; return Ok(Error::Registrar(variant_error)); } if pallet_name == "Slots" { - let variant_error = slots::Error::decode_with_metadata(cursor, 707u32, metadata)?; + let variant_error = slots::Error::decode_with_metadata(cursor, 789u32, metadata)?; return Ok(Error::Slots(variant_error)); } if pallet_name == "Auctions" { let variant_error = - auctions::Error::decode_with_metadata(cursor, 712u32, metadata)?; + auctions::Error::decode_with_metadata(cursor, 794u32, metadata)?; return Ok(Error::Auctions(variant_error)); } if pallet_name == "Crowdloan" { let variant_error = - crowdloan::Error::decode_with_metadata(cursor, 715u32, metadata)?; + crowdloan::Error::decode_with_metadata(cursor, 797u32, metadata)?; return Ok(Error::Crowdloan(variant_error)); } if pallet_name == "XcmPallet" { let variant_error = - xcm_pallet::Error::decode_with_metadata(cursor, 727u32, metadata)?; + xcm_pallet::Error::decode_with_metadata(cursor, 816u32, metadata)?; return Ok(Error::XcmPallet(variant_error)); } Err(::subxt::ext::scale_decode::Error::custom(format!( @@ -807,9 +861,6 @@ pub mod api { pub fn transaction_payment(&self) -> transaction_payment::constants::ConstantsApi { transaction_payment::constants::ConstantsApi } - pub fn authorship(&self) -> authorship::constants::ConstantsApi { - authorship::constants::ConstantsApi - } pub fn staking(&self) -> staking::constants::ConstantsApi { staking::constants::ConstantsApi } @@ -822,12 +873,24 @@ pub mod api { pub fn democracy(&self) -> democracy::constants::ConstantsApi { democracy::constants::ConstantsApi } + pub fn council(&self) -> council::constants::ConstantsApi { + council::constants::ConstantsApi + } + pub fn technical_committee(&self) -> technical_committee::constants::ConstantsApi { + technical_committee::constants::ConstantsApi + } pub fn phragmen_election(&self) -> phragmen_election::constants::ConstantsApi { phragmen_election::constants::ConstantsApi } pub fn treasury(&self) -> treasury::constants::ConstantsApi { treasury::constants::ConstantsApi } + pub fn conviction_voting(&self) -> conviction_voting::constants::ConstantsApi { + conviction_voting::constants::ConstantsApi + } + pub fn referenda(&self) -> referenda::constants::ConstantsApi { + referenda::constants::ConstantsApi + } pub fn claims(&self) -> claims::constants::ConstantsApi { claims::constants::ConstantsApi } @@ -866,6 +929,9 @@ pub mod api { pub fn nomination_pools(&self) -> nomination_pools::constants::ConstantsApi { nomination_pools::constants::ConstantsApi } + pub fn fast_unstake(&self) -> fast_unstake::constants::ConstantsApi { + fast_unstake::constants::ConstantsApi + } pub fn paras(&self) -> paras::constants::ConstantsApi { paras::constants::ConstantsApi } @@ -944,6 +1010,15 @@ pub mod api { pub fn treasury(&self) -> treasury::storage::StorageApi { treasury::storage::StorageApi } + pub fn conviction_voting(&self) -> conviction_voting::storage::StorageApi { + conviction_voting::storage::StorageApi + } + pub fn referenda(&self) -> referenda::storage::StorageApi { + referenda::storage::StorageApi + } + pub fn whitelist(&self) -> whitelist::storage::StorageApi { + whitelist::storage::StorageApi + } pub fn claims(&self) -> claims::storage::StorageApi { claims::storage::StorageApi } @@ -1018,6 +1093,9 @@ pub mod api { pub fn paras_disputes(&self) -> paras_disputes::storage::StorageApi { paras_disputes::storage::StorageApi } + pub fn paras_slashing(&self) -> paras_slashing::storage::StorageApi { + paras_slashing::storage::StorageApi + } pub fn registrar(&self) -> registrar::storage::StorageApi { registrar::storage::StorageApi } @@ -1057,9 +1135,6 @@ pub mod api { pub fn balances(&self) -> balances::calls::TransactionApi { balances::calls::TransactionApi } - pub fn authorship(&self) -> authorship::calls::TransactionApi { - authorship::calls::TransactionApi - } pub fn staking(&self) -> staking::calls::TransactionApi { staking::calls::TransactionApi } @@ -1090,6 +1165,15 @@ pub mod api { pub fn treasury(&self) -> treasury::calls::TransactionApi { treasury::calls::TransactionApi } + pub fn conviction_voting(&self) -> conviction_voting::calls::TransactionApi { + conviction_voting::calls::TransactionApi + } + pub fn referenda(&self) -> referenda::calls::TransactionApi { + referenda::calls::TransactionApi + } + pub fn whitelist(&self) -> whitelist::calls::TransactionApi { + whitelist::calls::TransactionApi + } pub fn claims(&self) -> claims::calls::TransactionApi { claims::calls::TransactionApi } @@ -1149,9 +1233,6 @@ pub mod api { pub fn initializer(&self) -> initializer::calls::TransactionApi { initializer::calls::TransactionApi } - pub fn dmp(&self) -> dmp::calls::TransactionApi { - dmp::calls::TransactionApi - } pub fn ump(&self) -> ump::calls::TransactionApi { ump::calls::TransactionApi } @@ -1161,6 +1242,9 @@ pub mod api { pub fn paras_disputes(&self) -> paras_disputes::calls::TransactionApi { paras_disputes::calls::TransactionApi } + pub fn paras_slashing(&self) -> paras_slashing::calls::TransactionApi { + paras_slashing::calls::TransactionApi + } pub fn registrar(&self) -> registrar::calls::TransactionApi { registrar::calls::TransactionApi } @@ -1184,9 +1268,9 @@ pub mod api { let runtime_metadata_hash = client.metadata().metadata_hash(&PALLETS); if runtime_metadata_hash != [ - 252u8, 179u8, 170u8, 129u8, 159u8, 95u8, 180u8, 114u8, 218u8, 56u8, 91u8, 93u8, - 175u8, 45u8, 57u8, 223u8, 178u8, 209u8, 250u8, 247u8, 243u8, 73u8, 182u8, 137u8, - 176u8, 129u8, 37u8, 196u8, 133u8, 123u8, 93u8, 186u8, + 193u8, 126u8, 5u8, 68u8, 158u8, 198u8, 107u8, 140u8, 166u8, 77u8, 81u8, 160u8, + 213u8, 179u8, 210u8, 41u8, 130u8, 34u8, 133u8, 228u8, 10u8, 134u8, 182u8, 62u8, + 72u8, 116u8, 209u8, 70u8, 115u8, 234u8, 227u8, 18u8, ] { Err(::subxt::error::MetadataError::IncompatibleMetadata) @@ -1214,19 +1298,6 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FillBlock { - pub ratio: runtime_types::sp_arithmetic::per_things::Perbill, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Remark { pub remark: ::std::vec::Vec<::core::primitive::u8>, } @@ -1328,28 +1399,10 @@ pub mod api { } pub struct TransactionApi; impl TransactionApi { - #[doc = "A dispatch that will fill the block weight up to the given ratio."] - pub fn fill_block( - &self, - ratio: runtime_types::sp_arithmetic::per_things::Perbill, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "fill_block", - FillBlock { ratio }, - [ - 48u8, 18u8, 205u8, 90u8, 222u8, 4u8, 20u8, 251u8, 173u8, 76u8, 167u8, - 4u8, 83u8, 203u8, 160u8, 89u8, 132u8, 218u8, 191u8, 145u8, 130u8, - 245u8, 177u8, 201u8, 169u8, 129u8, 173u8, 105u8, 88u8, 45u8, 136u8, - 191u8, - ], - ) - } #[doc = "Make some on-chain remark."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`"] - #[doc = "# "] pub fn remark( &self, remark: ::std::vec::Vec<::core::primitive::u8>, @@ -1384,16 +1437,8 @@ pub mod api { } #[doc = "Set the new runtime code."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(C + S)` where `C` length of `code` and `S` complexity of `can_set_code`"] - #[doc = "- 1 call to `can_set_code`: `O(S)` (calls `sp_io::misc::runtime_version` which is"] - #[doc = " expensive)."] - #[doc = "- 1 storage write (codec `O(C)`)."] - #[doc = "- 1 digest item."] - #[doc = "- 1 event."] - #[doc = "The weight of this function is dependent on the runtime, but generally this is very"] - #[doc = "expensive. We will treat this as a full block."] - #[doc = "# "] pub fn set_code( &self, code: ::std::vec::Vec<::core::primitive::u8>, @@ -1411,13 +1456,8 @@ pub mod api { } #[doc = "Set the new runtime code without doing any checks of the given `code`."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(C)` where `C` length of `code`"] - #[doc = "- 1 storage write (codec `O(C)`)."] - #[doc = "- 1 digest item."] - #[doc = "- 1 event."] - #[doc = "The weight of this function is dependent on the runtime. We will treat this as a full"] - #[doc = "block. # "] pub fn set_code_without_checks( &self, code: ::std::vec::Vec<::core::primitive::u8>, @@ -1634,7 +1674,7 @@ pub mod api { ::subxt::storage::address::StaticStorageMapKey, runtime_types::frame_system::AccountInfo< ::core::primitive::u32, - runtime_types::pallet_balances::AccountData<::core::primitive::u128>, + runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, >, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, @@ -1647,9 +1687,10 @@ pub mod api { _0.borrow(), )], [ - 176u8, 187u8, 21u8, 220u8, 159u8, 204u8, 127u8, 14u8, 21u8, 69u8, 77u8, - 114u8, 230u8, 141u8, 107u8, 79u8, 23u8, 16u8, 174u8, 243u8, 252u8, - 42u8, 65u8, 120u8, 229u8, 38u8, 210u8, 255u8, 22u8, 40u8, 109u8, 223u8, + 248u8, 178u8, 160u8, 222u8, 45u8, 231u8, 115u8, 164u8, 98u8, 184u8, + 174u8, 206u8, 149u8, 190u8, 175u8, 34u8, 202u8, 230u8, 69u8, 218u8, + 83u8, 43u8, 170u8, 41u8, 106u8, 77u8, 233u8, 97u8, 114u8, 14u8, 155u8, + 131u8, ], ) } @@ -1660,7 +1701,7 @@ pub mod api { ::subxt::storage::address::StaticStorageMapKey, runtime_types::frame_system::AccountInfo< ::core::primitive::u32, - runtime_types::pallet_balances::AccountData<::core::primitive::u128>, + runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, >, (), ::subxt::storage::address::Yes, @@ -1671,9 +1712,10 @@ pub mod api { "Account", Vec::new(), [ - 176u8, 187u8, 21u8, 220u8, 159u8, 204u8, 127u8, 14u8, 21u8, 69u8, 77u8, - 114u8, 230u8, 141u8, 107u8, 79u8, 23u8, 16u8, 174u8, 243u8, 252u8, - 42u8, 65u8, 120u8, 229u8, 38u8, 210u8, 255u8, 22u8, 40u8, 109u8, 223u8, + 248u8, 178u8, 160u8, 222u8, 45u8, 231u8, 115u8, 164u8, 98u8, 184u8, + 174u8, 206u8, 149u8, 190u8, 175u8, 34u8, 202u8, 230u8, 69u8, 218u8, + 83u8, 43u8, 170u8, 41u8, 106u8, 77u8, 233u8, 97u8, 114u8, 14u8, 155u8, + 131u8, ], ) } @@ -1925,9 +1967,9 @@ pub mod api { "Events", vec![], [ - 230u8, 215u8, 9u8, 223u8, 139u8, 55u8, 22u8, 144u8, 226u8, 245u8, - 166u8, 235u8, 8u8, 182u8, 131u8, 51u8, 41u8, 148u8, 102u8, 40u8, 86u8, - 230u8, 82u8, 41u8, 226u8, 151u8, 247u8, 41u8, 186u8, 190u8, 85u8, 20u8, + 78u8, 158u8, 91u8, 165u8, 29u8, 179u8, 204u8, 195u8, 39u8, 3u8, 127u8, + 199u8, 132u8, 93u8, 252u8, 17u8, 84u8, 58u8, 51u8, 56u8, 159u8, 51u8, + 188u8, 138u8, 75u8, 109u8, 148u8, 73u8, 227u8, 56u8, 162u8, 246u8, ], ) } @@ -2338,10 +2380,10 @@ pub mod api { call: ::std::boxed::Box::new(call), }, [ - 110u8, 118u8, 202u8, 51u8, 211u8, 53u8, 194u8, 114u8, 80u8, 166u8, - 134u8, 18u8, 89u8, 144u8, 204u8, 155u8, 201u8, 237u8, 138u8, 170u8, - 86u8, 16u8, 7u8, 2u8, 12u8, 96u8, 17u8, 148u8, 147u8, 144u8, 196u8, - 4u8, + 225u8, 142u8, 54u8, 240u8, 129u8, 69u8, 56u8, 230u8, 207u8, 110u8, + 78u8, 150u8, 87u8, 254u8, 95u8, 73u8, 74u8, 204u8, 165u8, 239u8, 246u8, + 132u8, 251u8, 183u8, 36u8, 102u8, 236u8, 244u8, 201u8, 2u8, 233u8, + 255u8, ], ) } @@ -2385,9 +2427,10 @@ pub mod api { call: ::std::boxed::Box::new(call), }, [ - 84u8, 106u8, 212u8, 23u8, 117u8, 33u8, 204u8, 44u8, 79u8, 178u8, 21u8, - 241u8, 151u8, 179u8, 201u8, 1u8, 48u8, 13u8, 125u8, 176u8, 166u8, 49u8, - 118u8, 174u8, 1u8, 187u8, 45u8, 75u8, 204u8, 219u8, 229u8, 24u8, + 158u8, 202u8, 183u8, 44u8, 48u8, 102u8, 44u8, 53u8, 74u8, 193u8, 176u8, + 21u8, 240u8, 144u8, 135u8, 240u8, 87u8, 70u8, 132u8, 36u8, 229u8, + 233u8, 249u8, 55u8, 129u8, 81u8, 37u8, 193u8, 207u8, 252u8, 49u8, + 165u8, ], ) } @@ -2408,10 +2451,6 @@ pub mod api { ) } #[doc = "Anonymously schedule a task after a delay."] - #[doc = ""] - #[doc = "# "] - #[doc = "Same as [`schedule`]."] - #[doc = "# "] pub fn schedule_after( &self, after: ::core::primitive::u32, @@ -2432,17 +2471,14 @@ pub mod api { call: ::std::boxed::Box::new(call), }, [ - 176u8, 3u8, 143u8, 176u8, 250u8, 9u8, 0u8, 75u8, 62u8, 93u8, 220u8, - 19u8, 98u8, 136u8, 178u8, 98u8, 187u8, 57u8, 228u8, 147u8, 133u8, 88u8, - 146u8, 58u8, 113u8, 166u8, 41u8, 25u8, 163u8, 95u8, 6u8, 47u8, + 73u8, 79u8, 70u8, 138u8, 189u8, 239u8, 243u8, 180u8, 250u8, 183u8, + 246u8, 40u8, 204u8, 164u8, 154u8, 219u8, 87u8, 144u8, 44u8, 185u8, + 181u8, 130u8, 147u8, 11u8, 156u8, 54u8, 201u8, 207u8, 238u8, 76u8, + 61u8, 179u8, ], ) } #[doc = "Schedule a named task after a delay."] - #[doc = ""] - #[doc = "# "] - #[doc = "Same as [`schedule_named`](Self::schedule_named)."] - #[doc = "# "] pub fn schedule_named_after( &self, id: [::core::primitive::u8; 32usize], @@ -2465,10 +2501,10 @@ pub mod api { call: ::std::boxed::Box::new(call), }, [ - 195u8, 224u8, 47u8, 168u8, 137u8, 114u8, 75u8, 129u8, 115u8, 108u8, - 190u8, 194u8, 60u8, 179u8, 249u8, 51u8, 110u8, 4u8, 109u8, 50u8, 68u8, - 121u8, 101u8, 41u8, 203u8, 4u8, 18u8, 182u8, 245u8, 197u8, 244u8, - 195u8, + 158u8, 154u8, 219u8, 160u8, 184u8, 209u8, 41u8, 234u8, 126u8, 157u8, + 63u8, 92u8, 143u8, 2u8, 82u8, 145u8, 45u8, 145u8, 148u8, 27u8, 48u8, + 255u8, 95u8, 70u8, 182u8, 146u8, 199u8, 252u8, 87u8, 105u8, 12u8, + 187u8, ], ) } @@ -2625,7 +2661,7 @@ pub mod api { _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + runtime_types::bounded_collections::bounded_vec::BoundedVec< ::core::option::Option< runtime_types::pallet_scheduler::Scheduled< [::core::primitive::u8; 32usize], @@ -2649,9 +2685,10 @@ pub mod api { _0.borrow(), )], [ - 159u8, 237u8, 79u8, 176u8, 214u8, 27u8, 183u8, 165u8, 63u8, 185u8, - 233u8, 151u8, 81u8, 170u8, 97u8, 115u8, 47u8, 90u8, 254u8, 2u8, 66u8, - 209u8, 3u8, 247u8, 92u8, 11u8, 54u8, 144u8, 88u8, 172u8, 127u8, 143u8, + 130u8, 206u8, 243u8, 81u8, 169u8, 223u8, 74u8, 102u8, 75u8, 207u8, + 232u8, 175u8, 233u8, 167u8, 109u8, 190u8, 242u8, 24u8, 203u8, 144u8, + 31u8, 68u8, 147u8, 110u8, 77u8, 175u8, 2u8, 129u8, 127u8, 198u8, 49u8, + 151u8, ], ) } @@ -2660,7 +2697,7 @@ pub mod api { &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + runtime_types::bounded_collections::bounded_vec::BoundedVec< ::core::option::Option< runtime_types::pallet_scheduler::Scheduled< [::core::primitive::u8; 32usize], @@ -2682,9 +2719,10 @@ pub mod api { "Agenda", Vec::new(), [ - 159u8, 237u8, 79u8, 176u8, 214u8, 27u8, 183u8, 165u8, 63u8, 185u8, - 233u8, 151u8, 81u8, 170u8, 97u8, 115u8, 47u8, 90u8, 254u8, 2u8, 66u8, - 209u8, 3u8, 247u8, 92u8, 11u8, 54u8, 144u8, 88u8, 172u8, 127u8, 143u8, + 130u8, 206u8, 243u8, 81u8, 169u8, 223u8, 74u8, 102u8, 75u8, 207u8, + 232u8, 175u8, 233u8, 167u8, 109u8, 190u8, 242u8, 24u8, 203u8, 144u8, + 31u8, 68u8, 147u8, 110u8, 77u8, 175u8, 2u8, 129u8, 127u8, 198u8, 49u8, + 151u8, ], ) } @@ -2764,6 +2802,10 @@ pub mod api { ) } #[doc = " The maximum number of scheduled calls in the queue for a single block."] + #[doc = ""] + #[doc = " NOTE:"] + #[doc = " + Dependent pallets' benchmarks might require a higher limit for the setting. Set a"] + #[doc = " higher limit under `runtime-benchmarks` feature."] pub fn max_scheduled_per_block( &self, ) -> ::subxt::constants::Address<::core::primitive::u32> { @@ -3044,7 +3086,9 @@ pub mod api { _1: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec<::core::primitive::u8>, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, @@ -3067,7 +3111,9 @@ pub mod api { &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec<::core::primitive::u8>, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, (), (), ::subxt::storage::address::Yes, @@ -3270,7 +3316,7 @@ pub mod api { &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::weak_bounded_vec::WeakBoundedVec<( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec<( runtime_types::sp_consensus_babe::app::Public, ::core::primitive::u64, )>, @@ -3413,7 +3459,7 @@ pub mod api { &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::weak_bounded_vec::WeakBoundedVec<( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec<( runtime_types::sp_consensus_babe::app::Public, ::core::primitive::u64, )>, @@ -3467,7 +3513,7 @@ pub mod api { _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + runtime_types::bounded_collections::bounded_vec::BoundedVec< [::core::primitive::u8; 32usize], >, ::subxt::storage::address::Yes, @@ -3492,7 +3538,7 @@ pub mod api { &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + runtime_types::bounded_collections::bounded_vec::BoundedVec< [::core::primitive::u8; 32usize], >, (), @@ -3526,10 +3572,9 @@ pub mod api { "Initialized", vec![], [ - 142u8, 101u8, 250u8, 113u8, 93u8, 201u8, 157u8, 18u8, 166u8, 153u8, - 59u8, 197u8, 107u8, 247u8, 124u8, 110u8, 202u8, 67u8, 62u8, 57u8, - 186u8, 134u8, 49u8, 182u8, 149u8, 44u8, 255u8, 85u8, 87u8, 177u8, - 149u8, 121u8, + 40u8, 135u8, 28u8, 144u8, 247u8, 208u8, 48u8, 220u8, 46u8, 60u8, 131u8, + 190u8, 196u8, 235u8, 126u8, 66u8, 34u8, 14u8, 32u8, 131u8, 71u8, 46u8, + 62u8, 207u8, 177u8, 213u8, 167u8, 34u8, 199u8, 29u8, 16u8, 236u8, ], ) } @@ -3656,6 +3701,37 @@ pub mod api { ], ) } + #[doc = " A list of the last 100 skipped epochs and the corresponding session index"] + #[doc = " when the epoch was skipped."] + #[doc = ""] + #[doc = " This is only used for validating equivocation proofs. An equivocation proof"] + #[doc = " must contains a key-ownership proof for a given session, therefore we need a"] + #[doc = " way to tie together sessions and epoch indices, i.e. we need to validate that"] + #[doc = " a validator was the owner of a given key on a given session, and what the"] + #[doc = " active epoch index was during that session."] + pub fn skipped_epochs( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u64, + ::core::primitive::u32, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "SkippedEpochs", + vec![], + [ + 187u8, 66u8, 178u8, 110u8, 247u8, 41u8, 128u8, 194u8, 173u8, 197u8, + 28u8, 219u8, 112u8, 75u8, 9u8, 184u8, 51u8, 12u8, 121u8, 117u8, 176u8, + 213u8, 139u8, 144u8, 122u8, 72u8, 243u8, 105u8, 248u8, 63u8, 6u8, 87u8, + ], + ) + } } } pub mod constants { @@ -3750,12 +3826,11 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin for this call must be `Inherent`."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)` (Note that implementations of `OnTimestampSet` must also be `O(1)`)"] #[doc = "- 1 storage read and 1 storage mutation (codec `O(1)`). (because of `DidUpdate::take` in"] #[doc = " `on_finalize`)"] #[doc = "- 1 event handler `on_timestamp_set`. Must be `O(1)`."] - #[doc = "# "] pub fn set(&self, now: ::core::primitive::u64) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Timestamp", @@ -3936,14 +4011,8 @@ pub mod api { #[doc = ""] #[doc = "Emits `IndexAssigned` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- One storage mutation (codec `O(1)`)."] - #[doc = "- One reserve operation."] - #[doc = "- One event."] - #[doc = "-------------------"] - #[doc = "- DB Weight: 1 Read/Write (Accounts)"] - #[doc = "# "] pub fn claim(&self, index: ::core::primitive::u32) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Indices", @@ -3966,16 +4035,8 @@ pub mod api { #[doc = ""] #[doc = "Emits `IndexAssigned` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- One storage mutation (codec `O(1)`)."] - #[doc = "- One transfer operation."] - #[doc = "- One event."] - #[doc = "-------------------"] - #[doc = "- DB Weight:"] - #[doc = " - Reads: Indices Accounts, System Account (recipient)"] - #[doc = " - Writes: Indices Accounts, System Account (recipient)"] - #[doc = "# "] pub fn transfer( &self, new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -4002,14 +4063,8 @@ pub mod api { #[doc = ""] #[doc = "Emits `IndexFreed` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- One storage mutation (codec `O(1)`)."] - #[doc = "- One reserve operation."] - #[doc = "- One event."] - #[doc = "-------------------"] - #[doc = "- DB Weight: 1 Read/Write (Accounts)"] - #[doc = "# "] pub fn free(&self, index: ::core::primitive::u32) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Indices", @@ -4034,16 +4089,8 @@ pub mod api { #[doc = ""] #[doc = "Emits `IndexAssigned` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- One storage mutation (codec `O(1)`)."] - #[doc = "- Up to one reserve operation."] - #[doc = "- One event."] - #[doc = "-------------------"] - #[doc = "- DB Weight:"] - #[doc = " - Reads: Indices Accounts, System Account (original owner)"] - #[doc = " - Writes: Indices Accounts, System Account (original owner)"] - #[doc = "# "] pub fn force_transfer( &self, new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -4072,14 +4119,8 @@ pub mod api { #[doc = ""] #[doc = "Emits `IndexFrozen` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- One storage mutation (codec `O(1)`)."] - #[doc = "- Up to one slash operation."] - #[doc = "- One event."] - #[doc = "-------------------"] - #[doc = "- DB Weight: 1 Read/Write (Accounts)"] - #[doc = "# "] pub fn freeze( &self, index: ::core::primitive::u32, @@ -4259,7 +4300,7 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Transfer { + pub struct TransferAllowDeath { pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, #[codec(compact)] pub value: ::core::primitive::u128, @@ -4274,12 +4315,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetBalance { + pub struct SetBalanceDeprecated { pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, #[codec(compact)] pub new_free: ::core::primitive::u128, #[codec(compact)] - pub new_reserved: ::core::primitive::u128, + pub old_reserved: ::core::primitive::u128, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -4340,86 +4381,104 @@ pub mod api { pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, pub amount: ::core::primitive::u128, } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UpgradeAccounts { + pub who: ::std::vec::Vec<::subxt::utils::AccountId32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Transfer { + pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceSetBalance { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub new_free: ::core::primitive::u128, + } pub struct TransactionApi; impl TransactionApi { #[doc = "Transfer some liquid free balance to another account."] #[doc = ""] - #[doc = "`transfer` will set the `FreeBalance` of the sender and receiver."] + #[doc = "`transfer_allow_death` will set the `FreeBalance` of the sender and receiver."] #[doc = "If the sender's account is below the existential deposit as a result"] #[doc = "of the transfer, the account will be reaped."] #[doc = ""] #[doc = "The dispatch origin for this call must be `Signed` by the transactor."] - #[doc = ""] - #[doc = "# "] - #[doc = "- Dependent on arguments but not critical, given proper implementations for input config"] - #[doc = " types. See related functions below."] - #[doc = "- It contains a limited number of reads and writes internally and no complex"] - #[doc = " computation."] - #[doc = ""] - #[doc = "Related functions:"] - #[doc = ""] - #[doc = " - `ensure_can_withdraw` is always called internally but has a bounded complexity."] - #[doc = " - Transferring balances to accounts that did not exist before will cause"] - #[doc = " `T::OnNewAccount::on_new_account` to be called."] - #[doc = " - Removing enough funds from an account will trigger `T::DustRemoval::on_unbalanced`."] - #[doc = " - `transfer_keep_alive` works the same way as `transfer`, but has an additional check"] - #[doc = " that the transfer will not kill the origin account."] - #[doc = "---------------------------------"] - #[doc = "- Origin account is already in memory, so no DB operations for them."] - #[doc = "# "] - pub fn transfer( + pub fn transfer_allow_death( &self, dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Balances", - "transfer", - Transfer { dest, value }, + "transfer_allow_death", + TransferAllowDeath { dest, value }, [ - 111u8, 222u8, 32u8, 56u8, 171u8, 77u8, 252u8, 29u8, 194u8, 155u8, - 200u8, 192u8, 198u8, 81u8, 23u8, 115u8, 236u8, 91u8, 218u8, 114u8, - 107u8, 141u8, 138u8, 100u8, 237u8, 21u8, 58u8, 172u8, 3u8, 20u8, 216u8, - 38u8, + 234u8, 130u8, 149u8, 36u8, 235u8, 112u8, 159u8, 189u8, 104u8, 148u8, + 108u8, 230u8, 25u8, 198u8, 71u8, 158u8, 112u8, 3u8, 162u8, 25u8, 145u8, + 252u8, 44u8, 63u8, 47u8, 34u8, 47u8, 158u8, 61u8, 14u8, 120u8, 255u8, ], ) } - #[doc = "Set the balances of a given account."] - #[doc = ""] - #[doc = "This will alter `FreeBalance` and `ReservedBalance` in storage. it will"] - #[doc = "also alter the total issuance of the system (`TotalIssuance`) appropriately."] - #[doc = "If the new free or reserved balance is below the existential deposit,"] - #[doc = "it will reset the account nonce (`frame_system::AccountNonce`)."] + #[doc = "Set the regular balance of a given account; it also takes a reserved balance but this"] + #[doc = "must be the same as the account's current reserved balance."] #[doc = ""] #[doc = "The dispatch origin for this call is `root`."] - pub fn set_balance( + #[doc = ""] + #[doc = "WARNING: This call is DEPRECATED! Use `force_set_balance` instead."] + pub fn set_balance_deprecated( &self, who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, new_free: ::core::primitive::u128, - new_reserved: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + old_reserved: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Balances", - "set_balance", - SetBalance { + "set_balance_deprecated", + SetBalanceDeprecated { who, new_free, - new_reserved, + old_reserved, }, [ - 234u8, 215u8, 97u8, 98u8, 243u8, 199u8, 57u8, 76u8, 59u8, 161u8, 118u8, - 207u8, 34u8, 197u8, 198u8, 61u8, 231u8, 210u8, 169u8, 235u8, 150u8, - 137u8, 173u8, 49u8, 28u8, 77u8, 84u8, 149u8, 143u8, 210u8, 139u8, - 193u8, + 240u8, 107u8, 184u8, 206u8, 78u8, 106u8, 115u8, 152u8, 130u8, 56u8, + 156u8, 176u8, 105u8, 27u8, 176u8, 187u8, 49u8, 171u8, 229u8, 79u8, + 254u8, 248u8, 8u8, 162u8, 134u8, 12u8, 89u8, 100u8, 137u8, 102u8, + 132u8, 158u8, ], ) } - #[doc = "Exactly as `transfer`, except the origin must be root and the source account may be"] - #[doc = "specified."] - #[doc = "# "] - #[doc = "- Same as transfer, but additional read and write because the source account is not"] - #[doc = " assumed to be in the overlay."] - #[doc = "# "] + #[doc = "Exactly as `transfer_allow_death`, except the origin must be root and the source account"] + #[doc = "may be specified."] pub fn force_transfer( &self, source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -4442,12 +4501,12 @@ pub mod api { ], ) } - #[doc = "Same as the [`transfer`] call, but with a check that the transfer will not kill the"] - #[doc = "origin account."] + #[doc = "Same as the [`transfer_allow_death`] call, but with a check that the transfer will not"] + #[doc = "kill the origin account."] #[doc = ""] - #[doc = "99% of the time you want [`transfer`] instead."] + #[doc = "99% of the time you want [`transfer_allow_death`] instead."] #[doc = ""] - #[doc = "[`transfer`]: struct.Pallet.html#method.transfer"] + #[doc = "[`transfer_allow_death`]: struct.Pallet.html#method.transfer"] pub fn transfer_keep_alive( &self, dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -4479,9 +4538,7 @@ pub mod api { #[doc = "- `keep_alive`: A boolean to determine if the `transfer_all` operation should send all"] #[doc = " of the funds the account has, causing the sender account to be killed (false), or"] #[doc = " transfer everything except at least the existential deposit, which will guarantee to"] - #[doc = " keep the sender account alive (true). # "] - #[doc = "- O(1). Just like transfer, but reading the user's transferable balance first."] - #[doc = " #"] + #[doc = " keep the sender account alive (true)."] pub fn transfer_all( &self, dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -4519,6 +4576,68 @@ pub mod api { ], ) } + #[doc = "Upgrade a specified account."] + #[doc = ""] + #[doc = "- `origin`: Must be `Signed`."] + #[doc = "- `who`: The account to be upgraded."] + #[doc = ""] + #[doc = "This will waive the transaction fee if at least all but 10% of the accounts needed to"] + #[doc = "be upgraded. (We let some not have to be upgraded just in order to allow for the"] + #[doc = "possibililty of churn)."] + pub fn upgrade_accounts( + &self, + who: ::std::vec::Vec<::subxt::utils::AccountId32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "upgrade_accounts", + UpgradeAccounts { who }, + [ + 164u8, 61u8, 119u8, 24u8, 165u8, 46u8, 197u8, 59u8, 39u8, 198u8, 228u8, + 96u8, 228u8, 45u8, 85u8, 51u8, 37u8, 5u8, 75u8, 40u8, 241u8, 163u8, + 86u8, 228u8, 151u8, 217u8, 47u8, 105u8, 203u8, 103u8, 207u8, 4u8, + ], + ) + } + #[doc = "Alias for `transfer_allow_death`, provided only for name-wise compatibility."] + #[doc = ""] + #[doc = "WARNING: DEPRECATED! Will be released in approximately 3 months."] + pub fn transfer( + &self, + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "transfer", + Transfer { dest, value }, + [ + 111u8, 222u8, 32u8, 56u8, 171u8, 77u8, 252u8, 29u8, 194u8, 155u8, + 200u8, 192u8, 198u8, 81u8, 23u8, 115u8, 236u8, 91u8, 218u8, 114u8, + 107u8, 141u8, 138u8, 100u8, 237u8, 21u8, 58u8, 172u8, 3u8, 20u8, 216u8, + 38u8, + ], + ) + } + #[doc = "Set the regular balance of a given account."] + #[doc = ""] + #[doc = "The dispatch origin for this call is `root`."] + pub fn force_set_balance( + &self, + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + new_free: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "force_set_balance", + ForceSetBalance { who, new_free }, + [ + 237u8, 4u8, 41u8, 58u8, 62u8, 179u8, 160u8, 4u8, 50u8, 71u8, 178u8, + 36u8, 130u8, 130u8, 92u8, 229u8, 16u8, 245u8, 169u8, 109u8, 165u8, + 72u8, 94u8, 70u8, 196u8, 136u8, 37u8, 94u8, 140u8, 215u8, 125u8, 125u8, + ], + ) + } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -4598,7 +4717,6 @@ pub mod api { pub struct BalanceSet { pub who: ::subxt::utils::AccountId32, pub free: ::core::primitive::u128, - pub reserved: ::core::primitive::u128, } impl ::subxt::events::StaticEvent for BalanceSet { const PALLET: &'static str = "Balances"; @@ -4722,6 +4840,214 @@ pub mod api { const PALLET: &'static str = "Balances"; const EVENT: &'static str = "Slashed"; } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was minted into an account."] + pub struct Minted { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Minted { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Minted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was burned from an account."] + pub struct Burned { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Burned { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Burned"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was suspended from an account (it can be restored later)."] + pub struct Suspended { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Suspended { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Suspended"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was restored into an account."] + pub struct Restored { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Restored { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Restored"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account was upgraded."] + pub struct Upgraded { + pub who: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for Upgraded { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Upgraded"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Total issuance was increased by `amount`, creating a credit to be balanced."] + pub struct Issued { + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Issued { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Issued"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Total issuance was decreased by `amount`, creating a debt to be balanced."] + pub struct Rescinded { + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Rescinded { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Rescinded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was locked."] + pub struct Locked { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Locked { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Locked"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was unlocked."] + pub struct Unlocked { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Unlocked { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Unlocked"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was frozen."] + pub struct Frozen { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Frozen { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Frozen"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was thawed."] + pub struct Thawed { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Thawed { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Thawed"; + } } pub mod storage { use super::runtime_types; @@ -4748,6 +5074,28 @@ pub mod api { ], ) } + #[doc = " The total units of outstanding deactivated balance in the system."] + pub fn inactive_issuance( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "InactiveIssuance", + vec![], + [ + 74u8, 203u8, 111u8, 142u8, 225u8, 104u8, 173u8, 51u8, 226u8, 12u8, + 85u8, 135u8, 41u8, 206u8, 177u8, 238u8, 94u8, 246u8, 184u8, 250u8, + 140u8, 213u8, 91u8, 118u8, 163u8, 111u8, 211u8, 46u8, 204u8, 160u8, + 154u8, 21u8, + ], + ) + } #[doc = " The Balances pallet example of storing the balance of an account."] #[doc = ""] #[doc = " # Example"] @@ -4777,7 +5125,7 @@ pub mod api { _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_balances::AccountData<::core::primitive::u128>, + runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, @@ -4789,9 +5137,10 @@ pub mod api { _0.borrow(), )], [ - 246u8, 154u8, 253u8, 71u8, 192u8, 192u8, 192u8, 236u8, 128u8, 80u8, - 40u8, 252u8, 201u8, 43u8, 3u8, 131u8, 19u8, 49u8, 141u8, 240u8, 172u8, - 217u8, 215u8, 109u8, 87u8, 135u8, 248u8, 57u8, 98u8, 185u8, 22u8, 4u8, + 109u8, 250u8, 18u8, 96u8, 139u8, 232u8, 4u8, 139u8, 133u8, 239u8, 30u8, + 237u8, 73u8, 209u8, 143u8, 160u8, 94u8, 248u8, 124u8, 43u8, 224u8, + 165u8, 11u8, 6u8, 176u8, 144u8, 189u8, 161u8, 174u8, 210u8, 56u8, + 225u8, ], ) } @@ -4823,7 +5172,7 @@ pub mod api { &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_balances::AccountData<::core::primitive::u128>, + runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, (), ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, @@ -4833,9 +5182,10 @@ pub mod api { "Account", Vec::new(), [ - 246u8, 154u8, 253u8, 71u8, 192u8, 192u8, 192u8, 236u8, 128u8, 80u8, - 40u8, 252u8, 201u8, 43u8, 3u8, 131u8, 19u8, 49u8, 141u8, 240u8, 172u8, - 217u8, 215u8, 109u8, 87u8, 135u8, 248u8, 57u8, 98u8, 185u8, 22u8, 4u8, + 109u8, 250u8, 18u8, 96u8, 139u8, 232u8, 4u8, 139u8, 133u8, 239u8, 30u8, + 237u8, 73u8, 209u8, 143u8, 160u8, 94u8, 248u8, 124u8, 43u8, 224u8, + 165u8, 11u8, 6u8, 176u8, 144u8, 189u8, 161u8, 174u8, 210u8, 56u8, + 225u8, ], ) } @@ -4846,8 +5196,8 @@ pub mod api { _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::weak_bounded_vec::WeakBoundedVec< - runtime_types::pallet_balances::BalanceLock<::core::primitive::u128>, + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, >, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, @@ -4872,8 +5222,8 @@ pub mod api { &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::weak_bounded_vec::WeakBoundedVec< - runtime_types::pallet_balances::BalanceLock<::core::primitive::u128>, + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, >, (), ::subxt::storage::address::Yes, @@ -4896,8 +5246,8 @@ pub mod api { _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - runtime_types::pallet_balances::ReserveData< + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::ReserveData< [::core::primitive::u8; 8usize], ::core::primitive::u128, >, @@ -4924,8 +5274,8 @@ pub mod api { &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - runtime_types::pallet_balances::ReserveData< + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::ReserveData< [::core::primitive::u8; 8usize], ::core::primitive::u128, >, @@ -4945,27 +5295,113 @@ pub mod api { ], ) } - #[doc = " Storage version of the pallet."] - #[doc = ""] - #[doc = " This is set to v2.0.0 for new networks."] - pub fn storage_version( + #[doc = " Holds on account balances."] + pub fn holds( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_balances::Releases, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::IdAmount< + (), + ::core::primitive::u128, + >, + >, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "Holds", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 247u8, 81u8, 4u8, 220u8, 77u8, 205u8, 28u8, 131u8, 215u8, 74u8, 197u8, + 137u8, 113u8, 214u8, 249u8, 91u8, 81u8, 216u8, 8u8, 5u8, 233u8, 39u8, + 104u8, 250u8, 3u8, 228u8, 148u8, 78u8, 4u8, 34u8, 45u8, 143u8, + ], + ) + } + #[doc = " Holds on account balances."] + pub fn holds_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::IdAmount< + (), + ::core::primitive::u128, + >, + >, (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( "Balances", - "StorageVersion", - vec![], + "Holds", + Vec::new(), + [ + 247u8, 81u8, 4u8, 220u8, 77u8, 205u8, 28u8, 131u8, 215u8, 74u8, 197u8, + 137u8, 113u8, 214u8, 249u8, 91u8, 81u8, 216u8, 8u8, 5u8, 233u8, 39u8, + 104u8, 250u8, 3u8, 228u8, 148u8, 78u8, 4u8, 34u8, 45u8, 143u8, + ], + ) + } + #[doc = " Freeze locks on account balances."] + pub fn freezes( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::IdAmount< + (), + ::core::primitive::u128, + >, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "Freezes", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 135u8, 96u8, 28u8, 234u8, 124u8, 212u8, 56u8, 140u8, 40u8, 101u8, - 235u8, 128u8, 136u8, 221u8, 182u8, 81u8, 17u8, 9u8, 184u8, 228u8, - 174u8, 165u8, 200u8, 162u8, 214u8, 178u8, 227u8, 72u8, 34u8, 5u8, - 173u8, 96u8, + 211u8, 24u8, 237u8, 217u8, 47u8, 230u8, 147u8, 39u8, 112u8, 209u8, + 193u8, 47u8, 242u8, 13u8, 241u8, 0u8, 100u8, 45u8, 116u8, 130u8, 246u8, + 196u8, 50u8, 134u8, 135u8, 112u8, 206u8, 1u8, 12u8, 53u8, 106u8, 131u8, + ], + ) + } + #[doc = " Freeze locks on account balances."] + pub fn freezes_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::IdAmount< + (), + ::core::primitive::u128, + >, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "Freezes", + Vec::new(), + [ + 211u8, 24u8, 237u8, 217u8, 47u8, 230u8, 147u8, 39u8, 112u8, 209u8, + 193u8, 47u8, 242u8, 13u8, 241u8, 0u8, 100u8, 45u8, 116u8, 130u8, 246u8, + 196u8, 50u8, 134u8, 135u8, 112u8, 206u8, 1u8, 12u8, 53u8, 106u8, 131u8, ], ) } @@ -4975,7 +5411,14 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " The minimum amount required to keep an account open."] + #[doc = " The minimum amount required to keep an account open. MUST BE GREATER THAN ZERO!"] + #[doc = ""] + #[doc = " If you *really* need it to be zero, you can enable the feature `insecure_zero_ed` for"] + #[doc = " this pallet. However, you do so at your own risk: this will open up a major DoS vector."] + #[doc = " In case you have multiple sources of provider references, you may also get unexpected"] + #[doc = " behaviour if you set this to zero."] + #[doc = ""] + #[doc = " Bottom line: Do yourself a favour and make it at least one!"] pub fn existential_deposit( &self, ) -> ::subxt::constants::Address<::core::primitive::u128> { @@ -5016,6 +5459,32 @@ pub mod api { ], ) } + #[doc = " The maximum number of holds that can exist on an account at any time."] + pub fn max_holds(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Balances", + "MaxHolds", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The maximum number of individual freeze locks that can exist on an account at any time."] + pub fn max_freezes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Balances", + "MaxFreezes", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } } } } @@ -5140,89 +5609,10 @@ pub mod api { pub mod authorship { use super::root_mod; use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_authorship::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetUncles { - pub new_uncles: ::std::vec::Vec< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - >, - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Provide a set of uncles."] - pub fn set_uncles( - &self, - new_uncles: ::std::vec::Vec< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Authorship", - "set_uncles", - SetUncles { new_uncles }, - [ - 181u8, 70u8, 222u8, 83u8, 154u8, 215u8, 200u8, 64u8, 154u8, 228u8, - 115u8, 247u8, 117u8, 89u8, 229u8, 102u8, 128u8, 189u8, 90u8, 60u8, - 223u8, 19u8, 111u8, 172u8, 5u8, 223u8, 132u8, 37u8, 235u8, 119u8, 42u8, - 64u8, - ], - ) - } - } - } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " Uncles"] - pub fn uncles( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - runtime_types::pallet_authorship::UncleEntryItem< - ::core::primitive::u32, - ::subxt::utils::H256, - ::subxt::utils::AccountId32, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Authorship", - "Uncles", - vec![], - [ - 193u8, 226u8, 196u8, 151u8, 233u8, 82u8, 60u8, 164u8, 27u8, 156u8, - 231u8, 51u8, 79u8, 134u8, 170u8, 166u8, 71u8, 120u8, 250u8, 255u8, - 52u8, 168u8, 74u8, 199u8, 122u8, 253u8, 248u8, 178u8, 39u8, 233u8, - 132u8, 67u8, - ], - ) - } #[doc = " Author of current block."] pub fn author( &self, @@ -5245,50 +5635,6 @@ pub mod api { ], ) } - #[doc = " Whether uncles were already set in this block."] - pub fn did_set_uncles( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Authorship", - "DidSetUncles", - vec![], - [ - 64u8, 3u8, 208u8, 187u8, 50u8, 45u8, 37u8, 88u8, 163u8, 226u8, 37u8, - 126u8, 232u8, 107u8, 156u8, 187u8, 29u8, 15u8, 53u8, 46u8, 28u8, 73u8, - 83u8, 123u8, 14u8, 244u8, 243u8, 43u8, 245u8, 143u8, 15u8, 115u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The number of blocks back we should accept uncles."] - #[doc = " This means that we will deal with uncle-parents that are"] - #[doc = " `UncleGenerations + 1` before `now`."] - pub fn uncle_generations( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Authorship", - "UncleGenerations", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } } } } @@ -5651,6 +5997,19 @@ pub mod api { pub struct ForceApplyMinCommission { pub validator_stash: ::subxt::utils::AccountId32, } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMinCommission { + pub new: runtime_types::sp_arithmetic::per_things::Perbill, + } pub struct TransactionApi; impl TransactionApi { #[doc = "Take the origin account as a stash and lock up `value` of its balance. `controller` will"] @@ -5661,15 +6020,13 @@ pub mod api { #[doc = "The dispatch origin for this call must be _Signed_ by the stash account."] #[doc = ""] #[doc = "Emits `Bonded`."] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- Independent of the arguments. Moderate complexity."] #[doc = "- O(1)."] #[doc = "- Three extra DB entries."] #[doc = ""] #[doc = "NOTE: Two of the storage writes (`Self::bonded`, `Self::payee`) are _never_ cleaned"] #[doc = "unless the `origin` falls below _existential deposit_ and gets removed as dust."] - #[doc = "------------------"] - #[doc = "# "] pub fn bond( &self, controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -5705,10 +6062,9 @@ pub mod api { #[doc = ""] #[doc = "Emits `Bonded`."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- Independent of the arguments. Insignificant complexity."] #[doc = "- O(1)."] - #[doc = "# "] pub fn bond_extra( &self, max_additional: ::core::primitive::u128, @@ -5734,8 +6090,8 @@ pub mod api { #[doc = "the funds out of management ready for transfer."] #[doc = ""] #[doc = "No more than a limited number of unlocking chunks (see `MaxUnlockingChunks`)"] - #[doc = "can co-exists at the same time. In that case, [`Call::withdraw_unbonded`] need"] - #[doc = "to be called first to remove some of the chunks (if possible)."] + #[doc = "can co-exists at the same time. If there are no unlocking chunks slots available"] + #[doc = "[`Call::withdraw_unbonded`] is called to remove some of the chunks (if possible)."] #[doc = ""] #[doc = "If a user encounters the `InsufficientBond` error when calling this extrinsic,"] #[doc = "they should call `chill` first in order to free up their bonded funds."] @@ -5770,10 +6126,9 @@ pub mod api { #[doc = ""] #[doc = "See also [`Call::unbond`]."] #[doc = ""] - #[doc = "# "] - #[doc = "Complexity O(S) where S is the number of slashing spans to remove"] + #[doc = "## Complexity"] + #[doc = "O(S) where S is the number of slashing spans to remove"] #[doc = "NOTE: Weight annotation is the kill scenario, we refund otherwise."] - #[doc = "# "] pub fn withdraw_unbonded( &self, num_slashing_spans: ::core::primitive::u32, @@ -5817,11 +6172,10 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- The transaction's complexity is proportional to the size of `targets` (N)"] #[doc = "which is capped at CompactAssignments::LIMIT (T::MaxNominations)."] #[doc = "- Both the reads and writes follow a similar pattern."] - #[doc = "# "] pub fn nominate( &self, targets: ::std::vec::Vec< @@ -5846,11 +6200,10 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- Independent of the arguments. Insignificant complexity."] #[doc = "- Contains one read."] #[doc = "- Writes are limited to the `origin` account key."] - #[doc = "# "] pub fn chill(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", @@ -5870,16 +6223,12 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- O(1)"] #[doc = "- Independent of the arguments. Insignificant complexity."] #[doc = "- Contains a limited number of reads."] #[doc = "- Writes are limited to the `origin` account key."] #[doc = "---------"] - #[doc = "- Weight: O(1)"] - #[doc = "- DB Weight:"] - #[doc = " - Read: Ledger"] - #[doc = " - Write: Payee"] - #[doc = "# "] pub fn set_payee( &self, payee: runtime_types::pallet_staking::RewardDestination< @@ -5903,16 +6252,11 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin for this call must be _Signed_ by the stash, not the controller."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "O(1)"] #[doc = "- Independent of the arguments. Insignificant complexity."] #[doc = "- Contains a limited number of reads."] #[doc = "- Writes are limited to the `origin` account key."] - #[doc = "----------"] - #[doc = "Weight: O(1)"] - #[doc = "DB Weight:"] - #[doc = "- Read: Bonded, Ledger New Controller, Ledger Old Controller"] - #[doc = "- Write: Bonded, Ledger New Controller, Ledger Old Controller"] - #[doc = "# "] pub fn set_controller( &self, controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -5932,10 +6276,8 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin must be Root."] #[doc = ""] - #[doc = "# "] - #[doc = "Weight: O(1)"] - #[doc = "Write: Validator Count"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "O(1)"] pub fn set_validator_count( &self, new: ::core::primitive::u32, @@ -5956,9 +6298,8 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin must be Root."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "Same as [`Self::set_validator_count`]."] - #[doc = "# "] pub fn increase_validator_count( &self, additional: ::core::primitive::u32, @@ -5979,9 +6320,8 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin must be Root."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "Same as [`Self::set_validator_count`]."] - #[doc = "# "] pub fn scale_validator_count( &self, factor: runtime_types::sp_arithmetic::per_things::Percent, @@ -6008,11 +6348,9 @@ pub mod api { #[doc = "Thus the election process may be ongoing when this is called. In this case the"] #[doc = "election will continue until the next era is triggered."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- No arguments."] #[doc = "- Weight: O(1)"] - #[doc = "- Write: ForceEra"] - #[doc = "# "] pub fn force_no_eras(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", @@ -6036,11 +6374,9 @@ pub mod api { #[doc = "If this is called just before a new era is triggered, the election process may not"] #[doc = "have enough blocks to get a result."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- No arguments."] #[doc = "- Weight: O(1)"] - #[doc = "- Write ForceEra"] - #[doc = "# "] pub fn force_new_era(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", @@ -6118,7 +6454,7 @@ pub mod api { } #[doc = "Cancel enactment of a deferred slash."] #[doc = ""] - #[doc = "Can be called by the `T::SlashCancelOrigin`."] + #[doc = "Can be called by the `T::AdminOrigin`."] #[doc = ""] #[doc = "Parameters: era and indices of the slashes for that era to kill."] pub fn cancel_deferred_slash( @@ -6147,18 +6483,8 @@ pub mod api { #[doc = "The origin of this call must be _Signed_. Any account can call this function, even if"] #[doc = "it is not one of the stakers."] #[doc = ""] - #[doc = "# "] - #[doc = "- Time complexity: at most O(MaxNominatorRewardedPerValidator)."] - #[doc = "- Contains a limited number of reads and writes."] - #[doc = "-----------"] - #[doc = "N is the Number of payouts for the validator (including the validator)"] - #[doc = "Weight:"] - #[doc = "- Reward Destination Staked: O(N)"] - #[doc = "- Reward Destination Controller (Creating): O(N)"] - #[doc = ""] - #[doc = " NOTE: weights are assuming that payouts are made to alive stash account (Staked)."] - #[doc = " Paying even a dead controller is cheaper weight-wise. We don't do any refunds here."] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- At most O(MaxNominatorRewardedPerValidator)."] pub fn payout_stakers( &self, validator_stash: ::subxt::utils::AccountId32, @@ -6182,11 +6508,9 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin must be signed by the controller."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- Time complexity: O(L), where L is unlocking chunks"] #[doc = "- Bounded by `MaxUnlockingChunks`."] - #[doc = "- Storage changes: Can't increase storage, only decrease it."] - #[doc = "# "] pub fn rebond( &self, value: ::core::primitive::u128, @@ -6379,6 +6703,26 @@ pub mod api { ], ) } + #[doc = "Sets the minimum amount of commission that each validators must maintain."] + #[doc = ""] + #[doc = "This call has lower privilege requirements than `set_staking_config` and can be called"] + #[doc = "by the `T::AdminOrigin`. Root can always call this."] + pub fn set_min_commission( + &self, + new: runtime_types::sp_arithmetic::per_things::Perbill, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Staking", + "set_min_commission", + SetMinCommission { new }, + [ + 62u8, 139u8, 175u8, 245u8, 212u8, 113u8, 117u8, 130u8, 191u8, 173u8, + 78u8, 97u8, 19u8, 104u8, 185u8, 207u8, 201u8, 14u8, 200u8, 208u8, + 184u8, 195u8, 242u8, 175u8, 158u8, 156u8, 51u8, 58u8, 118u8, 154u8, + 68u8, 221u8, + ], + ) + } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -6435,7 +6779,7 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "One staker (and potentially its nominators) has been slashed by the given amount."] + #[doc = "A staker (validator or nominator) has been slashed by the given amount."] pub struct Slashed { pub staker: ::subxt::utils::AccountId32, pub amount: ::core::primitive::u128, @@ -6444,6 +6788,27 @@ pub mod api { const PALLET: &'static str = "Staking"; const EVENT: &'static str = "Slashed"; } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A slash for the given validator, for the given percentage of their stake, at the given"] + #[doc = "era as been reported."] + pub struct SlashReported { + pub validator: ::subxt::utils::AccountId32, + pub fraction: runtime_types::sp_arithmetic::per_things::Perbill, + pub slash_era: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for SlashReported { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "SlashReported"; + } #[derive( :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, @@ -6632,6 +6997,24 @@ pub mod api { const PALLET: &'static str = "Staking"; const EVENT: &'static str = "ValidatorPrefsSet"; } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new force era mode was set."] + pub struct ForceEra { + pub mode: runtime_types::pallet_staking::Forcing, + } + impl ::subxt::events::StaticEvent for ForceEra { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "ForceEra"; + } } pub mod storage { use super::runtime_types; @@ -6703,6 +7086,8 @@ pub mod api { ) } #[doc = " Map from all locked \"stash\" accounts to the controller account."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] pub fn bonded( &self, _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, @@ -6727,6 +7112,8 @@ pub mod api { ) } #[doc = " Map from all locked \"stash\" accounts to the controller account."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] pub fn bonded_root( &self, ) -> ::subxt::storage::address::Address< @@ -6789,6 +7176,27 @@ pub mod api { ], ) } + #[doc = " The minimum active nominator stake of the last successful election."] + pub fn minimum_active_stake( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "MinimumActiveStake", + vec![], + [ + 172u8, 190u8, 228u8, 47u8, 47u8, 192u8, 182u8, 59u8, 9u8, 18u8, 103u8, + 46u8, 175u8, 54u8, 17u8, 79u8, 89u8, 107u8, 255u8, 200u8, 182u8, 107u8, + 89u8, 157u8, 55u8, 16u8, 77u8, 46u8, 154u8, 169u8, 103u8, 151u8, + ], + ) + } #[doc = " The minimum amount of commission that validators can set."] #[doc = ""] #[doc = " If set to `0`, no limit exists."] @@ -6860,6 +7268,8 @@ pub mod api { ) } #[doc = " Where the reward payment should be made. Keyed by stash."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] pub fn payee( &self, _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, @@ -6885,6 +7295,8 @@ pub mod api { ) } #[doc = " Where the reward payment should be made. Keyed by stash."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] pub fn payee_root( &self, ) -> ::subxt::storage::address::Address< @@ -6907,6 +7319,8 @@ pub mod api { ) } #[doc = " The map from (wannabe) validator stash key to the preferences of that validator."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] pub fn validators( &self, _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, @@ -6932,6 +7346,8 @@ pub mod api { ) } #[doc = " The map from (wannabe) validator stash key to the preferences of that validator."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] pub fn validators_root( &self, ) -> ::subxt::storage::address::Address< @@ -7013,6 +7429,8 @@ pub mod api { #[doc = ""] #[doc = " Lastly, if any of the nominators become non-decodable, they can be chilled immediately via"] #[doc = " [`Call::chill_other`] dispatchable by anyone."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] pub fn nominators( &self, _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, @@ -7053,6 +7471,8 @@ pub mod api { #[doc = ""] #[doc = " Lastly, if any of the nominators become non-decodable, they can be chilled immediately via"] #[doc = " [`Call::chill_other`] dispatchable by anyone."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] pub fn nominators_root( &self, ) -> ::subxt::storage::address::Address< @@ -7957,30 +8377,6 @@ pub mod api { ], ) } - #[doc = " True if network has been upgraded to this version."] - #[doc = " Storage version of the pallet."] - #[doc = ""] - #[doc = " This is set to v7.0.0 for new networks."] - pub fn storage_version( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::Releases, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "StorageVersion", - vec![], - [ - 70u8, 24u8, 179u8, 189u8, 168u8, 164u8, 175u8, 150u8, 215u8, 43u8, - 18u8, 110u8, 180u8, 137u8, 237u8, 187u8, 185u8, 50u8, 31u8, 57u8, 16u8, - 110u8, 6u8, 170u8, 19u8, 7u8, 160u8, 134u8, 232u8, 227u8, 151u8, 116u8, - ], - ) - } #[doc = " The threshold for when users can start calling `chill_other` for other validators /"] #[doc = " nominators. The threshold is compared to the actual number of validators / nominators"] #[doc = " (`CountFor*`) in the system compared to the configured max (`Max*Count`)."] @@ -8293,63 +8689,6 @@ pub mod api { ], ) } - #[doc = " Enumerates all reports of a kind along with the time they happened."] - #[doc = ""] - #[doc = " All reports are sorted by the time of offence."] - #[doc = ""] - #[doc = " Note that the actual type of this mapping is `Vec`, this is because values of"] - #[doc = " different types are not supported at the moment so we are doing the manual serialization."] - pub fn reports_by_kind_index( - &self, - _0: impl ::std::borrow::Borrow<[::core::primitive::u8; 16usize]>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Offences", - "ReportsByKindIndex", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 162u8, 66u8, 131u8, 48u8, 250u8, 237u8, 179u8, 214u8, 36u8, 137u8, - 226u8, 136u8, 120u8, 61u8, 215u8, 43u8, 164u8, 50u8, 91u8, 164u8, 20u8, - 96u8, 189u8, 100u8, 242u8, 106u8, 21u8, 136u8, 98u8, 215u8, 180u8, - 145u8, - ], - ) - } - #[doc = " Enumerates all reports of a kind along with the time they happened."] - #[doc = ""] - #[doc = " All reports are sorted by the time of offence."] - #[doc = ""] - #[doc = " Note that the actual type of this mapping is `Vec`, this is because values of"] - #[doc = " different types are not supported at the moment so we are doing the manual serialization."] - pub fn reports_by_kind_index_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Offences", - "ReportsByKindIndex", - Vec::new(), - [ - 162u8, 66u8, 131u8, 48u8, 250u8, 237u8, 179u8, 214u8, 36u8, 137u8, - 226u8, 136u8, 120u8, 61u8, 215u8, 43u8, 164u8, 50u8, 91u8, 164u8, 20u8, - 96u8, 189u8, 100u8, 242u8, 106u8, 21u8, 136u8, 98u8, 215u8, 180u8, - 145u8, - ], - ) - } } } } @@ -8400,14 +8739,9 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin of this function must be signed."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(1)`. Actual cost depends on the number of length of"] - #[doc = " `T::Keys::key_ids()` which is fixed."] - #[doc = "- DbReads: `origin account`, `T::ValidatorIdOf`, `NextKeys`"] - #[doc = "- DbWrites: `origin account`, `NextKeys`"] - #[doc = "- DbReads per key id: `KeyOwner`"] - #[doc = "- DbWrites per key id: `KeyOwner`"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- `O(1)`. Actual cost depends on the number of length of `T::Keys::key_ids()` which is"] + #[doc = " fixed."] pub fn set_keys( &self, keys: runtime_types::polkadot_runtime::SessionKeys, @@ -8433,13 +8767,9 @@ pub mod api { #[doc = "means being a controller account) or directly convertible into a validator ID (which"] #[doc = "usually means being a stash account)."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(1)` in number of key types. Actual cost depends on the number of length"] - #[doc = " of `T::Keys::key_ids()` which is fixed."] - #[doc = "- DbReads: `T::ValidatorIdOf`, `NextKeys`, `origin account`"] - #[doc = "- DbWrites: `NextKeys`, `origin account`"] - #[doc = "- DbWrites per key id: `KeyOwner`"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- `O(1)` in number of key types. Actual cost depends on the number of length of"] + #[doc = " `T::Keys::key_ids()` which is fixed."] pub fn purge_keys(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Session", @@ -8720,7 +9050,7 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReportEquivocation { pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_finality_grandpa::EquivocationProof< + runtime_types::sp_consensus_grandpa::EquivocationProof< ::subxt::utils::H256, ::core::primitive::u32, >, @@ -8739,7 +9069,7 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReportEquivocationUnsigned { pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_finality_grandpa::EquivocationProof< + runtime_types::sp_consensus_grandpa::EquivocationProof< ::subxt::utils::H256, ::core::primitive::u32, >, @@ -8768,7 +9098,7 @@ pub mod api { #[doc = "will be reported."] pub fn report_equivocation( &self, - equivocation_proof: runtime_types::sp_finality_grandpa::EquivocationProof< + equivocation_proof: runtime_types::sp_consensus_grandpa::EquivocationProof< ::subxt::utils::H256, ::core::primitive::u32, >, @@ -8799,7 +9129,7 @@ pub mod api { #[doc = "reporter."] pub fn report_equivocation_unsigned( &self, - equivocation_proof: runtime_types::sp_finality_grandpa::EquivocationProof< + equivocation_proof: runtime_types::sp_consensus_grandpa::EquivocationProof< ::subxt::utils::H256, ::core::primitive::u32, >, @@ -8871,7 +9201,7 @@ pub mod api { #[doc = "New authority set has been applied."] pub struct NewAuthorities { pub authority_set: ::std::vec::Vec<( - runtime_types::sp_finality_grandpa::app::Public, + runtime_types::sp_consensus_grandpa::app::Public, ::core::primitive::u64, )>, } @@ -9028,6 +9358,12 @@ pub mod api { #[doc = " A mapping from grandpa set ID to the index of the *most recent* session for which its"] #[doc = " members were responsible."] #[doc = ""] + #[doc = " This is only used for validating equivocation proofs. An equivocation proof must"] + #[doc = " contains a key-ownership proof for a given session, therefore we need a way to tie"] + #[doc = " together sessions and GRANDPA set ids, i.e. we need to validate that a validator"] + #[doc = " was the owner of a given key on a given session, and what the active set ID was"] + #[doc = " during that session."] + #[doc = ""] #[doc = " TWOX-NOTE: `SetId` is not under user control."] pub fn set_id_session( &self, @@ -9056,6 +9392,12 @@ pub mod api { #[doc = " A mapping from grandpa set ID to the index of the *most recent* session for which its"] #[doc = " members were responsible."] #[doc = ""] + #[doc = " This is only used for validating equivocation proofs. An equivocation proof must"] + #[doc = " contains a key-ownership proof for a given session, therefore we need a way to tie"] + #[doc = " together sessions and GRANDPA set ids, i.e. we need to validate that a validator"] + #[doc = " was the owner of a given key on a given session, and what the active set ID was"] + #[doc = " during that session."] + #[doc = ""] #[doc = " TWOX-NOTE: `SetId` is not under user control."] pub fn set_id_session_root( &self, @@ -9099,6 +9441,26 @@ pub mod api { ], ) } + #[doc = " The maximum number of entries to keep in the set id to session index mapping."] + #[doc = ""] + #[doc = " Since the `SetIdSession` map is only used for validating equivocations this"] + #[doc = " value should relate to the bonding duration of whatever staking system is"] + #[doc = " being used (if any). If equivocation handling is not enabled then this value"] + #[doc = " can be zero."] + pub fn max_set_id_session_entries( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u64> { + ::subxt::constants::Address::new_static( + "Grandpa", + "MaxSetIdSessionEntries", + [ + 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, + 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, + 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, + 246u8, + ], + ) + } } } } @@ -9128,15 +9490,11 @@ pub mod api { } pub struct TransactionApi; impl TransactionApi { - #[doc = "# "] - #[doc = "- Complexity: `O(K + E)` where K is length of `Keys` (heartbeat.validators_len) and E is"] - #[doc = " length of `heartbeat.network_state.external_address`"] + #[doc = "## Complexity:"] + #[doc = "- `O(K + E)` where K is length of `Keys` (heartbeat.validators_len) and E is length of"] + #[doc = " `heartbeat.network_state.external_address`"] #[doc = " - `O(K)`: decoding of length `K`"] #[doc = " - `O(E)`: decoding/encoding of length `E`"] - #[doc = "- DbReads: pallet_session `Validators`, pallet_session `CurrentIndex`, `Keys`,"] - #[doc = " `ReceivedHeartbeats`"] - #[doc = "- DbWrites: `ReceivedHeartbeats`"] - #[doc = "# "] pub fn heartbeat( &self, heartbeat: runtime_types::pallet_im_online::Heartbeat<::core::primitive::u32>, @@ -9263,7 +9621,7 @@ pub mod api { &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::weak_bounded_vec::WeakBoundedVec< + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< runtime_types::pallet_im_online::sr25519::app_sr25519::Public, >, ::subxt::storage::address::Yes, @@ -9683,6 +10041,20 @@ pub mod api { #[codec(compact)] pub prop_index: ::core::primitive::u32, } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMetadata { + pub owner: runtime_types::pallet_democracy::types::MetadataOwner, + pub maybe_hash: ::core::option::Option<::subxt::utils::H256>, + } pub struct TransactionApi; impl TransactionApi { #[doc = "Propose a sensitive action to be taken."] @@ -10186,6 +10558,37 @@ pub mod api { ], ) } + #[doc = "Set or clear a metadata of a proposal or a referendum."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `origin`: Must correspond to the `MetadataOwner`."] + #[doc = " - `ExternalOrigin` for an external proposal with the `SuperMajorityApprove`"] + #[doc = " threshold."] + #[doc = " - `ExternalDefaultOrigin` for an external proposal with the `SuperMajorityAgainst`"] + #[doc = " threshold."] + #[doc = " - `ExternalMajorityOrigin` for an external proposal with the `SimpleMajority`"] + #[doc = " threshold."] + #[doc = " - `Signed` by a creator for a public proposal."] + #[doc = " - `Signed` to clear a metadata for a finished referendum."] + #[doc = " - `Root` to set a metadata for an ongoing referendum."] + #[doc = "- `owner`: an identifier of a metadata owner."] + #[doc = "- `maybe_hash`: The hash of an on-chain stored preimage. `None` to clear a metadata."] + pub fn set_metadata( + &self, + owner: runtime_types::pallet_democracy::types::MetadataOwner, + maybe_hash: ::core::option::Option<::subxt::utils::H256>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "set_metadata", + SetMetadata { owner, maybe_hash }, + [ + 182u8, 2u8, 168u8, 244u8, 247u8, 35u8, 65u8, 9u8, 39u8, 164u8, 30u8, + 141u8, 69u8, 137u8, 75u8, 156u8, 158u8, 107u8, 67u8, 28u8, 145u8, 65u8, + 175u8, 30u8, 254u8, 231u8, 4u8, 77u8, 207u8, 166u8, 157u8, 73u8, + ], + ) + } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] @@ -10456,6 +10859,64 @@ pub mod api { const PALLET: &'static str = "Democracy"; const EVENT: &'static str = "ProposalCanceled"; } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Metadata for a proposal or a referendum has been set."] + pub struct MetadataSet { + pub owner: runtime_types::pallet_democracy::types::MetadataOwner, + pub hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for MetadataSet { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "MetadataSet"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Metadata for a proposal or a referendum has been cleared."] + pub struct MetadataCleared { + pub owner: runtime_types::pallet_democracy::types::MetadataOwner, + pub hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for MetadataCleared { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "MetadataCleared"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Metadata has been transferred to new owner."] + pub struct MetadataTransferred { + pub prev_owner: runtime_types::pallet_democracy::types::MetadataOwner, + pub owner: runtime_types::pallet_democracy::types::MetadataOwner, + pub hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for MetadataTransferred { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "MetadataTransferred"; + } } pub mod storage { use super::runtime_types; @@ -10488,7 +10949,7 @@ pub mod api { &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec<( + runtime_types::bounded_collections::bounded_vec::BoundedVec<( ::core::primitive::u32, runtime_types::frame_support::traits::preimages::Bounded< runtime_types::polkadot_runtime::RuntimeCall, @@ -10520,7 +10981,7 @@ pub mod api { ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, ( - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + runtime_types::bounded_collections::bounded_vec::BoundedVec< ::subxt::utils::AccountId32, >, ::core::primitive::u128, @@ -10550,7 +11011,7 @@ pub mod api { ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, ( - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + runtime_types::bounded_collections::bounded_vec::BoundedVec< ::subxt::utils::AccountId32, >, ::core::primitive::u128, @@ -10797,7 +11258,7 @@ pub mod api { ::subxt::storage::address::StaticStorageMapKey, ( ::core::primitive::u32, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + runtime_types::bounded_collections::bounded_vec::BoundedVec< ::subxt::utils::AccountId32, >, ), @@ -10827,7 +11288,7 @@ pub mod api { ::subxt::storage::address::StaticStorageMapKey, ( ::core::primitive::u32, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + runtime_types::bounded_collections::bounded_vec::BoundedVec< ::subxt::utils::AccountId32, >, ), @@ -10894,6 +11355,65 @@ pub mod api { ], ) } + #[doc = " General information concerning any proposal or referendum."] + #[doc = " The `PreimageHash` refers to the preimage of the `Preimages` provider which can be a JSON"] + #[doc = " dump or IPFS hash of a JSON file."] + #[doc = ""] + #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] + #[doc = " large preimages."] + pub fn metadata_of( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::pallet_democracy::types::MetadataOwner, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Democracy", + "MetadataOf", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 157u8, 252u8, 120u8, 151u8, 76u8, 82u8, 189u8, 77u8, 196u8, 65u8, + 113u8, 138u8, 138u8, 57u8, 199u8, 136u8, 22u8, 35u8, 114u8, 144u8, + 172u8, 42u8, 130u8, 19u8, 19u8, 245u8, 76u8, 177u8, 145u8, 146u8, + 107u8, 23u8, + ], + ) + } + #[doc = " General information concerning any proposal or referendum."] + #[doc = " The `PreimageHash` refers to the preimage of the `Preimages` provider which can be a JSON"] + #[doc = " dump or IPFS hash of a JSON file."] + #[doc = ""] + #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] + #[doc = " large preimages."] + pub fn metadata_of_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Democracy", + "MetadataOf", + Vec::new(), + [ + 157u8, 252u8, 120u8, 151u8, 76u8, 82u8, 189u8, 77u8, 196u8, 65u8, + 113u8, 138u8, 138u8, 57u8, 199u8, 136u8, 22u8, 35u8, 114u8, 144u8, + 172u8, 42u8, 130u8, 19u8, 19u8, 245u8, 76u8, 177u8, 145u8, 146u8, + 107u8, 23u8, + ], + ) + } } } pub mod constants { @@ -11166,25 +11686,6 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseOldWeight { - pub proposal_hash: ::subxt::utils::H256, - #[codec(compact)] - pub index: ::core::primitive::u32, - #[codec(compact)] - pub proposal_weight_bound: runtime_types::sp_weights::OldWeight, - #[codec(compact)] - pub length_bound: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct DisapproveProposal { pub proposal_hash: ::subxt::utils::H256, } @@ -11215,7 +11716,7 @@ pub mod api { #[doc = "- `old_count`: The upper bound for the previous number of members in storage. Used for"] #[doc = " weight estimation."] #[doc = ""] - #[doc = "Requires root origin."] + #[doc = "The dispatch of this call must be `SetMembersOrigin`."] #[doc = ""] #[doc = "NOTE: Does not enforce the expected `MaxMembers` limit on the amount of members, but"] #[doc = " the weight estimations rely on it to estimate dispatchable weight."] @@ -11227,19 +11728,11 @@ pub mod api { #[doc = "Any call to `set_members` must be careful that the member set doesn't get out of sync"] #[doc = "with other logic managing the member set."] #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] + #[doc = "## Complexity:"] #[doc = "- `O(MP + N)` where:"] #[doc = " - `M` old-members-count (code- and governance-bounded)"] #[doc = " - `N` new-members-count (code- and governance-bounded)"] #[doc = " - `P` proposals-count (code-bounded)"] - #[doc = "- DB:"] - #[doc = " - 1 storage mutation (codec `O(M)` read, `O(N)` write) for reading and writing the"] - #[doc = " members"] - #[doc = " - 1 storage read (codec `O(P)`) for reading the proposals"] - #[doc = " - `P` storage mutations (codec `O(M)`) for updating the votes for each proposal"] - #[doc = " - 1 storage write (codec `O(1)`) for deleting the old `prime` and setting the new one"] - #[doc = "# "] pub fn set_members( &self, new_members: ::std::vec::Vec<::subxt::utils::AccountId32>, @@ -11266,13 +11759,11 @@ pub mod api { #[doc = ""] #[doc = "Origin must be a member of the collective."] #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] - #[doc = "- `O(M + P)` where `M` members-count (code-bounded) and `P` complexity of dispatching"] - #[doc = " `proposal`"] - #[doc = "- DB: 1 read (codec `O(M)`) + DB access of `proposal`"] - #[doc = "- 1 event"] - #[doc = "# "] + #[doc = "## Complexity:"] + #[doc = "- `O(B + M + P)` where:"] + #[doc = "- `B` is `proposal` size in bytes (length-fee-bounded)"] + #[doc = "- `M` members-count (code-bounded)"] + #[doc = "- `P` complexity of dispatching `proposal`"] pub fn execute( &self, proposal: runtime_types::polkadot_runtime::RuntimeCall, @@ -11286,10 +11777,9 @@ pub mod api { length_bound, }, [ - 207u8, 108u8, 143u8, 240u8, 75u8, 66u8, 184u8, 27u8, 120u8, 174u8, - 60u8, 30u8, 179u8, 210u8, 21u8, 55u8, 253u8, 128u8, 255u8, 184u8, 36u8, - 121u8, 162u8, 148u8, 200u8, 98u8, 165u8, 193u8, 132u8, 20u8, 244u8, - 40u8, + 0u8, 74u8, 70u8, 223u8, 112u8, 196u8, 199u8, 189u8, 93u8, 14u8, 101u8, + 211u8, 221u8, 38u8, 32u8, 220u8, 90u8, 120u8, 94u8, 107u8, 46u8, 121u8, + 250u8, 150u8, 26u8, 24u8, 20u8, 242u8, 253u8, 229u8, 43u8, 195u8, ], ) } @@ -11300,26 +11790,13 @@ pub mod api { #[doc = "`threshold` determines whether `proposal` is executed directly (`threshold < 2`)"] #[doc = "or put up for voting."] #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] + #[doc = "## Complexity"] #[doc = "- `O(B + M + P1)` or `O(B + M + P2)` where:"] #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] #[doc = " - `M` is members-count (code- and governance-bounded)"] #[doc = " - branching is influenced by `threshold` where:"] #[doc = " - `P1` is proposal execution complexity (`threshold < 2`)"] #[doc = " - `P2` is proposals-count (code-bounded) (`threshold >= 2`)"] - #[doc = "- DB:"] - #[doc = " - 1 storage read `is_member` (codec `O(M)`)"] - #[doc = " - 1 storage read `ProposalOf::contains_key` (codec `O(1)`)"] - #[doc = " - DB accesses influenced by `threshold`:"] - #[doc = " - EITHER storage accesses done by `proposal` (`threshold < 2`)"] - #[doc = " - OR proposal insertion (`threshold <= 2`)"] - #[doc = " - 1 storage mutation `Proposals` (codec `O(P2)`)"] - #[doc = " - 1 storage mutation `ProposalCount` (codec `O(1)`)"] - #[doc = " - 1 storage write `ProposalOf` (codec `O(B)`)"] - #[doc = " - 1 storage write `Voting` (codec `O(M)`)"] - #[doc = " - 1 event"] - #[doc = "# "] pub fn propose( &self, threshold: ::core::primitive::u32, @@ -11335,10 +11812,9 @@ pub mod api { length_bound, }, [ - 185u8, 29u8, 21u8, 240u8, 194u8, 157u8, 44u8, 223u8, 201u8, 106u8, - 168u8, 104u8, 111u8, 7u8, 168u8, 17u8, 73u8, 188u8, 70u8, 235u8, 43u8, - 82u8, 236u8, 70u8, 236u8, 94u8, 68u8, 201u8, 201u8, 114u8, 236u8, - 197u8, + 157u8, 103u8, 73u8, 75u8, 15u8, 79u8, 50u8, 64u8, 5u8, 151u8, 194u8, + 216u8, 45u8, 47u8, 128u8, 206u8, 191u8, 52u8, 5u8, 104u8, 70u8, 6u8, + 139u8, 184u8, 12u8, 190u8, 109u8, 132u8, 195u8, 177u8, 197u8, 179u8, ], ) } @@ -11349,14 +11825,8 @@ pub mod api { #[doc = "Transaction fees will be waived if the member is voting on any particular proposal"] #[doc = "for the first time and the call is successful. Subsequent vote changes will charge a"] #[doc = "fee."] - #[doc = "# "] - #[doc = "## Weight"] + #[doc = "## Complexity"] #[doc = "- `O(M)` where `M` is members-count (code- and governance-bounded)"] - #[doc = "- DB:"] - #[doc = " - 1 storage read `Members` (codec `O(M)`)"] - #[doc = " - 1 storage mutation `Voting` (codec `O(M)`)"] - #[doc = "- 1 event"] - #[doc = "# "] pub fn vote( &self, proposal: ::subxt::utils::H256, @@ -11378,61 +11848,6 @@ pub mod api { ], ) } - #[doc = "Close a vote that is either approved, disapproved or whose voting period has ended."] - #[doc = ""] - #[doc = "May be called by any signed account in order to finish voting and close the proposal."] - #[doc = ""] - #[doc = "If called before the end of the voting period it will only close the vote if it is"] - #[doc = "has enough votes to be approved or disapproved."] - #[doc = ""] - #[doc = "If called after the end of the voting period abstentions are counted as rejections"] - #[doc = "unless there is a prime member set and the prime member cast an approval."] - #[doc = ""] - #[doc = "If the close operation completes successfully with disapproval, the transaction fee will"] - #[doc = "be waived. Otherwise execution of the approved operation will be charged to the caller."] - #[doc = ""] - #[doc = "+ `proposal_weight_bound`: The maximum amount of weight consumed by executing the closed"] - #[doc = "proposal."] - #[doc = "+ `length_bound`: The upper bound for the length of the proposal in storage. Checked via"] - #[doc = "`storage::read` so it is `size_of::() == 4` larger than the pure length."] - #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] - #[doc = "- `O(B + M + P1 + P2)` where:"] - #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] - #[doc = " - `M` is members-count (code- and governance-bounded)"] - #[doc = " - `P1` is the complexity of `proposal` preimage."] - #[doc = " - `P2` is proposal-count (code-bounded)"] - #[doc = "- DB:"] - #[doc = " - 2 storage reads (`Members`: codec `O(M)`, `Prime`: codec `O(1)`)"] - #[doc = " - 3 mutations (`Voting`: codec `O(M)`, `ProposalOf`: codec `O(B)`, `Proposals`: codec"] - #[doc = " `O(P2)`)"] - #[doc = " - any mutations done while executing `proposal` (`P1`)"] - #[doc = "- up to 3 events"] - #[doc = "# "] - pub fn close_old_weight( - &self, - proposal_hash: ::subxt::utils::H256, - index: ::core::primitive::u32, - proposal_weight_bound: runtime_types::sp_weights::OldWeight, - length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Council", - "close_old_weight", - CloseOldWeight { - proposal_hash, - index, - proposal_weight_bound, - length_bound, - }, - [ - 133u8, 219u8, 90u8, 40u8, 102u8, 95u8, 4u8, 199u8, 45u8, 234u8, 109u8, - 17u8, 162u8, 63u8, 102u8, 186u8, 95u8, 182u8, 13u8, 123u8, 227u8, 20u8, - 186u8, 207u8, 12u8, 47u8, 87u8, 252u8, 244u8, 172u8, 60u8, 206u8, - ], - ) - } #[doc = "Disapprove a proposal, close, and remove it from the system, regardless of its current"] #[doc = "state."] #[doc = ""] @@ -11441,12 +11856,8 @@ pub mod api { #[doc = "Parameters:"] #[doc = "* `proposal_hash`: The hash of the proposal that should be disapproved."] #[doc = ""] - #[doc = "# "] - #[doc = "Complexity: O(P) where P is the number of max proposals"] - #[doc = "DB Weight:"] - #[doc = "* Reads: Proposals"] - #[doc = "* Writes: Voting, Proposals, ProposalOf"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "O(P) where P is the number of max proposals"] pub fn disapprove_proposal( &self, proposal_hash: ::subxt::utils::H256, @@ -11480,20 +11891,12 @@ pub mod api { #[doc = "+ `length_bound`: The upper bound for the length of the proposal in storage. Checked via"] #[doc = "`storage::read` so it is `size_of::() == 4` larger than the pure length."] #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] + #[doc = "## Complexity"] #[doc = "- `O(B + M + P1 + P2)` where:"] #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] #[doc = " - `M` is members-count (code- and governance-bounded)"] #[doc = " - `P1` is the complexity of `proposal` preimage."] #[doc = " - `P2` is proposal-count (code-bounded)"] - #[doc = "- DB:"] - #[doc = " - 2 storage reads (`Members`: codec `O(M)`, `Prime`: codec `O(1)`)"] - #[doc = " - 3 mutations (`Voting`: codec `O(M)`, `ProposalOf`: codec `O(B)`, `Proposals`: codec"] - #[doc = " `O(P2)`)"] - #[doc = " - any mutations done while executing `proposal` (`P1`)"] - #[doc = "- up to 3 events"] - #[doc = "# "] pub fn close( &self, proposal_hash: ::subxt::utils::H256, @@ -11672,7 +12075,9 @@ pub mod api { &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec<::subxt::utils::H256>, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::H256, + >, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), @@ -11707,10 +12112,9 @@ pub mod api { _0.borrow(), )], [ - 99u8, 114u8, 104u8, 38u8, 106u8, 3u8, 76u8, 17u8, 152u8, 13u8, 170u8, - 109u8, 232u8, 209u8, 208u8, 60u8, 216u8, 48u8, 170u8, 235u8, 241u8, - 25u8, 78u8, 92u8, 141u8, 251u8, 247u8, 253u8, 110u8, 183u8, 61u8, - 225u8, + 6u8, 23u8, 244u8, 48u8, 73u8, 203u8, 222u8, 109u8, 218u8, 166u8, 6u8, + 137u8, 121u8, 88u8, 54u8, 188u8, 37u8, 8u8, 229u8, 217u8, 170u8, 108u8, + 198u8, 66u8, 36u8, 92u8, 107u8, 168u8, 162u8, 204u8, 210u8, 20u8, ], ) } @@ -11729,10 +12133,9 @@ pub mod api { "ProposalOf", Vec::new(), [ - 99u8, 114u8, 104u8, 38u8, 106u8, 3u8, 76u8, 17u8, 152u8, 13u8, 170u8, - 109u8, 232u8, 209u8, 208u8, 60u8, 216u8, 48u8, 170u8, 235u8, 241u8, - 25u8, 78u8, 92u8, 141u8, 251u8, 247u8, 253u8, 110u8, 183u8, 61u8, - 225u8, + 6u8, 23u8, 244u8, 48u8, 73u8, 203u8, 222u8, 109u8, 218u8, 166u8, 6u8, + 137u8, 121u8, 88u8, 54u8, 188u8, 37u8, 8u8, 229u8, 217u8, 170u8, 108u8, + 198u8, 66u8, 36u8, 92u8, 107u8, 168u8, 162u8, 204u8, 210u8, 20u8, ], ) } @@ -11857,6 +12260,28 @@ pub mod api { } } } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The maximum weight of a dispatch call that can be proposed and executed."] + pub fn max_proposal_weight( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "Council", + "MaxProposalWeight", + [ + 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, + 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, + 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, + 106u8, 76u8, + ], + ) + } + } + } } pub mod technical_committee { use super::root_mod; @@ -11941,25 +12366,6 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseOldWeight { - pub proposal_hash: ::subxt::utils::H256, - #[codec(compact)] - pub index: ::core::primitive::u32, - #[codec(compact)] - pub proposal_weight_bound: runtime_types::sp_weights::OldWeight, - #[codec(compact)] - pub length_bound: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct DisapproveProposal { pub proposal_hash: ::subxt::utils::H256, } @@ -11990,7 +12396,7 @@ pub mod api { #[doc = "- `old_count`: The upper bound for the previous number of members in storage. Used for"] #[doc = " weight estimation."] #[doc = ""] - #[doc = "Requires root origin."] + #[doc = "The dispatch of this call must be `SetMembersOrigin`."] #[doc = ""] #[doc = "NOTE: Does not enforce the expected `MaxMembers` limit on the amount of members, but"] #[doc = " the weight estimations rely on it to estimate dispatchable weight."] @@ -12002,19 +12408,11 @@ pub mod api { #[doc = "Any call to `set_members` must be careful that the member set doesn't get out of sync"] #[doc = "with other logic managing the member set."] #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] + #[doc = "## Complexity:"] #[doc = "- `O(MP + N)` where:"] #[doc = " - `M` old-members-count (code- and governance-bounded)"] #[doc = " - `N` new-members-count (code- and governance-bounded)"] #[doc = " - `P` proposals-count (code-bounded)"] - #[doc = "- DB:"] - #[doc = " - 1 storage mutation (codec `O(M)` read, `O(N)` write) for reading and writing the"] - #[doc = " members"] - #[doc = " - 1 storage read (codec `O(P)`) for reading the proposals"] - #[doc = " - `P` storage mutations (codec `O(M)`) for updating the votes for each proposal"] - #[doc = " - 1 storage write (codec `O(1)`) for deleting the old `prime` and setting the new one"] - #[doc = "# "] pub fn set_members( &self, new_members: ::std::vec::Vec<::subxt::utils::AccountId32>, @@ -12041,13 +12439,11 @@ pub mod api { #[doc = ""] #[doc = "Origin must be a member of the collective."] #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] - #[doc = "- `O(M + P)` where `M` members-count (code-bounded) and `P` complexity of dispatching"] - #[doc = " `proposal`"] - #[doc = "- DB: 1 read (codec `O(M)`) + DB access of `proposal`"] - #[doc = "- 1 event"] - #[doc = "# "] + #[doc = "## Complexity:"] + #[doc = "- `O(B + M + P)` where:"] + #[doc = "- `B` is `proposal` size in bytes (length-fee-bounded)"] + #[doc = "- `M` members-count (code-bounded)"] + #[doc = "- `P` complexity of dispatching `proposal`"] pub fn execute( &self, proposal: runtime_types::polkadot_runtime::RuntimeCall, @@ -12061,10 +12457,9 @@ pub mod api { length_bound, }, [ - 207u8, 108u8, 143u8, 240u8, 75u8, 66u8, 184u8, 27u8, 120u8, 174u8, - 60u8, 30u8, 179u8, 210u8, 21u8, 55u8, 253u8, 128u8, 255u8, 184u8, 36u8, - 121u8, 162u8, 148u8, 200u8, 98u8, 165u8, 193u8, 132u8, 20u8, 244u8, - 40u8, + 0u8, 74u8, 70u8, 223u8, 112u8, 196u8, 199u8, 189u8, 93u8, 14u8, 101u8, + 211u8, 221u8, 38u8, 32u8, 220u8, 90u8, 120u8, 94u8, 107u8, 46u8, 121u8, + 250u8, 150u8, 26u8, 24u8, 20u8, 242u8, 253u8, 229u8, 43u8, 195u8, ], ) } @@ -12075,26 +12470,13 @@ pub mod api { #[doc = "`threshold` determines whether `proposal` is executed directly (`threshold < 2`)"] #[doc = "or put up for voting."] #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] + #[doc = "## Complexity"] #[doc = "- `O(B + M + P1)` or `O(B + M + P2)` where:"] #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] #[doc = " - `M` is members-count (code- and governance-bounded)"] #[doc = " - branching is influenced by `threshold` where:"] #[doc = " - `P1` is proposal execution complexity (`threshold < 2`)"] #[doc = " - `P2` is proposals-count (code-bounded) (`threshold >= 2`)"] - #[doc = "- DB:"] - #[doc = " - 1 storage read `is_member` (codec `O(M)`)"] - #[doc = " - 1 storage read `ProposalOf::contains_key` (codec `O(1)`)"] - #[doc = " - DB accesses influenced by `threshold`:"] - #[doc = " - EITHER storage accesses done by `proposal` (`threshold < 2`)"] - #[doc = " - OR proposal insertion (`threshold <= 2`)"] - #[doc = " - 1 storage mutation `Proposals` (codec `O(P2)`)"] - #[doc = " - 1 storage mutation `ProposalCount` (codec `O(1)`)"] - #[doc = " - 1 storage write `ProposalOf` (codec `O(B)`)"] - #[doc = " - 1 storage write `Voting` (codec `O(M)`)"] - #[doc = " - 1 event"] - #[doc = "# "] pub fn propose( &self, threshold: ::core::primitive::u32, @@ -12110,10 +12492,9 @@ pub mod api { length_bound, }, [ - 185u8, 29u8, 21u8, 240u8, 194u8, 157u8, 44u8, 223u8, 201u8, 106u8, - 168u8, 104u8, 111u8, 7u8, 168u8, 17u8, 73u8, 188u8, 70u8, 235u8, 43u8, - 82u8, 236u8, 70u8, 236u8, 94u8, 68u8, 201u8, 201u8, 114u8, 236u8, - 197u8, + 157u8, 103u8, 73u8, 75u8, 15u8, 79u8, 50u8, 64u8, 5u8, 151u8, 194u8, + 216u8, 45u8, 47u8, 128u8, 206u8, 191u8, 52u8, 5u8, 104u8, 70u8, 6u8, + 139u8, 184u8, 12u8, 190u8, 109u8, 132u8, 195u8, 177u8, 197u8, 179u8, ], ) } @@ -12124,14 +12505,8 @@ pub mod api { #[doc = "Transaction fees will be waived if the member is voting on any particular proposal"] #[doc = "for the first time and the call is successful. Subsequent vote changes will charge a"] #[doc = "fee."] - #[doc = "# "] - #[doc = "## Weight"] + #[doc = "## Complexity"] #[doc = "- `O(M)` where `M` is members-count (code- and governance-bounded)"] - #[doc = "- DB:"] - #[doc = " - 1 storage read `Members` (codec `O(M)`)"] - #[doc = " - 1 storage mutation `Voting` (codec `O(M)`)"] - #[doc = "- 1 event"] - #[doc = "# "] pub fn vote( &self, proposal: ::subxt::utils::H256, @@ -12153,61 +12528,6 @@ pub mod api { ], ) } - #[doc = "Close a vote that is either approved, disapproved or whose voting period has ended."] - #[doc = ""] - #[doc = "May be called by any signed account in order to finish voting and close the proposal."] - #[doc = ""] - #[doc = "If called before the end of the voting period it will only close the vote if it is"] - #[doc = "has enough votes to be approved or disapproved."] - #[doc = ""] - #[doc = "If called after the end of the voting period abstentions are counted as rejections"] - #[doc = "unless there is a prime member set and the prime member cast an approval."] - #[doc = ""] - #[doc = "If the close operation completes successfully with disapproval, the transaction fee will"] - #[doc = "be waived. Otherwise execution of the approved operation will be charged to the caller."] - #[doc = ""] - #[doc = "+ `proposal_weight_bound`: The maximum amount of weight consumed by executing the closed"] - #[doc = "proposal."] - #[doc = "+ `length_bound`: The upper bound for the length of the proposal in storage. Checked via"] - #[doc = "`storage::read` so it is `size_of::() == 4` larger than the pure length."] - #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] - #[doc = "- `O(B + M + P1 + P2)` where:"] - #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] - #[doc = " - `M` is members-count (code- and governance-bounded)"] - #[doc = " - `P1` is the complexity of `proposal` preimage."] - #[doc = " - `P2` is proposal-count (code-bounded)"] - #[doc = "- DB:"] - #[doc = " - 2 storage reads (`Members`: codec `O(M)`, `Prime`: codec `O(1)`)"] - #[doc = " - 3 mutations (`Voting`: codec `O(M)`, `ProposalOf`: codec `O(B)`, `Proposals`: codec"] - #[doc = " `O(P2)`)"] - #[doc = " - any mutations done while executing `proposal` (`P1`)"] - #[doc = "- up to 3 events"] - #[doc = "# "] - pub fn close_old_weight( - &self, - proposal_hash: ::subxt::utils::H256, - index: ::core::primitive::u32, - proposal_weight_bound: runtime_types::sp_weights::OldWeight, - length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "TechnicalCommittee", - "close_old_weight", - CloseOldWeight { - proposal_hash, - index, - proposal_weight_bound, - length_bound, - }, - [ - 133u8, 219u8, 90u8, 40u8, 102u8, 95u8, 4u8, 199u8, 45u8, 234u8, 109u8, - 17u8, 162u8, 63u8, 102u8, 186u8, 95u8, 182u8, 13u8, 123u8, 227u8, 20u8, - 186u8, 207u8, 12u8, 47u8, 87u8, 252u8, 244u8, 172u8, 60u8, 206u8, - ], - ) - } #[doc = "Disapprove a proposal, close, and remove it from the system, regardless of its current"] #[doc = "state."] #[doc = ""] @@ -12216,12 +12536,8 @@ pub mod api { #[doc = "Parameters:"] #[doc = "* `proposal_hash`: The hash of the proposal that should be disapproved."] #[doc = ""] - #[doc = "# "] - #[doc = "Complexity: O(P) where P is the number of max proposals"] - #[doc = "DB Weight:"] - #[doc = "* Reads: Proposals"] - #[doc = "* Writes: Voting, Proposals, ProposalOf"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "O(P) where P is the number of max proposals"] pub fn disapprove_proposal( &self, proposal_hash: ::subxt::utils::H256, @@ -12255,20 +12571,12 @@ pub mod api { #[doc = "+ `length_bound`: The upper bound for the length of the proposal in storage. Checked via"] #[doc = "`storage::read` so it is `size_of::() == 4` larger than the pure length."] #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] + #[doc = "## Complexity"] #[doc = "- `O(B + M + P1 + P2)` where:"] #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] #[doc = " - `M` is members-count (code- and governance-bounded)"] #[doc = " - `P1` is the complexity of `proposal` preimage."] #[doc = " - `P2` is proposal-count (code-bounded)"] - #[doc = "- DB:"] - #[doc = " - 2 storage reads (`Members`: codec `O(M)`, `Prime`: codec `O(1)`)"] - #[doc = " - 3 mutations (`Voting`: codec `O(M)`, `ProposalOf`: codec `O(B)`, `Proposals`: codec"] - #[doc = " `O(P2)`)"] - #[doc = " - any mutations done while executing `proposal` (`P1`)"] - #[doc = "- up to 3 events"] - #[doc = "# "] pub fn close( &self, proposal_hash: ::subxt::utils::H256, @@ -12447,7 +12755,9 @@ pub mod api { &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec<::subxt::utils::H256>, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::H256, + >, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), @@ -12482,10 +12792,9 @@ pub mod api { _0.borrow(), )], [ - 99u8, 114u8, 104u8, 38u8, 106u8, 3u8, 76u8, 17u8, 152u8, 13u8, 170u8, - 109u8, 232u8, 209u8, 208u8, 60u8, 216u8, 48u8, 170u8, 235u8, 241u8, - 25u8, 78u8, 92u8, 141u8, 251u8, 247u8, 253u8, 110u8, 183u8, 61u8, - 225u8, + 6u8, 23u8, 244u8, 48u8, 73u8, 203u8, 222u8, 109u8, 218u8, 166u8, 6u8, + 137u8, 121u8, 88u8, 54u8, 188u8, 37u8, 8u8, 229u8, 217u8, 170u8, 108u8, + 198u8, 66u8, 36u8, 92u8, 107u8, 168u8, 162u8, 204u8, 210u8, 20u8, ], ) } @@ -12504,10 +12813,9 @@ pub mod api { "ProposalOf", Vec::new(), [ - 99u8, 114u8, 104u8, 38u8, 106u8, 3u8, 76u8, 17u8, 152u8, 13u8, 170u8, - 109u8, 232u8, 209u8, 208u8, 60u8, 216u8, 48u8, 170u8, 235u8, 241u8, - 25u8, 78u8, 92u8, 141u8, 251u8, 247u8, 253u8, 110u8, 183u8, 61u8, - 225u8, + 6u8, 23u8, 244u8, 48u8, 73u8, 203u8, 222u8, 109u8, 218u8, 166u8, 6u8, + 137u8, 121u8, 88u8, 54u8, 188u8, 37u8, 8u8, 229u8, 217u8, 170u8, 108u8, + 198u8, 66u8, 36u8, 92u8, 107u8, 168u8, 162u8, 204u8, 210u8, 20u8, ], ) } @@ -12632,6 +12940,28 @@ pub mod api { } } } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The maximum weight of a dispatch call that can be proposed and executed."] + pub fn max_proposal_weight( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "TechnicalCommittee", + "MaxProposalWeight", + [ + 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, + 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, + 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, + 106u8, 76u8, + ], + ) + } + } + } } pub mod phragmen_election { use super::root_mod; @@ -12746,10 +13076,6 @@ pub mod api { #[doc = ""] #[doc = "It is the responsibility of the caller to **NOT** place all of their balance into the"] #[doc = "lock and keep some for further operations."] - #[doc = ""] - #[doc = "# "] - #[doc = "We assume the maximum weight among all 3 cases: vote_equal, vote_more and vote_less."] - #[doc = "# "] pub fn vote( &self, votes: ::std::vec::Vec<::subxt::utils::AccountId32>, @@ -12796,9 +13122,9 @@ pub mod api { #[doc = "Even if a candidate ends up being a member, they must call [`Call::renounce_candidacy`]"] #[doc = "to get their deposit back. Losing the spot in an election will always lead to a slash."] #[doc = ""] - #[doc = "# "] #[doc = "The number of current candidates must be provided as witness data."] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "O(C + log(C)) where C is candidate_count."] pub fn submit_candidacy( &self, candidate_count: ::core::primitive::u32, @@ -12828,10 +13154,12 @@ pub mod api { #[doc = " next round."] #[doc = ""] #[doc = "The dispatch origin of this call must be signed, and have one of the above roles."] - #[doc = ""] - #[doc = "# "] #[doc = "The type of renouncing must be provided as witness data."] - #[doc = "# "] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = " - Renouncing::Candidate(count): O(count + log(count))"] + #[doc = " - Renouncing::Member: O(1)"] + #[doc = " - Renouncing::RunnerUp: O(1)"] pub fn renounce_candidacy( &self, renouncing: runtime_types::pallet_elections_phragmen::Renouncing, @@ -12861,10 +13189,8 @@ pub mod api { #[doc = ""] #[doc = "Note that this does not affect the designated block number of the next election."] #[doc = ""] - #[doc = "# "] - #[doc = "If we have a replacement, we use a small weight. Else, since this is a root call and"] - #[doc = "will go into phragmen, we assume full block for now."] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- Check details of remove_and_replace_member() and do_phragmen()."] pub fn remove_member( &self, who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -12893,9 +13219,8 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin of this call must be root."] #[doc = ""] - #[doc = "# "] - #[doc = "The total number of voters and those that are defunct must be provided as witness data."] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- Check is_defunct_voter() details."] pub fn clean_defunct_voters( &self, num_voters: ::core::primitive::u32, @@ -13337,9 +13662,10 @@ pub mod api { } #[doc = " The maximum number of candidates in a phragmen election."] #[doc = ""] - #[doc = " Warning: The election happens onchain, and this value will determine"] - #[doc = " the size of the election. When this limit is reached no more"] - #[doc = " candidates are accepted in the election."] + #[doc = " Warning: This impacts the size of the election which is run onchain. Chose wisely, and"] + #[doc = " consider how it will impact `T::WeightInfo::election_phragmen`."] + #[doc = ""] + #[doc = " When this limit is reached no more candidates are accepted in the election."] pub fn max_candidates( &self, ) -> ::subxt::constants::Address<::core::primitive::u32> { @@ -13356,7 +13682,9 @@ pub mod api { } #[doc = " The maximum number of voters to allow in a phragmen election."] #[doc = ""] - #[doc = " Warning: This impacts the size of the election which is run onchain."] + #[doc = " Warning: This impacts the size of the election which is run onchain. Chose wisely, and"] + #[doc = " consider how it will impact `T::WeightInfo::election_phragmen`."] + #[doc = ""] #[doc = " When the limit is reached the new voters are ignored."] pub fn max_voters(&self) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( @@ -13370,6 +13698,24 @@ pub mod api { ], ) } + #[doc = " Maximum numbers of votes per voter."] + #[doc = ""] + #[doc = " Warning: This impacts the size of the election which is run onchain. Chose wisely, and"] + #[doc = " consider how it will impact `T::WeightInfo::election_phragmen`."] + pub fn max_votes_per_voter( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "PhragmenElection", + "MaxVotesPerVoter", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } } } } @@ -13719,7 +14065,7 @@ pub mod api { &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + runtime_types::bounded_collections::bounded_vec::BoundedVec< ::subxt::utils::AccountId32, >, ::subxt::storage::address::Yes, @@ -13850,11 +14196,8 @@ pub mod api { #[doc = "is reserved and slashed if the proposal is rejected. It is returned once the"] #[doc = "proposal is awarded."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(1)"] - #[doc = "- DbReads: `ProposalCount`, `origin account`"] - #[doc = "- DbWrites: `ProposalCount`, `Proposals`, `origin account`"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- O(1)"] pub fn propose_spend( &self, value: ::core::primitive::u128, @@ -13875,11 +14218,8 @@ pub mod api { #[doc = ""] #[doc = "May only be called from `T::RejectOrigin`."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(1)"] - #[doc = "- DbReads: `Proposals`, `rejected proposer account`"] - #[doc = "- DbWrites: `Proposals`, `rejected proposer account`"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- O(1)"] pub fn reject_proposal( &self, proposal_id: ::core::primitive::u32, @@ -13901,11 +14241,8 @@ pub mod api { #[doc = ""] #[doc = "May only be called from `T::ApproveOrigin`."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(1)."] - #[doc = "- DbReads: `Proposals`, `Approvals`"] - #[doc = "- DbWrite: `Approvals`"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = " - O(1)."] pub fn approve_proposal( &self, proposal_id: ::core::primitive::u32, @@ -13954,10 +14291,8 @@ pub mod api { #[doc = "May only be called from `T::RejectOrigin`."] #[doc = "- `proposal_id`: The index of a proposal"] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(A) where `A` is the number of approvals"] - #[doc = "- Db reads and writes: `Approvals`"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- O(A) where `A` is the number of approvals"] #[doc = ""] #[doc = "Errors:"] #[doc = "- `ProposalNotApproved`: The `proposal_id` supplied was not found in the approval queue,"] @@ -14138,6 +14473,25 @@ pub mod api { const PALLET: &'static str = "Treasury"; const EVENT: &'static str = "SpendApproved"; } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The inactive funds of the pallet have been updated."] + pub struct UpdatedInactive { + pub reactivated: ::core::primitive::u128, + pub deactivated: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for UpdatedInactive { + const PALLET: &'static str = "Treasury"; + const EVENT: &'static str = "UpdatedInactive"; + } } pub mod storage { use super::runtime_types; @@ -14216,12 +14570,33 @@ pub mod api { ], ) } + #[doc = " The amount which has been reported as inactive to Currency."] + pub fn deactivated( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Treasury", + "Deactivated", + vec![], + [ + 159u8, 57u8, 5u8, 85u8, 136u8, 128u8, 70u8, 43u8, 67u8, 76u8, 123u8, + 206u8, 48u8, 253u8, 51u8, 40u8, 14u8, 35u8, 162u8, 173u8, 127u8, 79u8, + 38u8, 235u8, 9u8, 141u8, 201u8, 37u8, 211u8, 176u8, 119u8, 106u8, + ], + ) + } #[doc = " Proposal indices that have been approved but not yet awarded."] pub fn approvals( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + runtime_types::bounded_collections::bounded_vec::BoundedVec< ::core::primitive::u32, >, ::subxt::storage::address::Yes, @@ -14353,11 +14728,11 @@ pub mod api { } } } - pub mod claims { + pub mod conviction_voting { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_common::claims::pallet::Error; + pub type Error = runtime_types::pallet_conviction_voting::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -14373,10 +14748,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Claim { - pub dest: ::subxt::utils::AccountId32, - pub ethereum_signature: - runtime_types::polkadot_runtime_common::claims::EcdsaSignature, + pub struct Vote { + #[codec(compact)] + pub poll_index: ::core::primitive::u32, + pub vote: runtime_types::pallet_conviction_voting::vote::AccountVote< + ::core::primitive::u128, + >, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -14388,19 +14765,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MintClaim { - pub who: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub value: ::core::primitive::u128, - pub vesting_schedule: ::core::option::Option<( - ::core::primitive::u128, - ::core::primitive::u128, - ::core::primitive::u32, - )>, - pub statement: ::core::option::Option< - runtime_types::polkadot_runtime_common::claims::StatementKind, - >, + pub struct Delegate { + pub class: ::core::primitive::u16, + pub to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub conviction: runtime_types::pallet_conviction_voting::conviction::Conviction, + pub balance: ::core::primitive::u128, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -14410,11 +14782,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimAttest { - pub dest: ::subxt::utils::AccountId32, - pub ethereum_signature: - runtime_types::polkadot_runtime_common::claims::EcdsaSignature, - pub statement: ::std::vec::Vec<::core::primitive::u8>, + pub struct Undelegate { + pub class: ::core::primitive::u16, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -14426,8 +14795,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Attest { - pub statement: ::std::vec::Vec<::core::primitive::u8>, + pub struct Unlock { + pub class: ::core::primitive::u16, + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -14439,206 +14809,241 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MoveClaim { - pub old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, + pub struct RemoveVote { + pub class: ::core::option::Option<::core::primitive::u16>, + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveOtherVote { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub class: ::core::primitive::u16, + pub index: ::core::primitive::u32, } pub struct TransactionApi; impl TransactionApi { - #[doc = "Make a claim to collect your DOTs."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _None_."] - #[doc = ""] - #[doc = "Unsigned Validation:"] - #[doc = "A call to claim is deemed valid if the signature provided matches"] - #[doc = "the expected signed message of:"] - #[doc = ""] - #[doc = "> Ethereum Signed Message:"] - #[doc = "> (configured prefix string)(address)"] - #[doc = ""] - #[doc = "and `address` matches the `dest` account."] + #[doc = "Vote in a poll. If `vote.is_aye()`, the vote is to enact the proposal;"] + #[doc = "otherwise it is a vote to keep the status quo."] #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `dest`: The destination account to payout the claim."] - #[doc = "- `ethereum_signature`: The signature of an ethereum signed message"] - #[doc = " matching the format described above."] + #[doc = "The dispatch origin of this call must be _Signed_."] #[doc = ""] - #[doc = ""] - #[doc = "The weight of this call is invariant over the input parameters."] - #[doc = "Weight includes logic to validate unsigned `claim` call."] + #[doc = "- `poll_index`: The index of the poll to vote for."] + #[doc = "- `vote`: The vote configuration."] #[doc = ""] - #[doc = "Total Complexity: O(1)"] - #[doc = ""] - pub fn claim( + #[doc = "Weight: `O(R)` where R is the number of polls the voter has voted on."] + pub fn vote( &self, - dest: ::subxt::utils::AccountId32, - ethereum_signature : runtime_types :: polkadot_runtime_common :: claims :: EcdsaSignature, - ) -> ::subxt::tx::Payload { + poll_index: ::core::primitive::u32, + vote: runtime_types::pallet_conviction_voting::vote::AccountVote< + ::core::primitive::u128, + >, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Claims", - "claim", - Claim { - dest, - ethereum_signature, - }, + "ConvictionVoting", + "vote", + Vote { poll_index, vote }, [ - 33u8, 63u8, 71u8, 104u8, 200u8, 179u8, 248u8, 38u8, 193u8, 198u8, - 250u8, 49u8, 106u8, 26u8, 109u8, 183u8, 33u8, 50u8, 217u8, 28u8, 50u8, - 107u8, 249u8, 80u8, 199u8, 10u8, 192u8, 1u8, 54u8, 41u8, 146u8, 11u8, + 255u8, 8u8, 191u8, 166u8, 7u8, 48u8, 227u8, 0u8, 34u8, 109u8, 3u8, + 172u8, 168u8, 37u8, 220u8, 229u8, 88u8, 61u8, 117u8, 212u8, 131u8, + 124u8, 74u8, 60u8, 83u8, 62u8, 193u8, 66u8, 162u8, 121u8, 76u8, 180u8, ], ) } - #[doc = "Mint a new claim to collect DOTs."] + #[doc = "Delegate the voting power (with some given conviction) of the sending account for a"] + #[doc = "particular class of polls."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Root_."] + #[doc = "The balance delegated is locked for as long as it's delegated, and thereafter for the"] + #[doc = "time appropriate for the conviction's lock period."] #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `who`: The Ethereum address allowed to collect this claim."] - #[doc = "- `value`: The number of DOTs that will be claimed."] - #[doc = "- `vesting_schedule`: An optional vesting schedule for these DOTs."] + #[doc = "The dispatch origin of this call must be _Signed_, and the signing account must either:"] + #[doc = " - be delegating already; or"] + #[doc = " - have no voting activity (if there is, then it will need to be removed/consolidated"] + #[doc = " through `reap_vote` or `unvote`)."] #[doc = ""] - #[doc = ""] - #[doc = "The weight of this call is invariant over the input parameters."] - #[doc = "We assume worst case that both vesting and statement is being inserted."] + #[doc = "- `to`: The account whose voting the `target` account's voting power will follow."] + #[doc = "- `class`: The class of polls to delegate. To delegate multiple classes, multiple calls"] + #[doc = " to this function are required."] + #[doc = "- `conviction`: The conviction that will be attached to the delegated votes. When the"] + #[doc = " account is undelegated, the funds will be locked for the corresponding period."] + #[doc = "- `balance`: The amount of the account's balance to be used in delegating. This must not"] + #[doc = " be more than the account's current balance."] #[doc = ""] - #[doc = "Total Complexity: O(1)"] - #[doc = ""] - pub fn mint_claim( + #[doc = "Emits `Delegated`."] + #[doc = ""] + #[doc = "Weight: `O(R)` where R is the number of polls the voter delegating to has"] + #[doc = " voted on. Weight is initially charged as if maximum votes, but is refunded later."] + pub fn delegate( &self, - who: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - value: ::core::primitive::u128, - vesting_schedule: ::core::option::Option<( - ::core::primitive::u128, - ::core::primitive::u128, - ::core::primitive::u32, - )>, - statement: ::core::option::Option< - runtime_types::polkadot_runtime_common::claims::StatementKind, - >, - ) -> ::subxt::tx::Payload { + class: ::core::primitive::u16, + to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + conviction: runtime_types::pallet_conviction_voting::conviction::Conviction, + balance: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Claims", - "mint_claim", - MintClaim { - who, - value, - vesting_schedule, - statement, + "ConvictionVoting", + "delegate", + Delegate { + class, + to, + conviction, + balance, }, [ - 213u8, 79u8, 204u8, 40u8, 104u8, 84u8, 82u8, 62u8, 193u8, 93u8, 246u8, - 21u8, 37u8, 244u8, 166u8, 132u8, 208u8, 18u8, 86u8, 195u8, 156u8, 9u8, - 220u8, 120u8, 40u8, 183u8, 28u8, 103u8, 84u8, 163u8, 153u8, 110u8, + 241u8, 83u8, 114u8, 135u8, 173u8, 98u8, 8u8, 2u8, 197u8, 164u8, 105u8, + 93u8, 87u8, 243u8, 54u8, 149u8, 10u8, 168u8, 199u8, 211u8, 102u8, + 176u8, 217u8, 244u8, 78u8, 211u8, 124u8, 133u8, 32u8, 28u8, 235u8, + 222u8, ], ) } - #[doc = "Make a claim to collect your DOTs by signing a statement."] + #[doc = "Undelegate the voting power of the sending account for a particular class of polls."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _None_."] + #[doc = "Tokens may be unlocked following once an amount of time consistent with the lock period"] + #[doc = "of the conviction with which the delegation was issued has passed."] #[doc = ""] - #[doc = "Unsigned Validation:"] - #[doc = "A call to `claim_attest` is deemed valid if the signature provided matches"] - #[doc = "the expected signed message of:"] + #[doc = "The dispatch origin of this call must be _Signed_ and the signing account must be"] + #[doc = "currently delegating."] #[doc = ""] - #[doc = "> Ethereum Signed Message:"] - #[doc = "> (configured prefix string)(address)(statement)"] + #[doc = "- `class`: The class of polls to remove the delegation from."] #[doc = ""] - #[doc = "and `address` matches the `dest` account; the `statement` must match that which is"] - #[doc = "expected according to your purchase arrangement."] + #[doc = "Emits `Undelegated`."] #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `dest`: The destination account to payout the claim."] - #[doc = "- `ethereum_signature`: The signature of an ethereum signed message"] - #[doc = " matching the format described above."] - #[doc = "- `statement`: The identity of the statement which is being attested to in the signature."] + #[doc = "Weight: `O(R)` where R is the number of polls the voter delegating to has"] + #[doc = " voted on. Weight is initially charged as if maximum votes, but is refunded later."] + pub fn undelegate( + &self, + class: ::core::primitive::u16, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ConvictionVoting", + "undelegate", + Undelegate { class }, + [ + 0u8, 244u8, 151u8, 108u8, 96u8, 240u8, 126u8, 247u8, 29u8, 33u8, 25u8, + 34u8, 253u8, 207u8, 107u8, 227u8, 139u8, 64u8, 184u8, 112u8, 246u8, + 81u8, 201u8, 41u8, 32u8, 201u8, 194u8, 201u8, 4u8, 170u8, 40u8, 83u8, + ], + ) + } + #[doc = "Remove the lock caused by prior voting/delegating which has expired within a particular"] + #[doc = "class."] #[doc = ""] - #[doc = ""] - #[doc = "The weight of this call is invariant over the input parameters."] - #[doc = "Weight includes logic to validate unsigned `claim_attest` call."] + #[doc = "The dispatch origin of this call must be _Signed_."] #[doc = ""] - #[doc = "Total Complexity: O(1)"] - #[doc = ""] - pub fn claim_attest( + #[doc = "- `class`: The class of polls to unlock."] + #[doc = "- `target`: The account to remove the lock on."] + #[doc = ""] + #[doc = "Weight: `O(R)` with R number of vote of target."] + pub fn unlock( &self, - dest: ::subxt::utils::AccountId32, - ethereum_signature : runtime_types :: polkadot_runtime_common :: claims :: EcdsaSignature, - statement: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + class: ::core::primitive::u16, + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Claims", - "claim_attest", - ClaimAttest { - dest, - ethereum_signature, - statement, - }, + "ConvictionVoting", + "unlock", + Unlock { class, target }, [ - 255u8, 10u8, 87u8, 106u8, 101u8, 195u8, 249u8, 25u8, 109u8, 82u8, - 213u8, 95u8, 203u8, 145u8, 224u8, 113u8, 92u8, 141u8, 31u8, 54u8, - 218u8, 47u8, 218u8, 239u8, 211u8, 206u8, 77u8, 176u8, 19u8, 176u8, - 175u8, 135u8, + 130u8, 244u8, 207u8, 112u8, 194u8, 4u8, 121u8, 4u8, 59u8, 75u8, 168u8, + 246u8, 210u8, 249u8, 247u8, 242u8, 252u8, 28u8, 190u8, 93u8, 11u8, 8u8, + 234u8, 222u8, 22u8, 110u8, 182u8, 252u8, 82u8, 64u8, 74u8, 169u8, ], ) } - #[doc = "Attest to a statement, needed to finalize the claims process."] + #[doc = "Remove a vote for a poll."] #[doc = ""] - #[doc = "WARNING: Insecure unless your chain includes `PrevalidateAttests` as a `SignedExtension`."] + #[doc = "If:"] + #[doc = "- the poll was cancelled, or"] + #[doc = "- the poll is ongoing, or"] + #[doc = "- the poll has ended such that"] + #[doc = " - the vote of the account was in opposition to the result; or"] + #[doc = " - there was no conviction to the account's vote; or"] + #[doc = " - the account made a split vote"] + #[doc = "...then the vote is removed cleanly and a following call to `unlock` may result in more"] + #[doc = "funds being available."] #[doc = ""] - #[doc = "Unsigned Validation:"] - #[doc = "A call to attest is deemed valid if the sender has a `Preclaim` registered"] - #[doc = "and provides a `statement` which is expected for the account."] + #[doc = "If, however, the poll has ended and:"] + #[doc = "- it finished corresponding to the vote of the account, and"] + #[doc = "- the account made a standard vote with conviction, and"] + #[doc = "- the lock period of the conviction is not over"] + #[doc = "...then the lock will be aggregated into the overall account's lock, which may involve"] + #[doc = "*overlocking* (where the two locks are combined into a single lock that is the maximum"] + #[doc = "of both the amount locked and the time is it locked for)."] #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `statement`: The identity of the statement which is being attested to in the signature."] + #[doc = "The dispatch origin of this call must be _Signed_, and the signer must have a vote"] + #[doc = "registered for poll `index`."] #[doc = ""] - #[doc = ""] - #[doc = "The weight of this call is invariant over the input parameters."] - #[doc = "Weight includes logic to do pre-validation on `attest` call."] + #[doc = "- `index`: The index of poll of the vote to be removed."] + #[doc = "- `class`: Optional parameter, if given it indicates the class of the poll. For polls"] + #[doc = " which have finished or are cancelled, this must be `Some`."] #[doc = ""] - #[doc = "Total Complexity: O(1)"] - #[doc = ""] - pub fn attest( + #[doc = "Weight: `O(R + log R)` where R is the number of polls that `target` has voted on."] + #[doc = " Weight is calculated for the maximum number of vote."] + pub fn remove_vote( &self, - statement: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + class: ::core::option::Option<::core::primitive::u16>, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Claims", - "attest", - Attest { statement }, + "ConvictionVoting", + "remove_vote", + RemoveVote { class, index }, [ - 8u8, 218u8, 97u8, 237u8, 185u8, 61u8, 55u8, 4u8, 134u8, 18u8, 244u8, - 226u8, 40u8, 97u8, 222u8, 246u8, 221u8, 74u8, 253u8, 22u8, 52u8, 223u8, - 224u8, 83u8, 21u8, 218u8, 248u8, 100u8, 107u8, 58u8, 247u8, 10u8, + 151u8, 255u8, 135u8, 195u8, 137u8, 27u8, 116u8, 193u8, 245u8, 78u8, + 38u8, 130u8, 233u8, 28u8, 235u8, 50u8, 144u8, 191u8, 39u8, 68u8, 17u8, + 214u8, 25u8, 2u8, 120u8, 14u8, 219u8, 205u8, 59u8, 192u8, 125u8, 142u8, ], ) } - pub fn move_claim( + #[doc = "Remove a vote for a poll."] + #[doc = ""] + #[doc = "If the `target` is equal to the signer, then this function is exactly equivalent to"] + #[doc = "`remove_vote`. If not equal to the signer, then the vote must have expired,"] + #[doc = "either because the poll was cancelled, because the voter lost the poll or"] + #[doc = "because the conviction period is over."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be _Signed_."] + #[doc = ""] + #[doc = "- `target`: The account of the vote to be removed; this account must have voted for poll"] + #[doc = " `index`."] + #[doc = "- `index`: The index of poll of the vote to be removed."] + #[doc = "- `class`: The class of the poll."] + #[doc = ""] + #[doc = "Weight: `O(R + log R)` where R is the number of polls that `target` has voted on."] + #[doc = " Weight is calculated for the maximum number of vote."] + pub fn remove_other_vote( &self, - old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + class: ::core::primitive::u16, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Claims", - "move_claim", - MoveClaim { - old, - new, - maybe_preclaim, + "ConvictionVoting", + "remove_other_vote", + RemoveOtherVote { + target, + class, + index, }, [ - 63u8, 48u8, 217u8, 16u8, 161u8, 102u8, 165u8, 241u8, 57u8, 185u8, - 230u8, 161u8, 202u8, 11u8, 223u8, 15u8, 57u8, 181u8, 34u8, 131u8, - 235u8, 168u8, 227u8, 152u8, 157u8, 4u8, 192u8, 243u8, 194u8, 120u8, - 130u8, 202u8, + 0u8, 148u8, 112u8, 202u8, 220u8, 85u8, 1u8, 77u8, 199u8, 156u8, 47u8, + 38u8, 105u8, 128u8, 71u8, 108u8, 185u8, 231u8, 252u8, 132u8, 37u8, + 114u8, 211u8, 110u8, 142u8, 64u8, 80u8, 90u8, 138u8, 108u8, 59u8, 87u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::polkadot_runtime_common::claims::pallet::Event; + pub type Event = runtime_types::pallet_conviction_voting::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -14651,241 +15056,149 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Someone claimed some DOTs."] - pub struct Claimed { - pub who: ::subxt::utils::AccountId32, - pub ethereum_address: - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub amount: ::core::primitive::u128, + #[doc = "An account has delegated their vote to another account. \\[who, target\\]"] + pub struct Delegated( + pub ::subxt::utils::AccountId32, + pub ::subxt::utils::AccountId32, + ); + impl ::subxt::events::StaticEvent for Delegated { + const PALLET: &'static str = "ConvictionVoting"; + const EVENT: &'static str = "Delegated"; } - impl ::subxt::events::StaticEvent for Claimed { - const PALLET: &'static str = "Claims"; - const EVENT: &'static str = "Claimed"; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An \\[account\\] has cancelled a previous delegation operation."] + pub struct Undelegated(pub ::subxt::utils::AccountId32); + impl ::subxt::events::StaticEvent for Undelegated { + const PALLET: &'static str = "ConvictionVoting"; + const EVENT: &'static str = "Undelegated"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - pub fn claims( + #[doc = " All voting for a particular voter in a particular voting class. We store the balance for the"] + #[doc = " number of votes that we have recorded."] + pub fn voting_for( &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - >, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _1: impl ::std::borrow::Borrow<::core::primitive::u16>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, + runtime_types::pallet_conviction_voting::vote::Voting< + ::core::primitive::u128, + ::subxt::utils::AccountId32, + ::core::primitive::u32, + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Claims", - "Claims", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "ConvictionVoting", + "VotingFor", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], [ - 36u8, 247u8, 169u8, 171u8, 103u8, 176u8, 70u8, 213u8, 255u8, 175u8, - 97u8, 142u8, 231u8, 70u8, 90u8, 213u8, 128u8, 67u8, 50u8, 37u8, 51u8, - 184u8, 72u8, 27u8, 193u8, 254u8, 12u8, 253u8, 91u8, 60u8, 88u8, 182u8, + 45u8, 18u8, 71u8, 145u8, 31u8, 220u8, 221u8, 51u8, 69u8, 73u8, 153u8, + 139u8, 46u8, 231u8, 122u8, 15u8, 98u8, 186u8, 57u8, 121u8, 24u8, 241u8, + 161u8, 150u8, 252u8, 133u8, 65u8, 232u8, 21u8, 28u8, 25u8, 75u8, ], ) } - pub fn claims_root( + #[doc = " All voting for a particular voter in a particular voting class. We store the balance for the"] + #[doc = " number of votes that we have recorded."] + pub fn voting_for_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - (), + runtime_types::pallet_conviction_voting::vote::Voting< + ::core::primitive::u128, + ::subxt::utils::AccountId32, + ::core::primitive::u32, + ::core::primitive::u32, + >, (), ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Claims", - "Claims", + "ConvictionVoting", + "VotingFor", Vec::new(), [ - 36u8, 247u8, 169u8, 171u8, 103u8, 176u8, 70u8, 213u8, 255u8, 175u8, - 97u8, 142u8, 231u8, 70u8, 90u8, 213u8, 128u8, 67u8, 50u8, 37u8, 51u8, - 184u8, 72u8, 27u8, 193u8, 254u8, 12u8, 253u8, 91u8, 60u8, 88u8, 182u8, + 45u8, 18u8, 71u8, 145u8, 31u8, 220u8, 221u8, 51u8, 69u8, 73u8, 153u8, + 139u8, 46u8, 231u8, 122u8, 15u8, 98u8, 186u8, 57u8, 121u8, 24u8, 241u8, + 161u8, 150u8, 252u8, 133u8, 65u8, 232u8, 21u8, 28u8, 25u8, 75u8, ], ) } - pub fn total( + #[doc = " The voting classes which have a non-zero lock requirement and the lock amounts which they"] + #[doc = " require. The actual amount locked on behalf of this pallet should always be the maximum of"] + #[doc = " this list."] + pub fn class_locks_for( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u16, + ::core::primitive::u128, + )>, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), > { ::subxt::storage::address::Address::new_static( - "Claims", - "Total", - vec![], + "ConvictionVoting", + "ClassLocksFor", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 162u8, 59u8, 237u8, 63u8, 23u8, 44u8, 74u8, 169u8, 131u8, 166u8, 174u8, - 61u8, 127u8, 165u8, 32u8, 115u8, 73u8, 171u8, 36u8, 10u8, 6u8, 23u8, - 19u8, 202u8, 3u8, 189u8, 29u8, 169u8, 144u8, 187u8, 235u8, 77u8, + 65u8, 181u8, 225u8, 49u8, 35u8, 141u8, 185u8, 155u8, 124u8, 178u8, + 118u8, 51u8, 220u8, 232u8, 95u8, 24u8, 181u8, 135u8, 42u8, 207u8, + 103u8, 166u8, 244u8, 249u8, 106u8, 96u8, 177u8, 56u8, 243u8, 117u8, + 228u8, 145u8, ], ) } - #[doc = " Vesting schedule for a claim."] - #[doc = " First balance is the total amount that should be held for vesting."] - #[doc = " Second balance is how much should be unlocked per block."] - #[doc = " The block number is when the vesting should start."] - pub fn vesting( + #[doc = " The voting classes which have a non-zero lock requirement and the lock amounts which they"] + #[doc = " require. The actual amount locked on behalf of this pallet should always be the maximum of"] + #[doc = " this list."] + pub fn class_locks_for_root( &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - >, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u128, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u16, ::core::primitive::u128, - ::core::primitive::u32, - ), - ::subxt::storage::address::Yes, + )>, (), ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Claims", - "Vesting", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "ConvictionVoting", + "ClassLocksFor", + Vec::new(), [ - 112u8, 174u8, 151u8, 185u8, 225u8, 170u8, 63u8, 147u8, 100u8, 23u8, - 102u8, 148u8, 244u8, 47u8, 87u8, 99u8, 28u8, 59u8, 48u8, 205u8, 43u8, - 41u8, 87u8, 225u8, 191u8, 164u8, 31u8, 208u8, 80u8, 53u8, 25u8, 205u8, - ], - ) - } - #[doc = " Vesting schedule for a claim."] - #[doc = " First balance is the total amount that should be held for vesting."] - #[doc = " Second balance is how much should be unlocked per block."] - #[doc = " The block number is when the vesting should start."] - pub fn vesting_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u128, - ::core::primitive::u128, - ::core::primitive::u32, - ), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Vesting", - Vec::new(), - [ - 112u8, 174u8, 151u8, 185u8, 225u8, 170u8, 63u8, 147u8, 100u8, 23u8, - 102u8, 148u8, 244u8, 47u8, 87u8, 99u8, 28u8, 59u8, 48u8, 205u8, 43u8, - 41u8, 87u8, 225u8, 191u8, 164u8, 31u8, 208u8, 80u8, 53u8, 25u8, 205u8, - ], - ) - } - #[doc = " The statement kind that must be signed, if any."] - pub fn signing( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::claims::StatementKind, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Signing", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 51u8, 184u8, 211u8, 207u8, 13u8, 194u8, 181u8, 153u8, 25u8, 212u8, - 106u8, 189u8, 149u8, 14u8, 19u8, 61u8, 210u8, 109u8, 23u8, 168u8, - 191u8, 74u8, 112u8, 190u8, 242u8, 112u8, 183u8, 17u8, 30u8, 125u8, - 85u8, 107u8, - ], - ) - } - #[doc = " The statement kind that must be signed, if any."] - pub fn signing_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::claims::StatementKind, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Signing", - Vec::new(), - [ - 51u8, 184u8, 211u8, 207u8, 13u8, 194u8, 181u8, 153u8, 25u8, 212u8, - 106u8, 189u8, 149u8, 14u8, 19u8, 61u8, 210u8, 109u8, 23u8, 168u8, - 191u8, 74u8, 112u8, 190u8, 242u8, 112u8, 183u8, 17u8, 30u8, 125u8, - 85u8, 107u8, - ], - ) - } - #[doc = " Pre-claimed Ethereum accounts, by the Account ID that they are claimed to."] - pub fn preclaims( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Preclaims", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 149u8, 61u8, 170u8, 170u8, 60u8, 212u8, 29u8, 214u8, 141u8, 136u8, - 207u8, 248u8, 51u8, 135u8, 242u8, 105u8, 121u8, 91u8, 186u8, 30u8, 0u8, - 173u8, 154u8, 133u8, 20u8, 244u8, 58u8, 184u8, 133u8, 214u8, 67u8, - 95u8, - ], - ) - } - #[doc = " Pre-claimed Ethereum accounts, by the Account ID that they are claimed to."] - pub fn preclaims_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Preclaims", - Vec::new(), - [ - 149u8, 61u8, 170u8, 170u8, 60u8, 212u8, 29u8, 214u8, 141u8, 136u8, - 207u8, 248u8, 51u8, 135u8, 242u8, 105u8, 121u8, 91u8, 186u8, 30u8, 0u8, - 173u8, 154u8, 133u8, 20u8, 244u8, 58u8, 184u8, 133u8, 214u8, 67u8, - 95u8, + 65u8, 181u8, 225u8, 49u8, 35u8, 141u8, 185u8, 155u8, 124u8, 178u8, + 118u8, 51u8, 220u8, 232u8, 95u8, 24u8, 181u8, 135u8, 42u8, 207u8, + 103u8, 166u8, 244u8, 249u8, 106u8, 96u8, 177u8, 56u8, 243u8, 117u8, + 228u8, 145u8, ], ) } @@ -14895,28 +15208,48 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - pub fn prefix( + #[doc = " The maximum number of concurrent votes an account may have."] + #[doc = ""] + #[doc = " Also used to compute weight, an overly large value can lead to extrinsics with large"] + #[doc = " weight estimation: see `delegate` for instance."] + pub fn max_votes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ConvictionVoting", + "MaxVotes", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The minimum period of vote locking."] + #[doc = ""] + #[doc = " It should be no shorter than enactment period to ensure that in the case of an approval,"] + #[doc = " those successful voters are locked into the consequences that their votes entail."] + pub fn vote_locking_period( &self, - ) -> ::subxt::constants::Address<::std::vec::Vec<::core::primitive::u8>> - { + ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Claims", - "Prefix", + "ConvictionVoting", + "VoteLockingPeriod", [ - 106u8, 50u8, 57u8, 116u8, 43u8, 202u8, 37u8, 248u8, 102u8, 22u8, 62u8, - 22u8, 242u8, 54u8, 152u8, 168u8, 107u8, 64u8, 72u8, 172u8, 124u8, 40u8, - 42u8, 110u8, 104u8, 145u8, 31u8, 144u8, 242u8, 189u8, 145u8, 208u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } } } } - pub mod vesting { + pub mod referenda { use super::root_mod; use super::runtime_types; - #[doc = "Error for the vesting pallet."] - pub type Error = runtime_types::pallet_vesting::pallet::Error; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_referenda::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -14932,8 +15265,18 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vest; + pub struct Submit { + pub proposal_origin: + ::std::boxed::Box, + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + pub enactment_moment: runtime_types::frame_support::traits::schedule::DispatchTime< + ::core::primitive::u32, + >, + } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -14943,10 +15286,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VestOther { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub struct PlaceDecisionDeposit { + pub index: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -14956,14 +15300,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VestedTransfer { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, + pub struct RefundDecisionDeposit { + pub index: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -14973,15 +15314,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceVestedTransfer { - pub source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, + pub struct Cancel { + pub index: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -14991,191 +15328,281 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MergeSchedules { - pub schedule1_index: ::core::primitive::u32, - pub schedule2_index: ::core::primitive::u32, + pub struct Kill { + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct NudgeReferendum { + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OneFewerDeciding { + pub track: ::core::primitive::u16, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RefundSubmissionDeposit { + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMetadata { + pub index: ::core::primitive::u32, + pub maybe_hash: ::core::option::Option<::subxt::utils::H256>, } pub struct TransactionApi; impl TransactionApi { - #[doc = "Unlock any vested funds of the sender account."] + #[doc = "Propose a referendum on a privileged action."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have funds still"] - #[doc = "locked under this pallet."] - #[doc = ""] - #[doc = "Emits either `VestingCompleted` or `VestingUpdated`."] + #[doc = "- `origin`: must be `SubmitOrigin` and the account must have `SubmissionDeposit` funds"] + #[doc = " available."] + #[doc = "- `proposal_origin`: The origin from which the proposal should be executed."] + #[doc = "- `proposal`: The proposal."] + #[doc = "- `enactment_moment`: The moment that the proposal should be enacted."] #[doc = ""] - #[doc = "# "] - #[doc = "- `O(1)`."] - #[doc = "- DbWeight: 2 Reads, 2 Writes"] - #[doc = " - Reads: Vesting Storage, Balances Locks, [Sender Account]"] - #[doc = " - Writes: Vesting Storage, Balances Locks, [Sender Account]"] - #[doc = "# "] - pub fn vest(&self) -> ::subxt::tx::Payload { + #[doc = "Emits `Submitted`."] + pub fn submit( + &self, + proposal_origin: runtime_types::polkadot_runtime::OriginCaller, + proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + enactment_moment: runtime_types::frame_support::traits::schedule::DispatchTime< + ::core::primitive::u32, + >, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Vesting", - "vest", - Vest {}, + "Referenda", + "submit", + Submit { + proposal_origin: ::std::boxed::Box::new(proposal_origin), + proposal, + enactment_moment, + }, [ - 123u8, 54u8, 10u8, 208u8, 154u8, 24u8, 39u8, 166u8, 64u8, 27u8, 74u8, - 29u8, 243u8, 97u8, 155u8, 5u8, 130u8, 155u8, 65u8, 181u8, 196u8, 125u8, - 45u8, 133u8, 25u8, 33u8, 3u8, 34u8, 21u8, 167u8, 172u8, 54u8, + 213u8, 114u8, 86u8, 47u8, 165u8, 41u8, 216u8, 45u8, 93u8, 56u8, 92u8, + 228u8, 10u8, 88u8, 70u8, 82u8, 134u8, 252u8, 214u8, 45u8, 154u8, 150u8, + 221u8, 52u8, 235u8, 186u8, 47u8, 120u8, 221u8, 170u8, 29u8, 239u8, ], ) } - #[doc = "Unlock any vested funds of a `target` account."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "- `target`: The account whose vested funds should be unlocked. Must have funds still"] - #[doc = "locked under this pallet."] + #[doc = "Post the Decision Deposit for a referendum."] #[doc = ""] - #[doc = "Emits either `VestingCompleted` or `VestingUpdated`."] + #[doc = "- `origin`: must be `Signed` and the account must have funds available for the"] + #[doc = " referendum's track's Decision Deposit."] + #[doc = "- `index`: The index of the submitted referendum whose Decision Deposit is yet to be"] + #[doc = " posted."] #[doc = ""] - #[doc = "# "] - #[doc = "- `O(1)`."] - #[doc = "- DbWeight: 3 Reads, 3 Writes"] - #[doc = " - Reads: Vesting Storage, Balances Locks, Target Account"] - #[doc = " - Writes: Vesting Storage, Balances Locks, Target Account"] - #[doc = "# "] - pub fn vest_other( + #[doc = "Emits `DecisionDepositPlaced`."] + pub fn place_decision_deposit( &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Vesting", - "vest_other", - VestOther { target }, + "Referenda", + "place_decision_deposit", + PlaceDecisionDeposit { index }, [ - 164u8, 19u8, 93u8, 81u8, 235u8, 101u8, 18u8, 52u8, 187u8, 81u8, 243u8, - 216u8, 116u8, 84u8, 188u8, 135u8, 1u8, 241u8, 128u8, 90u8, 117u8, - 164u8, 111u8, 0u8, 251u8, 148u8, 250u8, 248u8, 102u8, 79u8, 165u8, - 175u8, + 118u8, 227u8, 8u8, 55u8, 41u8, 171u8, 244u8, 40u8, 164u8, 232u8, 119u8, + 129u8, 139u8, 123u8, 77u8, 70u8, 219u8, 236u8, 145u8, 159u8, 84u8, + 111u8, 36u8, 4u8, 206u8, 5u8, 139u8, 231u8, 11u8, 231u8, 6u8, 30u8, ], ) } - #[doc = "Create a vested transfer."] + #[doc = "Refund the Decision Deposit for a closed referendum back to the depositor."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "- `target`: The account receiving the vested funds."] - #[doc = "- `schedule`: The vesting schedule attached to the transfer."] + #[doc = "- `origin`: must be `Signed` or `Root`."] + #[doc = "- `index`: The index of a closed referendum whose Decision Deposit has not yet been"] + #[doc = " refunded."] #[doc = ""] - #[doc = "Emits `VestingCreated`."] + #[doc = "Emits `DecisionDepositRefunded`."] + pub fn refund_decision_deposit( + &self, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Referenda", + "refund_decision_deposit", + RefundDecisionDeposit { index }, + [ + 120u8, 116u8, 89u8, 51u8, 255u8, 76u8, 150u8, 74u8, 54u8, 93u8, 19u8, + 64u8, 13u8, 177u8, 144u8, 93u8, 132u8, 150u8, 244u8, 48u8, 202u8, + 223u8, 201u8, 130u8, 112u8, 167u8, 29u8, 207u8, 112u8, 181u8, 43u8, + 93u8, + ], + ) + } + #[doc = "Cancel an ongoing referendum."] #[doc = ""] - #[doc = "NOTE: This will unlock all schedules through the current block."] + #[doc = "- `origin`: must be the `CancelOrigin`."] + #[doc = "- `index`: The index of the referendum to be cancelled."] #[doc = ""] - #[doc = "# "] - #[doc = "- `O(1)`."] - #[doc = "- DbWeight: 3 Reads, 3 Writes"] - #[doc = " - Reads: Vesting Storage, Balances Locks, Target Account, [Sender Account]"] - #[doc = " - Writes: Vesting Storage, Balances Locks, Target Account, [Sender Account]"] - #[doc = "# "] - pub fn vested_transfer( + #[doc = "Emits `Cancelled`."] + pub fn cancel( &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - ) -> ::subxt::tx::Payload { + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Vesting", - "vested_transfer", - VestedTransfer { target, schedule }, + "Referenda", + "cancel", + Cancel { index }, [ - 135u8, 172u8, 56u8, 97u8, 45u8, 141u8, 93u8, 173u8, 111u8, 252u8, 75u8, - 246u8, 92u8, 181u8, 138u8, 87u8, 145u8, 174u8, 71u8, 108u8, 126u8, - 118u8, 49u8, 122u8, 249u8, 132u8, 19u8, 2u8, 132u8, 160u8, 247u8, - 195u8, + 247u8, 55u8, 146u8, 211u8, 168u8, 140u8, 248u8, 217u8, 218u8, 235u8, + 25u8, 39u8, 47u8, 132u8, 134u8, 18u8, 239u8, 70u8, 223u8, 50u8, 245u8, + 101u8, 97u8, 39u8, 226u8, 4u8, 196u8, 16u8, 66u8, 177u8, 178u8, 252u8, ], ) } - #[doc = "Force a vested transfer."] + #[doc = "Cancel an ongoing referendum and slash the deposits."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Root_."] + #[doc = "- `origin`: must be the `KillOrigin`."] + #[doc = "- `index`: The index of the referendum to be cancelled."] #[doc = ""] - #[doc = "- `source`: The account whose funds should be transferred."] - #[doc = "- `target`: The account that should be transferred the vested funds."] - #[doc = "- `schedule`: The vesting schedule attached to the transfer."] + #[doc = "Emits `Killed` and `DepositSlashed`."] + pub fn kill(&self, index: ::core::primitive::u32) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Referenda", + "kill", + Kill { index }, + [ + 98u8, 109u8, 143u8, 42u8, 24u8, 80u8, 39u8, 243u8, 249u8, 141u8, 104u8, + 195u8, 29u8, 93u8, 149u8, 37u8, 27u8, 130u8, 84u8, 178u8, 246u8, 26u8, + 113u8, 224u8, 157u8, 94u8, 16u8, 14u8, 158u8, 80u8, 148u8, 198u8, + ], + ) + } + #[doc = "Advance a referendum onto its next logical state. Only used internally."] #[doc = ""] - #[doc = "Emits `VestingCreated`."] + #[doc = "- `origin`: must be `Root`."] + #[doc = "- `index`: the referendum to be advanced."] + pub fn nudge_referendum( + &self, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Referenda", + "nudge_referendum", + NudgeReferendum { index }, + [ + 60u8, 221u8, 153u8, 136u8, 107u8, 209u8, 59u8, 178u8, 208u8, 170u8, + 10u8, 225u8, 213u8, 170u8, 228u8, 64u8, 204u8, 166u8, 7u8, 230u8, + 243u8, 15u8, 206u8, 114u8, 8u8, 128u8, 46u8, 150u8, 114u8, 241u8, + 112u8, 97u8, + ], + ) + } + #[doc = "Advance a track onto its next logical state. Only used internally."] #[doc = ""] - #[doc = "NOTE: This will unlock all schedules through the current block."] + #[doc = "- `origin`: must be `Root`."] + #[doc = "- `track`: the track to be advanced."] #[doc = ""] - #[doc = "# "] - #[doc = "- `O(1)`."] - #[doc = "- DbWeight: 4 Reads, 4 Writes"] - #[doc = " - Reads: Vesting Storage, Balances Locks, Target Account, Source Account"] - #[doc = " - Writes: Vesting Storage, Balances Locks, Target Account, Source Account"] - #[doc = "# "] - pub fn force_vested_transfer( + #[doc = "Action item for when there is now one fewer referendum in the deciding phase and the"] + #[doc = "`DecidingCount` is not yet updated. This means that we should either:"] + #[doc = "- begin deciding another referendum (and leave `DecidingCount` alone); or"] + #[doc = "- decrement `DecidingCount`."] + pub fn one_fewer_deciding( &self, - source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - ) -> ::subxt::tx::Payload { + track: ::core::primitive::u16, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Vesting", - "force_vested_transfer", - ForceVestedTransfer { - source, - target, - schedule, - }, + "Referenda", + "one_fewer_deciding", + OneFewerDeciding { track }, [ - 110u8, 142u8, 63u8, 148u8, 90u8, 229u8, 237u8, 183u8, 240u8, 237u8, - 242u8, 32u8, 88u8, 48u8, 220u8, 101u8, 210u8, 212u8, 27u8, 7u8, 186u8, - 98u8, 28u8, 197u8, 148u8, 140u8, 77u8, 59u8, 202u8, 166u8, 63u8, 97u8, + 239u8, 43u8, 70u8, 73u8, 77u8, 28u8, 75u8, 62u8, 29u8, 67u8, 110u8, + 120u8, 234u8, 236u8, 126u8, 99u8, 46u8, 183u8, 169u8, 16u8, 143u8, + 233u8, 137u8, 247u8, 138u8, 96u8, 32u8, 223u8, 149u8, 52u8, 214u8, + 195u8, ], ) } - #[doc = "Merge two vesting schedules together, creating a new vesting schedule that unlocks over"] - #[doc = "the highest possible start and end blocks. If both schedules have already started the"] - #[doc = "current block will be used as the schedule start; with the caveat that if one schedule"] - #[doc = "is finished by the current block, the other will be treated as the new merged schedule,"] - #[doc = "unmodified."] - #[doc = ""] - #[doc = "NOTE: If `schedule1_index == schedule2_index` this is a no-op."] - #[doc = "NOTE: This will unlock all schedules through the current block prior to merging."] - #[doc = "NOTE: If both schedules have ended by the current block, no new schedule will be created"] - #[doc = "and both will be removed."] + #[doc = "Refund the Submission Deposit for a closed referendum back to the depositor."] #[doc = ""] - #[doc = "Merged schedule attributes:"] - #[doc = "- `starting_block`: `MAX(schedule1.starting_block, scheduled2.starting_block,"] - #[doc = " current_block)`."] - #[doc = "- `ending_block`: `MAX(schedule1.ending_block, schedule2.ending_block)`."] - #[doc = "- `locked`: `schedule1.locked_at(current_block) + schedule2.locked_at(current_block)`."] + #[doc = "- `origin`: must be `Signed` or `Root`."] + #[doc = "- `index`: The index of a closed referendum whose Submission Deposit has not yet been"] + #[doc = " refunded."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "Emits `SubmissionDepositRefunded`."] + pub fn refund_submission_deposit( + &self, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Referenda", + "refund_submission_deposit", + RefundSubmissionDeposit { index }, + [ + 101u8, 147u8, 237u8, 27u8, 220u8, 116u8, 73u8, 131u8, 191u8, 92u8, + 134u8, 31u8, 175u8, 172u8, 129u8, 225u8, 91u8, 33u8, 23u8, 132u8, 89u8, + 19u8, 81u8, 238u8, 133u8, 243u8, 56u8, 70u8, 143u8, 43u8, 176u8, 83u8, + ], + ) + } + #[doc = "Set or clear metadata of a referendum."] #[doc = ""] - #[doc = "- `schedule1_index`: index of the first schedule to merge."] - #[doc = "- `schedule2_index`: index of the second schedule to merge."] - pub fn merge_schedules( + #[doc = "Parameters:"] + #[doc = "- `origin`: Must be `Signed` by a creator of a referendum or by anyone to clear a"] + #[doc = " metadata of a finished referendum."] + #[doc = "- `index`: The index of a referendum to set or clear metadata for."] + #[doc = "- `maybe_hash`: The hash of an on-chain stored preimage. `None` to clear a metadata."] + pub fn set_metadata( &self, - schedule1_index: ::core::primitive::u32, - schedule2_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + index: ::core::primitive::u32, + maybe_hash: ::core::option::Option<::subxt::utils::H256>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Vesting", - "merge_schedules", - MergeSchedules { - schedule1_index, - schedule2_index, - }, + "Referenda", + "set_metadata", + SetMetadata { index, maybe_hash }, [ - 95u8, 255u8, 147u8, 12u8, 49u8, 25u8, 70u8, 112u8, 55u8, 154u8, 183u8, - 97u8, 56u8, 244u8, 148u8, 61u8, 107u8, 163u8, 220u8, 31u8, 153u8, 25u8, - 193u8, 251u8, 131u8, 26u8, 166u8, 157u8, 75u8, 4u8, 110u8, 125u8, + 235u8, 215u8, 66u8, 214u8, 157u8, 177u8, 233u8, 214u8, 103u8, 92u8, + 216u8, 228u8, 7u8, 123u8, 167u8, 225u8, 128u8, 16u8, 161u8, 102u8, + 217u8, 36u8, 80u8, 207u8, 137u8, 24u8, 219u8, 239u8, 42u8, 234u8, + 144u8, 133u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_vesting::pallet::Event; + pub type Event = runtime_types::pallet_referenda::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -15188,15 +15615,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The amount vested has been updated. This could indicate a change in funds available."] - #[doc = "The balance given is the amount which is left unvested (and thus locked)."] - pub struct VestingUpdated { - pub account: ::subxt::utils::AccountId32, - pub unvested: ::core::primitive::u128, + #[doc = "A referendum has been submitted."] + pub struct Submitted { + pub index: ::core::primitive::u32, + pub track: ::core::primitive::u16, + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, } - impl ::subxt::events::StaticEvent for VestingUpdated { - const PALLET: &'static str = "Vesting"; - const EVENT: &'static str = "VestingUpdated"; + impl ::subxt::events::StaticEvent for Submitted { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "Submitted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15208,144 +15637,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An \\[account\\] has become fully vested."] - pub struct VestingCompleted { - pub account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for VestingCompleted { - const PALLET: &'static str = "Vesting"; - const EVENT: &'static str = "VestingCompleted"; + #[doc = "The decision deposit has been placed."] + pub struct DecisionDepositPlaced { + pub index: ::core::primitive::u32, + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Information regarding the vesting of a given account."] - pub fn vesting( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - >, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Vesting", - "Vesting", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 23u8, 209u8, 233u8, 126u8, 89u8, 156u8, 193u8, 204u8, 100u8, 90u8, - 14u8, 120u8, 36u8, 167u8, 148u8, 239u8, 179u8, 74u8, 207u8, 83u8, 54u8, - 77u8, 27u8, 135u8, 74u8, 31u8, 33u8, 11u8, 168u8, 239u8, 212u8, 36u8, - ], - ) - } - #[doc = " Information regarding the vesting of a given account."] - pub fn vesting_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Vesting", - "Vesting", - Vec::new(), - [ - 23u8, 209u8, 233u8, 126u8, 89u8, 156u8, 193u8, 204u8, 100u8, 90u8, - 14u8, 120u8, 36u8, 167u8, 148u8, 239u8, 179u8, 74u8, 207u8, 83u8, 54u8, - 77u8, 27u8, 135u8, 74u8, 31u8, 33u8, 11u8, 168u8, 239u8, 212u8, 36u8, - ], - ) - } - #[doc = " Storage version of the pallet."] - #[doc = ""] - #[doc = " New networks start with latest version, as determined by the genesis build."] - pub fn storage_version( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_vesting::Releases, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Vesting", - "StorageVersion", - vec![], - [ - 50u8, 143u8, 26u8, 88u8, 129u8, 31u8, 61u8, 118u8, 19u8, 202u8, 119u8, - 160u8, 34u8, 219u8, 60u8, 57u8, 189u8, 66u8, 93u8, 239u8, 121u8, 114u8, - 241u8, 116u8, 0u8, 122u8, 232u8, 94u8, 189u8, 23u8, 45u8, 191u8, - ], - ) - } + impl ::subxt::events::StaticEvent for DecisionDepositPlaced { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "DecisionDepositPlaced"; } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The minimum amount transferred to call `vested_transfer`."] - pub fn min_vested_transfer( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Vesting", - "MinVestedTransfer", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - pub fn max_vesting_schedules( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Vesting", - "MaxVestingSchedules", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod utility { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_utility::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -15356,22 +15657,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Batch { - pub calls: ::std::vec::Vec, + #[doc = "The decision deposit has been refunded."] + pub struct DecisionDepositRefunded { + pub index: ::core::primitive::u32, + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsDerivative { - pub index: ::core::primitive::u16, - pub call: ::std::boxed::Box, + impl ::subxt::events::StaticEvent for DecisionDepositRefunded { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "DecisionDepositRefunded"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15383,22 +15677,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BatchAll { - pub calls: ::std::vec::Vec, + #[doc = "A deposit has been slashaed."] + pub struct DepositSlashed { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DispatchAs { - pub as_origin: ::std::boxed::Box, - pub call: ::std::boxed::Box, + impl ::subxt::events::StaticEvent for DepositSlashed { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "DepositSlashed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15410,176 +15696,22 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceBatch { - pub calls: ::std::vec::Vec, + #[doc = "A referendum has moved into the deciding phase."] + pub struct DecisionStarted { + pub index: ::core::primitive::u32, + pub track: ::core::primitive::u16, + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + pub tally: + runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Send a batch of dispatch calls."] - #[doc = ""] - #[doc = "May be called from any origin except `None`."] - #[doc = ""] - #[doc = "- `calls`: The calls to be dispatched from the same origin. The number of call must not"] - #[doc = " exceed the constant: `batched_calls_limit` (available in constant metadata)."] - #[doc = ""] - #[doc = "If origin is root then the calls are dispatched without checking origin filter. (This"] - #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] - #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(C) where C is the number of calls to be batched."] - #[doc = "# "] - #[doc = ""] - #[doc = "This will return `Ok` in all circumstances. To determine the success of the batch, an"] - #[doc = "event is deposited. If a call failed and the batch was interrupted, then the"] - #[doc = "`BatchInterrupted` event is deposited, along with the number of successful calls made"] - #[doc = "and the error of the failed call. If all were successful, then the `BatchCompleted`"] - #[doc = "event is deposited."] - pub fn batch( - &self, - calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "batch", - Batch { calls }, - [ - 243u8, 245u8, 145u8, 160u8, 31u8, 99u8, 157u8, 224u8, 164u8, 104u8, - 116u8, 163u8, 209u8, 121u8, 149u8, 251u8, 122u8, 66u8, 50u8, 7u8, - 190u8, 93u8, 155u8, 159u8, 70u8, 132u8, 23u8, 55u8, 47u8, 202u8, 146u8, - 168u8, - ], - ) - } - #[doc = "Send a call through an indexed pseudonym of the sender."] - #[doc = ""] - #[doc = "Filter from origin are passed along. The call will be dispatched with an origin which"] - #[doc = "use the same filter as the origin of this call."] - #[doc = ""] - #[doc = "NOTE: If you need to ensure that any account-based filtering is not honored (i.e."] - #[doc = "because you expect `proxy` to have been used prior in the call stack and you do not want"] - #[doc = "the call restrictions to apply to any sub-accounts), then use `as_multi_threshold_1`"] - #[doc = "in the Multisig pallet instead."] - #[doc = ""] - #[doc = "NOTE: Prior to version *12, this was called `as_limited_sub`."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - pub fn as_derivative( - &self, - index: ::core::primitive::u16, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "as_derivative", - AsDerivative { - index, - call: ::std::boxed::Box::new(call), - }, - [ - 93u8, 108u8, 41u8, 206u8, 109u8, 149u8, 77u8, 161u8, 27u8, 247u8, - 177u8, 201u8, 245u8, 248u8, 46u8, 53u8, 207u8, 62u8, 10u8, 174u8, - 240u8, 59u8, 186u8, 0u8, 197u8, 135u8, 181u8, 94u8, 1u8, 132u8, 60u8, - 233u8, - ], - ) - } - #[doc = "Send a batch of dispatch calls and atomically execute them."] - #[doc = "The whole transaction will rollback and fail if any of the calls failed."] - #[doc = ""] - #[doc = "May be called from any origin except `None`."] - #[doc = ""] - #[doc = "- `calls`: The calls to be dispatched from the same origin. The number of call must not"] - #[doc = " exceed the constant: `batched_calls_limit` (available in constant metadata)."] - #[doc = ""] - #[doc = "If origin is root then the calls are dispatched without checking origin filter. (This"] - #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] - #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(C) where C is the number of calls to be batched."] - #[doc = "# "] - pub fn batch_all( - &self, - calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "batch_all", - BatchAll { calls }, - [ - 234u8, 106u8, 151u8, 10u8, 11u8, 227u8, 168u8, 197u8, 187u8, 69u8, - 202u8, 14u8, 120u8, 94u8, 156u8, 128u8, 103u8, 185u8, 26u8, 181u8, - 146u8, 249u8, 108u8, 67u8, 142u8, 209u8, 140u8, 208u8, 2u8, 185u8, - 175u8, 223u8, - ], - ) - } - #[doc = "Dispatches a function call with a provided origin."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Root_."] - #[doc = ""] - #[doc = "# "] - #[doc = "- O(1)."] - #[doc = "- Limited storage reads."] - #[doc = "- One DB write (event)."] - #[doc = "- Weight of derivative `call` execution + T::WeightInfo::dispatch_as()."] - #[doc = "# "] - pub fn dispatch_as( - &self, - as_origin: runtime_types::polkadot_runtime::OriginCaller, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "dispatch_as", - DispatchAs { - as_origin: ::std::boxed::Box::new(as_origin), - call: ::std::boxed::Box::new(call), - }, - [ - 148u8, 0u8, 144u8, 26u8, 218u8, 140u8, 68u8, 101u8, 15u8, 56u8, 160u8, - 237u8, 202u8, 222u8, 125u8, 100u8, 209u8, 101u8, 159u8, 117u8, 218u8, - 192u8, 55u8, 235u8, 171u8, 54u8, 86u8, 206u8, 126u8, 188u8, 143u8, - 253u8, - ], - ) - } - #[doc = "Send a batch of dispatch calls."] - #[doc = "Unlike `batch`, it allows errors and won't interrupt."] - #[doc = ""] - #[doc = "May be called from any origin except `None`."] - #[doc = ""] - #[doc = "- `calls`: The calls to be dispatched from the same origin. The number of call must not"] - #[doc = " exceed the constant: `batched_calls_limit` (available in constant metadata)."] - #[doc = ""] - #[doc = "If origin is root then the calls are dispatch without checking origin filter. (This"] - #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] - #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(C) where C is the number of calls to be batched."] - #[doc = "# "] - pub fn force_batch( - &self, - calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "force_batch", - ForceBatch { calls }, - [ - 221u8, 22u8, 196u8, 62u8, 193u8, 137u8, 221u8, 234u8, 195u8, 7u8, - 133u8, 191u8, 243u8, 204u8, 109u8, 46u8, 94u8, 254u8, 31u8, 16u8, - 188u8, 65u8, 160u8, 80u8, 58u8, 202u8, 215u8, 11u8, 99u8, 31u8, 12u8, - 66u8, - ], - ) - } + impl ::subxt::events::StaticEvent for DecisionStarted { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "DecisionStarted"; } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_utility::pallet::Event; - pub mod events { - use super::runtime_types; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -15589,33 +15721,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Batch of dispatches did not complete fully. Index of first failing dispatch given, as"] - #[doc = "well as the error."] - pub struct BatchInterrupted { + pub struct ConfirmStarted { pub index: ::core::primitive::u32, - pub error: runtime_types::sp_runtime::DispatchError, } - impl ::subxt::events::StaticEvent for BatchInterrupted { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "BatchInterrupted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Batch of dispatches completed fully with no error."] - pub struct BatchCompleted; - impl ::subxt::events::StaticEvent for BatchCompleted { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "BatchCompleted"; + impl ::subxt::events::StaticEvent for ConfirmStarted { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "ConfirmStarted"; } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -15625,27 +15739,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Batch of dispatches completed but has errors."] - pub struct BatchCompletedWithErrors; - impl ::subxt::events::StaticEvent for BatchCompletedWithErrors { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "BatchCompletedWithErrors"; + pub struct ConfirmAborted { + pub index: ::core::primitive::u32, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A single item within a Batch of dispatches has completed with no error."] - pub struct ItemCompleted; - impl ::subxt::events::StaticEvent for ItemCompleted { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "ItemCompleted"; + impl ::subxt::events::StaticEvent for ConfirmAborted { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "ConfirmAborted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15657,15 +15756,18 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A single item within a Batch of dispatches has completed with error."] - pub struct ItemFailed { - pub error: runtime_types::sp_runtime::DispatchError, + #[doc = "A referendum has ended its confirmation phase and is ready for approval."] + pub struct Confirmed { + pub index: ::core::primitive::u32, + pub tally: + runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, } - impl ::subxt::events::StaticEvent for ItemFailed { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "ItemFailed"; + impl ::subxt::events::StaticEvent for Confirmed { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "Confirmed"; } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -15675,59 +15777,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A call was dispatched."] - pub struct DispatchedAs { - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for DispatchedAs { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "DispatchedAs"; - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The limit on the number of batched calls."] - pub fn batched_calls_limit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Utility", - "batched_calls_limit", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } + #[doc = "A referendum has been approved and its proposal has been scheduled."] + pub struct Approved { + pub index: ::core::primitive::u32, } - } - } - pub mod identity { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_identity::pallet::Error; - #[doc = "Identity pallet declaration."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddRegistrar { - pub account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + impl ::subxt::events::StaticEvent for Approved { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "Approved"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15739,24 +15795,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetIdentity { - pub info: ::std::boxed::Box, + #[doc = "A proposal has been rejected by referendum."] + pub struct Rejected { + pub index: ::core::primitive::u32, + pub tally: + runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetSubs { - pub subs: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::pallet_identity::types::Data, - )>, + impl ::subxt::events::StaticEvent for Rejected { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "Rejected"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15768,36 +15815,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClearIdentity; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RequestJudgement { - #[codec(compact)] - pub reg_index: ::core::primitive::u32, - #[codec(compact)] - pub max_fee: ::core::primitive::u128, + #[doc = "A referendum has been timed out without being decided."] + pub struct TimedOut { + pub index: ::core::primitive::u32, + pub tally: + runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelRequest { - pub reg_index: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for TimedOut { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "TimedOut"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15809,11 +15835,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetFee { - #[codec(compact)] + #[doc = "A referendum has been cancelled."] + pub struct Cancelled { pub index: ::core::primitive::u32, - #[codec(compact)] - pub fee: ::core::primitive::u128, + pub tally: + runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, + } + impl ::subxt::events::StaticEvent for Cancelled { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "Cancelled"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15825,10 +15855,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetAccountId { - #[codec(compact)] + #[doc = "A referendum has been killed."] + pub struct Killed { pub index: ::core::primitive::u32, - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub tally: + runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, + } + impl ::subxt::events::StaticEvent for Killed { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "Killed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15840,30 +15875,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetFields { - #[codec(compact)] + #[doc = "The submission deposit has been refunded."] + pub struct SubmissionDepositRefunded { pub index: ::core::primitive::u32, - pub fields: runtime_types::pallet_identity::types::BitFlags< - runtime_types::pallet_identity::types::IdentityField, - >, + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProvideJudgement { - #[codec(compact)] - pub reg_index: ::core::primitive::u32, - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub judgement: - runtime_types::pallet_identity::types::Judgement<::core::primitive::u128>, - pub identity: ::subxt::utils::H256, + impl ::subxt::events::StaticEvent for SubmissionDepositRefunded { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "SubmissionDepositRefunded"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15875,22 +15895,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillIdentity { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[doc = "Metadata for a referendum has been set."] + pub struct MetadataSet { + pub index: ::core::primitive::u32, + pub hash: ::subxt::utils::H256, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddSub { - pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub data: runtime_types::pallet_identity::types::Data, + impl ::subxt::events::StaticEvent for MetadataSet { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "MetadataSet"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15902,507 +15914,377 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RenameSub { - pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub data: runtime_types::pallet_identity::types::Data, + #[doc = "Metadata for a referendum has been cleared."] + pub struct MetadataCleared { + pub index: ::core::primitive::u32, + pub hash: ::subxt::utils::H256, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveSub { - pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + impl ::subxt::events::StaticEvent for MetadataCleared { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "MetadataCleared"; } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QuitSub; - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Add a registrar to the system."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be `T::RegistrarOrigin`."] - #[doc = ""] - #[doc = "- `account`: the account of the registrar."] - #[doc = ""] - #[doc = "Emits `RegistrarAdded` if successful."] - #[doc = ""] - #[doc = "# "] - #[doc = "- `O(R)` where `R` registrar-count (governance-bounded and code-bounded)."] - #[doc = "- One storage mutation (codec `O(R)`)."] - #[doc = "- One event."] - #[doc = "# "] - pub fn add_registrar( + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The next free referendum index, aka the number of referenda started so far."] + pub fn referendum_count( &self, - account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "add_registrar", - AddRegistrar { account }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Referenda", + "ReferendumCount", + vec![], [ - 157u8, 232u8, 252u8, 190u8, 203u8, 233u8, 127u8, 63u8, 111u8, 16u8, - 118u8, 200u8, 31u8, 234u8, 144u8, 111u8, 161u8, 224u8, 217u8, 86u8, - 179u8, 254u8, 162u8, 212u8, 248u8, 8u8, 125u8, 89u8, 23u8, 195u8, 4u8, - 231u8, + 153u8, 210u8, 106u8, 244u8, 156u8, 70u8, 124u8, 251u8, 123u8, 75u8, + 7u8, 189u8, 199u8, 145u8, 95u8, 119u8, 137u8, 11u8, 240u8, 160u8, + 151u8, 248u8, 229u8, 231u8, 89u8, 222u8, 18u8, 237u8, 144u8, 78u8, + 99u8, 58u8, ], ) } - #[doc = "Set an account's identity information and reserve the appropriate deposit."] - #[doc = ""] - #[doc = "If the account already has identity information, the deposit is taken as part payment"] - #[doc = "for the new deposit."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "- `info`: The identity information."] - #[doc = ""] - #[doc = "Emits `IdentitySet` if successful."] - #[doc = ""] - #[doc = "# "] - #[doc = "- `O(X + X' + R)`"] - #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)"] - #[doc = " - where `R` judgements-count (registrar-count-bounded)"] - #[doc = "- One balance reserve operation."] - #[doc = "- One storage mutation (codec-read `O(X' + R)`, codec-write `O(X + R)`)."] - #[doc = "- One event."] - #[doc = "# "] - pub fn set_identity( + #[doc = " Information concerning any given referendum."] + pub fn referendum_info_for( &self, - info: runtime_types::pallet_identity::types::IdentityInfo, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_identity", - SetIdentity { - info: ::std::boxed::Box::new(info), - }, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_referenda::types::ReferendumInfo< + ::core::primitive::u16, + runtime_types::polkadot_runtime::OriginCaller, + ::core::primitive::u32, + runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + ::core::primitive::u128, + runtime_types::pallet_conviction_voting::types::Tally< + ::core::primitive::u128, + >, + ::subxt::utils::AccountId32, + (::core::primitive::u32, ::core::primitive::u32), + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Referenda", + "ReferendumInfoFor", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 130u8, 89u8, 118u8, 6u8, 134u8, 166u8, 35u8, 192u8, 73u8, 6u8, 171u8, - 20u8, 225u8, 255u8, 152u8, 142u8, 111u8, 8u8, 206u8, 200u8, 64u8, 52u8, - 110u8, 123u8, 42u8, 101u8, 191u8, 242u8, 133u8, 139u8, 154u8, 205u8, + 180u8, 213u8, 110u8, 2u8, 75u8, 24u8, 34u8, 143u8, 56u8, 197u8, 106u8, + 105u8, 182u8, 118u8, 114u8, 242u8, 48u8, 85u8, 147u8, 22u8, 29u8, + 211u8, 246u8, 127u8, 217u8, 251u8, 208u8, 20u8, 9u8, 84u8, 53u8, 249u8, ], ) } - #[doc = "Set the sub-accounts of the sender."] - #[doc = ""] - #[doc = "Payment: Any aggregate balance reserved by previous `set_subs` calls will be returned"] - #[doc = "and an amount `SubAccountDeposit` will be reserved for each item in `subs`."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] - #[doc = "identity."] - #[doc = ""] - #[doc = "- `subs`: The identity's (new) sub-accounts."] - #[doc = ""] - #[doc = "# "] - #[doc = "- `O(P + S)`"] - #[doc = " - where `P` old-subs-count (hard- and deposit-bounded)."] - #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] - #[doc = "- At most one balance operations."] - #[doc = "- DB:"] - #[doc = " - `P + S` storage mutations (codec complexity `O(1)`)"] - #[doc = " - One storage read (codec complexity `O(P)`)."] - #[doc = " - One storage write (codec complexity `O(S)`)."] - #[doc = " - One storage-exists (`IdentityOf::contains_key`)."] - #[doc = "# "] - pub fn set_subs( + #[doc = " Information concerning any given referendum."] + pub fn referendum_info_for_root( &self, - subs: ::std::vec::Vec<( + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_referenda::types::ReferendumInfo< + ::core::primitive::u16, + runtime_types::polkadot_runtime::OriginCaller, + ::core::primitive::u32, + runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + ::core::primitive::u128, + runtime_types::pallet_conviction_voting::types::Tally< + ::core::primitive::u128, + >, ::subxt::utils::AccountId32, - runtime_types::pallet_identity::types::Data, - )>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_subs", - SetSubs { subs }, - [ - 177u8, 219u8, 84u8, 183u8, 5u8, 32u8, 192u8, 82u8, 174u8, 68u8, 198u8, - 224u8, 56u8, 85u8, 134u8, 171u8, 30u8, 132u8, 140u8, 236u8, 117u8, - 24u8, 150u8, 218u8, 146u8, 194u8, 144u8, 92u8, 103u8, 206u8, 46u8, - 90u8, - ], - ) - } - #[doc = "Clear an account's identity info and all sub-accounts and return all deposits."] - #[doc = ""] - #[doc = "Payment: All reserved balances on the account are returned."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] - #[doc = "identity."] - #[doc = ""] - #[doc = "Emits `IdentityCleared` if successful."] - #[doc = ""] - #[doc = "# "] - #[doc = "- `O(R + S + X)`"] - #[doc = " - where `R` registrar-count (governance-bounded)."] - #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] - #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] - #[doc = "- One balance-unreserve operation."] - #[doc = "- `2` storage reads and `S + 2` storage deletions."] - #[doc = "- One event."] - #[doc = "# "] - pub fn clear_identity(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "clear_identity", - ClearIdentity {}, + (::core::primitive::u32, ::core::primitive::u32), + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Referenda", + "ReferendumInfoFor", + Vec::new(), [ - 75u8, 44u8, 74u8, 122u8, 149u8, 202u8, 114u8, 230u8, 0u8, 255u8, 140u8, - 122u8, 14u8, 196u8, 205u8, 249u8, 220u8, 94u8, 216u8, 34u8, 63u8, 14u8, - 8u8, 205u8, 74u8, 23u8, 181u8, 129u8, 252u8, 110u8, 231u8, 114u8, + 180u8, 213u8, 110u8, 2u8, 75u8, 24u8, 34u8, 143u8, 56u8, 197u8, 106u8, + 105u8, 182u8, 118u8, 114u8, 242u8, 48u8, 85u8, 147u8, 22u8, 29u8, + 211u8, 246u8, 127u8, 217u8, 251u8, 208u8, 20u8, 9u8, 84u8, 53u8, 249u8, ], ) } - #[doc = "Request a judgement from a registrar."] - #[doc = ""] - #[doc = "Payment: At most `max_fee` will be reserved for payment to the registrar if judgement"] - #[doc = "given."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a"] - #[doc = "registered identity."] - #[doc = ""] - #[doc = "- `reg_index`: The index of the registrar whose judgement is requested."] - #[doc = "- `max_fee`: The maximum fee that may be paid. This should just be auto-populated as:"] - #[doc = ""] - #[doc = "```nocompile"] - #[doc = "Self::registrars().get(reg_index).unwrap().fee"] - #[doc = "```"] - #[doc = ""] - #[doc = "Emits `JudgementRequested` if successful."] + #[doc = " The sorted list of referenda ready to be decided but not yet being decided, ordered by"] + #[doc = " conviction-weighted approvals."] #[doc = ""] - #[doc = "# "] - #[doc = "- `O(R + X)`."] - #[doc = "- One balance-reserve operation."] - #[doc = "- Storage: 1 read `O(R)`, 1 mutate `O(X + R)`."] - #[doc = "- One event."] - #[doc = "# "] - pub fn request_judgement( + #[doc = " This should be empty if `DecidingCount` is less than `TrackInfo::max_deciding`."] + pub fn track_queue( &self, - reg_index: ::core::primitive::u32, - max_fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "request_judgement", - RequestJudgement { reg_index, max_fee }, + _0: impl ::std::borrow::Borrow<::core::primitive::u16>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u32, + ::core::primitive::u128, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Referenda", + "TrackQueue", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 186u8, 149u8, 61u8, 54u8, 159u8, 194u8, 77u8, 161u8, 220u8, 157u8, 3u8, - 216u8, 23u8, 105u8, 119u8, 76u8, 144u8, 198u8, 157u8, 45u8, 235u8, - 139u8, 87u8, 82u8, 81u8, 12u8, 25u8, 134u8, 225u8, 92u8, 182u8, 101u8, + 254u8, 82u8, 183u8, 246u8, 168u8, 87u8, 175u8, 224u8, 192u8, 117u8, + 129u8, 244u8, 18u8, 18u8, 249u8, 30u8, 51u8, 133u8, 244u8, 117u8, + 194u8, 174u8, 99u8, 51u8, 155u8, 76u8, 206u8, 202u8, 109u8, 39u8, + 253u8, 240u8, ], ) } - #[doc = "Cancel a previous request."] - #[doc = ""] - #[doc = "Payment: A previously reserved deposit is returned on success."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a"] - #[doc = "registered identity."] + #[doc = " The sorted list of referenda ready to be decided but not yet being decided, ordered by"] + #[doc = " conviction-weighted approvals."] #[doc = ""] - #[doc = "- `reg_index`: The index of the registrar whose judgement is no longer requested."] - #[doc = ""] - #[doc = "Emits `JudgementUnrequested` if successful."] - #[doc = ""] - #[doc = "# "] - #[doc = "- `O(R + X)`."] - #[doc = "- One balance-reserve operation."] - #[doc = "- One storage mutation `O(R + X)`."] - #[doc = "- One event"] - #[doc = "# "] - pub fn cancel_request( + #[doc = " This should be empty if `DecidingCount` is less than `TrackInfo::max_deciding`."] + pub fn track_queue_root( &self, - reg_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "cancel_request", - CancelRequest { reg_index }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u32, + ::core::primitive::u128, + )>, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Referenda", + "TrackQueue", + Vec::new(), [ - 83u8, 180u8, 239u8, 126u8, 32u8, 51u8, 17u8, 20u8, 180u8, 3u8, 59u8, - 96u8, 24u8, 32u8, 136u8, 92u8, 58u8, 254u8, 68u8, 70u8, 50u8, 11u8, - 51u8, 91u8, 180u8, 79u8, 81u8, 84u8, 216u8, 138u8, 6u8, 215u8, + 254u8, 82u8, 183u8, 246u8, 168u8, 87u8, 175u8, 224u8, 192u8, 117u8, + 129u8, 244u8, 18u8, 18u8, 249u8, 30u8, 51u8, 133u8, 244u8, 117u8, + 194u8, 174u8, 99u8, 51u8, 155u8, 76u8, 206u8, 202u8, 109u8, 39u8, + 253u8, 240u8, ], ) } - #[doc = "Set the fee required for a judgement to be requested from a registrar."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] - #[doc = "of the registrar whose index is `index`."] - #[doc = ""] - #[doc = "- `index`: the index of the registrar whose fee is to be set."] - #[doc = "- `fee`: the new fee."] - #[doc = ""] - #[doc = "# "] - #[doc = "- `O(R)`."] - #[doc = "- One storage mutation `O(R)`."] - #[doc = "- Benchmark: 7.315 + R * 0.329 µs (min squares analysis)"] - #[doc = "# "] - pub fn set_fee( + #[doc = " The number of referenda being decided currently."] + pub fn deciding_count( &self, - index: ::core::primitive::u32, - fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_fee", - SetFee { index, fee }, + _0: impl ::std::borrow::Borrow<::core::primitive::u16>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Referenda", + "DecidingCount", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 21u8, 157u8, 123u8, 182u8, 160u8, 190u8, 117u8, 37u8, 136u8, 133u8, - 104u8, 234u8, 31u8, 145u8, 115u8, 154u8, 125u8, 40u8, 2u8, 87u8, 118u8, - 56u8, 247u8, 73u8, 89u8, 0u8, 251u8, 3u8, 58u8, 105u8, 239u8, 211u8, + 101u8, 153u8, 200u8, 225u8, 229u8, 227u8, 232u8, 26u8, 98u8, 60u8, + 60u8, 94u8, 204u8, 195u8, 193u8, 69u8, 50u8, 72u8, 31u8, 250u8, 224u8, + 179u8, 139u8, 207u8, 19u8, 156u8, 67u8, 234u8, 177u8, 223u8, 63u8, + 150u8, ], ) } - #[doc = "Change the account associated with a registrar."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] - #[doc = "of the registrar whose index is `index`."] - #[doc = ""] - #[doc = "- `index`: the index of the registrar whose fee is to be set."] - #[doc = "- `new`: the new account ID."] - #[doc = ""] - #[doc = "# "] - #[doc = "- `O(R)`."] - #[doc = "- One storage mutation `O(R)`."] - #[doc = "- Benchmark: 8.823 + R * 0.32 µs (min squares analysis)"] - #[doc = "# "] - pub fn set_account_id( + #[doc = " The number of referenda being decided currently."] + pub fn deciding_count_root( &self, - index: ::core::primitive::u32, - new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_account_id", - SetAccountId { index, new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Referenda", + "DecidingCount", + Vec::new(), [ - 13u8, 91u8, 36u8, 7u8, 88u8, 64u8, 151u8, 104u8, 94u8, 174u8, 195u8, - 99u8, 97u8, 181u8, 236u8, 251u8, 26u8, 236u8, 234u8, 40u8, 183u8, 38u8, - 220u8, 216u8, 48u8, 115u8, 7u8, 230u8, 216u8, 28u8, 123u8, 11u8, + 101u8, 153u8, 200u8, 225u8, 229u8, 227u8, 232u8, 26u8, 98u8, 60u8, + 60u8, 94u8, 204u8, 195u8, 193u8, 69u8, 50u8, 72u8, 31u8, 250u8, 224u8, + 179u8, 139u8, 207u8, 19u8, 156u8, 67u8, 234u8, 177u8, 223u8, 63u8, + 150u8, ], ) } - #[doc = "Set the field information for a registrar."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] - #[doc = "of the registrar whose index is `index`."] - #[doc = ""] - #[doc = "- `index`: the index of the registrar whose fee is to be set."] - #[doc = "- `fields`: the fields that the registrar concerns themselves with."] + #[doc = " The metadata is a general information concerning the referendum."] + #[doc = " The `PreimageHash` refers to the preimage of the `Preimages` provider which can be a JSON"] + #[doc = " dump or IPFS hash of a JSON file."] #[doc = ""] - #[doc = "# "] - #[doc = "- `O(R)`."] - #[doc = "- One storage mutation `O(R)`."] - #[doc = "- Benchmark: 7.464 + R * 0.325 µs (min squares analysis)"] - #[doc = "# "] - pub fn set_fields( + #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] + #[doc = " large preimages."] + pub fn metadata_of( &self, - index: ::core::primitive::u32, - fields: runtime_types::pallet_identity::types::BitFlags< - runtime_types::pallet_identity::types::IdentityField, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_fields", - SetFields { index, fields }, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Referenda", + "MetadataOf", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 50u8, 196u8, 179u8, 71u8, 66u8, 65u8, 235u8, 7u8, 51u8, 14u8, 81u8, - 173u8, 201u8, 58u8, 6u8, 151u8, 174u8, 245u8, 102u8, 184u8, 28u8, 84u8, - 125u8, 93u8, 126u8, 134u8, 92u8, 203u8, 200u8, 129u8, 240u8, 252u8, + 104u8, 255u8, 134u8, 120u8, 111u8, 124u8, 108u8, 232u8, 61u8, 47u8, + 251u8, 228u8, 50u8, 49u8, 125u8, 229u8, 254u8, 88u8, 215u8, 90u8, + 116u8, 145u8, 111u8, 72u8, 132u8, 91u8, 106u8, 207u8, 13u8, 104u8, + 164u8, 100u8, ], ) } - #[doc = "Provide a judgement for an account's identity."] + #[doc = " The metadata is a general information concerning the referendum."] + #[doc = " The `PreimageHash` refers to the preimage of the `Preimages` provider which can be a JSON"] + #[doc = " dump or IPFS hash of a JSON file."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] - #[doc = "of the registrar whose index is `reg_index`."] - #[doc = ""] - #[doc = "- `reg_index`: the index of the registrar whose judgement is being made."] - #[doc = "- `target`: the account whose identity the judgement is upon. This must be an account"] - #[doc = " with a registered identity."] - #[doc = "- `judgement`: the judgement of the registrar of index `reg_index` about `target`."] - #[doc = "- `identity`: The hash of the [`IdentityInfo`] for that the judgement is provided."] - #[doc = ""] - #[doc = "Emits `JudgementGiven` if successful."] - #[doc = ""] - #[doc = "# "] - #[doc = "- `O(R + X)`."] - #[doc = "- One balance-transfer operation."] - #[doc = "- Up to one account-lookup operation."] - #[doc = "- Storage: 1 read `O(R)`, 1 mutate `O(R + X)`."] - #[doc = "- One event."] - #[doc = "# "] - pub fn provide_judgement( + #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] + #[doc = " large preimages."] + pub fn metadata_of_root( &self, - reg_index: ::core::primitive::u32, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - judgement: runtime_types::pallet_identity::types::Judgement< - ::core::primitive::u128, - >, - identity: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "provide_judgement", - ProvideJudgement { - reg_index, - target, - judgement, - identity, - }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Referenda", + "MetadataOf", + Vec::new(), [ - 147u8, 66u8, 29u8, 90u8, 149u8, 65u8, 161u8, 115u8, 12u8, 254u8, 188u8, - 248u8, 165u8, 115u8, 191u8, 2u8, 167u8, 223u8, 199u8, 169u8, 203u8, - 64u8, 101u8, 217u8, 73u8, 185u8, 93u8, 109u8, 22u8, 184u8, 146u8, 73u8, + 104u8, 255u8, 134u8, 120u8, 111u8, 124u8, 108u8, 232u8, 61u8, 47u8, + 251u8, 228u8, 50u8, 49u8, 125u8, 229u8, 254u8, 88u8, 215u8, 90u8, + 116u8, 145u8, 111u8, 72u8, 132u8, 91u8, 106u8, 207u8, 13u8, 104u8, + 164u8, 100u8, ], ) } - #[doc = "Remove an account's identity and sub-account information and slash the deposits."] - #[doc = ""] - #[doc = "Payment: Reserved balances from `set_subs` and `set_identity` are slashed and handled by"] - #[doc = "`Slash`. Verification request deposits are not returned; they should be cancelled"] - #[doc = "manually using `cancel_request`."] - #[doc = ""] - #[doc = "The dispatch origin for this call must match `T::ForceOrigin`."] - #[doc = ""] - #[doc = "- `target`: the account whose identity the judgement is upon. This must be an account"] - #[doc = " with a registered identity."] - #[doc = ""] - #[doc = "Emits `IdentityKilled` if successful."] - #[doc = ""] - #[doc = "# "] - #[doc = "- `O(R + S + X)`."] - #[doc = "- One balance-reserve operation."] - #[doc = "- `S + 2` storage mutations."] - #[doc = "- One event."] - #[doc = "# "] - pub fn kill_identity( + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The minimum amount to be used as a deposit for a public referendum proposal."] + pub fn submission_deposit( &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "kill_identity", - KillIdentity { target }, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Referenda", + "SubmissionDeposit", [ - 76u8, 13u8, 158u8, 219u8, 221u8, 0u8, 151u8, 241u8, 137u8, 136u8, - 179u8, 194u8, 188u8, 230u8, 56u8, 16u8, 254u8, 28u8, 127u8, 216u8, - 205u8, 117u8, 224u8, 121u8, 240u8, 231u8, 126u8, 181u8, 230u8, 68u8, - 13u8, 174u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = "Add the given account to the sender's subs."] - #[doc = ""] - #[doc = "Payment: Balance reserved by a previous `set_subs` call for one sub will be repatriated"] - #[doc = "to the sender."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] - #[doc = "sub identity of `sub`."] - pub fn add_sub( - &self, - sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - data: runtime_types::pallet_identity::types::Data, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "add_sub", - AddSub { sub, data }, + #[doc = " Maximum size of the referendum queue for a single track."] + pub fn max_queued(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Referenda", + "MaxQueued", [ - 122u8, 218u8, 25u8, 93u8, 33u8, 176u8, 191u8, 254u8, 223u8, 147u8, - 100u8, 135u8, 86u8, 71u8, 47u8, 163u8, 105u8, 222u8, 162u8, 173u8, - 207u8, 182u8, 130u8, 128u8, 214u8, 242u8, 101u8, 250u8, 242u8, 24u8, - 17u8, 84u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Alter the associated name of the given sub-account."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] - #[doc = "sub identity of `sub`."] - pub fn rename_sub( + #[doc = " The number of blocks after submission that a referendum must begin being decided by."] + #[doc = " Once this passes, then anyone may cancel the referendum."] + pub fn undeciding_timeout( &self, - sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - data: runtime_types::pallet_identity::types::Data, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "rename_sub", - RenameSub { sub, data }, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Referenda", + "UndecidingTimeout", [ - 166u8, 167u8, 49u8, 114u8, 199u8, 168u8, 187u8, 221u8, 100u8, 85u8, - 147u8, 211u8, 157u8, 31u8, 109u8, 135u8, 194u8, 135u8, 15u8, 89u8, - 59u8, 57u8, 252u8, 163u8, 9u8, 138u8, 216u8, 189u8, 177u8, 42u8, 96u8, - 34u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Remove the given account from the sender's subs."] - #[doc = ""] - #[doc = "Payment: Balance reserved by a previous `set_subs` call for one sub will be repatriated"] - #[doc = "to the sender."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] - #[doc = "sub identity of `sub`."] - pub fn remove_sub( + #[doc = " Quantization level for the referendum wakeup scheduler. A higher number will result in"] + #[doc = " fewer storage reads/writes needed for smaller voters, but also result in delays to the"] + #[doc = " automatic referendum status changes. Explicit servicing instructions are unaffected."] + pub fn alarm_interval( &self, - sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "remove_sub", - RemoveSub { sub }, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Referenda", + "AlarmInterval", [ - 106u8, 223u8, 210u8, 67u8, 54u8, 11u8, 144u8, 222u8, 42u8, 46u8, 157u8, - 33u8, 13u8, 245u8, 166u8, 195u8, 227u8, 81u8, 224u8, 149u8, 154u8, - 158u8, 187u8, 203u8, 215u8, 91u8, 43u8, 105u8, 69u8, 213u8, 141u8, - 124u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Remove the sender as a sub-account."] - #[doc = ""] - #[doc = "Payment: Balance reserved by a previous `set_subs` call for one sub will be repatriated"] - #[doc = "to the sender (*not* the original depositor)."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] - #[doc = "super-identity."] - #[doc = ""] - #[doc = "NOTE: This should not normally be used, but is provided in the case that the non-"] - #[doc = "controller of an account is maliciously registered as a sub-account."] - pub fn quit_sub(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "quit_sub", - QuitSub {}, + #[doc = " Information concerning the different referendum tracks."] + pub fn tracks( + &self, + ) -> ::subxt::constants::Address< + ::std::vec::Vec<( + ::core::primitive::u16, + runtime_types::pallet_referenda::types::TrackInfo< + ::core::primitive::u128, + ::core::primitive::u32, + >, + )>, + > { + ::subxt::constants::Address::new_static( + "Referenda", + "Tracks", [ - 62u8, 57u8, 73u8, 72u8, 119u8, 216u8, 250u8, 155u8, 57u8, 169u8, 157u8, - 44u8, 87u8, 51u8, 63u8, 231u8, 77u8, 7u8, 0u8, 119u8, 244u8, 42u8, - 179u8, 51u8, 254u8, 240u8, 55u8, 25u8, 142u8, 38u8, 87u8, 44u8, + 71u8, 253u8, 246u8, 54u8, 168u8, 190u8, 182u8, 15u8, 207u8, 26u8, 50u8, + 138u8, 212u8, 124u8, 13u8, 203u8, 27u8, 35u8, 224u8, 1u8, 176u8, 192u8, + 197u8, 220u8, 147u8, 94u8, 196u8, 150u8, 125u8, 23u8, 48u8, 255u8, ], ) } } } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_identity::pallet::Event; - pub mod events { + } + pub mod whitelist { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_whitelist::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -16413,32 +16295,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A name was set or reset (which will remove all judgements)."] - pub struct IdentitySet { - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for IdentitySet { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "IdentitySet"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A name was cleared, and the given balance returned."] - pub struct IdentityCleared { - pub who: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for IdentityCleared { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "IdentityCleared"; + pub struct WhitelistCall { + pub call_hash: ::subxt::utils::H256, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -16450,14 +16308,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A name was removed and the given balance slashed."] - pub struct IdentityKilled { - pub who: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for IdentityKilled { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "IdentityKilled"; + pub struct RemoveWhitelistedCall { + pub call_hash: ::subxt::utils::H256, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -16469,14 +16321,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A judgement was asked from a registrar."] - pub struct JudgementRequested { - pub who: ::subxt::utils::AccountId32, - pub registrar_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for JudgementRequested { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "JudgementRequested"; + pub struct DispatchWhitelistedCall { + pub call_hash: ::subxt::utils::H256, + pub call_encoded_len: ::core::primitive::u32, + pub call_weight_witness: runtime_types::sp_weights::weight_v2::Weight, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -16488,53 +16336,87 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A judgement request was retracted."] - pub struct JudgementUnrequested { - pub who: ::subxt::utils::AccountId32, - pub registrar_index: ::core::primitive::u32, + pub struct DispatchWhitelistedCallWithPreimage { + pub call: ::std::boxed::Box, } - impl ::subxt::events::StaticEvent for JudgementUnrequested { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "JudgementUnrequested"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A judgement was given by a registrar."] - pub struct JudgementGiven { - pub target: ::subxt::utils::AccountId32, - pub registrar_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for JudgementGiven { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "JudgementGiven"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A registrar was added."] - pub struct RegistrarAdded { - pub registrar_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for RegistrarAdded { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "RegistrarAdded"; + pub struct TransactionApi; + impl TransactionApi { + pub fn whitelist_call( + &self, + call_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Whitelist", + "whitelist_call", + WhitelistCall { call_hash }, + [ + 21u8, 246u8, 244u8, 176u8, 163u8, 80u8, 45u8, 191u8, 3u8, 180u8, 150u8, + 66u8, 168u8, 3u8, 196u8, 129u8, 177u8, 104u8, 48u8, 5u8, 201u8, 208u8, + 226u8, 76u8, 148u8, 116u8, 206u8, 119u8, 145u8, 78u8, 86u8, 41u8, + ], + ) + } + pub fn remove_whitelisted_call( + &self, + call_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Whitelist", + "remove_whitelisted_call", + RemoveWhitelistedCall { call_hash }, + [ + 142u8, 227u8, 198u8, 110u8, 90u8, 127u8, 218u8, 117u8, 181u8, 209u8, + 210u8, 86u8, 133u8, 95u8, 244u8, 64u8, 50u8, 240u8, 220u8, 50u8, 212u8, + 106u8, 4u8, 189u8, 2u8, 72u8, 96u8, 52u8, 187u8, 140u8, 144u8, 76u8, + ], + ) + } + pub fn dispatch_whitelisted_call( + &self, + call_hash: ::subxt::utils::H256, + call_encoded_len: ::core::primitive::u32, + call_weight_witness: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Whitelist", + "dispatch_whitelisted_call", + DispatchWhitelistedCall { + call_hash, + call_encoded_len, + call_weight_witness, + }, + [ + 243u8, 130u8, 216u8, 251u8, 131u8, 220u8, 75u8, 210u8, 203u8, 137u8, + 174u8, 95u8, 134u8, 252u8, 76u8, 33u8, 230u8, 185u8, 125u8, 15u8, + 200u8, 85u8, 46u8, 43u8, 34u8, 205u8, 245u8, 85u8, 46u8, 78u8, 245u8, + 135u8, + ], + ) + } + pub fn dispatch_whitelisted_call_with_preimage( + &self, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Whitelist", + "dispatch_whitelisted_call_with_preimage", + DispatchWhitelistedCallWithPreimage { + call: ::std::boxed::Box::new(call), + }, + [ + 97u8, 254u8, 134u8, 138u8, 68u8, 168u8, 207u8, 37u8, 107u8, 232u8, + 197u8, 219u8, 22u8, 91u8, 16u8, 162u8, 159u8, 99u8, 232u8, 92u8, 187u8, + 182u8, 231u8, 220u8, 235u8, 215u8, 186u8, 185u8, 40u8, 131u8, 191u8, + 37u8, + ], + ) + } } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_whitelist::pallet::Event; + pub mod events { + use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -16545,15 +16427,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A sub-identity was added to an identity and the deposit paid."] - pub struct SubIdentityAdded { - pub sub: ::subxt::utils::AccountId32, - pub main: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, + pub struct CallWhitelisted { + pub call_hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for SubIdentityAdded { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "SubIdentityAdded"; + impl ::subxt::events::StaticEvent for CallWhitelisted { + const PALLET: &'static str = "Whitelist"; + const EVENT: &'static str = "CallWhitelisted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -16565,15 +16444,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A sub-identity was removed from an identity and the deposit freed."] - pub struct SubIdentityRemoved { - pub sub: ::subxt::utils::AccountId32, - pub main: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, + pub struct WhitelistedCallRemoved { + pub call_hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for SubIdentityRemoved { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "SubIdentityRemoved"; + impl ::subxt::events::StaticEvent for WhitelistedCallRemoved { + const PALLET: &'static str = "Whitelist"; + const EVENT: &'static str = "WhitelistedCallRemoved"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -16585,327 +16461,75 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A sub-identity was cleared, and the given deposit repatriated from the"] - #[doc = "main identity account to the sub-identity account."] - pub struct SubIdentityRevoked { - pub sub: ::subxt::utils::AccountId32, - pub main: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, + pub struct WhitelistedCallDispatched { + pub call_hash: ::subxt::utils::H256, + pub result: ::core::result::Result< + runtime_types::frame_support::dispatch::PostDispatchInfo, + runtime_types::sp_runtime::DispatchErrorWithPostInfo< + runtime_types::frame_support::dispatch::PostDispatchInfo, + >, + >, } - impl ::subxt::events::StaticEvent for SubIdentityRevoked { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "SubIdentityRevoked"; + impl ::subxt::events::StaticEvent for WhitelistedCallDispatched { + const PALLET: &'static str = "Whitelist"; + const EVENT: &'static str = "WhitelistedCallDispatched"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " Information that is pertinent to identify the entity behind an account."] - #[doc = ""] - #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] - pub fn identity_of( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_identity::types::Registration<::core::primitive::u128>, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "IdentityOf", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 193u8, 195u8, 180u8, 188u8, 129u8, 250u8, 180u8, 219u8, 22u8, 95u8, - 175u8, 170u8, 143u8, 188u8, 80u8, 124u8, 234u8, 228u8, 245u8, 39u8, - 72u8, 153u8, 107u8, 199u8, 23u8, 75u8, 47u8, 247u8, 104u8, 208u8, - 171u8, 82u8, - ], - ) - } - #[doc = " Information that is pertinent to identify the entity behind an account."] - #[doc = ""] - #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] - pub fn identity_of_root( + pub fn whitelisted_call( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_identity::types::Registration<::core::primitive::u128>, (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "IdentityOf", - Vec::new(), - [ - 193u8, 195u8, 180u8, 188u8, 129u8, 250u8, 180u8, 219u8, 22u8, 95u8, - 175u8, 170u8, 143u8, 188u8, 80u8, 124u8, 234u8, 228u8, 245u8, 39u8, - 72u8, 153u8, 107u8, 199u8, 23u8, 75u8, 47u8, 247u8, 104u8, 208u8, - 171u8, 82u8, - ], - ) - } - #[doc = " The super-identity of an alternative \"sub\" identity together with its name, within that"] - #[doc = " context. If the account is not some other account's sub-identity, then just `None`."] - pub fn super_of( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::subxt::utils::AccountId32, - runtime_types::pallet_identity::types::Data, - ), ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Identity", - "SuperOf", + "Whitelist", + "WhitelistedCall", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 170u8, 249u8, 112u8, 249u8, 75u8, 176u8, 21u8, 29u8, 152u8, 149u8, - 69u8, 113u8, 20u8, 92u8, 113u8, 130u8, 135u8, 62u8, 18u8, 204u8, 166u8, - 193u8, 133u8, 167u8, 248u8, 117u8, 80u8, 137u8, 158u8, 111u8, 100u8, - 137u8, + 251u8, 179u8, 58u8, 232u8, 231u8, 121u8, 89u8, 218u8, 90u8, 70u8, 96u8, + 132u8, 54u8, 41u8, 18u8, 129u8, 197u8, 122u8, 221u8, 206u8, 41u8, + 100u8, 200u8, 141u8, 71u8, 98u8, 3u8, 3u8, 112u8, 167u8, 196u8, 77u8, ], ) } - #[doc = " The super-identity of an alternative \"sub\" identity together with its name, within that"] - #[doc = " context. If the account is not some other account's sub-identity, then just `None`."] - pub fn super_of_root( + pub fn whitelisted_call_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - ::subxt::utils::AccountId32, - runtime_types::pallet_identity::types::Data, - ), (), (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "SuperOf", - Vec::new(), - [ - 170u8, 249u8, 112u8, 249u8, 75u8, 176u8, 21u8, 29u8, 152u8, 149u8, - 69u8, 113u8, 20u8, 92u8, 113u8, 130u8, 135u8, 62u8, 18u8, 204u8, 166u8, - 193u8, 133u8, 167u8, 248u8, 117u8, 80u8, 137u8, 158u8, 111u8, 100u8, - 137u8, - ], - ) - } - #[doc = " Alternative \"sub\" identities of this account."] - #[doc = ""] - #[doc = " The first item is the deposit, the second is a vector of the accounts."] - #[doc = ""] - #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] - pub fn subs_of( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u128, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - ), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "SubsOf", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 128u8, 15u8, 175u8, 155u8, 216u8, 225u8, 200u8, 169u8, 215u8, 206u8, - 110u8, 22u8, 204u8, 89u8, 212u8, 210u8, 159u8, 169u8, 53u8, 7u8, 44u8, - 164u8, 91u8, 151u8, 7u8, 227u8, 38u8, 230u8, 175u8, 84u8, 6u8, 4u8, - ], - ) - } - #[doc = " Alternative \"sub\" identities of this account."] - #[doc = ""] - #[doc = " The first item is the deposit, the second is a vector of the accounts."] - #[doc = ""] - #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] - pub fn subs_of_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u128, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - ), (), ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Identity", - "SubsOf", + "Whitelist", + "WhitelistedCall", Vec::new(), [ - 128u8, 15u8, 175u8, 155u8, 216u8, 225u8, 200u8, 169u8, 215u8, 206u8, - 110u8, 22u8, 204u8, 89u8, 212u8, 210u8, 159u8, 169u8, 53u8, 7u8, 44u8, - 164u8, 91u8, 151u8, 7u8, 227u8, 38u8, 230u8, 175u8, 84u8, 6u8, 4u8, - ], - ) - } - #[doc = " The set of registrars. Not expected to get very big as can only be added through a"] - #[doc = " special origin (likely a council motion)."] - #[doc = ""] - #[doc = " The index into this can be cast to `RegistrarIndex` to get a valid value."] - pub fn registrars( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - ::core::option::Option< - runtime_types::pallet_identity::types::RegistrarInfo< - ::core::primitive::u128, - ::subxt::utils::AccountId32, - >, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "Registrars", - vec![], - [ - 157u8, 87u8, 39u8, 240u8, 154u8, 54u8, 241u8, 229u8, 76u8, 9u8, 62u8, - 252u8, 40u8, 143u8, 186u8, 182u8, 233u8, 187u8, 251u8, 61u8, 236u8, - 229u8, 19u8, 55u8, 42u8, 36u8, 82u8, 173u8, 215u8, 155u8, 229u8, 111u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The amount held on deposit for a registered identity"] - pub fn basic_deposit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Identity", - "BasicDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount held on deposit per additional field for a registered identity."] - pub fn field_deposit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Identity", - "FieldDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount held on deposit for a registered subaccount. This should account for the fact"] - #[doc = " that one storage item's value will increase by the size of an account ID, and there will"] - #[doc = " be another trie item whose value is the size of an account ID plus 32 bytes."] - pub fn sub_account_deposit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Identity", - "SubAccountDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum number of sub-accounts allowed per identified account."] - pub fn max_sub_accounts( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Identity", - "MaxSubAccounts", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Maximum number of additional fields that may be stored in an ID. Needed to bound the I/O"] - #[doc = " required to access an identity, but can be pretty high."] - pub fn max_additional_fields( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Identity", - "MaxAdditionalFields", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Maxmimum number of registrars allowed in the system. Needed to bound the complexity"] - #[doc = " of, e.g., updating judgements."] - pub fn max_registrars( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Identity", - "MaxRegistrars", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 251u8, 179u8, 58u8, 232u8, 231u8, 121u8, 89u8, 218u8, 90u8, 70u8, 96u8, + 132u8, 54u8, 41u8, 18u8, 129u8, 197u8, 122u8, 221u8, 206u8, 41u8, + 100u8, 200u8, 141u8, 71u8, 98u8, 3u8, 3u8, 112u8, 167u8, 196u8, 77u8, ], ) } } } } - pub mod proxy { + pub mod claims { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_proxy::pallet::Error; + pub type Error = runtime_types::polkadot_runtime_common::claims::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -16921,86 +16545,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Proxy { - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub force_proxy_type: - ::core::option::Option, - pub call: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddProxy { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub delay: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveProxy { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub delay: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveProxies; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CreatePure { - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub delay: ::core::primitive::u32, - pub index: ::core::primitive::u16, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillPure { - pub spawner: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub index: ::core::primitive::u16, - #[codec(compact)] - pub height: ::core::primitive::u32, - #[codec(compact)] - pub ext_index: ::core::primitive::u32, + pub struct Claim { + pub dest: ::subxt::utils::AccountId32, + pub ethereum_signature: + runtime_types::polkadot_runtime_common::claims::EcdsaSignature, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17012,9 +16560,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Announce { - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call_hash: ::subxt::utils::H256, + pub struct MintClaim { + pub who: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + pub value: ::core::primitive::u128, + pub vesting_schedule: ::core::option::Option<( + ::core::primitive::u128, + ::core::primitive::u128, + ::core::primitive::u32, + )>, + pub statement: ::core::option::Option< + runtime_types::polkadot_runtime_common::claims::StatementKind, + >, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17026,9 +16582,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveAnnouncement { - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call_hash: ::subxt::utils::H256, + pub struct ClaimAttest { + pub dest: ::subxt::utils::AccountId32, + pub ethereum_signature: + runtime_types::polkadot_runtime_common::claims::EcdsaSignature, + pub statement: ::std::vec::Vec<::core::primitive::u8>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17040,9 +16598,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RejectAnnouncement { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call_hash: ::subxt::utils::H256, + pub struct Attest { + pub statement: ::std::vec::Vec<::core::primitive::u8>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17054,338 +16611,206 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProxyAnnounced { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub force_proxy_type: - ::core::option::Option, - pub call: ::std::boxed::Box, + pub struct MoveClaim { + pub old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + pub new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + pub maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, } pub struct TransactionApi; impl TransactionApi { - #[doc = "Dispatch the given `call` from an account that the sender is authorised for through"] - #[doc = "`add_proxy`."] + #[doc = "Make a claim to collect your DOTs."] #[doc = ""] - #[doc = "Removes any corresponding announcement(s)."] + #[doc = "The dispatch origin for this call must be _None_."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "Unsigned Validation:"] + #[doc = "A call to claim is deemed valid if the signature provided matches"] + #[doc = "the expected signed message of:"] + #[doc = ""] + #[doc = "> Ethereum Signed Message:"] + #[doc = "> (configured prefix string)(address)"] + #[doc = ""] + #[doc = "and `address` matches the `dest` account."] #[doc = ""] #[doc = "Parameters:"] - #[doc = "- `real`: The account that the proxy will make a call on behalf of."] - #[doc = "- `force_proxy_type`: Specify the exact proxy type to be used and checked for this call."] - #[doc = "- `call`: The call to be made by the `real` account."] - pub fn proxy( - &self, - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - force_proxy_type: ::core::option::Option< - runtime_types::polkadot_runtime::ProxyType, - >, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "proxy", - Proxy { - real, - force_proxy_type, - call: ::std::boxed::Box::new(call), - }, - [ - 2u8, 110u8, 54u8, 249u8, 204u8, 49u8, 0u8, 174u8, 55u8, 97u8, 168u8, - 240u8, 133u8, 33u8, 119u8, 57u8, 207u8, 107u8, 9u8, 58u8, 91u8, 16u8, - 97u8, 49u8, 136u8, 119u8, 180u8, 187u8, 105u8, 150u8, 228u8, 140u8, - ], - ) - } - #[doc = "Register a proxy account for the sender that is able to make calls on its behalf."] + #[doc = "- `dest`: The destination account to payout the claim."] + #[doc = "- `ethereum_signature`: The signature of an ethereum signed message"] + #[doc = " matching the format described above."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "The weight of this call is invariant over the input parameters."] + #[doc = "Weight includes logic to validate unsigned `claim` call."] #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `proxy`: The account that the `caller` would like to make a proxy."] - #[doc = "- `proxy_type`: The permissions allowed for this proxy account."] - #[doc = "- `delay`: The announcement period required of the initial proxy. Will generally be"] - #[doc = "zero."] - pub fn add_proxy( + #[doc = "Total Complexity: O(1)"] + #[doc = ""] + pub fn claim( &self, - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - proxy_type: runtime_types::polkadot_runtime::ProxyType, - delay: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + dest: ::subxt::utils::AccountId32, + ethereum_signature : runtime_types :: polkadot_runtime_common :: claims :: EcdsaSignature, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Proxy", - "add_proxy", - AddProxy { - delegate, - proxy_type, - delay, + "Claims", + "claim", + Claim { + dest, + ethereum_signature, }, [ - 4u8, 227u8, 81u8, 178u8, 130u8, 182u8, 247u8, 112u8, 127u8, 90u8, - 105u8, 143u8, 65u8, 137u8, 181u8, 63u8, 204u8, 92u8, 140u8, 38u8, - 153u8, 233u8, 186u8, 226u8, 8u8, 76u8, 228u8, 206u8, 174u8, 54u8, 23u8, - 238u8, + 33u8, 63u8, 71u8, 104u8, 200u8, 179u8, 248u8, 38u8, 193u8, 198u8, + 250u8, 49u8, 106u8, 26u8, 109u8, 183u8, 33u8, 50u8, 217u8, 28u8, 50u8, + 107u8, 249u8, 80u8, 199u8, 10u8, 192u8, 1u8, 54u8, 41u8, 146u8, 11u8, ], ) } - #[doc = "Unregister a proxy account for the sender."] + #[doc = "Mint a new claim to collect DOTs."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "The dispatch origin for this call must be _Root_."] #[doc = ""] #[doc = "Parameters:"] - #[doc = "- `proxy`: The account that the `caller` would like to remove as a proxy."] - #[doc = "- `proxy_type`: The permissions currently enabled for the removed proxy account."] - pub fn remove_proxy( - &self, - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - proxy_type: runtime_types::polkadot_runtime::ProxyType, - delay: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "remove_proxy", - RemoveProxy { - delegate, - proxy_type, - delay, - }, - [ - 227u8, 7u8, 240u8, 130u8, 4u8, 168u8, 145u8, 107u8, 6u8, 146u8, 138u8, - 235u8, 245u8, 178u8, 168u8, 85u8, 104u8, 133u8, 28u8, 93u8, 232u8, - 99u8, 163u8, 75u8, 100u8, 113u8, 40u8, 16u8, 238u8, 123u8, 169u8, - 218u8, - ], - ) - } - #[doc = "Unregister all proxy accounts for the sender."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "WARNING: This may be called on accounts created by `pure`, however if done, then"] - #[doc = "the unreserved fees will be inaccessible. **All access to this account will be lost.**"] - pub fn remove_proxies(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "remove_proxies", - RemoveProxies {}, - [ - 15u8, 237u8, 27u8, 166u8, 254u8, 218u8, 92u8, 5u8, 213u8, 239u8, 99u8, - 59u8, 1u8, 26u8, 73u8, 252u8, 81u8, 94u8, 214u8, 227u8, 169u8, 58u8, - 40u8, 253u8, 187u8, 225u8, 192u8, 26u8, 19u8, 23u8, 121u8, 129u8, - ], - ) - } - #[doc = "Spawn a fresh new account that is guaranteed to be otherwise inaccessible, and"] - #[doc = "initialize it with a proxy of `proxy_type` for `origin` sender."] - #[doc = ""] - #[doc = "Requires a `Signed` origin."] - #[doc = ""] - #[doc = "- `proxy_type`: The type of the proxy that the sender will be registered as over the"] - #[doc = "new account. This will almost always be the most permissive `ProxyType` possible to"] - #[doc = "allow for maximum flexibility."] - #[doc = "- `index`: A disambiguation index, in case this is called multiple times in the same"] - #[doc = "transaction (e.g. with `utility::batch`). Unless you're using `batch` you probably just"] - #[doc = "want to use `0`."] - #[doc = "- `delay`: The announcement period required of the initial proxy. Will generally be"] - #[doc = "zero."] + #[doc = "- `who`: The Ethereum address allowed to collect this claim."] + #[doc = "- `value`: The number of DOTs that will be claimed."] + #[doc = "- `vesting_schedule`: An optional vesting schedule for these DOTs."] #[doc = ""] - #[doc = "Fails with `Duplicate` if this has already been called in this transaction, from the"] - #[doc = "same sender, with the same parameters."] + #[doc = ""] + #[doc = "The weight of this call is invariant over the input parameters."] + #[doc = "We assume worst case that both vesting and statement is being inserted."] #[doc = ""] - #[doc = "Fails if there are insufficient funds to pay for deposit."] - pub fn create_pure( + #[doc = "Total Complexity: O(1)"] + #[doc = ""] + pub fn mint_claim( &self, - proxy_type: runtime_types::polkadot_runtime::ProxyType, - delay: ::core::primitive::u32, - index: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { + who: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + value: ::core::primitive::u128, + vesting_schedule: ::core::option::Option<( + ::core::primitive::u128, + ::core::primitive::u128, + ::core::primitive::u32, + )>, + statement: ::core::option::Option< + runtime_types::polkadot_runtime_common::claims::StatementKind, + >, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Proxy", - "create_pure", - CreatePure { - proxy_type, - delay, - index, + "Claims", + "mint_claim", + MintClaim { + who, + value, + vesting_schedule, + statement, }, [ - 65u8, 120u8, 166u8, 57u8, 89u8, 119u8, 161u8, 93u8, 184u8, 203u8, - 190u8, 29u8, 64u8, 238u8, 70u8, 17u8, 151u8, 227u8, 170u8, 84u8, 21u8, - 161u8, 171u8, 180u8, 193u8, 175u8, 211u8, 228u8, 246u8, 216u8, 152u8, - 91u8, + 213u8, 79u8, 204u8, 40u8, 104u8, 84u8, 82u8, 62u8, 193u8, 93u8, 246u8, + 21u8, 37u8, 244u8, 166u8, 132u8, 208u8, 18u8, 86u8, 195u8, 156u8, 9u8, + 220u8, 120u8, 40u8, 183u8, 28u8, 103u8, 84u8, 163u8, 153u8, 110u8, ], ) } - #[doc = "Removes a previously spawned pure proxy."] - #[doc = ""] - #[doc = "WARNING: **All access to this account will be lost.** Any funds held in it will be"] - #[doc = "inaccessible."] - #[doc = ""] - #[doc = "Requires a `Signed` origin, and the sender account must have been created by a call to"] - #[doc = "`pure` with corresponding parameters."] + #[doc = "Make a claim to collect your DOTs by signing a statement."] #[doc = ""] - #[doc = "- `spawner`: The account that originally called `pure` to create this account."] - #[doc = "- `index`: The disambiguation index originally passed to `pure`. Probably `0`."] - #[doc = "- `proxy_type`: The proxy type originally passed to `pure`."] - #[doc = "- `height`: The height of the chain when the call to `pure` was processed."] - #[doc = "- `ext_index`: The extrinsic index in which the call to `pure` was processed."] + #[doc = "The dispatch origin for this call must be _None_."] #[doc = ""] - #[doc = "Fails with `NoPermission` in case the caller is not a previously created pure"] - #[doc = "account whose `pure` call has corresponding parameters."] - pub fn kill_pure( - &self, - spawner: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - proxy_type: runtime_types::polkadot_runtime::ProxyType, - index: ::core::primitive::u16, - height: ::core::primitive::u32, - ext_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "kill_pure", - KillPure { - spawner, - proxy_type, - index, - height, - ext_index, - }, - [ - 67u8, 233u8, 31u8, 138u8, 222u8, 70u8, 182u8, 77u8, 103u8, 39u8, 195u8, - 35u8, 39u8, 89u8, 50u8, 248u8, 187u8, 101u8, 170u8, 188u8, 87u8, 143u8, - 6u8, 180u8, 178u8, 181u8, 158u8, 111u8, 19u8, 139u8, 222u8, 208u8, - ], - ) - } - #[doc = "Publish the hash of a proxy-call that will be made in the future."] + #[doc = "Unsigned Validation:"] + #[doc = "A call to `claim_attest` is deemed valid if the signature provided matches"] + #[doc = "the expected signed message of:"] #[doc = ""] - #[doc = "This must be called some number of blocks before the corresponding `proxy` is attempted"] - #[doc = "if the delay associated with the proxy relationship is greater than zero."] + #[doc = "> Ethereum Signed Message:"] + #[doc = "> (configured prefix string)(address)(statement)"] #[doc = ""] - #[doc = "No more than `MaxPending` announcements may be made at any one time."] + #[doc = "and `address` matches the `dest` account; the `statement` must match that which is"] + #[doc = "expected according to your purchase arrangement."] #[doc = ""] - #[doc = "This will take a deposit of `AnnouncementDepositFactor` as well as"] - #[doc = "`AnnouncementDepositBase` if there are no other pending announcements."] + #[doc = "Parameters:"] + #[doc = "- `dest`: The destination account to payout the claim."] + #[doc = "- `ethereum_signature`: The signature of an ethereum signed message"] + #[doc = " matching the format described above."] + #[doc = "- `statement`: The identity of the statement which is being attested to in the signature."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and a proxy of `real`."] + #[doc = ""] + #[doc = "The weight of this call is invariant over the input parameters."] + #[doc = "Weight includes logic to validate unsigned `claim_attest` call."] #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `real`: The account that the proxy will make a call on behalf of."] - #[doc = "- `call_hash`: The hash of the call to be made by the `real` account."] - pub fn announce( + #[doc = "Total Complexity: O(1)"] + #[doc = ""] + pub fn claim_attest( &self, - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + dest: ::subxt::utils::AccountId32, + ethereum_signature : runtime_types :: polkadot_runtime_common :: claims :: EcdsaSignature, + statement: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Proxy", - "announce", - Announce { real, call_hash }, + "Claims", + "claim_attest", + ClaimAttest { + dest, + ethereum_signature, + statement, + }, [ - 235u8, 116u8, 208u8, 53u8, 128u8, 91u8, 100u8, 68u8, 255u8, 254u8, - 119u8, 253u8, 108u8, 130u8, 88u8, 56u8, 113u8, 99u8, 105u8, 179u8, - 16u8, 143u8, 131u8, 203u8, 234u8, 76u8, 199u8, 191u8, 35u8, 158u8, - 130u8, 209u8, + 255u8, 10u8, 87u8, 106u8, 101u8, 195u8, 249u8, 25u8, 109u8, 82u8, + 213u8, 95u8, 203u8, 145u8, 224u8, 113u8, 92u8, 141u8, 31u8, 54u8, + 218u8, 47u8, 218u8, 239u8, 211u8, 206u8, 77u8, 176u8, 19u8, 176u8, + 175u8, 135u8, ], ) } - #[doc = "Remove a given announcement."] + #[doc = "Attest to a statement, needed to finalize the claims process."] #[doc = ""] - #[doc = "May be called by a proxy account to remove a call they previously announced and return"] - #[doc = "the deposit."] + #[doc = "WARNING: Insecure unless your chain includes `PrevalidateAttests` as a `SignedExtension`."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "Unsigned Validation:"] + #[doc = "A call to attest is deemed valid if the sender has a `Preclaim` registered"] + #[doc = "and provides a `statement` which is expected for the account."] #[doc = ""] #[doc = "Parameters:"] - #[doc = "- `real`: The account that the proxy will make a call on behalf of."] - #[doc = "- `call_hash`: The hash of the call to be made by the `real` account."] - pub fn remove_announcement( - &self, - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "remove_announcement", - RemoveAnnouncement { real, call_hash }, - [ - 140u8, 186u8, 140u8, 129u8, 40u8, 124u8, 57u8, 61u8, 84u8, 247u8, - 123u8, 241u8, 148u8, 15u8, 94u8, 146u8, 121u8, 78u8, 190u8, 68u8, - 185u8, 125u8, 62u8, 49u8, 108u8, 131u8, 229u8, 82u8, 68u8, 37u8, 184u8, - 223u8, - ], - ) - } - #[doc = "Remove the given announcement of a delegate."] - #[doc = ""] - #[doc = "May be called by a target (proxied) account to remove a call that one of their delegates"] - #[doc = "(`delegate`) has announced they want to execute. The deposit is returned."] + #[doc = "- `statement`: The identity of the statement which is being attested to in the signature."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "The weight of this call is invariant over the input parameters."] + #[doc = "Weight includes logic to do pre-validation on `attest` call."] #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `delegate`: The account that previously announced the call."] - #[doc = "- `call_hash`: The hash of the call to be made."] - pub fn reject_announcement( + #[doc = "Total Complexity: O(1)"] + #[doc = ""] + pub fn attest( &self, - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + statement: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Proxy", - "reject_announcement", - RejectAnnouncement { - delegate, - call_hash, - }, + "Claims", + "attest", + Attest { statement }, [ - 225u8, 198u8, 31u8, 173u8, 157u8, 141u8, 121u8, 51u8, 226u8, 170u8, - 219u8, 86u8, 14u8, 131u8, 122u8, 157u8, 161u8, 200u8, 157u8, 37u8, - 43u8, 97u8, 143u8, 97u8, 46u8, 206u8, 204u8, 42u8, 78u8, 33u8, 85u8, - 127u8, + 8u8, 218u8, 97u8, 237u8, 185u8, 61u8, 55u8, 4u8, 134u8, 18u8, 244u8, + 226u8, 40u8, 97u8, 222u8, 246u8, 221u8, 74u8, 253u8, 22u8, 52u8, 223u8, + 224u8, 83u8, 21u8, 218u8, 248u8, 100u8, 107u8, 58u8, 247u8, 10u8, ], ) } - #[doc = "Dispatch the given `call` from an account that the sender is authorized for through"] - #[doc = "`add_proxy`."] - #[doc = ""] - #[doc = "Removes any corresponding announcement(s)."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `real`: The account that the proxy will make a call on behalf of."] - #[doc = "- `force_proxy_type`: Specify the exact proxy type to be used and checked for this call."] - #[doc = "- `call`: The call to be made by the `real` account."] - pub fn proxy_announced( + pub fn move_claim( &self, - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - force_proxy_type: ::core::option::Option< - runtime_types::polkadot_runtime::ProxyType, - >, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Proxy", - "proxy_announced", - ProxyAnnounced { - delegate, - real, - force_proxy_type, - call: ::std::boxed::Box::new(call), + "Claims", + "move_claim", + MoveClaim { + old, + new, + maybe_preclaim, }, [ - 201u8, 208u8, 101u8, 152u8, 52u8, 146u8, 71u8, 255u8, 2u8, 250u8, - 225u8, 24u8, 117u8, 32u8, 113u8, 251u8, 230u8, 233u8, 30u8, 187u8, - 194u8, 116u8, 65u8, 51u8, 142u8, 106u8, 91u8, 178u8, 193u8, 170u8, - 150u8, 118u8, + 63u8, 48u8, 217u8, 16u8, 161u8, 102u8, 165u8, 241u8, 57u8, 185u8, + 230u8, 161u8, 202u8, 11u8, 223u8, 15u8, 57u8, 181u8, 34u8, 131u8, + 235u8, 168u8, 227u8, 152u8, 157u8, 4u8, 192u8, 243u8, 194u8, 120u8, + 130u8, 202u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_proxy::pallet::Event; + pub type Event = runtime_types::polkadot_runtime_common::claims::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -17398,342 +16823,272 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proxy was executed correctly, with the given."] - pub struct ProxyExecuted { - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for ProxyExecuted { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "ProxyExecuted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A pure account has been created by new proxy with given"] - #[doc = "disambiguation index and proxy type."] - pub struct PureCreated { - pub pure: ::subxt::utils::AccountId32, + #[doc = "Someone claimed some DOTs."] + pub struct Claimed { pub who: ::subxt::utils::AccountId32, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub disambiguation_index: ::core::primitive::u16, - } - impl ::subxt::events::StaticEvent for PureCreated { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "PureCreated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An announcement was placed to make a call in the future."] - pub struct Announced { - pub real: ::subxt::utils::AccountId32, - pub proxy: ::subxt::utils::AccountId32, - pub call_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Announced { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "Announced"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proxy was added."] - pub struct ProxyAdded { - pub delegator: ::subxt::utils::AccountId32, - pub delegatee: ::subxt::utils::AccountId32, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub delay: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for ProxyAdded { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "ProxyAdded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proxy was removed."] - pub struct ProxyRemoved { - pub delegator: ::subxt::utils::AccountId32, - pub delegatee: ::subxt::utils::AccountId32, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub delay: ::core::primitive::u32, + pub ethereum_address: + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + pub amount: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for ProxyRemoved { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "ProxyRemoved"; + impl ::subxt::events::StaticEvent for Claimed { + const PALLET: &'static str = "Claims"; + const EVENT: &'static str = "Claimed"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " The set of account proxies. Maps the account which has delegated to the accounts"] - #[doc = " which are being delegated to, together with the amount held on deposit."] - pub fn proxies( + pub fn claims( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + >, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - runtime_types::pallet_proxy::ProxyDefinition< - ::subxt::utils::AccountId32, - runtime_types::polkadot_runtime::ProxyType, - ::core::primitive::u32, - >, - >, - ::core::primitive::u128, - ), - ::subxt::storage::address::Yes, + ::core::primitive::u128, ::subxt::storage::address::Yes, + (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Proxy", - "Proxies", + "Claims", + "Claims", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 106u8, 101u8, 77u8, 184u8, 193u8, 162u8, 132u8, 209u8, 130u8, 70u8, - 249u8, 183u8, 78u8, 52u8, 153u8, 120u8, 84u8, 224u8, 233u8, 37u8, - 171u8, 192u8, 99u8, 31u8, 49u8, 43u8, 126u8, 67u8, 161u8, 103u8, 248u8, - 14u8, + 36u8, 247u8, 169u8, 171u8, 103u8, 176u8, 70u8, 213u8, 255u8, 175u8, + 97u8, 142u8, 231u8, 70u8, 90u8, 213u8, 128u8, 67u8, 50u8, 37u8, 51u8, + 184u8, 72u8, 27u8, 193u8, 254u8, 12u8, 253u8, 91u8, 60u8, 88u8, 182u8, ], ) } - #[doc = " The set of account proxies. Maps the account which has delegated to the accounts"] - #[doc = " which are being delegated to, together with the amount held on deposit."] - pub fn proxies_root( + pub fn claims_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - runtime_types::pallet_proxy::ProxyDefinition< - ::subxt::utils::AccountId32, - runtime_types::polkadot_runtime::ProxyType, - ::core::primitive::u32, - >, - >, - ::core::primitive::u128, - ), + ::core::primitive::u128, + (), (), - ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Proxy", - "Proxies", + "Claims", + "Claims", Vec::new(), [ - 106u8, 101u8, 77u8, 184u8, 193u8, 162u8, 132u8, 209u8, 130u8, 70u8, - 249u8, 183u8, 78u8, 52u8, 153u8, 120u8, 84u8, 224u8, 233u8, 37u8, - 171u8, 192u8, 99u8, 31u8, 49u8, 43u8, 126u8, 67u8, 161u8, 103u8, 248u8, - 14u8, + 36u8, 247u8, 169u8, 171u8, 103u8, 176u8, 70u8, 213u8, 255u8, 175u8, + 97u8, 142u8, 231u8, 70u8, 90u8, 213u8, 128u8, 67u8, 50u8, 37u8, 51u8, + 184u8, 72u8, 27u8, 193u8, 254u8, 12u8, 253u8, 91u8, 60u8, 88u8, 182u8, ], ) } - #[doc = " The announcements made by the proxy (key)."] - pub fn announcements( + pub fn total( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - runtime_types::pallet_proxy::Announcement< - ::subxt::utils::AccountId32, - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Claims", + "Total", + vec![], + [ + 162u8, 59u8, 237u8, 63u8, 23u8, 44u8, 74u8, 169u8, 131u8, 166u8, 174u8, + 61u8, 127u8, 165u8, 32u8, 115u8, 73u8, 171u8, 36u8, 10u8, 6u8, 23u8, + 19u8, 202u8, 3u8, 189u8, 29u8, 169u8, 144u8, 187u8, 235u8, 77u8, + ], + ) + } + #[doc = " Vesting schedule for a claim."] + #[doc = " First balance is the total amount that should be held for vesting."] + #[doc = " Second balance is how much should be unlocked per block."] + #[doc = " The block number is when the vesting should start."] + pub fn vesting( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ( ::core::primitive::u128, + ::core::primitive::u128, + ::core::primitive::u32, ), ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Proxy", - "Announcements", + "Claims", + "Vesting", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 233u8, 38u8, 249u8, 89u8, 103u8, 87u8, 64u8, 52u8, 140u8, 228u8, 110u8, - 37u8, 8u8, 92u8, 48u8, 7u8, 46u8, 99u8, 179u8, 83u8, 232u8, 171u8, - 160u8, 45u8, 37u8, 23u8, 151u8, 198u8, 237u8, 103u8, 217u8, 53u8, + 112u8, 174u8, 151u8, 185u8, 225u8, 170u8, 63u8, 147u8, 100u8, 23u8, + 102u8, 148u8, 244u8, 47u8, 87u8, 99u8, 28u8, 59u8, 48u8, 205u8, 43u8, + 41u8, 87u8, 225u8, 191u8, 164u8, 31u8, 208u8, 80u8, 53u8, 25u8, 205u8, ], ) } - #[doc = " The announcements made by the proxy (key)."] - pub fn announcements_root( + #[doc = " Vesting schedule for a claim."] + #[doc = " First balance is the total amount that should be held for vesting."] + #[doc = " Second balance is how much should be unlocked per block."] + #[doc = " The block number is when the vesting should start."] + pub fn vesting_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, ( - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - runtime_types::pallet_proxy::Announcement< - ::subxt::utils::AccountId32, - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, ::core::primitive::u128, + ::core::primitive::u128, + ::core::primitive::u32, ), (), - ::subxt::storage::address::Yes, + (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Proxy", - "Announcements", + "Claims", + "Vesting", Vec::new(), [ - 233u8, 38u8, 249u8, 89u8, 103u8, 87u8, 64u8, 52u8, 140u8, 228u8, 110u8, - 37u8, 8u8, 92u8, 48u8, 7u8, 46u8, 99u8, 179u8, 83u8, 232u8, 171u8, - 160u8, 45u8, 37u8, 23u8, 151u8, 198u8, 237u8, 103u8, 217u8, 53u8, + 112u8, 174u8, 151u8, 185u8, 225u8, 170u8, 63u8, 147u8, 100u8, 23u8, + 102u8, 148u8, 244u8, 47u8, 87u8, 99u8, 28u8, 59u8, 48u8, 205u8, 43u8, + 41u8, 87u8, 225u8, 191u8, 164u8, 31u8, 208u8, 80u8, 53u8, 25u8, 205u8, ], ) } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The base amount of currency needed to reserve for creating a proxy."] - #[doc = ""] - #[doc = " This is held for an additional storage item whose value size is"] - #[doc = " `sizeof(Balance)` bytes and whose key size is `sizeof(AccountId)` bytes."] - pub fn proxy_deposit_base( + #[doc = " The statement kind that must be signed, if any."] + pub fn signing( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Proxy", - "ProxyDepositBase", + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_common::claims::StatementKind, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Claims", + "Signing", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 51u8, 184u8, 211u8, 207u8, 13u8, 194u8, 181u8, 153u8, 25u8, 212u8, + 106u8, 189u8, 149u8, 14u8, 19u8, 61u8, 210u8, 109u8, 23u8, 168u8, + 191u8, 74u8, 112u8, 190u8, 242u8, 112u8, 183u8, 17u8, 30u8, 125u8, + 85u8, 107u8, ], ) } - #[doc = " The amount of currency needed per proxy added."] - #[doc = ""] - #[doc = " This is held for adding 32 bytes plus an instance of `ProxyType` more into a"] - #[doc = " pre-existing storage value. Thus, when configuring `ProxyDepositFactor` one should take"] - #[doc = " into account `32 + proxy_type.encode().len()` bytes of data."] - pub fn proxy_deposit_factor( + #[doc = " The statement kind that must be signed, if any."] + pub fn signing_root( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Proxy", - "ProxyDepositFactor", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum amount of proxies allowed for a single account."] - pub fn max_proxies(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Proxy", - "MaxProxies", + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_common::claims::StatementKind, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Claims", + "Signing", + Vec::new(), [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 51u8, 184u8, 211u8, 207u8, 13u8, 194u8, 181u8, 153u8, 25u8, 212u8, + 106u8, 189u8, 149u8, 14u8, 19u8, 61u8, 210u8, 109u8, 23u8, 168u8, + 191u8, 74u8, 112u8, 190u8, 242u8, 112u8, 183u8, 17u8, 30u8, 125u8, + 85u8, 107u8, ], ) } - #[doc = " The maximum amount of time-delayed announcements that are allowed to be pending."] - pub fn max_pending(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Proxy", - "MaxPending", + #[doc = " Pre-claimed Ethereum accounts, by the Account ID that they are claimed to."] + pub fn preclaims( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Claims", + "Preclaims", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 149u8, 61u8, 170u8, 170u8, 60u8, 212u8, 29u8, 214u8, 141u8, 136u8, + 207u8, 248u8, 51u8, 135u8, 242u8, 105u8, 121u8, 91u8, 186u8, 30u8, 0u8, + 173u8, 154u8, 133u8, 20u8, 244u8, 58u8, 184u8, 133u8, 214u8, 67u8, + 95u8, ], ) } - #[doc = " The base amount of currency needed to reserve for creating an announcement."] - #[doc = ""] - #[doc = " This is held when a new storage item holding a `Balance` is created (typically 16"] - #[doc = " bytes)."] - pub fn announcement_deposit_base( + #[doc = " Pre-claimed Ethereum accounts, by the Account ID that they are claimed to."] + pub fn preclaims_root( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Proxy", - "AnnouncementDepositBase", + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Claims", + "Preclaims", + Vec::new(), [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 149u8, 61u8, 170u8, 170u8, 60u8, 212u8, 29u8, 214u8, 141u8, 136u8, + 207u8, 248u8, 51u8, 135u8, 242u8, 105u8, 121u8, 91u8, 186u8, 30u8, 0u8, + 173u8, 154u8, 133u8, 20u8, 244u8, 58u8, 184u8, 133u8, 214u8, 67u8, + 95u8, ], ) } - #[doc = " The amount of currency needed per announcement made."] - #[doc = ""] - #[doc = " This is held for adding an `AccountId`, `Hash` and `BlockNumber` (typically 68 bytes)"] - #[doc = " into a pre-existing storage value."] - pub fn announcement_deposit_factor( + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + pub fn prefix( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { + ) -> ::subxt::constants::Address<::std::vec::Vec<::core::primitive::u8>> + { ::subxt::constants::Address::new_static( - "Proxy", - "AnnouncementDepositFactor", + "Claims", + "Prefix", [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 106u8, 50u8, 57u8, 116u8, 43u8, 202u8, 37u8, 248u8, 102u8, 22u8, 62u8, + 22u8, 242u8, 54u8, 152u8, 168u8, 107u8, 64u8, 72u8, 172u8, 124u8, 40u8, + 42u8, 110u8, 104u8, 145u8, 31u8, 144u8, 242u8, 189u8, 145u8, 208u8, ], ) } } } } - pub mod multisig { + pub mod vesting { use super::root_mod; use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_multisig::pallet::Error; + #[doc = "Error for the vesting pallet."] + pub type Error = runtime_types::pallet_vesting::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -17749,9 +17104,19 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsMultiThreshold1 { - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub call: ::std::boxed::Box, + pub struct Vest; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct VestOther { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17763,14 +17128,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub struct VestedTransfer { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, >, - pub call: ::std::boxed::Box, - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17782,14 +17145,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApproveAsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub struct ForceVestedTransfer { + pub source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, >, - pub call_hash: [::core::primitive::u8; 32usize], - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17801,238 +17163,175 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelAsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub call_hash: [::core::primitive::u8; 32usize], + pub struct MergeSchedules { + pub schedule1_index: ::core::primitive::u32, + pub schedule2_index: ::core::primitive::u32, } pub struct TransactionApi; impl TransactionApi { - #[doc = "Immediately dispatch a multi-signature call using a single approval from the caller."] + #[doc = "Unlock any vested funds of the sender account."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have funds still"] + #[doc = "locked under this pallet."] + #[doc = ""] + #[doc = "Emits either `VestingCompleted` or `VestingUpdated`."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(1)`."] + pub fn vest(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Vesting", + "vest", + Vest {}, + [ + 123u8, 54u8, 10u8, 208u8, 154u8, 24u8, 39u8, 166u8, 64u8, 27u8, 74u8, + 29u8, 243u8, 97u8, 155u8, 5u8, 130u8, 155u8, 65u8, 181u8, 196u8, 125u8, + 45u8, 133u8, 25u8, 33u8, 3u8, 34u8, 21u8, 167u8, 172u8, 54u8, + ], + ) + } + #[doc = "Unlock any vested funds of a `target` account."] #[doc = ""] #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] - #[doc = "- `other_signatories`: The accounts (other than the sender) who are part of the"] - #[doc = "multi-signature, but do not participate in the approval process."] - #[doc = "- `call`: The call to be executed."] + #[doc = "- `target`: The account whose vested funds should be unlocked. Must have funds still"] + #[doc = "locked under this pallet."] #[doc = ""] - #[doc = "Result is equivalent to the dispatched result."] + #[doc = "Emits either `VestingCompleted` or `VestingUpdated`."] #[doc = ""] - #[doc = "# "] - #[doc = "O(Z + C) where Z is the length of the call and C its execution weight."] - #[doc = "-------------------------------"] - #[doc = "- DB Weight: None"] - #[doc = "- Plus Call Weight"] - #[doc = "# "] - pub fn as_multi_threshold_1( + #[doc = "## Complexity"] + #[doc = "- `O(1)`."] + pub fn vest_other( &self, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Multisig", - "as_multi_threshold_1", - AsMultiThreshold1 { - other_signatories, - call: ::std::boxed::Box::new(call), - }, + "Vesting", + "vest_other", + VestOther { target }, [ - 147u8, 128u8, 190u8, 162u8, 129u8, 151u8, 240u8, 184u8, 12u8, 100u8, - 188u8, 81u8, 25u8, 140u8, 46u8, 215u8, 52u8, 135u8, 134u8, 207u8, 40u8, - 221u8, 114u8, 48u8, 102u8, 107u8, 173u8, 90u8, 74u8, 56u8, 147u8, - 238u8, + 164u8, 19u8, 93u8, 81u8, 235u8, 101u8, 18u8, 52u8, 187u8, 81u8, 243u8, + 216u8, 116u8, 84u8, 188u8, 135u8, 1u8, 241u8, 128u8, 90u8, 117u8, + 164u8, 111u8, 0u8, 251u8, 148u8, 250u8, 248u8, 102u8, 79u8, 165u8, + 175u8, ], ) } - #[doc = "Register approval for a dispatch to be made from a deterministic composite account if"] - #[doc = "approved by a total of `threshold - 1` of `other_signatories`."] - #[doc = ""] - #[doc = "If there are enough, then dispatch the call."] - #[doc = ""] - #[doc = "Payment: `DepositBase` will be reserved if this is the first approval, plus"] - #[doc = "`threshold` times `DepositFactor`. It is returned once this dispatch happens or"] - #[doc = "is cancelled."] + #[doc = "Create a vested transfer."] #[doc = ""] #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] - #[doc = "- `threshold`: The total number of approvals for this dispatch before it is executed."] - #[doc = "- `other_signatories`: The accounts (other than the sender) who can approve this"] - #[doc = "dispatch. May not be empty."] - #[doc = "- `maybe_timepoint`: If this is the first approval, then this must be `None`. If it is"] - #[doc = "not the first approval, then it must be `Some`, with the timepoint (block number and"] - #[doc = "transaction index) of the first approval transaction."] - #[doc = "- `call`: The call to be executed."] + #[doc = "- `target`: The account receiving the vested funds."] + #[doc = "- `schedule`: The vesting schedule attached to the transfer."] #[doc = ""] - #[doc = "NOTE: Unless this is the final approval, you will generally want to use"] - #[doc = "`approve_as_multi` instead, since it only requires a hash of the call."] + #[doc = "Emits `VestingCreated`."] #[doc = ""] - #[doc = "Result is equivalent to the dispatched result if `threshold` is exactly `1`. Otherwise"] - #[doc = "on success, result is `Ok` and the result from the interior call, if it was executed,"] - #[doc = "may be found in the deposited `MultisigExecuted` event."] + #[doc = "NOTE: This will unlock all schedules through the current block."] #[doc = ""] - #[doc = "# "] - #[doc = "- `O(S + Z + Call)`."] - #[doc = "- Up to one balance-reserve or unreserve operation."] - #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] - #[doc = " signatories. `S` is capped by `MaxSignatories`, with weight being proportional."] - #[doc = "- One call encode & hash, both of complexity `O(Z)` where `Z` is tx-len."] - #[doc = "- One encode & hash, both of complexity `O(S)`."] - #[doc = "- Up to one binary search and insert (`O(logS + S)`)."] - #[doc = "- I/O: 1 read `O(S)`, up to 1 mutate `O(S)`. Up to one remove."] - #[doc = "- One event."] - #[doc = "- The weight of the `call`."] - #[doc = "- Storage: inserts one item, value size bounded by `MaxSignatories`, with a deposit"] - #[doc = " taken for its lifetime of `DepositBase + threshold * DepositFactor`."] - #[doc = "-------------------------------"] - #[doc = "- DB Weight:"] - #[doc = " - Reads: Multisig Storage, [Caller Account]"] - #[doc = " - Writes: Multisig Storage, [Caller Account]"] - #[doc = "- Plus Call Weight"] - #[doc = "# "] - pub fn as_multi( + #[doc = "## Complexity"] + #[doc = "- `O(1)`."] + pub fn vested_transfer( &self, - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, >, - call: runtime_types::polkadot_runtime::RuntimeCall, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Multisig", - "as_multi", - AsMulti { - threshold, - other_signatories, - maybe_timepoint, - call: ::std::boxed::Box::new(call), - max_weight, - }, + "Vesting", + "vested_transfer", + VestedTransfer { target, schedule }, [ - 223u8, 45u8, 132u8, 89u8, 48u8, 61u8, 93u8, 46u8, 76u8, 28u8, 217u8, - 194u8, 89u8, 170u8, 245u8, 6u8, 76u8, 50u8, 12u8, 133u8, 230u8, 10u8, - 56u8, 231u8, 29u8, 202u8, 60u8, 50u8, 181u8, 144u8, 238u8, 151u8, + 135u8, 172u8, 56u8, 97u8, 45u8, 141u8, 93u8, 173u8, 111u8, 252u8, 75u8, + 246u8, 92u8, 181u8, 138u8, 87u8, 145u8, 174u8, 71u8, 108u8, 126u8, + 118u8, 49u8, 122u8, 249u8, 132u8, 19u8, 2u8, 132u8, 160u8, 247u8, + 195u8, ], ) } - #[doc = "Register approval for a dispatch to be made from a deterministic composite account if"] - #[doc = "approved by a total of `threshold - 1` of `other_signatories`."] + #[doc = "Force a vested transfer."] #[doc = ""] - #[doc = "Payment: `DepositBase` will be reserved if this is the first approval, plus"] - #[doc = "`threshold` times `DepositFactor`. It is returned once this dispatch happens or"] - #[doc = "is cancelled."] + #[doc = "The dispatch origin for this call must be _Root_."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "- `source`: The account whose funds should be transferred."] + #[doc = "- `target`: The account that should be transferred the vested funds."] + #[doc = "- `schedule`: The vesting schedule attached to the transfer."] #[doc = ""] - #[doc = "- `threshold`: The total number of approvals for this dispatch before it is executed."] - #[doc = "- `other_signatories`: The accounts (other than the sender) who can approve this"] - #[doc = "dispatch. May not be empty."] - #[doc = "- `maybe_timepoint`: If this is the first approval, then this must be `None`. If it is"] - #[doc = "not the first approval, then it must be `Some`, with the timepoint (block number and"] - #[doc = "transaction index) of the first approval transaction."] - #[doc = "- `call_hash`: The hash of the call to be executed."] + #[doc = "Emits `VestingCreated`."] #[doc = ""] - #[doc = "NOTE: If this is the final approval, you will want to use `as_multi` instead."] + #[doc = "NOTE: This will unlock all schedules through the current block."] #[doc = ""] - #[doc = "# "] - #[doc = "- `O(S)`."] - #[doc = "- Up to one balance-reserve or unreserve operation."] - #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] - #[doc = " signatories. `S` is capped by `MaxSignatories`, with weight being proportional."] - #[doc = "- One encode & hash, both of complexity `O(S)`."] - #[doc = "- Up to one binary search and insert (`O(logS + S)`)."] - #[doc = "- I/O: 1 read `O(S)`, up to 1 mutate `O(S)`. Up to one remove."] - #[doc = "- One event."] - #[doc = "- Storage: inserts one item, value size bounded by `MaxSignatories`, with a deposit"] - #[doc = " taken for its lifetime of `DepositBase + threshold * DepositFactor`."] - #[doc = "----------------------------------"] - #[doc = "- DB Weight:"] - #[doc = " - Read: Multisig Storage, [Caller Account]"] - #[doc = " - Write: Multisig Storage, [Caller Account]"] - #[doc = "# "] - pub fn approve_as_multi( + #[doc = "## Complexity"] + #[doc = "- `O(1)`."] + pub fn force_vested_transfer( &self, - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, >, - call_hash: [::core::primitive::u8; 32usize], - max_weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Multisig", - "approve_as_multi", - ApproveAsMulti { - threshold, - other_signatories, - maybe_timepoint, - call_hash, - max_weight, + "Vesting", + "force_vested_transfer", + ForceVestedTransfer { + source, + target, + schedule, }, [ - 133u8, 113u8, 121u8, 66u8, 218u8, 219u8, 48u8, 64u8, 211u8, 114u8, - 163u8, 193u8, 164u8, 21u8, 140u8, 218u8, 253u8, 237u8, 240u8, 126u8, - 200u8, 213u8, 184u8, 50u8, 187u8, 182u8, 30u8, 52u8, 142u8, 72u8, - 210u8, 101u8, + 110u8, 142u8, 63u8, 148u8, 90u8, 229u8, 237u8, 183u8, 240u8, 237u8, + 242u8, 32u8, 88u8, 48u8, 220u8, 101u8, 210u8, 212u8, 27u8, 7u8, 186u8, + 98u8, 28u8, 197u8, 148u8, 140u8, 77u8, 59u8, 202u8, 166u8, 63u8, 97u8, ], ) } - #[doc = "Cancel a pre-existing, on-going multisig transaction. Any deposit reserved previously"] - #[doc = "for this operation will be unreserved on success."] + #[doc = "Merge two vesting schedules together, creating a new vesting schedule that unlocks over"] + #[doc = "the highest possible start and end blocks. If both schedules have already started the"] + #[doc = "current block will be used as the schedule start; with the caveat that if one schedule"] + #[doc = "is finished by the current block, the other will be treated as the new merged schedule,"] + #[doc = "unmodified."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "NOTE: If `schedule1_index == schedule2_index` this is a no-op."] + #[doc = "NOTE: This will unlock all schedules through the current block prior to merging."] + #[doc = "NOTE: If both schedules have ended by the current block, no new schedule will be created"] + #[doc = "and both will be removed."] #[doc = ""] - #[doc = "- `threshold`: The total number of approvals for this dispatch before it is executed."] - #[doc = "- `other_signatories`: The accounts (other than the sender) who can approve this"] - #[doc = "dispatch. May not be empty."] - #[doc = "- `timepoint`: The timepoint (block number and transaction index) of the first approval"] - #[doc = "transaction for this dispatch."] - #[doc = "- `call_hash`: The hash of the call to be executed."] + #[doc = "Merged schedule attributes:"] + #[doc = "- `starting_block`: `MAX(schedule1.starting_block, scheduled2.starting_block,"] + #[doc = " current_block)`."] + #[doc = "- `ending_block`: `MAX(schedule1.ending_block, schedule2.ending_block)`."] + #[doc = "- `locked`: `schedule1.locked_at(current_block) + schedule2.locked_at(current_block)`."] #[doc = ""] - #[doc = "# "] - #[doc = "- `O(S)`."] - #[doc = "- Up to one balance-reserve or unreserve operation."] - #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] - #[doc = " signatories. `S` is capped by `MaxSignatories`, with weight being proportional."] - #[doc = "- One encode & hash, both of complexity `O(S)`."] - #[doc = "- One event."] - #[doc = "- I/O: 1 read `O(S)`, one remove."] - #[doc = "- Storage: removes one item."] - #[doc = "----------------------------------"] - #[doc = "- DB Weight:"] - #[doc = " - Read: Multisig Storage, [Caller Account], Refund Account"] - #[doc = " - Write: Multisig Storage, [Caller Account], Refund Account"] - #[doc = "# "] - pub fn cancel_as_multi( + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "- `schedule1_index`: index of the first schedule to merge."] + #[doc = "- `schedule2_index`: index of the second schedule to merge."] + pub fn merge_schedules( &self, - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - call_hash: [::core::primitive::u8; 32usize], - ) -> ::subxt::tx::Payload { + schedule1_index: ::core::primitive::u32, + schedule2_index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Multisig", - "cancel_as_multi", - CancelAsMulti { - threshold, - other_signatories, - timepoint, - call_hash, + "Vesting", + "merge_schedules", + MergeSchedules { + schedule1_index, + schedule2_index, }, [ - 30u8, 25u8, 186u8, 142u8, 168u8, 81u8, 235u8, 164u8, 82u8, 209u8, 66u8, - 129u8, 209u8, 78u8, 172u8, 9u8, 163u8, 222u8, 125u8, 57u8, 2u8, 43u8, - 169u8, 174u8, 159u8, 167u8, 25u8, 226u8, 254u8, 110u8, 80u8, 216u8, + 95u8, 255u8, 147u8, 12u8, 49u8, 25u8, 70u8, 112u8, 55u8, 154u8, 183u8, + 97u8, 56u8, 244u8, 148u8, 61u8, 107u8, 163u8, 220u8, 31u8, 153u8, 25u8, + 193u8, 251u8, 131u8, 26u8, 166u8, 157u8, 75u8, 4u8, 110u8, 125u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_multisig::pallet::Event; + pub type Event = runtime_types::pallet_vesting::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -18045,58 +17344,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new multisig operation has begun."] - pub struct NewMultisig { - pub approving: ::subxt::utils::AccountId32, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for NewMultisig { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "NewMultisig"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A multisig operation has been approved by someone."] - pub struct MultisigApproval { - pub approving: ::subxt::utils::AccountId32, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for MultisigApproval { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "MultisigApproval"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A multisig operation has been executed."] - pub struct MultisigExecuted { - pub approving: ::subxt::utils::AccountId32, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + #[doc = "The amount vested has been updated. This could indicate a change in funds available."] + #[doc = "The balance given is the amount which is left unvested (and thus locked)."] + pub struct VestingUpdated { + pub account: ::subxt::utils::AccountId32, + pub unvested: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for MultisigExecuted { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "MultisigExecuted"; + impl ::subxt::events::StaticEvent for VestingUpdated { + const PALLET: &'static str = "Vesting"; + const EVENT: &'static str = "VestingUpdated"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18108,74 +17364,94 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A multisig operation has been cancelled."] - pub struct MultisigCancelled { - pub cancelling: ::subxt::utils::AccountId32, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], + #[doc = "An \\[account\\] has become fully vested."] + pub struct VestingCompleted { + pub account: ::subxt::utils::AccountId32, } - impl ::subxt::events::StaticEvent for MultisigCancelled { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "MultisigCancelled"; + impl ::subxt::events::StaticEvent for VestingCompleted { + const PALLET: &'static str = "Vesting"; + const EVENT: &'static str = "VestingCompleted"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " The set of open multisig operations."] - pub fn multisigs( + #[doc = " Information regarding the vesting of a given account."] + pub fn vesting( &self, _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - _1: impl ::std::borrow::Borrow<[::core::primitive::u8; 32usize]>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_multisig::Multisig< - ::core::primitive::u32, - ::core::primitive::u128, - ::subxt::utils::AccountId32, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, + >, >, ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Multisig", - "Multisigs", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + "Vesting", + "Vesting", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 69u8, 153u8, 186u8, 204u8, 117u8, 95u8, 119u8, 182u8, 220u8, 87u8, 8u8, - 15u8, 123u8, 83u8, 5u8, 188u8, 115u8, 121u8, 163u8, 96u8, 218u8, 3u8, - 106u8, 44u8, 44u8, 187u8, 46u8, 238u8, 80u8, 203u8, 175u8, 155u8, + 23u8, 209u8, 233u8, 126u8, 89u8, 156u8, 193u8, 204u8, 100u8, 90u8, + 14u8, 120u8, 36u8, 167u8, 148u8, 239u8, 179u8, 74u8, 207u8, 83u8, 54u8, + 77u8, 27u8, 135u8, 74u8, 31u8, 33u8, 11u8, 168u8, 239u8, 212u8, 36u8, ], ) } - #[doc = " The set of open multisig operations."] - pub fn multisigs_root( + #[doc = " Information regarding the vesting of a given account."] + pub fn vesting_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_multisig::Multisig< - ::core::primitive::u32, - ::core::primitive::u128, - ::subxt::utils::AccountId32, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, + >, >, (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Multisig", - "Multisigs", + "Vesting", + "Vesting", Vec::new(), [ - 69u8, 153u8, 186u8, 204u8, 117u8, 95u8, 119u8, 182u8, 220u8, 87u8, 8u8, - 15u8, 123u8, 83u8, 5u8, 188u8, 115u8, 121u8, 163u8, 96u8, 218u8, 3u8, - 106u8, 44u8, 44u8, 187u8, 46u8, 238u8, 80u8, 203u8, 175u8, 155u8, + 23u8, 209u8, 233u8, 126u8, 89u8, 156u8, 193u8, 204u8, 100u8, 90u8, + 14u8, 120u8, 36u8, 167u8, 148u8, 239u8, 179u8, 74u8, 207u8, 83u8, 54u8, + 77u8, 27u8, 135u8, 74u8, 31u8, 33u8, 11u8, 168u8, 239u8, 212u8, 36u8, + ], + ) + } + #[doc = " Storage version of the pallet."] + #[doc = ""] + #[doc = " New networks start with latest version, as determined by the genesis build."] + pub fn storage_version( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_vesting::Releases, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Vesting", + "StorageVersion", + vec![], + [ + 50u8, 143u8, 26u8, 88u8, 129u8, 31u8, 61u8, 118u8, 19u8, 202u8, 119u8, + 160u8, 34u8, 219u8, 60u8, 57u8, 189u8, 66u8, 93u8, 239u8, 121u8, 114u8, + 241u8, 116u8, 0u8, 122u8, 232u8, 94u8, 189u8, 23u8, 45u8, 191u8, ], ) } @@ -18185,32 +17461,13 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " The base amount of currency needed to reserve for creating a multisig execution or to"] - #[doc = " store a dispatch call for later."] - #[doc = ""] - #[doc = " This is held for an additional storage item whose value size is"] - #[doc = " `4 + sizeof((BlockNumber, Balance, AccountId))` bytes and whose key size is"] - #[doc = " `32 + sizeof(AccountId)` bytes."] - pub fn deposit_base(&self) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Multisig", - "DepositBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount of currency needed per unit threshold when creating a multisig execution."] - #[doc = ""] - #[doc = " This is held for adding 32 bytes more into a pre-existing storage value."] - pub fn deposit_factor( + #[doc = " The minimum amount transferred to call `vested_transfer`."] + pub fn min_vested_transfer( &self, ) -> ::subxt::constants::Address<::core::primitive::u128> { ::subxt::constants::Address::new_static( - "Multisig", - "DepositFactor", + "Vesting", + "MinVestedTransfer", [ 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, @@ -18218,13 +17475,12 @@ pub mod api { ], ) } - #[doc = " The maximum amount of signatories allowed in the multisig."] - pub fn max_signatories( + pub fn max_vesting_schedules( &self, ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Multisig", - "MaxSignatories", + "Vesting", + "MaxVestingSchedules", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -18236,11 +17492,11 @@ pub mod api { } } } - pub mod bounties { + pub mod utility { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_bounties::pallet::Error; + pub type Error = runtime_types::pallet_utility::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -18256,55 +17512,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeBounty { - #[codec(compact)] - pub value: ::core::primitive::u128, - pub description: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApproveBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeCurator { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub fee: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnassignCurator { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, + pub struct Batch { + pub calls: ::std::vec::Vec, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18316,9 +17525,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AcceptCurator { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, + pub struct AsDerivative { + pub index: ::core::primitive::u16, + pub call: ::std::boxed::Box, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18330,10 +17539,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AwardBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub struct BatchAll { + pub calls: ::std::vec::Vec, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18345,9 +17552,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, + pub struct DispatchAs { + pub as_origin: ::std::boxed::Box, + pub call: ::std::boxed::Box, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18359,9 +17566,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, + pub struct ForceBatch { + pub calls: ::std::vec::Vec, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18373,283 +17579,191 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExtendBountyExpiry { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - pub remark: ::std::vec::Vec<::core::primitive::u8>, + pub struct WithWeight { + pub call: ::std::boxed::Box, + pub weight: runtime_types::sp_weights::weight_v2::Weight, } pub struct TransactionApi; impl TransactionApi { - #[doc = "Propose a new bounty."] + #[doc = "Send a batch of dispatch calls."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "May be called from any origin except `None`."] #[doc = ""] - #[doc = "Payment: `TipReportDepositBase` will be reserved from the origin account, as well as"] - #[doc = "`DataDepositPerByte` for each byte in `reason`. It will be unreserved upon approval,"] - #[doc = "or slashed when rejected."] + #[doc = "- `calls`: The calls to be dispatched from the same origin. The number of call must not"] + #[doc = " exceed the constant: `batched_calls_limit` (available in constant metadata)."] #[doc = ""] - #[doc = "- `curator`: The curator account whom will manage this bounty."] - #[doc = "- `fee`: The curator fee."] - #[doc = "- `value`: The total payment amount of this bounty, curator fee included."] - #[doc = "- `description`: The description of this bounty."] - pub fn propose_bounty( - &self, - value: ::core::primitive::u128, - description: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "propose_bounty", - ProposeBounty { value, description }, - [ - 99u8, 160u8, 94u8, 74u8, 105u8, 161u8, 123u8, 239u8, 241u8, 117u8, - 97u8, 99u8, 84u8, 101u8, 87u8, 3u8, 88u8, 175u8, 75u8, 59u8, 114u8, - 87u8, 18u8, 113u8, 126u8, 26u8, 42u8, 104u8, 201u8, 128u8, 102u8, - 219u8, - ], - ) - } - #[doc = "Approve a bounty proposal. At a later time, the bounty will be funded and become active"] - #[doc = "and the original deposit will be returned."] + #[doc = "If origin is root then the calls are dispatched without checking origin filter. (This"] + #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] #[doc = ""] - #[doc = "May only be called from `T::ApproveOrigin`."] + #[doc = "## Complexity"] + #[doc = "- O(C) where C is the number of calls to be batched."] #[doc = ""] - #[doc = "# "] - #[doc = "- O(1)."] - #[doc = "# "] - pub fn approve_bounty( + #[doc = "This will return `Ok` in all circumstances. To determine the success of the batch, an"] + #[doc = "event is deposited. If a call failed and the batch was interrupted, then the"] + #[doc = "`BatchInterrupted` event is deposited, along with the number of successful calls made"] + #[doc = "and the error of the failed call. If all were successful, then the `BatchCompleted`"] + #[doc = "event is deposited."] + pub fn batch( &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + calls: ::std::vec::Vec, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Bounties", - "approve_bounty", - ApproveBounty { bounty_id }, + "Utility", + "batch", + Batch { calls }, [ - 82u8, 228u8, 232u8, 103u8, 198u8, 173u8, 190u8, 148u8, 159u8, 86u8, - 48u8, 4u8, 32u8, 169u8, 1u8, 129u8, 96u8, 145u8, 235u8, 68u8, 48u8, - 34u8, 5u8, 1u8, 76u8, 26u8, 100u8, 228u8, 92u8, 198u8, 183u8, 173u8, + 221u8, 151u8, 56u8, 10u8, 237u8, 176u8, 153u8, 88u8, 29u8, 225u8, 27u8, + 231u8, 98u8, 222u8, 51u8, 94u8, 88u8, 16u8, 40u8, 253u8, 61u8, 35u8, + 70u8, 110u8, 15u8, 75u8, 102u8, 140u8, 125u8, 54u8, 223u8, 231u8, ], ) } - #[doc = "Assign a curator to a funded bounty."] + #[doc = "Send a call through an indexed pseudonym of the sender."] #[doc = ""] - #[doc = "May only be called from `T::ApproveOrigin`."] + #[doc = "Filter from origin are passed along. The call will be dispatched with an origin which"] + #[doc = "use the same filter as the origin of this call."] #[doc = ""] - #[doc = "# "] - #[doc = "- O(1)."] - #[doc = "# "] - pub fn propose_curator( + #[doc = "NOTE: If you need to ensure that any account-based filtering is not honored (i.e."] + #[doc = "because you expect `proxy` to have been used prior in the call stack and you do not want"] + #[doc = "the call restrictions to apply to any sub-accounts), then use `as_multi_threshold_1`"] + #[doc = "in the Multisig pallet instead."] + #[doc = ""] + #[doc = "NOTE: Prior to version *12, this was called `as_limited_sub`."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + pub fn as_derivative( &self, - bounty_id: ::core::primitive::u32, - curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + index: ::core::primitive::u16, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Bounties", - "propose_curator", - ProposeCurator { - bounty_id, - curator, - fee, + "Utility", + "as_derivative", + AsDerivative { + index, + call: ::std::boxed::Box::new(call), }, [ - 123u8, 148u8, 21u8, 204u8, 216u8, 6u8, 47u8, 83u8, 182u8, 30u8, 171u8, - 48u8, 193u8, 200u8, 197u8, 147u8, 111u8, 88u8, 14u8, 242u8, 66u8, - 175u8, 241u8, 208u8, 95u8, 151u8, 41u8, 46u8, 213u8, 188u8, 65u8, - 196u8, + 154u8, 209u8, 156u8, 16u8, 183u8, 67u8, 69u8, 4u8, 187u8, 100u8, 27u8, + 221u8, 195u8, 187u8, 165u8, 6u8, 121u8, 94u8, 27u8, 111u8, 214u8, 91u8, + 83u8, 160u8, 242u8, 13u8, 236u8, 70u8, 155u8, 94u8, 78u8, 71u8, ], ) } - #[doc = "Unassign curator from a bounty."] - #[doc = ""] - #[doc = "This function can only be called by the `RejectOrigin` a signed origin."] + #[doc = "Send a batch of dispatch calls and atomically execute them."] + #[doc = "The whole transaction will rollback and fail if any of the calls failed."] #[doc = ""] - #[doc = "If this function is called by the `RejectOrigin`, we assume that the curator is"] - #[doc = "malicious or inactive. As a result, we will slash the curator when possible."] + #[doc = "May be called from any origin except `None`."] #[doc = ""] - #[doc = "If the origin is the curator, we take this as a sign they are unable to do their job and"] - #[doc = "they willingly give up. We could slash them, but for now we allow them to recover their"] - #[doc = "deposit and exit without issue. (We may want to change this if it is abused.)"] + #[doc = "- `calls`: The calls to be dispatched from the same origin. The number of call must not"] + #[doc = " exceed the constant: `batched_calls_limit` (available in constant metadata)."] #[doc = ""] - #[doc = "Finally, the origin can be anyone if and only if the curator is \"inactive\". This allows"] - #[doc = "anyone in the community to call out that a curator is not doing their due diligence, and"] - #[doc = "we should pick a new curator. In this case the curator should also be slashed."] + #[doc = "If origin is root then the calls are dispatched without checking origin filter. (This"] + #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] #[doc = ""] - #[doc = "# "] - #[doc = "- O(1)."] - #[doc = "# "] - pub fn unassign_curator( + #[doc = "## Complexity"] + #[doc = "- O(C) where C is the number of calls to be batched."] + pub fn batch_all( &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + calls: ::std::vec::Vec, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Bounties", - "unassign_curator", - UnassignCurator { bounty_id }, + "Utility", + "batch_all", + BatchAll { calls }, [ - 218u8, 241u8, 247u8, 89u8, 95u8, 120u8, 93u8, 18u8, 85u8, 114u8, 158u8, - 254u8, 68u8, 77u8, 230u8, 186u8, 230u8, 201u8, 63u8, 223u8, 28u8, - 173u8, 244u8, 82u8, 113u8, 177u8, 99u8, 27u8, 207u8, 247u8, 207u8, - 213u8, + 255u8, 107u8, 81u8, 108u8, 78u8, 19u8, 231u8, 220u8, 177u8, 177u8, + 28u8, 24u8, 100u8, 228u8, 227u8, 45u8, 3u8, 51u8, 132u8, 12u8, 48u8, + 158u8, 67u8, 201u8, 193u8, 126u8, 251u8, 177u8, 102u8, 251u8, 90u8, + 81u8, ], ) } - #[doc = "Accept the curator role for a bounty."] - #[doc = "A deposit will be reserved from curator and refund upon successful payout."] + #[doc = "Dispatches a function call with a provided origin."] #[doc = ""] - #[doc = "May only be called from the curator."] + #[doc = "The dispatch origin for this call must be _Root_."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- O(1)."] - #[doc = "# "] - pub fn accept_curator( + pub fn dispatch_as( &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + as_origin: runtime_types::polkadot_runtime::OriginCaller, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Bounties", - "accept_curator", - AcceptCurator { bounty_id }, + "Utility", + "dispatch_as", + DispatchAs { + as_origin: ::std::boxed::Box::new(as_origin), + call: ::std::boxed::Box::new(call), + }, [ - 106u8, 96u8, 22u8, 67u8, 52u8, 109u8, 180u8, 225u8, 122u8, 253u8, - 209u8, 214u8, 132u8, 131u8, 247u8, 131u8, 162u8, 51u8, 144u8, 30u8, - 12u8, 126u8, 50u8, 152u8, 229u8, 119u8, 54u8, 116u8, 112u8, 235u8, - 34u8, 166u8, + 74u8, 215u8, 136u8, 17u8, 87u8, 74u8, 107u8, 176u8, 229u8, 23u8, 109u8, + 233u8, 84u8, 229u8, 27u8, 35u8, 154u8, 93u8, 104u8, 222u8, 71u8, 167u8, + 39u8, 12u8, 235u8, 46u8, 204u8, 125u8, 67u8, 96u8, 236u8, 91u8, ], ) } - #[doc = "Award bounty to a beneficiary account. The beneficiary will be able to claim the funds"] - #[doc = "after a delay."] + #[doc = "Send a batch of dispatch calls."] + #[doc = "Unlike `batch`, it allows errors and won't interrupt."] #[doc = ""] - #[doc = "The dispatch origin for this call must be the curator of this bounty."] + #[doc = "May be called from any origin except `None`."] #[doc = ""] - #[doc = "- `bounty_id`: Bounty ID to award."] - #[doc = "- `beneficiary`: The beneficiary account whom will receive the payout."] + #[doc = "- `calls`: The calls to be dispatched from the same origin. The number of call must not"] + #[doc = " exceed the constant: `batched_calls_limit` (available in constant metadata)."] #[doc = ""] - #[doc = "# "] - #[doc = "- O(1)."] - #[doc = "# "] - pub fn award_bounty( + #[doc = "If origin is root then the calls are dispatch without checking origin filter. (This"] + #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(C) where C is the number of calls to be batched."] + pub fn force_batch( &self, - bounty_id: ::core::primitive::u32, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + calls: ::std::vec::Vec, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Bounties", - "award_bounty", - AwardBounty { - bounty_id, - beneficiary, - }, + "Utility", + "force_batch", + ForceBatch { calls }, [ - 203u8, 164u8, 214u8, 242u8, 1u8, 11u8, 217u8, 32u8, 189u8, 136u8, 29u8, - 230u8, 88u8, 17u8, 134u8, 189u8, 15u8, 204u8, 223u8, 20u8, 168u8, - 182u8, 129u8, 48u8, 83u8, 25u8, 125u8, 25u8, 209u8, 155u8, 170u8, 68u8, + 183u8, 158u8, 12u8, 76u8, 9u8, 251u8, 54u8, 89u8, 139u8, 70u8, 51u8, + 72u8, 181u8, 28u8, 110u8, 207u8, 211u8, 236u8, 224u8, 44u8, 104u8, + 231u8, 238u8, 141u8, 176u8, 194u8, 100u8, 217u8, 63u8, 127u8, 166u8, + 24u8, ], ) } - #[doc = "Claim the payout from an awarded bounty after payout delay."] + #[doc = "Dispatch a function call with a specified weight."] #[doc = ""] - #[doc = "The dispatch origin for this call must be the beneficiary of this bounty."] - #[doc = ""] - #[doc = "- `bounty_id`: Bounty ID to claim."] + #[doc = "This function does not check the weight of the call, and instead allows the"] + #[doc = "Root origin to specify the weight of the call."] #[doc = ""] - #[doc = "# "] - #[doc = "- O(1)."] - #[doc = "# "] - pub fn claim_bounty( + #[doc = "The dispatch origin for this call must be _Root_."] + pub fn with_weight( &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + call: runtime_types::polkadot_runtime::RuntimeCall, + weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Bounties", - "claim_bounty", - ClaimBounty { bounty_id }, + "Utility", + "with_weight", + WithWeight { + call: ::std::boxed::Box::new(call), + weight, + }, [ - 102u8, 95u8, 8u8, 89u8, 4u8, 126u8, 189u8, 28u8, 241u8, 16u8, 125u8, - 218u8, 42u8, 92u8, 177u8, 91u8, 8u8, 235u8, 33u8, 48u8, 64u8, 115u8, - 177u8, 95u8, 242u8, 97u8, 181u8, 50u8, 68u8, 37u8, 59u8, 85u8, - ], - ) - } - #[doc = "Cancel a proposed or active bounty. All the funds will be sent to treasury and"] - #[doc = "the curator deposit will be unreserved if possible."] - #[doc = ""] - #[doc = "Only `T::RejectOrigin` is able to cancel a bounty."] - #[doc = ""] - #[doc = "- `bounty_id`: Bounty ID to cancel."] - #[doc = ""] - #[doc = "# "] - #[doc = "- O(1)."] - #[doc = "# "] - pub fn close_bounty( - &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "close_bounty", - CloseBounty { bounty_id }, - [ - 64u8, 113u8, 151u8, 228u8, 90u8, 55u8, 251u8, 63u8, 27u8, 211u8, 119u8, - 229u8, 137u8, 137u8, 183u8, 240u8, 241u8, 146u8, 69u8, 169u8, 124u8, - 220u8, 236u8, 111u8, 98u8, 188u8, 100u8, 52u8, 127u8, 245u8, 244u8, - 92u8, - ], - ) - } - #[doc = "Extend the expiry time of an active bounty."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be the curator of this bounty."] - #[doc = ""] - #[doc = "- `bounty_id`: Bounty ID to extend."] - #[doc = "- `remark`: additional information."] - #[doc = ""] - #[doc = "# "] - #[doc = "- O(1)."] - #[doc = "# "] - pub fn extend_bounty_expiry( - &self, - bounty_id: ::core::primitive::u32, - remark: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "extend_bounty_expiry", - ExtendBountyExpiry { bounty_id, remark }, - [ - 97u8, 69u8, 157u8, 39u8, 59u8, 72u8, 79u8, 88u8, 104u8, 119u8, 91u8, - 26u8, 73u8, 216u8, 174u8, 95u8, 254u8, 214u8, 63u8, 138u8, 100u8, - 112u8, 185u8, 81u8, 159u8, 247u8, 221u8, 60u8, 87u8, 40u8, 80u8, 202u8, + 206u8, 4u8, 190u8, 61u8, 107u8, 61u8, 249u8, 88u8, 255u8, 170u8, 65u8, + 96u8, 12u8, 54u8, 149u8, 75u8, 250u8, 153u8, 103u8, 142u8, 117u8, 64u8, + 45u8, 189u8, 129u8, 28u8, 143u8, 78u8, 53u8, 188u8, 178u8, 19u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_bounties::pallet::Event; + pub type Event = runtime_types::pallet_utility::pallet::Event; pub mod events { use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "New bounty proposal."] - pub struct BountyProposed { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for BountyProposed { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyProposed"; - } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -18660,17 +17774,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty proposal was rejected; funds were slashed."] - pub struct BountyRejected { + #[doc = "Batch of dispatches did not complete fully. Index of first failing dispatch given, as"] + #[doc = "well as the error."] + pub struct BatchInterrupted { pub index: ::core::primitive::u32, - pub bond: ::core::primitive::u128, + pub error: runtime_types::sp_runtime::DispatchError, } - impl ::subxt::events::StaticEvent for BountyRejected { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyRejected"; + impl ::subxt::events::StaticEvent for BatchInterrupted { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "BatchInterrupted"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -18680,13 +17794,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty proposal is funded and became active."] - pub struct BountyBecameActive { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for BountyBecameActive { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyBecameActive"; + #[doc = "Batch of dispatches completed fully with no error."] + pub struct BatchCompleted; + impl ::subxt::events::StaticEvent for BatchCompleted { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "BatchCompleted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18698,14 +17810,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty is awarded to a beneficiary."] - pub struct BountyAwarded { - pub index: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for BountyAwarded { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyAwarded"; + #[doc = "Batch of dispatches completed but has errors."] + pub struct BatchCompletedWithErrors; + impl ::subxt::events::StaticEvent for BatchCompletedWithErrors { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "BatchCompletedWithErrors"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18717,18 +17826,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty is claimed by beneficiary."] - pub struct BountyClaimed { - pub index: ::core::primitive::u32, - pub payout: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for BountyClaimed { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyClaimed"; + #[doc = "A single item within a Batch of dispatches has completed with no error."] + pub struct ItemCompleted; + impl ::subxt::events::StaticEvent for ItemCompleted { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "ItemCompleted"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -18738,16 +17842,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty is cancelled."] - pub struct BountyCanceled { - pub index: ::core::primitive::u32, + #[doc = "A single item within a Batch of dispatches has completed with error."] + pub struct ItemFailed { + pub error: runtime_types::sp_runtime::DispatchError, } - impl ::subxt::events::StaticEvent for BountyCanceled { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyCanceled"; + impl ::subxt::events::StaticEvent for ItemFailed { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "ItemFailed"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -18757,300 +17860,26 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty expiry is extended."] - pub struct BountyExtended { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for BountyExtended { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyExtended"; + #[doc = "A call was dispatched."] + pub struct DispatchedAs { + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Number of bounty proposals that have been made."] - pub fn bounty_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Bounties", - "BountyCount", - vec![], - [ - 5u8, 188u8, 134u8, 220u8, 64u8, 49u8, 188u8, 98u8, 185u8, 186u8, 230u8, - 65u8, 247u8, 199u8, 28u8, 178u8, 202u8, 193u8, 41u8, 83u8, 115u8, - 253u8, 182u8, 123u8, 92u8, 138u8, 12u8, 31u8, 31u8, 213u8, 23u8, 118u8, - ], - ) - } - #[doc = " Bounties that have been made."] - pub fn bounties( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bounties::Bounty< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Bounties", - "Bounties", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 111u8, 149u8, 33u8, 54u8, 172u8, 143u8, 41u8, 231u8, 184u8, 255u8, - 238u8, 206u8, 87u8, 142u8, 84u8, 10u8, 236u8, 141u8, 190u8, 193u8, - 72u8, 170u8, 19u8, 110u8, 135u8, 136u8, 220u8, 11u8, 99u8, 126u8, - 225u8, 208u8, - ], - ) - } - #[doc = " Bounties that have been made."] - pub fn bounties_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bounties::Bounty< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Bounties", - "Bounties", - Vec::new(), - [ - 111u8, 149u8, 33u8, 54u8, 172u8, 143u8, 41u8, 231u8, 184u8, 255u8, - 238u8, 206u8, 87u8, 142u8, 84u8, 10u8, 236u8, 141u8, 190u8, 193u8, - 72u8, 170u8, 19u8, 110u8, 135u8, 136u8, 220u8, 11u8, 99u8, 126u8, - 225u8, 208u8, - ], - ) - } - #[doc = " The description of each bounty."] - pub fn bounty_descriptions( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec<::core::primitive::u8>, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Bounties", - "BountyDescriptions", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 252u8, 0u8, 9u8, 225u8, 13u8, 135u8, 7u8, 121u8, 154u8, 155u8, 116u8, - 83u8, 160u8, 37u8, 72u8, 11u8, 72u8, 0u8, 248u8, 73u8, 158u8, 84u8, - 125u8, 221u8, 176u8, 231u8, 100u8, 239u8, 111u8, 22u8, 29u8, 13u8, - ], - ) - } - #[doc = " The description of each bounty."] - pub fn bounty_descriptions_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec<::core::primitive::u8>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Bounties", - "BountyDescriptions", - Vec::new(), - [ - 252u8, 0u8, 9u8, 225u8, 13u8, 135u8, 7u8, 121u8, 154u8, 155u8, 116u8, - 83u8, 160u8, 37u8, 72u8, 11u8, 72u8, 0u8, 248u8, 73u8, 158u8, 84u8, - 125u8, 221u8, 176u8, 231u8, 100u8, 239u8, 111u8, 22u8, 29u8, 13u8, - ], - ) - } - #[doc = " Bounty indices that have been approved but not yet funded."] - pub fn bounty_approvals( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Bounties", - "BountyApprovals", - vec![], - [ - 64u8, 93u8, 54u8, 94u8, 122u8, 9u8, 246u8, 86u8, 234u8, 30u8, 125u8, - 132u8, 49u8, 128u8, 1u8, 219u8, 241u8, 13u8, 217u8, 186u8, 48u8, 21u8, - 5u8, 227u8, 71u8, 157u8, 128u8, 226u8, 214u8, 49u8, 249u8, 183u8, - ], - ) - } + impl ::subxt::events::StaticEvent for DispatchedAs { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "DispatchedAs"; } } pub mod constants { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " The amount held on deposit for placing a bounty proposal."] - pub fn bounty_deposit_base( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Bounties", - "BountyDepositBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The delay period for which a bounty beneficiary need to wait before claim the payout."] - pub fn bounty_deposit_payout_delay( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Bounties", - "BountyDepositPayoutDelay", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Bounty duration in blocks."] - pub fn bounty_update_period( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Bounties", - "BountyUpdatePeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The curator deposit is calculated as a percentage of the curator fee."] - #[doc = ""] - #[doc = " This deposit has optional upper and lower bounds with `CuratorDepositMax` and"] - #[doc = " `CuratorDepositMin`."] - pub fn curator_deposit_multiplier( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "Bounties", - "CuratorDepositMultiplier", - [ - 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, - 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, - 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, - ], - ) - } - #[doc = " Maximum amount of funds that should be placed in a deposit for making a proposal."] - pub fn curator_deposit_max( - &self, - ) -> ::subxt::constants::Address<::core::option::Option<::core::primitive::u128>> - { - ::subxt::constants::Address::new_static( - "Bounties", - "CuratorDepositMax", - [ - 84u8, 154u8, 218u8, 83u8, 84u8, 189u8, 32u8, 20u8, 120u8, 194u8, 88u8, - 205u8, 109u8, 216u8, 114u8, 193u8, 120u8, 198u8, 154u8, 237u8, 134u8, - 204u8, 102u8, 247u8, 52u8, 103u8, 231u8, 43u8, 243u8, 122u8, 60u8, - 216u8, - ], - ) - } - #[doc = " Minimum amount of funds that should be placed in a deposit for making a proposal."] - pub fn curator_deposit_min( - &self, - ) -> ::subxt::constants::Address<::core::option::Option<::core::primitive::u128>> - { - ::subxt::constants::Address::new_static( - "Bounties", - "CuratorDepositMin", - [ - 84u8, 154u8, 218u8, 83u8, 84u8, 189u8, 32u8, 20u8, 120u8, 194u8, 88u8, - 205u8, 109u8, 216u8, 114u8, 193u8, 120u8, 198u8, 154u8, 237u8, 134u8, - 204u8, 102u8, 247u8, 52u8, 103u8, 231u8, 43u8, 243u8, 122u8, 60u8, - 216u8, - ], - ) - } - #[doc = " Minimum value for a bounty."] - pub fn bounty_value_minimum( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Bounties", - "BountyValueMinimum", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount held on deposit per byte within the tip report reason or bounty description."] - pub fn data_deposit_per_byte( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Bounties", - "DataDepositPerByte", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Maximum acceptable reason length."] - #[doc = ""] - #[doc = " Benchmarks depend on this value, be sure to update weights file when changing this value"] - pub fn maximum_reason_length( + #[doc = " The limit on the number of batched calls."] + pub fn batched_calls_limit( &self, ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Bounties", - "MaximumReasonLength", + "Utility", + "batched_calls_limit", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -19062,12 +17891,12 @@ pub mod api { } } } - pub mod child_bounties { + pub mod identity { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_child_bounties::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub type Error = runtime_types::pallet_identity::pallet::Error; + #[doc = "Identity pallet declaration."] pub mod calls { use super::root_mod; use super::runtime_types; @@ -19082,12 +17911,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub value: ::core::primitive::u128, - pub description: ::std::vec::Vec<::core::primitive::u8>, + pub struct AddRegistrar { + pub account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19099,14 +17924,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeCurator { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub fee: ::core::primitive::u128, + pub struct SetIdentity { + pub info: ::std::boxed::Box, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19118,11 +17937,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AcceptCurator { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, + pub struct SetSubs { + pub subs: ::std::vec::Vec<( + ::subxt::utils::AccountId32, + runtime_types::pallet_identity::types::Data, + )>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19134,13 +17953,25 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnassignCurator { + pub struct ClearIdentity; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RequestJudgement { #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, + pub reg_index: ::core::primitive::u32, #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, + pub max_fee: ::core::primitive::u128, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -19150,12 +17981,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AwardChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub struct CancelRequest { + pub reg_index: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19167,11 +17994,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimChildBounty { + pub struct SetFee { #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, + pub index: ::core::primitive::u32, #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, + pub fee: ::core::primitive::u128, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19183,328 +18010,554 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, + pub struct SetAccountId { #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, + pub index: ::core::primitive::u32, + pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Add a new child-bounty."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be the curator of parent"] - #[doc = "bounty and the parent bounty must be in \"active\" state."] - #[doc = ""] - #[doc = "Child-bounty gets added successfully & fund gets transferred from"] - #[doc = "parent bounty to child-bounty account, if parent bounty has enough"] - #[doc = "funds, else the call fails."] - #[doc = ""] - #[doc = "Upper bound to maximum number of active child bounties that can be"] - #[doc = "added are managed via runtime trait config"] - #[doc = "[`Config::MaxActiveChildBountyCount`]."] + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetFields { + #[codec(compact)] + pub index: ::core::primitive::u32, + pub fields: runtime_types::pallet_identity::types::BitFlags< + runtime_types::pallet_identity::types::IdentityField, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProvideJudgement { + #[codec(compact)] + pub reg_index: ::core::primitive::u32, + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub judgement: + runtime_types::pallet_identity::types::Judgement<::core::primitive::u128>, + pub identity: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct KillIdentity { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddSub { + pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub data: runtime_types::pallet_identity::types::Data, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RenameSub { + pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub data: runtime_types::pallet_identity::types::Data, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveSub { + pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QuitSub; + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Add a registrar to the system."] #[doc = ""] - #[doc = "If the call is success, the status of child-bounty is updated to"] - #[doc = "\"Added\"."] + #[doc = "The dispatch origin for this call must be `T::RegistrarOrigin`."] #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty for which child-bounty is being added."] - #[doc = "- `value`: Value for executing the proposal."] - #[doc = "- `description`: Text description for the child-bounty."] - pub fn add_child_bounty( + #[doc = "- `account`: the account of the registrar."] + #[doc = ""] + #[doc = "Emits `RegistrarAdded` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(R)` where `R` registrar-count (governance-bounded and code-bounded)."] + pub fn add_registrar( &self, - parent_bounty_id: ::core::primitive::u32, - value: ::core::primitive::u128, - description: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ChildBounties", - "add_child_bounty", - AddChildBounty { - parent_bounty_id, - value, - description, - }, + "Identity", + "add_registrar", + AddRegistrar { account }, [ - 210u8, 156u8, 242u8, 121u8, 28u8, 214u8, 212u8, 203u8, 46u8, 45u8, - 110u8, 25u8, 33u8, 138u8, 136u8, 71u8, 23u8, 102u8, 203u8, 122u8, 77u8, - 162u8, 112u8, 133u8, 43u8, 73u8, 201u8, 176u8, 102u8, 68u8, 188u8, 8u8, + 157u8, 232u8, 252u8, 190u8, 203u8, 233u8, 127u8, 63u8, 111u8, 16u8, + 118u8, 200u8, 31u8, 234u8, 144u8, 111u8, 161u8, 224u8, 217u8, 86u8, + 179u8, 254u8, 162u8, 212u8, 248u8, 8u8, 125u8, 89u8, 23u8, 195u8, 4u8, + 231u8, ], ) } - #[doc = "Propose curator for funded child-bounty."] + #[doc = "Set an account's identity information and reserve the appropriate deposit."] #[doc = ""] - #[doc = "The dispatch origin for this call must be curator of parent bounty."] + #[doc = "If the account already has identity information, the deposit is taken as part payment"] + #[doc = "for the new deposit."] #[doc = ""] - #[doc = "Parent bounty must be in active state, for this child-bounty call to"] - #[doc = "work."] + #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] - #[doc = "Child-bounty must be in \"Added\" state, for processing the call. And"] - #[doc = "state of child-bounty is moved to \"CuratorProposed\" on successful"] - #[doc = "call completion."] + #[doc = "- `info`: The identity information."] #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty."] - #[doc = "- `child_bounty_id`: Index of child bounty."] - #[doc = "- `curator`: Address of child-bounty curator."] - #[doc = "- `fee`: payment fee to child-bounty curator for execution."] - pub fn propose_curator( + #[doc = "Emits `IdentitySet` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(X + X' + R)`"] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)"] + #[doc = " - where `R` judgements-count (registrar-count-bounded)"] + pub fn set_identity( &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + info: runtime_types::pallet_identity::types::IdentityInfo, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ChildBounties", - "propose_curator", - ProposeCurator { - parent_bounty_id, - child_bounty_id, - curator, - fee, + "Identity", + "set_identity", + SetIdentity { + info: ::std::boxed::Box::new(info), }, [ - 37u8, 101u8, 96u8, 75u8, 254u8, 212u8, 42u8, 140u8, 72u8, 107u8, 157u8, - 110u8, 147u8, 236u8, 17u8, 138u8, 161u8, 153u8, 119u8, 177u8, 225u8, - 22u8, 83u8, 5u8, 123u8, 38u8, 30u8, 240u8, 134u8, 208u8, 183u8, 247u8, + 130u8, 89u8, 118u8, 6u8, 134u8, 166u8, 35u8, 192u8, 73u8, 6u8, 171u8, + 20u8, 225u8, 255u8, 152u8, 142u8, 111u8, 8u8, 206u8, 200u8, 64u8, 52u8, + 110u8, 123u8, 42u8, 101u8, 191u8, 242u8, 133u8, 139u8, 154u8, 205u8, ], ) } - #[doc = "Accept the curator role for the child-bounty."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be the curator of this"] - #[doc = "child-bounty."] - #[doc = ""] - #[doc = "A deposit will be reserved from the curator and refund upon"] - #[doc = "successful payout or cancellation."] + #[doc = "Set the sub-accounts of the sender."] #[doc = ""] - #[doc = "Fee for curator is deducted from curator fee of parent bounty."] + #[doc = "Payment: Any aggregate balance reserved by previous `set_subs` calls will be returned"] + #[doc = "and an amount `SubAccountDeposit` will be reserved for each item in `subs`."] #[doc = ""] - #[doc = "Parent bounty must be in active state, for this child-bounty call to"] - #[doc = "work."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] + #[doc = "identity."] #[doc = ""] - #[doc = "Child-bounty must be in \"CuratorProposed\" state, for processing the"] - #[doc = "call. And state of child-bounty is moved to \"Active\" on successful"] - #[doc = "call completion."] + #[doc = "- `subs`: The identity's (new) sub-accounts."] #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty."] - #[doc = "- `child_bounty_id`: Index of child bounty."] - pub fn accept_curator( + #[doc = "## Complexity"] + #[doc = "- `O(P + S)`"] + #[doc = " - where `P` old-subs-count (hard- and deposit-bounded)."] + #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] + pub fn set_subs( &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + subs: ::std::vec::Vec<( + ::subxt::utils::AccountId32, + runtime_types::pallet_identity::types::Data, + )>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ChildBounties", - "accept_curator", - AcceptCurator { - parent_bounty_id, - child_bounty_id, - }, + "Identity", + "set_subs", + SetSubs { subs }, [ - 112u8, 175u8, 238u8, 54u8, 132u8, 20u8, 206u8, 59u8, 220u8, 228u8, - 207u8, 222u8, 132u8, 240u8, 188u8, 0u8, 210u8, 225u8, 234u8, 142u8, - 232u8, 53u8, 64u8, 89u8, 220u8, 29u8, 28u8, 123u8, 125u8, 207u8, 10u8, - 52u8, + 177u8, 219u8, 84u8, 183u8, 5u8, 32u8, 192u8, 82u8, 174u8, 68u8, 198u8, + 224u8, 56u8, 85u8, 134u8, 171u8, 30u8, 132u8, 140u8, 236u8, 117u8, + 24u8, 150u8, 218u8, 146u8, 194u8, 144u8, 92u8, 103u8, 206u8, 46u8, + 90u8, ], ) } - #[doc = "Unassign curator from a child-bounty."] + #[doc = "Clear an account's identity info and all sub-accounts and return all deposits."] #[doc = ""] - #[doc = "The dispatch origin for this call can be either `RejectOrigin`, or"] - #[doc = "the curator of the parent bounty, or any signed origin."] + #[doc = "Payment: All reserved balances on the account are returned."] #[doc = ""] - #[doc = "For the origin other than T::RejectOrigin and the child-bounty"] - #[doc = "curator, parent bounty must be in active state, for this call to"] - #[doc = "work. We allow child-bounty curator and T::RejectOrigin to execute"] - #[doc = "this call irrespective of the parent bounty state."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] + #[doc = "identity."] #[doc = ""] - #[doc = "If this function is called by the `RejectOrigin` or the"] - #[doc = "parent bounty curator, we assume that the child-bounty curator is"] - #[doc = "malicious or inactive. As a result, child-bounty curator deposit is"] - #[doc = "slashed."] + #[doc = "Emits `IdentityCleared` if successful."] #[doc = ""] - #[doc = "If the origin is the child-bounty curator, we take this as a sign"] - #[doc = "that they are unable to do their job, and are willingly giving up."] - #[doc = "We could slash the deposit, but for now we allow them to unreserve"] - #[doc = "their deposit and exit without issue. (We may want to change this if"] - #[doc = "it is abused.)"] + #[doc = "## Complexity"] + #[doc = "- `O(R + S + X)`"] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] + pub fn clear_identity(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Identity", + "clear_identity", + ClearIdentity {}, + [ + 75u8, 44u8, 74u8, 122u8, 149u8, 202u8, 114u8, 230u8, 0u8, 255u8, 140u8, + 122u8, 14u8, 196u8, 205u8, 249u8, 220u8, 94u8, 216u8, 34u8, 63u8, 14u8, + 8u8, 205u8, 74u8, 23u8, 181u8, 129u8, 252u8, 110u8, 231u8, 114u8, + ], + ) + } + #[doc = "Request a judgement from a registrar."] #[doc = ""] - #[doc = "Finally, the origin can be anyone iff the child-bounty curator is"] - #[doc = "\"inactive\". Expiry update due of parent bounty is used to estimate"] - #[doc = "inactive state of child-bounty curator."] + #[doc = "Payment: At most `max_fee` will be reserved for payment to the registrar if judgement"] + #[doc = "given."] #[doc = ""] - #[doc = "This allows anyone in the community to call out that a child-bounty"] - #[doc = "curator is not doing their due diligence, and we should pick a new"] - #[doc = "one. In this case the child-bounty curator deposit is slashed."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a"] + #[doc = "registered identity."] #[doc = ""] - #[doc = "State of child-bounty is moved to Added state on successful call"] - #[doc = "completion."] + #[doc = "- `reg_index`: The index of the registrar whose judgement is requested."] + #[doc = "- `max_fee`: The maximum fee that may be paid. This should just be auto-populated as:"] #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty."] - #[doc = "- `child_bounty_id`: Index of child bounty."] - pub fn unassign_curator( + #[doc = "```nocompile"] + #[doc = "Self::registrars().get(reg_index).unwrap().fee"] + #[doc = "```"] + #[doc = ""] + #[doc = "Emits `JudgementRequested` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(R + X)`."] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] + pub fn request_judgement( &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + reg_index: ::core::primitive::u32, + max_fee: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ChildBounties", - "unassign_curator", - UnassignCurator { - parent_bounty_id, - child_bounty_id, - }, + "Identity", + "request_judgement", + RequestJudgement { reg_index, max_fee }, [ - 228u8, 189u8, 46u8, 75u8, 121u8, 161u8, 150u8, 87u8, 207u8, 86u8, - 192u8, 50u8, 52u8, 61u8, 49u8, 88u8, 178u8, 182u8, 89u8, 72u8, 203u8, - 45u8, 41u8, 26u8, 149u8, 114u8, 154u8, 169u8, 118u8, 128u8, 13u8, - 211u8, + 186u8, 149u8, 61u8, 54u8, 159u8, 194u8, 77u8, 161u8, 220u8, 157u8, 3u8, + 216u8, 23u8, 105u8, 119u8, 76u8, 144u8, 198u8, 157u8, 45u8, 235u8, + 139u8, 87u8, 82u8, 81u8, 12u8, 25u8, 134u8, 225u8, 92u8, 182u8, 101u8, ], ) } - #[doc = "Award child-bounty to a beneficiary."] + #[doc = "Cancel a previous request."] #[doc = ""] - #[doc = "The beneficiary will be able to claim the funds after a delay."] + #[doc = "Payment: A previously reserved deposit is returned on success."] #[doc = ""] - #[doc = "The dispatch origin for this call must be the parent curator or"] - #[doc = "curator of this child-bounty."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a"] + #[doc = "registered identity."] #[doc = ""] - #[doc = "Parent bounty must be in active state, for this child-bounty call to"] - #[doc = "work."] + #[doc = "- `reg_index`: The index of the registrar whose judgement is no longer requested."] #[doc = ""] - #[doc = "Child-bounty must be in active state, for processing the call. And"] - #[doc = "state of child-bounty is moved to \"PendingPayout\" on successful call"] - #[doc = "completion."] + #[doc = "Emits `JudgementUnrequested` if successful."] #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty."] - #[doc = "- `child_bounty_id`: Index of child bounty."] - #[doc = "- `beneficiary`: Beneficiary account."] - pub fn award_child_bounty( + #[doc = "## Complexity"] + #[doc = "- `O(R + X)`."] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] + pub fn cancel_request( &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + reg_index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ChildBounties", - "award_child_bounty", - AwardChildBounty { - parent_bounty_id, - child_bounty_id, - beneficiary, - }, + "Identity", + "cancel_request", + CancelRequest { reg_index }, [ - 231u8, 185u8, 73u8, 232u8, 92u8, 116u8, 204u8, 165u8, 216u8, 194u8, - 151u8, 21u8, 127u8, 239u8, 78u8, 45u8, 27u8, 252u8, 119u8, 23u8, 71u8, - 140u8, 137u8, 209u8, 189u8, 128u8, 126u8, 247u8, 13u8, 42u8, 68u8, - 134u8, + 83u8, 180u8, 239u8, 126u8, 32u8, 51u8, 17u8, 20u8, 180u8, 3u8, 59u8, + 96u8, 24u8, 32u8, 136u8, 92u8, 58u8, 254u8, 68u8, 70u8, 50u8, 11u8, + 51u8, 91u8, 180u8, 79u8, 81u8, 84u8, 216u8, 138u8, 6u8, 215u8, ], ) } - #[doc = "Claim the payout from an awarded child-bounty after payout delay."] - #[doc = ""] - #[doc = "The dispatch origin for this call may be any signed origin."] - #[doc = ""] - #[doc = "Call works independent of parent bounty state, No need for parent"] - #[doc = "bounty to be in active state."] + #[doc = "Set the fee required for a judgement to be requested from a registrar."] #[doc = ""] - #[doc = "The Beneficiary is paid out with agreed bounty value. Curator fee is"] - #[doc = "paid & curator deposit is unreserved."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] + #[doc = "of the registrar whose index is `index`."] #[doc = ""] - #[doc = "Child-bounty must be in \"PendingPayout\" state, for processing the"] - #[doc = "call. And instance of child-bounty is removed from the state on"] - #[doc = "successful call completion."] + #[doc = "- `index`: the index of the registrar whose fee is to be set."] + #[doc = "- `fee`: the new fee."] #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty."] - #[doc = "- `child_bounty_id`: Index of child bounty."] - pub fn claim_child_bounty( + #[doc = "## Complexity"] + #[doc = "- `O(R)`."] + #[doc = " - where `R` registrar-count (governance-bounded)."] + pub fn set_fee( &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + index: ::core::primitive::u32, + fee: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ChildBounties", - "claim_child_bounty", - ClaimChildBounty { - parent_bounty_id, - child_bounty_id, - }, + "Identity", + "set_fee", + SetFee { index, fee }, [ - 134u8, 243u8, 151u8, 228u8, 38u8, 174u8, 96u8, 140u8, 104u8, 124u8, - 166u8, 206u8, 126u8, 211u8, 17u8, 100u8, 172u8, 5u8, 234u8, 171u8, - 125u8, 2u8, 191u8, 163u8, 72u8, 29u8, 163u8, 107u8, 65u8, 92u8, 41u8, - 45u8, + 21u8, 157u8, 123u8, 182u8, 160u8, 190u8, 117u8, 37u8, 136u8, 133u8, + 104u8, 234u8, 31u8, 145u8, 115u8, 154u8, 125u8, 40u8, 2u8, 87u8, 118u8, + 56u8, 247u8, 73u8, 89u8, 0u8, 251u8, 3u8, 58u8, 105u8, 239u8, 211u8, ], ) } - #[doc = "Cancel a proposed or active child-bounty. Child-bounty account funds"] - #[doc = "are transferred to parent bounty account. The child-bounty curator"] - #[doc = "deposit may be unreserved if possible."] + #[doc = "Change the account associated with a registrar."] #[doc = ""] - #[doc = "The dispatch origin for this call must be either parent curator or"] - #[doc = "`T::RejectOrigin`."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] + #[doc = "of the registrar whose index is `index`."] #[doc = ""] - #[doc = "If the state of child-bounty is `Active`, curator deposit is"] - #[doc = "unreserved."] + #[doc = "- `index`: the index of the registrar whose fee is to be set."] + #[doc = "- `new`: the new account ID."] #[doc = ""] - #[doc = "If the state of child-bounty is `PendingPayout`, call fails &"] - #[doc = "returns `PendingPayout` error."] + #[doc = "## Complexity"] + #[doc = "- `O(R)`."] + #[doc = " - where `R` registrar-count (governance-bounded)."] + pub fn set_account_id( + &self, + index: ::core::primitive::u32, + new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Identity", + "set_account_id", + SetAccountId { index, new }, + [ + 13u8, 91u8, 36u8, 7u8, 88u8, 64u8, 151u8, 104u8, 94u8, 174u8, 195u8, + 99u8, 97u8, 181u8, 236u8, 251u8, 26u8, 236u8, 234u8, 40u8, 183u8, 38u8, + 220u8, 216u8, 48u8, 115u8, 7u8, 230u8, 216u8, 28u8, 123u8, 11u8, + ], + ) + } + #[doc = "Set the field information for a registrar."] #[doc = ""] - #[doc = "For the origin other than T::RejectOrigin, parent bounty must be in"] - #[doc = "active state, for this child-bounty call to work. For origin"] - #[doc = "T::RejectOrigin execution is forced."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] + #[doc = "of the registrar whose index is `index`."] #[doc = ""] - #[doc = "Instance of child-bounty is removed from the state on successful"] - #[doc = "call completion."] + #[doc = "- `index`: the index of the registrar whose fee is to be set."] + #[doc = "- `fields`: the fields that the registrar concerns themselves with."] #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty."] - #[doc = "- `child_bounty_id`: Index of child bounty."] - pub fn close_child_bounty( + #[doc = "## Complexity"] + #[doc = "- `O(R)`."] + #[doc = " - where `R` registrar-count (governance-bounded)."] + pub fn set_fields( &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + index: ::core::primitive::u32, + fields: runtime_types::pallet_identity::types::BitFlags< + runtime_types::pallet_identity::types::IdentityField, + >, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ChildBounties", - "close_child_bounty", - CloseChildBounty { - parent_bounty_id, - child_bounty_id, - }, + "Identity", + "set_fields", + SetFields { index, fields }, [ - 40u8, 0u8, 235u8, 75u8, 36u8, 196u8, 29u8, 26u8, 30u8, 172u8, 240u8, - 44u8, 129u8, 243u8, 55u8, 211u8, 96u8, 159u8, 72u8, 96u8, 142u8, 68u8, - 41u8, 238u8, 157u8, 167u8, 90u8, 141u8, 213u8, 249u8, 222u8, 22u8, + 50u8, 196u8, 179u8, 71u8, 66u8, 65u8, 235u8, 7u8, 51u8, 14u8, 81u8, + 173u8, 201u8, 58u8, 6u8, 151u8, 174u8, 245u8, 102u8, 184u8, 28u8, 84u8, + 125u8, 93u8, 126u8, 134u8, 92u8, 203u8, 200u8, 129u8, 240u8, 252u8, ], ) } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_child_bounties::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A child-bounty is added."] - pub struct Added { - pub index: ::core::primitive::u32, - pub child_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Added { - const PALLET: &'static str = "ChildBounties"; - const EVENT: &'static str = "Added"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, + #[doc = "Provide a judgement for an account's identity."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] + #[doc = "of the registrar whose index is `reg_index`."] + #[doc = ""] + #[doc = "- `reg_index`: the index of the registrar whose judgement is being made."] + #[doc = "- `target`: the account whose identity the judgement is upon. This must be an account"] + #[doc = " with a registered identity."] + #[doc = "- `judgement`: the judgement of the registrar of index `reg_index` about `target`."] + #[doc = "- `identity`: The hash of the [`IdentityInfo`] for that the judgement is provided."] + #[doc = ""] + #[doc = "Emits `JudgementGiven` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(R + X)`."] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] + pub fn provide_judgement( + &self, + reg_index: ::core::primitive::u32, + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + judgement: runtime_types::pallet_identity::types::Judgement< + ::core::primitive::u128, + >, + identity: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Identity", + "provide_judgement", + ProvideJudgement { + reg_index, + target, + judgement, + identity, + }, + [ + 147u8, 66u8, 29u8, 90u8, 149u8, 65u8, 161u8, 115u8, 12u8, 254u8, 188u8, + 248u8, 165u8, 115u8, 191u8, 2u8, 167u8, 223u8, 199u8, 169u8, 203u8, + 64u8, 101u8, 217u8, 73u8, 185u8, 93u8, 109u8, 22u8, 184u8, 146u8, 73u8, + ], + ) + } + #[doc = "Remove an account's identity and sub-account information and slash the deposits."] + #[doc = ""] + #[doc = "Payment: Reserved balances from `set_subs` and `set_identity` are slashed and handled by"] + #[doc = "`Slash`. Verification request deposits are not returned; they should be cancelled"] + #[doc = "manually using `cancel_request`."] + #[doc = ""] + #[doc = "The dispatch origin for this call must match `T::ForceOrigin`."] + #[doc = ""] + #[doc = "- `target`: the account whose identity the judgement is upon. This must be an account"] + #[doc = " with a registered identity."] + #[doc = ""] + #[doc = "Emits `IdentityKilled` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(R + S + X)`"] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] + pub fn kill_identity( + &self, + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Identity", + "kill_identity", + KillIdentity { target }, + [ + 76u8, 13u8, 158u8, 219u8, 221u8, 0u8, 151u8, 241u8, 137u8, 136u8, + 179u8, 194u8, 188u8, 230u8, 56u8, 16u8, 254u8, 28u8, 127u8, 216u8, + 205u8, 117u8, 224u8, 121u8, 240u8, 231u8, 126u8, 181u8, 230u8, 68u8, + 13u8, 174u8, + ], + ) + } + #[doc = "Add the given account to the sender's subs."] + #[doc = ""] + #[doc = "Payment: Balance reserved by a previous `set_subs` call for one sub will be repatriated"] + #[doc = "to the sender."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] + #[doc = "sub identity of `sub`."] + pub fn add_sub( + &self, + sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + data: runtime_types::pallet_identity::types::Data, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Identity", + "add_sub", + AddSub { sub, data }, + [ + 122u8, 218u8, 25u8, 93u8, 33u8, 176u8, 191u8, 254u8, 223u8, 147u8, + 100u8, 135u8, 86u8, 71u8, 47u8, 163u8, 105u8, 222u8, 162u8, 173u8, + 207u8, 182u8, 130u8, 128u8, 214u8, 242u8, 101u8, 250u8, 242u8, 24u8, + 17u8, 84u8, + ], + ) + } + #[doc = "Alter the associated name of the given sub-account."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] + #[doc = "sub identity of `sub`."] + pub fn rename_sub( + &self, + sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + data: runtime_types::pallet_identity::types::Data, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Identity", + "rename_sub", + RenameSub { sub, data }, + [ + 166u8, 167u8, 49u8, 114u8, 199u8, 168u8, 187u8, 221u8, 100u8, 85u8, + 147u8, 211u8, 157u8, 31u8, 109u8, 135u8, 194u8, 135u8, 15u8, 89u8, + 59u8, 57u8, 252u8, 163u8, 9u8, 138u8, 216u8, 189u8, 177u8, 42u8, 96u8, + 34u8, + ], + ) + } + #[doc = "Remove the given account from the sender's subs."] + #[doc = ""] + #[doc = "Payment: Balance reserved by a previous `set_subs` call for one sub will be repatriated"] + #[doc = "to the sender."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] + #[doc = "sub identity of `sub`."] + pub fn remove_sub( + &self, + sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Identity", + "remove_sub", + RemoveSub { sub }, + [ + 106u8, 223u8, 210u8, 67u8, 54u8, 11u8, 144u8, 222u8, 42u8, 46u8, 157u8, + 33u8, 13u8, 245u8, 166u8, 195u8, 227u8, 81u8, 224u8, 149u8, 154u8, + 158u8, 187u8, 203u8, 215u8, 91u8, 43u8, 105u8, 69u8, 213u8, 141u8, + 124u8, + ], + ) + } + #[doc = "Remove the sender as a sub-account."] + #[doc = ""] + #[doc = "Payment: Balance reserved by a previous `set_subs` call for one sub will be repatriated"] + #[doc = "to the sender (*not* the original depositor)."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] + #[doc = "super-identity."] + #[doc = ""] + #[doc = "NOTE: This should not normally be used, but is provided in the case that the non-"] + #[doc = "controller of an account is maliciously registered as a sub-account."] + pub fn quit_sub(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Identity", + "quit_sub", + QuitSub {}, + [ + 62u8, 57u8, 73u8, 72u8, 119u8, 216u8, 250u8, 155u8, 57u8, 169u8, 157u8, + 44u8, 87u8, 51u8, 63u8, 231u8, 77u8, 7u8, 0u8, 119u8, 244u8, 42u8, + 179u8, 51u8, 254u8, 240u8, 55u8, 25u8, 142u8, 38u8, 87u8, 44u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_identity::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, :: subxt :: ext :: scale_encode :: EncodeAsType, @@ -19513,15 +18566,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A child-bounty is awarded to a beneficiary."] - pub struct Awarded { - pub index: ::core::primitive::u32, - pub child_index: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::AccountId32, + #[doc = "A name was set or reset (which will remove all judgements)."] + pub struct IdentitySet { + pub who: ::subxt::utils::AccountId32, } - impl ::subxt::events::StaticEvent for Awarded { - const PALLET: &'static str = "ChildBounties"; - const EVENT: &'static str = "Awarded"; + impl ::subxt::events::StaticEvent for IdentitySet { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "IdentitySet"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19533,16 +18584,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A child-bounty is claimed by beneficiary."] - pub struct Claimed { - pub index: ::core::primitive::u32, - pub child_index: ::core::primitive::u32, - pub payout: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::AccountId32, + #[doc = "A name was cleared, and the given balance returned."] + pub struct IdentityCleared { + pub who: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for Claimed { - const PALLET: &'static str = "ChildBounties"; - const EVENT: &'static str = "Claimed"; + impl ::subxt::events::StaticEvent for IdentityCleared { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "IdentityCleared"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19554,236 +18603,354 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A child-bounty is cancelled."] - pub struct Canceled { - pub index: ::core::primitive::u32, - pub child_index: ::core::primitive::u32, + #[doc = "A name was removed and the given balance slashed."] + pub struct IdentityKilled { + pub who: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for Canceled { - const PALLET: &'static str = "ChildBounties"; - const EVENT: &'static str = "Canceled"; + impl ::subxt::events::StaticEvent for IdentityKilled { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "IdentityKilled"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A judgement was asked from a registrar."] + pub struct JudgementRequested { + pub who: ::subxt::utils::AccountId32, + pub registrar_index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for JudgementRequested { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "JudgementRequested"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A judgement request was retracted."] + pub struct JudgementUnrequested { + pub who: ::subxt::utils::AccountId32, + pub registrar_index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for JudgementUnrequested { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "JudgementUnrequested"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A judgement was given by a registrar."] + pub struct JudgementGiven { + pub target: ::subxt::utils::AccountId32, + pub registrar_index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for JudgementGiven { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "JudgementGiven"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A registrar was added."] + pub struct RegistrarAdded { + pub registrar_index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for RegistrarAdded { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "RegistrarAdded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A sub-identity was added to an identity and the deposit paid."] + pub struct SubIdentityAdded { + pub sub: ::subxt::utils::AccountId32, + pub main: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for SubIdentityAdded { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "SubIdentityAdded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A sub-identity was removed from an identity and the deposit freed."] + pub struct SubIdentityRemoved { + pub sub: ::subxt::utils::AccountId32, + pub main: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for SubIdentityRemoved { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "SubIdentityRemoved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A sub-identity was cleared, and the given deposit repatriated from the"] + #[doc = "main identity account to the sub-identity account."] + pub struct SubIdentityRevoked { + pub sub: ::subxt::utils::AccountId32, + pub main: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for SubIdentityRevoked { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "SubIdentityRevoked"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " Number of total child bounties."] - pub fn child_bounty_count( + #[doc = " Information that is pertinent to identify the entity behind an account."] + #[doc = ""] + #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] + pub fn identity_of( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, + runtime_types::pallet_identity::types::Registration<::core::primitive::u128>, ::subxt::storage::address::Yes, (), - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBountyCount", - vec![], - [ - 46u8, 10u8, 183u8, 160u8, 98u8, 215u8, 39u8, 253u8, 81u8, 94u8, 114u8, - 147u8, 115u8, 162u8, 33u8, 117u8, 160u8, 214u8, 167u8, 7u8, 109u8, - 143u8, 158u8, 1u8, 200u8, 205u8, 17u8, 93u8, 89u8, 26u8, 30u8, 95u8, - ], - ) - } - #[doc = " Number of child bounties per parent bounty."] - #[doc = " Map of parent bounty index to number of child bounties."] - pub fn parent_child_bounties( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ParentChildBounties", + "Identity", + "IdentityOf", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 127u8, 161u8, 181u8, 79u8, 235u8, 196u8, 252u8, 162u8, 39u8, 15u8, - 251u8, 49u8, 125u8, 80u8, 101u8, 24u8, 234u8, 88u8, 212u8, 126u8, 63u8, - 63u8, 19u8, 75u8, 137u8, 125u8, 38u8, 250u8, 77u8, 49u8, 76u8, 188u8, + 193u8, 195u8, 180u8, 188u8, 129u8, 250u8, 180u8, 219u8, 22u8, 95u8, + 175u8, 170u8, 143u8, 188u8, 80u8, 124u8, 234u8, 228u8, 245u8, 39u8, + 72u8, 153u8, 107u8, 199u8, 23u8, 75u8, 47u8, 247u8, 104u8, 208u8, + 171u8, 82u8, ], ) } - #[doc = " Number of child bounties per parent bounty."] - #[doc = " Map of parent bounty index to number of child bounties."] - pub fn parent_child_bounties_root( + #[doc = " Information that is pertinent to identify the entity behind an account."] + #[doc = ""] + #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] + pub fn identity_of_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + runtime_types::pallet_identity::types::Registration<::core::primitive::u128>, + (), (), - ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ParentChildBounties", + "Identity", + "IdentityOf", Vec::new(), [ - 127u8, 161u8, 181u8, 79u8, 235u8, 196u8, 252u8, 162u8, 39u8, 15u8, - 251u8, 49u8, 125u8, 80u8, 101u8, 24u8, 234u8, 88u8, 212u8, 126u8, 63u8, - 63u8, 19u8, 75u8, 137u8, 125u8, 38u8, 250u8, 77u8, 49u8, 76u8, 188u8, + 193u8, 195u8, 180u8, 188u8, 129u8, 250u8, 180u8, 219u8, 22u8, 95u8, + 175u8, 170u8, 143u8, 188u8, 80u8, 124u8, 234u8, 228u8, 245u8, 39u8, + 72u8, 153u8, 107u8, 199u8, 23u8, 75u8, 47u8, 247u8, 104u8, 208u8, + 171u8, 82u8, ], ) } - #[doc = " Child bounties that have been added."] - pub fn child_bounties( + #[doc = " The super-identity of an alternative \"sub\" identity together with its name, within that"] + #[doc = " context. If the account is not some other account's sub-identity, then just `None`."] + pub fn super_of( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::core::primitive::u32>, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_child_bounties::ChildBounty< + ( ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - >, + runtime_types::pallet_identity::types::Data, + ), ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBounties", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + "Identity", + "SuperOf", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 66u8, 132u8, 251u8, 223u8, 216u8, 52u8, 162u8, 150u8, 229u8, 239u8, - 219u8, 182u8, 211u8, 228u8, 181u8, 46u8, 243u8, 151u8, 111u8, 235u8, - 105u8, 40u8, 39u8, 10u8, 245u8, 113u8, 78u8, 116u8, 219u8, 186u8, - 165u8, 91u8, + 170u8, 249u8, 112u8, 249u8, 75u8, 176u8, 21u8, 29u8, 152u8, 149u8, + 69u8, 113u8, 20u8, 92u8, 113u8, 130u8, 135u8, 62u8, 18u8, 204u8, 166u8, + 193u8, 133u8, 167u8, 248u8, 117u8, 80u8, 137u8, 158u8, 111u8, 100u8, + 137u8, ], ) } - #[doc = " Child bounties that have been added."] - pub fn child_bounties_root( + #[doc = " The super-identity of an alternative \"sub\" identity together with its name, within that"] + #[doc = " context. If the account is not some other account's sub-identity, then just `None`."] + pub fn super_of_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_child_bounties::ChildBounty< + ( ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - >, + runtime_types::pallet_identity::types::Data, + ), (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBounties", + "Identity", + "SuperOf", Vec::new(), [ - 66u8, 132u8, 251u8, 223u8, 216u8, 52u8, 162u8, 150u8, 229u8, 239u8, - 219u8, 182u8, 211u8, 228u8, 181u8, 46u8, 243u8, 151u8, 111u8, 235u8, - 105u8, 40u8, 39u8, 10u8, 245u8, 113u8, 78u8, 116u8, 219u8, 186u8, - 165u8, 91u8, + 170u8, 249u8, 112u8, 249u8, 75u8, 176u8, 21u8, 29u8, 152u8, 149u8, + 69u8, 113u8, 20u8, 92u8, 113u8, 130u8, 135u8, 62u8, 18u8, 204u8, 166u8, + 193u8, 133u8, 167u8, 248u8, 117u8, 80u8, 137u8, 158u8, 111u8, 100u8, + 137u8, ], ) } - #[doc = " The description of each child-bounty."] - pub fn child_bounty_descriptions( + #[doc = " Alternative \"sub\" identities of this account."] + #[doc = ""] + #[doc = " The first item is the deposit, the second is a vector of the accounts."] + #[doc = ""] + #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] + pub fn subs_of( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec<::core::primitive::u8>, + ( + ::core::primitive::u128, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::AccountId32, + >, + ), + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBountyDescriptions", + "Identity", + "SubsOf", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 193u8, 200u8, 40u8, 30u8, 14u8, 71u8, 90u8, 42u8, 58u8, 253u8, 225u8, - 158u8, 172u8, 10u8, 45u8, 238u8, 36u8, 144u8, 184u8, 153u8, 11u8, - 157u8, 125u8, 220u8, 175u8, 31u8, 28u8, 93u8, 207u8, 212u8, 141u8, - 74u8, + 128u8, 15u8, 175u8, 155u8, 216u8, 225u8, 200u8, 169u8, 215u8, 206u8, + 110u8, 22u8, 204u8, 89u8, 212u8, 210u8, 159u8, 169u8, 53u8, 7u8, 44u8, + 164u8, 91u8, 151u8, 7u8, 227u8, 38u8, 230u8, 175u8, 84u8, 6u8, 4u8, ], ) } - #[doc = " The description of each child-bounty."] - pub fn child_bounty_descriptions_root( + #[doc = " Alternative \"sub\" identities of this account."] + #[doc = ""] + #[doc = " The first item is the deposit, the second is a vector of the accounts."] + #[doc = ""] + #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] + pub fn subs_of_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec<::core::primitive::u8>, - (), + ( + ::core::primitive::u128, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::AccountId32, + >, + ), (), ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBountyDescriptions", + "Identity", + "SubsOf", Vec::new(), [ - 193u8, 200u8, 40u8, 30u8, 14u8, 71u8, 90u8, 42u8, 58u8, 253u8, 225u8, - 158u8, 172u8, 10u8, 45u8, 238u8, 36u8, 144u8, 184u8, 153u8, 11u8, - 157u8, 125u8, 220u8, 175u8, 31u8, 28u8, 93u8, 207u8, 212u8, 141u8, - 74u8, + 128u8, 15u8, 175u8, 155u8, 216u8, 225u8, 200u8, 169u8, 215u8, 206u8, + 110u8, 22u8, 204u8, 89u8, 212u8, 210u8, 159u8, 169u8, 53u8, 7u8, 44u8, + 164u8, 91u8, 151u8, 7u8, 227u8, 38u8, 230u8, 175u8, 84u8, 6u8, 4u8, ], ) } - #[doc = " The cumulative child-bounty curator fee for each parent bounty."] - pub fn children_curator_fees( + #[doc = " The set of registrars. Not expected to get very big as can only be added through a"] + #[doc = " special origin (likely a council motion)."] + #[doc = ""] + #[doc = " The index into this can be cast to `RegistrarIndex` to get a valid value."] + pub fn registrars( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::option::Option< + runtime_types::pallet_identity::types::RegistrarInfo< + ::core::primitive::u128, + ::subxt::utils::AccountId32, + >, + >, + >, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildrenCuratorFees", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 174u8, 128u8, 86u8, 179u8, 133u8, 76u8, 98u8, 169u8, 234u8, 166u8, - 249u8, 214u8, 172u8, 171u8, 8u8, 161u8, 105u8, 69u8, 148u8, 151u8, - 35u8, 174u8, 118u8, 139u8, 101u8, 56u8, 85u8, 211u8, 121u8, 168u8, 0u8, - 216u8, - ], - ) - } - #[doc = " The cumulative child-bounty curator fee for each parent bounty."] - pub fn children_curator_fees_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildrenCuratorFees", - Vec::new(), + "Identity", + "Registrars", + vec![], [ - 174u8, 128u8, 86u8, 179u8, 133u8, 76u8, 98u8, 169u8, 234u8, 166u8, - 249u8, 214u8, 172u8, 171u8, 8u8, 161u8, 105u8, 69u8, 148u8, 151u8, - 35u8, 174u8, 118u8, 139u8, 101u8, 56u8, 85u8, 211u8, 121u8, 168u8, 0u8, - 216u8, + 157u8, 87u8, 39u8, 240u8, 154u8, 54u8, 241u8, 229u8, 76u8, 9u8, 62u8, + 252u8, 40u8, 143u8, 186u8, 182u8, 233u8, 187u8, 251u8, 61u8, 236u8, + 229u8, 19u8, 55u8, 42u8, 36u8, 82u8, 173u8, 215u8, 155u8, 229u8, 111u8, ], ) } @@ -19793,13 +18960,57 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " Maximum number of child bounties that can be added to a parent bounty."] - pub fn max_active_child_bounty_count( + #[doc = " The amount held on deposit for a registered identity"] + pub fn basic_deposit( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Identity", + "BasicDeposit", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The amount held on deposit per additional field for a registered identity."] + pub fn field_deposit( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Identity", + "FieldDeposit", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The amount held on deposit for a registered subaccount. This should account for the fact"] + #[doc = " that one storage item's value will increase by the size of an account ID, and there will"] + #[doc = " be another trie item whose value is the size of an account ID plus 32 bytes."] + pub fn sub_account_deposit( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Identity", + "SubAccountDeposit", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The maximum number of sub-accounts allowed per identified account."] + pub fn max_sub_accounts( &self, ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "ChildBounties", - "MaxActiveChildBountyCount", + "Identity", + "MaxSubAccounts", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -19808,28 +19019,46 @@ pub mod api { ], ) } - #[doc = " Minimum value for a child-bounty."] - pub fn child_bounty_value_minimum( + #[doc = " Maximum number of additional fields that may be stored in an ID. Needed to bound the I/O"] + #[doc = " required to access an identity, but can be pretty high."] + pub fn max_additional_fields( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { + ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "ChildBounties", - "ChildBountyValueMinimum", + "Identity", + "MaxAdditionalFields", [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " Maxmimum number of registrars allowed in the system. Needed to bound the complexity"] + #[doc = " of, e.g., updating judgements."] + pub fn max_registrars( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Identity", + "MaxRegistrars", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } } } } - pub mod tips { + pub mod proxy { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_tips::pallet::Error; + pub type Error = runtime_types::pallet_proxy::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -19845,9 +19074,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportAwesome { - pub reason: ::std::vec::Vec<::core::primitive::u8>, - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub struct Proxy { + pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub force_proxy_type: + ::core::option::Option, + pub call: ::std::boxed::Box, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19859,8 +19090,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RetractTip { - pub hash: ::subxt::utils::H256, + pub struct AddProxy { + pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub delay: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19872,11 +19105,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TipNew { - pub reason: ::std::vec::Vec<::core::primitive::u8>, - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub tip_value: ::core::primitive::u128, + pub struct RemoveProxy { + pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub delay: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19888,10 +19120,40 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Tip { - pub hash: ::subxt::utils::H256, + pub struct RemoveProxies; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CreatePure { + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub delay: ::core::primitive::u32, + pub index: ::core::primitive::u16, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct KillPure { + pub spawner: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub index: ::core::primitive::u16, #[codec(compact)] - pub tip_value: ::core::primitive::u128, + pub height: ::core::primitive::u32, + #[codec(compact)] + pub ext_index: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19903,8 +19165,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseTip { - pub hash: ::subxt::utils::H256, + pub struct Announce { + pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub call_hash: ::subxt::utils::H256, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19916,227 +19179,363 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SlashTip { - pub hash: ::subxt::utils::H256, + pub struct RemoveAnnouncement { + pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub call_hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RejectAnnouncement { + pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub call_hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProxyAnnounced { + pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub force_proxy_type: + ::core::option::Option, + pub call: ::std::boxed::Box, } pub struct TransactionApi; impl TransactionApi { - #[doc = "Report something `reason` that deserves a tip and claim any eventual the finder's fee."] + #[doc = "Dispatch the given `call` from an account that the sender is authorised for through"] + #[doc = "`add_proxy`."] #[doc = ""] #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] - #[doc = "Payment: `TipReportDepositBase` will be reserved from the origin account, as well as"] - #[doc = "`DataDepositPerByte` for each byte in `reason`."] - #[doc = ""] - #[doc = "- `reason`: The reason for, or the thing that deserves, the tip; generally this will be"] - #[doc = " a UTF-8-encoded URL."] - #[doc = "- `who`: The account which should be credited for the tip."] - #[doc = ""] - #[doc = "Emits `NewTip` if successful."] - #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(R)` where `R` length of `reason`."] - #[doc = " - encoding and hashing of 'reason'"] - #[doc = "- DbReads: `Reasons`, `Tips`"] - #[doc = "- DbWrites: `Reasons`, `Tips`"] - #[doc = "# "] - pub fn report_awesome( + #[doc = "Parameters:"] + #[doc = "- `real`: The account that the proxy will make a call on behalf of."] + #[doc = "- `force_proxy_type`: Specify the exact proxy type to be used and checked for this call."] + #[doc = "- `call`: The call to be made by the `real` account."] + pub fn proxy( &self, - reason: ::std::vec::Vec<::core::primitive::u8>, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + force_proxy_type: ::core::option::Option< + runtime_types::polkadot_runtime::ProxyType, + >, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Tips", - "report_awesome", - ReportAwesome { reason, who }, + "Proxy", + "proxy", + Proxy { + real, + force_proxy_type, + call: ::std::boxed::Box::new(call), + }, [ - 126u8, 68u8, 2u8, 54u8, 195u8, 15u8, 43u8, 27u8, 183u8, 254u8, 157u8, - 163u8, 252u8, 14u8, 207u8, 251u8, 215u8, 111u8, 98u8, 209u8, 150u8, - 11u8, 240u8, 177u8, 106u8, 93u8, 191u8, 31u8, 62u8, 11u8, 223u8, 79u8, + 29u8, 33u8, 67u8, 179u8, 234u8, 241u8, 45u8, 167u8, 110u8, 23u8, 85u8, + 27u8, 1u8, 184u8, 223u8, 187u8, 129u8, 206u8, 75u8, 237u8, 235u8, + 207u8, 43u8, 201u8, 194u8, 145u8, 149u8, 184u8, 95u8, 185u8, 205u8, + 248u8, ], ) } - #[doc = "Retract a prior tip-report from `report_awesome`, and cancel the process of tipping."] - #[doc = ""] - #[doc = "If successful, the original deposit will be unreserved."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the tip identified by `hash`"] - #[doc = "must have been reported by the signing account through `report_awesome` (and not"] - #[doc = "through `tip_new`)."] - #[doc = ""] - #[doc = "- `hash`: The identity of the open tip for which a tip value is declared. This is formed"] - #[doc = " as the hash of the tuple of the original tip `reason` and the beneficiary account ID."] + #[doc = "Register a proxy account for the sender that is able to make calls on its behalf."] #[doc = ""] - #[doc = "Emits `TipRetracted` if successful."] + #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(1)`"] - #[doc = " - Depends on the length of `T::Hash` which is fixed."] - #[doc = "- DbReads: `Tips`, `origin account`"] - #[doc = "- DbWrites: `Reasons`, `Tips`, `origin account`"] - #[doc = "# "] - pub fn retract_tip( + #[doc = "Parameters:"] + #[doc = "- `proxy`: The account that the `caller` would like to make a proxy."] + #[doc = "- `proxy_type`: The permissions allowed for this proxy account."] + #[doc = "- `delay`: The announcement period required of the initial proxy. Will generally be"] + #[doc = "zero."] + pub fn add_proxy( &self, - hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + proxy_type: runtime_types::polkadot_runtime::ProxyType, + delay: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Tips", - "retract_tip", - RetractTip { hash }, + "Proxy", + "add_proxy", + AddProxy { + delegate, + proxy_type, + delay, + }, [ - 137u8, 42u8, 229u8, 188u8, 157u8, 195u8, 184u8, 176u8, 64u8, 142u8, - 67u8, 175u8, 185u8, 207u8, 214u8, 71u8, 165u8, 29u8, 137u8, 227u8, - 132u8, 195u8, 255u8, 66u8, 186u8, 57u8, 34u8, 184u8, 187u8, 65u8, - 129u8, 131u8, + 76u8, 227u8, 139u8, 167u8, 131u8, 37u8, 104u8, 137u8, 224u8, 66u8, + 37u8, 1u8, 89u8, 113u8, 232u8, 199u8, 79u8, 187u8, 176u8, 106u8, 168u8, + 144u8, 68u8, 32u8, 0u8, 227u8, 188u8, 28u8, 218u8, 84u8, 82u8, 96u8, ], ) } - #[doc = "Give a tip for something new; no finder's fee will be taken."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the signing account must be a"] - #[doc = "member of the `Tippers` set."] - #[doc = ""] - #[doc = "- `reason`: The reason for, or the thing that deserves, the tip; generally this will be"] - #[doc = " a UTF-8-encoded URL."] - #[doc = "- `who`: The account which should be credited for the tip."] - #[doc = "- `tip_value`: The amount of tip that the sender would like to give. The median tip"] - #[doc = " value of active tippers will be given to the `who`."] + #[doc = "Unregister a proxy account for the sender."] #[doc = ""] - #[doc = "Emits `NewTip` if successful."] + #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(R + T)` where `R` length of `reason`, `T` is the number of tippers."] - #[doc = " - `O(T)`: decoding `Tipper` vec of length `T`. `T` is charged as upper bound given by"] - #[doc = " `ContainsLengthBound`. The actual cost depends on the implementation of"] - #[doc = " `T::Tippers`."] - #[doc = " - `O(R)`: hashing and encoding of reason of length `R`"] - #[doc = "- DbReads: `Tippers`, `Reasons`"] - #[doc = "- DbWrites: `Reasons`, `Tips`"] - #[doc = "# "] - pub fn tip_new( + #[doc = "Parameters:"] + #[doc = "- `proxy`: The account that the `caller` would like to remove as a proxy."] + #[doc = "- `proxy_type`: The permissions currently enabled for the removed proxy account."] + pub fn remove_proxy( &self, - reason: ::std::vec::Vec<::core::primitive::u8>, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - tip_value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + proxy_type: runtime_types::polkadot_runtime::ProxyType, + delay: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Tips", - "tip_new", - TipNew { - reason, - who, - tip_value, + "Proxy", + "remove_proxy", + RemoveProxy { + delegate, + proxy_type, + delay, }, [ - 217u8, 15u8, 70u8, 80u8, 193u8, 110u8, 212u8, 110u8, 212u8, 45u8, - 197u8, 150u8, 43u8, 116u8, 115u8, 231u8, 148u8, 102u8, 202u8, 28u8, - 55u8, 88u8, 166u8, 238u8, 11u8, 238u8, 229u8, 189u8, 89u8, 115u8, - 196u8, 95u8, + 46u8, 235u8, 142u8, 33u8, 21u8, 200u8, 243u8, 213u8, 62u8, 162u8, 70u8, + 132u8, 204u8, 76u8, 156u8, 66u8, 83u8, 95u8, 13u8, 208u8, 241u8, 242u8, + 219u8, 39u8, 229u8, 238u8, 221u8, 135u8, 66u8, 159u8, 38u8, 50u8, ], ) } - #[doc = "Declare a tip value for an already-open tip."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the signing account must be a"] - #[doc = "member of the `Tippers` set."] - #[doc = ""] - #[doc = "- `hash`: The identity of the open tip for which a tip value is declared. This is formed"] - #[doc = " as the hash of the tuple of the hash of the original tip `reason` and the beneficiary"] - #[doc = " account ID."] - #[doc = "- `tip_value`: The amount of tip that the sender would like to give. The median tip"] - #[doc = " value of active tippers will be given to the `who`."] - #[doc = ""] - #[doc = "Emits `TipClosing` if the threshold of tippers has been reached and the countdown period"] - #[doc = "has started."] + #[doc = "Unregister all proxy accounts for the sender."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(T)` where `T` is the number of tippers. decoding `Tipper` vec of length"] - #[doc = " `T`, insert tip and check closing, `T` is charged as upper bound given by"] - #[doc = " `ContainsLengthBound`. The actual cost depends on the implementation of `T::Tippers`."] + #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] - #[doc = " Actually weight could be lower as it depends on how many tips are in `OpenTip` but it"] - #[doc = " is weighted as if almost full i.e of length `T-1`."] - #[doc = "- DbReads: `Tippers`, `Tips`"] - #[doc = "- DbWrites: `Tips`"] - #[doc = "# "] - pub fn tip( - &self, - hash: ::subxt::utils::H256, - tip_value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + #[doc = "WARNING: This may be called on accounts created by `pure`, however if done, then"] + #[doc = "the unreserved fees will be inaccessible. **All access to this account will be lost.**"] + pub fn remove_proxies(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Tips", - "tip", - Tip { hash, tip_value }, + "Proxy", + "remove_proxies", + RemoveProxies {}, [ - 133u8, 52u8, 131u8, 14u8, 71u8, 232u8, 254u8, 31u8, 33u8, 206u8, 50u8, - 76u8, 56u8, 167u8, 228u8, 202u8, 195u8, 0u8, 164u8, 107u8, 170u8, 98u8, - 192u8, 37u8, 209u8, 199u8, 130u8, 15u8, 168u8, 63u8, 181u8, 134u8, + 15u8, 237u8, 27u8, 166u8, 254u8, 218u8, 92u8, 5u8, 213u8, 239u8, 99u8, + 59u8, 1u8, 26u8, 73u8, 252u8, 81u8, 94u8, 214u8, 227u8, 169u8, 58u8, + 40u8, 253u8, 187u8, 225u8, 192u8, 26u8, 19u8, 23u8, 121u8, 129u8, ], ) } - #[doc = "Close and payout a tip."] + #[doc = "Spawn a fresh new account that is guaranteed to be otherwise inaccessible, and"] + #[doc = "initialize it with a proxy of `proxy_type` for `origin` sender."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "Requires a `Signed` origin."] #[doc = ""] - #[doc = "The tip identified by `hash` must have finished its countdown period."] + #[doc = "- `proxy_type`: The type of the proxy that the sender will be registered as over the"] + #[doc = "new account. This will almost always be the most permissive `ProxyType` possible to"] + #[doc = "allow for maximum flexibility."] + #[doc = "- `index`: A disambiguation index, in case this is called multiple times in the same"] + #[doc = "transaction (e.g. with `utility::batch`). Unless you're using `batch` you probably just"] + #[doc = "want to use `0`."] + #[doc = "- `delay`: The announcement period required of the initial proxy. Will generally be"] + #[doc = "zero."] #[doc = ""] - #[doc = "- `hash`: The identity of the open tip for which a tip value is declared. This is formed"] - #[doc = " as the hash of the tuple of the original tip `reason` and the beneficiary account ID."] + #[doc = "Fails with `Duplicate` if this has already been called in this transaction, from the"] + #[doc = "same sender, with the same parameters."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(T)` where `T` is the number of tippers. decoding `Tipper` vec of length"] - #[doc = " `T`. `T` is charged as upper bound given by `ContainsLengthBound`. The actual cost"] - #[doc = " depends on the implementation of `T::Tippers`."] - #[doc = "- DbReads: `Tips`, `Tippers`, `tip finder`"] - #[doc = "- DbWrites: `Reasons`, `Tips`, `Tippers`, `tip finder`"] - #[doc = "# "] - pub fn close_tip( + #[doc = "Fails if there are insufficient funds to pay for deposit."] + pub fn create_pure( &self, - hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + proxy_type: runtime_types::polkadot_runtime::ProxyType, + delay: ::core::primitive::u32, + index: ::core::primitive::u16, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Tips", - "close_tip", - CloseTip { hash }, + "Proxy", + "create_pure", + CreatePure { + proxy_type, + delay, + index, + }, [ - 32u8, 53u8, 0u8, 222u8, 45u8, 157u8, 107u8, 174u8, 203u8, 50u8, 81u8, - 230u8, 6u8, 111u8, 79u8, 55u8, 49u8, 151u8, 107u8, 114u8, 81u8, 200u8, - 144u8, 175u8, 29u8, 142u8, 115u8, 184u8, 102u8, 116u8, 156u8, 173u8, + 184u8, 127u8, 177u8, 255u8, 195u8, 192u8, 136u8, 114u8, 249u8, 70u8, + 222u8, 77u8, 10u8, 213u8, 209u8, 6u8, 238u8, 173u8, 47u8, 182u8, 129u8, + 69u8, 74u8, 249u8, 25u8, 170u8, 119u8, 106u8, 54u8, 165u8, 0u8, 100u8, ], ) } - #[doc = "Remove and slash an already-open tip."] + #[doc = "Removes a previously spawned pure proxy."] #[doc = ""] - #[doc = "May only be called from `T::RejectOrigin`."] + #[doc = "WARNING: **All access to this account will be lost.** Any funds held in it will be"] + #[doc = "inaccessible."] #[doc = ""] - #[doc = "As a result, the finder is slashed and the deposits are lost."] + #[doc = "Requires a `Signed` origin, and the sender account must have been created by a call to"] + #[doc = "`pure` with corresponding parameters."] #[doc = ""] - #[doc = "Emits `TipSlashed` if successful."] + #[doc = "- `spawner`: The account that originally called `pure` to create this account."] + #[doc = "- `index`: The disambiguation index originally passed to `pure`. Probably `0`."] + #[doc = "- `proxy_type`: The proxy type originally passed to `pure`."] + #[doc = "- `height`: The height of the chain when the call to `pure` was processed."] + #[doc = "- `ext_index`: The extrinsic index in which the call to `pure` was processed."] #[doc = ""] - #[doc = "# "] - #[doc = " `T` is charged as upper bound given by `ContainsLengthBound`."] - #[doc = " The actual cost depends on the implementation of `T::Tippers`."] - #[doc = "# "] - pub fn slash_tip( + #[doc = "Fails with `NoPermission` in case the caller is not a previously created pure"] + #[doc = "account whose `pure` call has corresponding parameters."] + pub fn kill_pure( &self, - hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + spawner: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + proxy_type: runtime_types::polkadot_runtime::ProxyType, + index: ::core::primitive::u16, + height: ::core::primitive::u32, + ext_index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Tips", - "slash_tip", - SlashTip { hash }, + "Proxy", + "kill_pure", + KillPure { + spawner, + proxy_type, + index, + height, + ext_index, + }, [ - 222u8, 209u8, 22u8, 47u8, 114u8, 230u8, 81u8, 200u8, 131u8, 0u8, 209u8, - 54u8, 17u8, 200u8, 175u8, 125u8, 100u8, 254u8, 41u8, 178u8, 20u8, 27u8, - 9u8, 184u8, 79u8, 93u8, 208u8, 148u8, 27u8, 190u8, 176u8, 169u8, + 134u8, 133u8, 203u8, 194u8, 12u8, 188u8, 59u8, 222u8, 83u8, 30u8, + 217u8, 181u8, 224u8, 194u8, 81u8, 206u8, 30u8, 116u8, 94u8, 36u8, 87u8, + 227u8, 157u8, 129u8, 198u8, 115u8, 208u8, 105u8, 143u8, 175u8, 145u8, + 18u8, ], ) } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_tips::pallet::Event; + #[doc = "Publish the hash of a proxy-call that will be made in the future."] + #[doc = ""] + #[doc = "This must be called some number of blocks before the corresponding `proxy` is attempted"] + #[doc = "if the delay associated with the proxy relationship is greater than zero."] + #[doc = ""] + #[doc = "No more than `MaxPending` announcements may be made at any one time."] + #[doc = ""] + #[doc = "This will take a deposit of `AnnouncementDepositFactor` as well as"] + #[doc = "`AnnouncementDepositBase` if there are no other pending announcements."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and a proxy of `real`."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `real`: The account that the proxy will make a call on behalf of."] + #[doc = "- `call_hash`: The hash of the call to be made by the `real` account."] + pub fn announce( + &self, + real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + call_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "announce", + Announce { real, call_hash }, + [ + 235u8, 116u8, 208u8, 53u8, 128u8, 91u8, 100u8, 68u8, 255u8, 254u8, + 119u8, 253u8, 108u8, 130u8, 88u8, 56u8, 113u8, 99u8, 105u8, 179u8, + 16u8, 143u8, 131u8, 203u8, 234u8, 76u8, 199u8, 191u8, 35u8, 158u8, + 130u8, 209u8, + ], + ) + } + #[doc = "Remove a given announcement."] + #[doc = ""] + #[doc = "May be called by a proxy account to remove a call they previously announced and return"] + #[doc = "the deposit."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `real`: The account that the proxy will make a call on behalf of."] + #[doc = "- `call_hash`: The hash of the call to be made by the `real` account."] + pub fn remove_announcement( + &self, + real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + call_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "remove_announcement", + RemoveAnnouncement { real, call_hash }, + [ + 140u8, 186u8, 140u8, 129u8, 40u8, 124u8, 57u8, 61u8, 84u8, 247u8, + 123u8, 241u8, 148u8, 15u8, 94u8, 146u8, 121u8, 78u8, 190u8, 68u8, + 185u8, 125u8, 62u8, 49u8, 108u8, 131u8, 229u8, 82u8, 68u8, 37u8, 184u8, + 223u8, + ], + ) + } + #[doc = "Remove the given announcement of a delegate."] + #[doc = ""] + #[doc = "May be called by a target (proxied) account to remove a call that one of their delegates"] + #[doc = "(`delegate`) has announced they want to execute. The deposit is returned."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `delegate`: The account that previously announced the call."] + #[doc = "- `call_hash`: The hash of the call to be made."] + pub fn reject_announcement( + &self, + delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + call_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "reject_announcement", + RejectAnnouncement { + delegate, + call_hash, + }, + [ + 225u8, 198u8, 31u8, 173u8, 157u8, 141u8, 121u8, 51u8, 226u8, 170u8, + 219u8, 86u8, 14u8, 131u8, 122u8, 157u8, 161u8, 200u8, 157u8, 37u8, + 43u8, 97u8, 143u8, 97u8, 46u8, 206u8, 204u8, 42u8, 78u8, 33u8, 85u8, + 127u8, + ], + ) + } + #[doc = "Dispatch the given `call` from an account that the sender is authorized for through"] + #[doc = "`add_proxy`."] + #[doc = ""] + #[doc = "Removes any corresponding announcement(s)."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `real`: The account that the proxy will make a call on behalf of."] + #[doc = "- `force_proxy_type`: Specify the exact proxy type to be used and checked for this call."] + #[doc = "- `call`: The call to be made by the `real` account."] + pub fn proxy_announced( + &self, + delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + force_proxy_type: ::core::option::Option< + runtime_types::polkadot_runtime::ProxyType, + >, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "proxy_announced", + ProxyAnnounced { + delegate, + real, + force_proxy_type, + call: ::std::boxed::Box::new(call), + }, + [ + 144u8, 103u8, 250u8, 31u8, 18u8, 158u8, 175u8, 139u8, 73u8, 56u8, + 178u8, 80u8, 164u8, 100u8, 162u8, 163u8, 119u8, 102u8, 177u8, 28u8, + 229u8, 128u8, 250u8, 242u8, 26u8, 223u8, 74u8, 180u8, 127u8, 124u8, + 134u8, 123u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_proxy::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -20149,13 +19548,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new tip suggestion has been opened."] - pub struct NewTip { - pub tip_hash: ::subxt::utils::H256, + #[doc = "A proxy was executed correctly, with the given."] + pub struct ProxyExecuted { + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, } - impl ::subxt::events::StaticEvent for NewTip { - const PALLET: &'static str = "Tips"; - const EVENT: &'static str = "NewTip"; + impl ::subxt::events::StaticEvent for ProxyExecuted { + const PALLET: &'static str = "Proxy"; + const EVENT: &'static str = "ProxyExecuted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -20167,13 +19566,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A tip suggestion has reached threshold and is closing."] - pub struct TipClosing { - pub tip_hash: ::subxt::utils::H256, + #[doc = "A pure account has been created by new proxy with given"] + #[doc = "disambiguation index and proxy type."] + pub struct PureCreated { + pub pure: ::subxt::utils::AccountId32, + pub who: ::subxt::utils::AccountId32, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub disambiguation_index: ::core::primitive::u16, } - impl ::subxt::events::StaticEvent for TipClosing { - const PALLET: &'static str = "Tips"; - const EVENT: &'static str = "TipClosing"; + impl ::subxt::events::StaticEvent for PureCreated { + const PALLET: &'static str = "Proxy"; + const EVENT: &'static str = "PureCreated"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -20185,15 +19588,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A tip suggestion has been closed."] - pub struct TipClosed { - pub tip_hash: ::subxt::utils::H256, - pub who: ::subxt::utils::AccountId32, - pub payout: ::core::primitive::u128, + #[doc = "An announcement was placed to make a call in the future."] + pub struct Announced { + pub real: ::subxt::utils::AccountId32, + pub proxy: ::subxt::utils::AccountId32, + pub call_hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for TipClosed { - const PALLET: &'static str = "Tips"; - const EVENT: &'static str = "TipClosed"; + impl ::subxt::events::StaticEvent for Announced { + const PALLET: &'static str = "Proxy"; + const EVENT: &'static str = "Announced"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -20205,13 +19608,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A tip suggestion has been retracted."] - pub struct TipRetracted { - pub tip_hash: ::subxt::utils::H256, + #[doc = "A proxy was added."] + pub struct ProxyAdded { + pub delegator: ::subxt::utils::AccountId32, + pub delegatee: ::subxt::utils::AccountId32, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub delay: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for TipRetracted { - const PALLET: &'static str = "Tips"; - const EVENT: &'static str = "TipRetracted"; + impl ::subxt::events::StaticEvent for ProxyAdded { + const PALLET: &'static str = "Proxy"; + const EVENT: &'static str = "ProxyAdded"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -20223,124 +19629,149 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A tip suggestion has been slashed."] - pub struct TipSlashed { - pub tip_hash: ::subxt::utils::H256, - pub finder: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, + #[doc = "A proxy was removed."] + pub struct ProxyRemoved { + pub delegator: ::subxt::utils::AccountId32, + pub delegatee: ::subxt::utils::AccountId32, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub delay: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for TipSlashed { - const PALLET: &'static str = "Tips"; - const EVENT: &'static str = "TipSlashed"; + impl ::subxt::events::StaticEvent for ProxyRemoved { + const PALLET: &'static str = "Proxy"; + const EVENT: &'static str = "ProxyRemoved"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " TipsMap that are not yet completed. Keyed by the hash of `(reason, who)` from the value."] - #[doc = " This has the insecure enumerable hash function since the key itself is already"] - #[doc = " guaranteed to be a secure hash."] - pub fn tips( + #[doc = " The set of account proxies. Maps the account which has delegated to the accounts"] + #[doc = " which are being delegated to, together with the amount held on deposit."] + pub fn proxies( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_tips::OpenTip< - ::subxt::utils::AccountId32, + ( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_proxy::ProxyDefinition< + ::subxt::utils::AccountId32, + runtime_types::polkadot_runtime::ProxyType, + ::core::primitive::u32, + >, + >, ::core::primitive::u128, - ::core::primitive::u32, - ::subxt::utils::H256, - >, + ), + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Tips", - "Tips", + "Proxy", + "Proxies", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 241u8, 196u8, 105u8, 248u8, 29u8, 66u8, 86u8, 98u8, 6u8, 159u8, 191u8, - 0u8, 227u8, 232u8, 147u8, 248u8, 173u8, 20u8, 225u8, 12u8, 232u8, 5u8, - 93u8, 78u8, 18u8, 154u8, 130u8, 38u8, 142u8, 36u8, 66u8, 0u8, + 80u8, 71u8, 244u8, 42u8, 237u8, 5u8, 46u8, 156u8, 84u8, 213u8, 84u8, + 212u8, 157u8, 221u8, 174u8, 97u8, 157u8, 218u8, 166u8, 127u8, 162u8, + 139u8, 110u8, 98u8, 229u8, 166u8, 49u8, 172u8, 48u8, 237u8, 240u8, + 42u8, ], ) } - #[doc = " TipsMap that are not yet completed. Keyed by the hash of `(reason, who)` from the value."] - #[doc = " This has the insecure enumerable hash function since the key itself is already"] - #[doc = " guaranteed to be a secure hash."] - pub fn tips_root( + #[doc = " The set of account proxies. Maps the account which has delegated to the accounts"] + #[doc = " which are being delegated to, together with the amount held on deposit."] + pub fn proxies_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_tips::OpenTip< - ::subxt::utils::AccountId32, + ( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_proxy::ProxyDefinition< + ::subxt::utils::AccountId32, + runtime_types::polkadot_runtime::ProxyType, + ::core::primitive::u32, + >, + >, ::core::primitive::u128, - ::core::primitive::u32, - ::subxt::utils::H256, - >, - (), + ), (), ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Tips", - "Tips", + "Proxy", + "Proxies", Vec::new(), [ - 241u8, 196u8, 105u8, 248u8, 29u8, 66u8, 86u8, 98u8, 6u8, 159u8, 191u8, - 0u8, 227u8, 232u8, 147u8, 248u8, 173u8, 20u8, 225u8, 12u8, 232u8, 5u8, - 93u8, 78u8, 18u8, 154u8, 130u8, 38u8, 142u8, 36u8, 66u8, 0u8, + 80u8, 71u8, 244u8, 42u8, 237u8, 5u8, 46u8, 156u8, 84u8, 213u8, 84u8, + 212u8, 157u8, 221u8, 174u8, 97u8, 157u8, 218u8, 166u8, 127u8, 162u8, + 139u8, 110u8, 98u8, 229u8, 166u8, 49u8, 172u8, 48u8, 237u8, 240u8, + 42u8, ], ) } - #[doc = " Simple preimage lookup from the reason's hash to the original data. Again, has an"] - #[doc = " insecure enumerable hash since the key is guaranteed to be the result of a secure hash."] - pub fn reasons( + #[doc = " The announcements made by the proxy (key)."] + pub fn announcements( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, + ( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_proxy::Announcement< + ::subxt::utils::AccountId32, + ::subxt::utils::H256, + ::core::primitive::u32, + >, + >, + ::core::primitive::u128, + ), + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Tips", - "Reasons", + "Proxy", + "Announcements", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 202u8, 191u8, 36u8, 162u8, 156u8, 102u8, 115u8, 10u8, 203u8, 35u8, - 201u8, 70u8, 195u8, 151u8, 89u8, 82u8, 202u8, 35u8, 210u8, 176u8, 82u8, - 1u8, 77u8, 94u8, 31u8, 70u8, 252u8, 194u8, 166u8, 91u8, 189u8, 134u8, + 233u8, 38u8, 249u8, 89u8, 103u8, 87u8, 64u8, 52u8, 140u8, 228u8, 110u8, + 37u8, 8u8, 92u8, 48u8, 7u8, 46u8, 99u8, 179u8, 83u8, 232u8, 171u8, + 160u8, 45u8, 37u8, 23u8, 151u8, 198u8, 237u8, 103u8, 217u8, 53u8, ], ) } - #[doc = " Simple preimage lookup from the reason's hash to the original data. Again, has an"] - #[doc = " insecure enumerable hash since the key is guaranteed to be the result of a secure hash."] - pub fn reasons_root( + #[doc = " The announcements made by the proxy (key)."] + pub fn announcements_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - (), + ( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_proxy::Announcement< + ::subxt::utils::AccountId32, + ::subxt::utils::H256, + ::core::primitive::u32, + >, + >, + ::core::primitive::u128, + ), (), ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Tips", - "Reasons", + "Proxy", + "Announcements", Vec::new(), [ - 202u8, 191u8, 36u8, 162u8, 156u8, 102u8, 115u8, 10u8, 203u8, 35u8, - 201u8, 70u8, 195u8, 151u8, 89u8, 82u8, 202u8, 35u8, 210u8, 176u8, 82u8, - 1u8, 77u8, 94u8, 31u8, 70u8, 252u8, 194u8, 166u8, 91u8, 189u8, 134u8, + 233u8, 38u8, 249u8, 89u8, 103u8, 87u8, 64u8, 52u8, 140u8, 228u8, 110u8, + 37u8, 8u8, 92u8, 48u8, 7u8, 46u8, 99u8, 179u8, 83u8, 232u8, 171u8, + 160u8, 45u8, 37u8, 23u8, 151u8, 198u8, 237u8, 103u8, 217u8, 53u8, ], ) } @@ -20350,30 +19781,34 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " Maximum acceptable reason length."] + #[doc = " The base amount of currency needed to reserve for creating a proxy."] #[doc = ""] - #[doc = " Benchmarks depend on this value, be sure to update weights file when changing this value"] - pub fn maximum_reason_length( + #[doc = " This is held for an additional storage item whose value size is"] + #[doc = " `sizeof(Balance)` bytes and whose key size is `sizeof(AccountId)` bytes."] + pub fn proxy_deposit_base( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { + ) -> ::subxt::constants::Address<::core::primitive::u128> { ::subxt::constants::Address::new_static( - "Tips", - "MaximumReasonLength", + "Proxy", + "ProxyDepositBase", [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = " The amount held on deposit per byte within the tip report reason or bounty description."] - pub fn data_deposit_per_byte( + #[doc = " The amount of currency needed per proxy added."] + #[doc = ""] + #[doc = " This is held for adding 32 bytes plus an instance of `ProxyType` more into a"] + #[doc = " pre-existing storage value. Thus, when configuring `ProxyDepositFactor` one should take"] + #[doc = " into account `32 + proxy_type.encode().len()` bytes of data."] + pub fn proxy_deposit_factor( &self, ) -> ::subxt::constants::Address<::core::primitive::u128> { ::subxt::constants::Address::new_static( - "Tips", - "DataDepositPerByte", + "Proxy", + "ProxyDepositFactor", [ 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, @@ -20381,11 +19816,11 @@ pub mod api { ], ) } - #[doc = " The period for which a tip remains open after is has achieved threshold tippers."] - pub fn tip_countdown(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + #[doc = " The maximum amount of proxies allowed for a single account."] + pub fn max_proxies(&self) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Tips", - "TipCountdown", + "Proxy", + "MaxProxies", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -20394,29 +19829,46 @@ pub mod api { ], ) } - #[doc = " The percent of the final tip which goes to the original reporter of the tip."] - pub fn tip_finders_fee( + #[doc = " The maximum amount of time-delayed announcements that are allowed to be pending."] + pub fn max_pending(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Proxy", + "MaxPending", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The base amount of currency needed to reserve for creating an announcement."] + #[doc = ""] + #[doc = " This is held when a new storage item holding a `Balance` is created (typically 16"] + #[doc = " bytes)."] + pub fn announcement_deposit_base( &self, - ) -> ::subxt::constants::Address - { + ) -> ::subxt::constants::Address<::core::primitive::u128> { ::subxt::constants::Address::new_static( - "Tips", - "TipFindersFee", + "Proxy", + "AnnouncementDepositBase", [ - 99u8, 121u8, 176u8, 172u8, 235u8, 159u8, 116u8, 114u8, 179u8, 91u8, - 129u8, 117u8, 204u8, 135u8, 53u8, 7u8, 151u8, 26u8, 124u8, 151u8, - 202u8, 171u8, 171u8, 207u8, 183u8, 177u8, 24u8, 53u8, 109u8, 185u8, - 71u8, 183u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = " The amount held on deposit for placing a tip report."] - pub fn tip_report_deposit_base( + #[doc = " The amount of currency needed per announcement made."] + #[doc = ""] + #[doc = " This is held for adding an `AccountId`, `Hash` and `BlockNumber` (typically 68 bytes)"] + #[doc = " into a pre-existing storage value."] + pub fn announcement_deposit_factor( &self, ) -> ::subxt::constants::Address<::core::primitive::u128> { ::subxt::constants::Address::new_static( - "Tips", - "TipReportDepositBase", + "Proxy", + "AnnouncementDepositFactor", [ 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, @@ -20427,11 +19879,11 @@ pub mod api { } } } - pub mod election_provider_multi_phase { + pub mod multisig { use super::root_mod; use super::runtime_types; - #[doc = "Error of the pallet that can be returned in response to dispatches."] - pub type Error = runtime_types::pallet_election_provider_multi_phase::pallet::Error; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_multisig::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -20447,28 +19899,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SubmitUnsigned { - pub raw_solution: ::std::boxed::Box< - runtime_types::pallet_election_provider_multi_phase::RawSolution< - runtime_types::polkadot_runtime::NposCompactSolution16, - >, - >, - pub witness: - runtime_types::pallet_election_provider_multi_phase::SolutionOrSnapshotSize, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMinimumUntrustedScore { - pub maybe_next_score: - ::core::option::Option, + pub struct AsMultiThreshold1 { + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub call: ::std::boxed::Box, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -20480,11 +19913,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetEmergencyElectionResult { - pub supports: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::sp_npos_elections::Support<::subxt::utils::AccountId32>, - )>, + pub struct AsMulti { + pub threshold: ::core::primitive::u16, + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + >, + pub call: ::std::boxed::Box, + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -20496,12 +19932,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Submit { - pub raw_solution: ::std::boxed::Box< - runtime_types::pallet_election_provider_multi_phase::RawSolution< - runtime_types::polkadot_runtime::NposCompactSolution16, - >, + pub struct ApproveAsMulti { + pub threshold: ::core::primitive::u16, + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, >, + pub call_hash: [::core::primitive::u8; 32usize], + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -20513,151 +19951,219 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct GovernanceFallback { - pub maybe_max_voters: ::core::option::Option<::core::primitive::u32>, - pub maybe_max_targets: ::core::option::Option<::core::primitive::u32>, + pub struct CancelAsMulti { + pub threshold: ::core::primitive::u16, + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub call_hash: [::core::primitive::u8; 32usize], } pub struct TransactionApi; impl TransactionApi { - #[doc = "Submit a solution for the unsigned phase."] + #[doc = "Immediately dispatch a multi-signature call using a single approval from the caller."] #[doc = ""] - #[doc = "The dispatch origin fo this call must be __none__."] + #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] - #[doc = "This submission is checked on the fly. Moreover, this unsigned solution is only"] - #[doc = "validated when submitted to the pool from the **local** node. Effectively, this means"] - #[doc = "that only active validators can submit this transaction when authoring a block (similar"] - #[doc = "to an inherent)."] + #[doc = "- `other_signatories`: The accounts (other than the sender) who are part of the"] + #[doc = "multi-signature, but do not participate in the approval process."] + #[doc = "- `call`: The call to be executed."] #[doc = ""] - #[doc = "To prevent any incorrect solution (and thus wasted time/weight), this transaction will"] - #[doc = "panic if the solution submitted by the validator is invalid in any way, effectively"] - #[doc = "putting their authoring reward at risk."] + #[doc = "Result is equivalent to the dispatched result."] #[doc = ""] - #[doc = "No deposit or reward is associated with this submission."] - pub fn submit_unsigned( + #[doc = "## Complexity"] + #[doc = "O(Z + C) where Z is the length of the call and C its execution weight."] + pub fn as_multi_threshold_1( &self, - raw_solution: runtime_types::pallet_election_provider_multi_phase::RawSolution< - runtime_types::polkadot_runtime::NposCompactSolution16, - >, - witness : runtime_types :: pallet_election_provider_multi_phase :: SolutionOrSnapshotSize, - ) -> ::subxt::tx::Payload { + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ElectionProviderMultiPhase", - "submit_unsigned", - SubmitUnsigned { - raw_solution: ::std::boxed::Box::new(raw_solution), - witness, + "Multisig", + "as_multi_threshold_1", + AsMultiThreshold1 { + other_signatories, + call: ::std::boxed::Box::new(call), }, [ - 100u8, 240u8, 31u8, 34u8, 93u8, 98u8, 93u8, 57u8, 41u8, 197u8, 97u8, - 58u8, 242u8, 10u8, 69u8, 250u8, 185u8, 169u8, 21u8, 8u8, 202u8, 61u8, - 36u8, 25u8, 4u8, 148u8, 82u8, 56u8, 242u8, 18u8, 27u8, 219u8, + 113u8, 140u8, 77u8, 180u8, 170u8, 232u8, 85u8, 229u8, 218u8, 187u8, + 62u8, 64u8, 168u8, 186u8, 173u8, 27u8, 125u8, 216u8, 54u8, 167u8, + 225u8, 241u8, 10u8, 226u8, 138u8, 151u8, 242u8, 255u8, 212u8, 160u8, + 106u8, 69u8, ], ) } - #[doc = "Set a new value for `MinimumUntrustedScore`."] - #[doc = ""] - #[doc = "Dispatch origin must be aligned with `T::ForceOrigin`."] + #[doc = "Register approval for a dispatch to be made from a deterministic composite account if"] + #[doc = "approved by a total of `threshold - 1` of `other_signatories`."] #[doc = ""] - #[doc = "This check can be turned off by setting the value to `None`."] - pub fn set_minimum_untrusted_score( + #[doc = "If there are enough, then dispatch the call."] + #[doc = ""] + #[doc = "Payment: `DepositBase` will be reserved if this is the first approval, plus"] + #[doc = "`threshold` times `DepositFactor`. It is returned once this dispatch happens or"] + #[doc = "is cancelled."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "- `threshold`: The total number of approvals for this dispatch before it is executed."] + #[doc = "- `other_signatories`: The accounts (other than the sender) who can approve this"] + #[doc = "dispatch. May not be empty."] + #[doc = "- `maybe_timepoint`: If this is the first approval, then this must be `None`. If it is"] + #[doc = "not the first approval, then it must be `Some`, with the timepoint (block number and"] + #[doc = "transaction index) of the first approval transaction."] + #[doc = "- `call`: The call to be executed."] + #[doc = ""] + #[doc = "NOTE: Unless this is the final approval, you will generally want to use"] + #[doc = "`approve_as_multi` instead, since it only requires a hash of the call."] + #[doc = ""] + #[doc = "Result is equivalent to the dispatched result if `threshold` is exactly `1`. Otherwise"] + #[doc = "on success, result is `Ok` and the result from the interior call, if it was executed,"] + #[doc = "may be found in the deposited `MultisigExecuted` event."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(S + Z + Call)`."] + #[doc = "- Up to one balance-reserve or unreserve operation."] + #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] + #[doc = " signatories. `S` is capped by `MaxSignatories`, with weight being proportional."] + #[doc = "- One call encode & hash, both of complexity `O(Z)` where `Z` is tx-len."] + #[doc = "- One encode & hash, both of complexity `O(S)`."] + #[doc = "- Up to one binary search and insert (`O(logS + S)`)."] + #[doc = "- I/O: 1 read `O(S)`, up to 1 mutate `O(S)`. Up to one remove."] + #[doc = "- One event."] + #[doc = "- The weight of the `call`."] + #[doc = "- Storage: inserts one item, value size bounded by `MaxSignatories`, with a deposit"] + #[doc = " taken for its lifetime of `DepositBase + threshold * DepositFactor`."] + pub fn as_multi( &self, - maybe_next_score: ::core::option::Option< - runtime_types::sp_npos_elections::ElectionScore, + threshold: ::core::primitive::u16, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, >, - ) -> ::subxt::tx::Payload { + call: runtime_types::polkadot_runtime::RuntimeCall, + max_weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ElectionProviderMultiPhase", - "set_minimum_untrusted_score", - SetMinimumUntrustedScore { maybe_next_score }, + "Multisig", + "as_multi", + AsMulti { + threshold, + other_signatories, + maybe_timepoint, + call: ::std::boxed::Box::new(call), + max_weight, + }, [ - 63u8, 101u8, 105u8, 146u8, 133u8, 162u8, 149u8, 112u8, 150u8, 219u8, - 183u8, 213u8, 234u8, 211u8, 144u8, 74u8, 106u8, 15u8, 62u8, 196u8, - 247u8, 49u8, 20u8, 48u8, 3u8, 105u8, 85u8, 46u8, 76u8, 4u8, 67u8, 81u8, + 167u8, 155u8, 31u8, 18u8, 196u8, 45u8, 139u8, 126u8, 185u8, 246u8, + 31u8, 88u8, 200u8, 228u8, 82u8, 139u8, 123u8, 239u8, 169u8, 185u8, + 227u8, 160u8, 71u8, 242u8, 152u8, 146u8, 87u8, 243u8, 170u8, 237u8, + 11u8, 6u8, ], ) } - #[doc = "Set a solution in the queue, to be handed out to the client of this pallet in the next"] - #[doc = "call to `ElectionProvider::elect`."] + #[doc = "Register approval for a dispatch to be made from a deterministic composite account if"] + #[doc = "approved by a total of `threshold - 1` of `other_signatories`."] #[doc = ""] - #[doc = "This can only be set by `T::ForceOrigin`, and only when the phase is `Emergency`."] + #[doc = "Payment: `DepositBase` will be reserved if this is the first approval, plus"] + #[doc = "`threshold` times `DepositFactor`. It is returned once this dispatch happens or"] + #[doc = "is cancelled."] #[doc = ""] - #[doc = "The solution is not checked for any feasibility and is assumed to be trustworthy, as any"] - #[doc = "feasibility check itself can in principle cause the election process to fail (due to"] - #[doc = "memory/weight constrains)."] - pub fn set_emergency_election_result( - &self, - supports: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::sp_npos_elections::Support<::subxt::utils::AccountId32>, - )>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ElectionProviderMultiPhase", - "set_emergency_election_result", - SetEmergencyElectionResult { supports }, - [ - 115u8, 255u8, 205u8, 58u8, 153u8, 1u8, 246u8, 8u8, 225u8, 36u8, 66u8, - 144u8, 250u8, 145u8, 70u8, 76u8, 54u8, 63u8, 251u8, 51u8, 214u8, 204u8, - 55u8, 112u8, 46u8, 228u8, 255u8, 250u8, 151u8, 5u8, 44u8, 133u8, - ], - ) - } - #[doc = "Submit a solution for the signed phase."] + #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] - #[doc = "The dispatch origin fo this call must be __signed__."] + #[doc = "- `threshold`: The total number of approvals for this dispatch before it is executed."] + #[doc = "- `other_signatories`: The accounts (other than the sender) who can approve this"] + #[doc = "dispatch. May not be empty."] + #[doc = "- `maybe_timepoint`: If this is the first approval, then this must be `None`. If it is"] + #[doc = "not the first approval, then it must be `Some`, with the timepoint (block number and"] + #[doc = "transaction index) of the first approval transaction."] + #[doc = "- `call_hash`: The hash of the call to be executed."] #[doc = ""] - #[doc = "The solution is potentially queued, based on the claimed score and processed at the end"] - #[doc = "of the signed phase."] + #[doc = "NOTE: If this is the final approval, you will want to use `as_multi` instead."] #[doc = ""] - #[doc = "A deposit is reserved and recorded for the solution. Based on the outcome, the solution"] - #[doc = "might be rewarded, slashed, or get all or a part of the deposit back."] - pub fn submit( + #[doc = "## Complexity"] + #[doc = "- `O(S)`."] + #[doc = "- Up to one balance-reserve or unreserve operation."] + #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] + #[doc = " signatories. `S` is capped by `MaxSignatories`, with weight being proportional."] + #[doc = "- One encode & hash, both of complexity `O(S)`."] + #[doc = "- Up to one binary search and insert (`O(logS + S)`)."] + #[doc = "- I/O: 1 read `O(S)`, up to 1 mutate `O(S)`. Up to one remove."] + #[doc = "- One event."] + #[doc = "- Storage: inserts one item, value size bounded by `MaxSignatories`, with a deposit"] + #[doc = " taken for its lifetime of `DepositBase + threshold * DepositFactor`."] + pub fn approve_as_multi( &self, - raw_solution: runtime_types::pallet_election_provider_multi_phase::RawSolution< - runtime_types::polkadot_runtime::NposCompactSolution16, + threshold: ::core::primitive::u16, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, >, - ) -> ::subxt::tx::Payload { + call_hash: [::core::primitive::u8; 32usize], + max_weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ElectionProviderMultiPhase", - "submit", - Submit { - raw_solution: ::std::boxed::Box::new(raw_solution), + "Multisig", + "approve_as_multi", + ApproveAsMulti { + threshold, + other_signatories, + maybe_timepoint, + call_hash, + max_weight, }, [ - 220u8, 167u8, 40u8, 47u8, 253u8, 244u8, 72u8, 124u8, 30u8, 123u8, - 127u8, 227u8, 2u8, 66u8, 119u8, 64u8, 211u8, 200u8, 210u8, 98u8, 248u8, - 132u8, 68u8, 25u8, 34u8, 182u8, 230u8, 225u8, 241u8, 58u8, 193u8, - 134u8, + 133u8, 113u8, 121u8, 66u8, 218u8, 219u8, 48u8, 64u8, 211u8, 114u8, + 163u8, 193u8, 164u8, 21u8, 140u8, 218u8, 253u8, 237u8, 240u8, 126u8, + 200u8, 213u8, 184u8, 50u8, 187u8, 182u8, 30u8, 52u8, 142u8, 72u8, + 210u8, 101u8, ], ) } - #[doc = "Trigger the governance fallback."] + #[doc = "Cancel a pre-existing, on-going multisig transaction. Any deposit reserved previously"] + #[doc = "for this operation will be unreserved on success."] #[doc = ""] - #[doc = "This can only be called when [`Phase::Emergency`] is enabled, as an alternative to"] - #[doc = "calling [`Call::set_emergency_election_result`]."] - pub fn governance_fallback( + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "- `threshold`: The total number of approvals for this dispatch before it is executed."] + #[doc = "- `other_signatories`: The accounts (other than the sender) who can approve this"] + #[doc = "dispatch. May not be empty."] + #[doc = "- `timepoint`: The timepoint (block number and transaction index) of the first approval"] + #[doc = "transaction for this dispatch."] + #[doc = "- `call_hash`: The hash of the call to be executed."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(S)`."] + #[doc = "- Up to one balance-reserve or unreserve operation."] + #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] + #[doc = " signatories. `S` is capped by `MaxSignatories`, with weight being proportional."] + #[doc = "- One encode & hash, both of complexity `O(S)`."] + #[doc = "- One event."] + #[doc = "- I/O: 1 read `O(S)`, one remove."] + #[doc = "- Storage: removes one item."] + pub fn cancel_as_multi( &self, - maybe_max_voters: ::core::option::Option<::core::primitive::u32>, - maybe_max_targets: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { + threshold: ::core::primitive::u16, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + call_hash: [::core::primitive::u8; 32usize], + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ElectionProviderMultiPhase", - "governance_fallback", - GovernanceFallback { - maybe_max_voters, - maybe_max_targets, + "Multisig", + "cancel_as_multi", + CancelAsMulti { + threshold, + other_signatories, + timepoint, + call_hash, }, [ - 206u8, 247u8, 76u8, 85u8, 7u8, 24u8, 231u8, 226u8, 192u8, 143u8, 43u8, - 67u8, 91u8, 202u8, 88u8, 176u8, 130u8, 1u8, 83u8, 229u8, 227u8, 200u8, - 179u8, 4u8, 113u8, 60u8, 99u8, 190u8, 53u8, 226u8, 142u8, 182u8, + 30u8, 25u8, 186u8, 142u8, 168u8, 81u8, 235u8, 164u8, 82u8, 209u8, 66u8, + 129u8, 209u8, 78u8, 172u8, 9u8, 163u8, 222u8, 125u8, 57u8, 2u8, 43u8, + 169u8, 174u8, 159u8, 167u8, 25u8, 226u8, 254u8, 110u8, 80u8, 216u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_election_provider_multi_phase::pallet::Event; + pub type Event = runtime_types::pallet_multisig::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -20670,75 +20176,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A solution was stored with the given compute."] - #[doc = ""] - #[doc = "If the solution is signed, this means that it hasn't yet been processed. If the"] - #[doc = "solution is unsigned, this means that it has also been processed."] - #[doc = ""] - #[doc = "The `bool` is `true` when a previous solution was ejected to make room for this one."] - pub struct SolutionStored { - pub compute: runtime_types::pallet_election_provider_multi_phase::ElectionCompute, - pub prev_ejected: ::core::primitive::bool, - } - impl ::subxt::events::StaticEvent for SolutionStored { - const PALLET: &'static str = "ElectionProviderMultiPhase"; - const EVENT: &'static str = "SolutionStored"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The election has been finalized, with the given computation and score."] - pub struct ElectionFinalized { - pub compute: runtime_types::pallet_election_provider_multi_phase::ElectionCompute, - pub score: runtime_types::sp_npos_elections::ElectionScore, - } - impl ::subxt::events::StaticEvent for ElectionFinalized { - const PALLET: &'static str = "ElectionProviderMultiPhase"; - const EVENT: &'static str = "ElectionFinalized"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An election failed."] - #[doc = ""] - #[doc = "Not much can be said about which computes failed in the process."] - pub struct ElectionFailed; - impl ::subxt::events::StaticEvent for ElectionFailed { - const PALLET: &'static str = "ElectionProviderMultiPhase"; - const EVENT: &'static str = "ElectionFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has been rewarded for their signed submission being finalized."] - pub struct Rewarded { - pub account: ::subxt::utils::AccountId32, - pub value: ::core::primitive::u128, + #[doc = "A new multisig operation has begun."] + pub struct NewMultisig { + pub approving: ::subxt::utils::AccountId32, + pub multisig: ::subxt::utils::AccountId32, + pub call_hash: [::core::primitive::u8; 32usize], } - impl ::subxt::events::StaticEvent for Rewarded { - const PALLET: &'static str = "ElectionProviderMultiPhase"; - const EVENT: &'static str = "Rewarded"; + impl ::subxt::events::StaticEvent for NewMultisig { + const PALLET: &'static str = "Multisig"; + const EVENT: &'static str = "NewMultisig"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -20750,17 +20196,18 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has been slashed for submitting an invalid signed submission."] - pub struct Slashed { - pub account: ::subxt::utils::AccountId32, - pub value: ::core::primitive::u128, + #[doc = "A multisig operation has been approved by someone."] + pub struct MultisigApproval { + pub approving: ::subxt::utils::AccountId32, + pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub multisig: ::subxt::utils::AccountId32, + pub call_hash: [::core::primitive::u8; 32usize], } - impl ::subxt::events::StaticEvent for Slashed { - const PALLET: &'static str = "ElectionProviderMultiPhase"; - const EVENT: &'static str = "Slashed"; + impl ::subxt::events::StaticEvent for MultisigApproval { + const PALLET: &'static str = "Multisig"; + const EVENT: &'static str = "MultisigApproval"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -20770,16 +20217,19 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The signed phase of the given round has started."] - pub struct SignedPhaseStarted { - pub round: ::core::primitive::u32, + #[doc = "A multisig operation has been executed."] + pub struct MultisigExecuted { + pub approving: ::subxt::utils::AccountId32, + pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub multisig: ::subxt::utils::AccountId32, + pub call_hash: [::core::primitive::u8; 32usize], + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, } - impl ::subxt::events::StaticEvent for SignedPhaseStarted { - const PALLET: &'static str = "ElectionProviderMultiPhase"; - const EVENT: &'static str = "SignedPhaseStarted"; + impl ::subxt::events::StaticEvent for MultisigExecuted { + const PALLET: &'static str = "Multisig"; + const EVENT: &'static str = "MultisigExecuted"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -20789,626 +20239,523 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The unsigned phase of the given round has started."] - pub struct UnsignedPhaseStarted { - pub round: ::core::primitive::u32, + #[doc = "A multisig operation has been cancelled."] + pub struct MultisigCancelled { + pub cancelling: ::subxt::utils::AccountId32, + pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub multisig: ::subxt::utils::AccountId32, + pub call_hash: [::core::primitive::u8; 32usize], } - impl ::subxt::events::StaticEvent for UnsignedPhaseStarted { - const PALLET: &'static str = "ElectionProviderMultiPhase"; - const EVENT: &'static str = "UnsignedPhaseStarted"; + impl ::subxt::events::StaticEvent for MultisigCancelled { + const PALLET: &'static str = "Multisig"; + const EVENT: &'static str = "MultisigCancelled"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " Internal counter for the number of rounds."] - #[doc = ""] - #[doc = " This is useful for de-duplication of transactions submitted to the pool, and general"] - #[doc = " diagnostics of the pallet."] - #[doc = ""] - #[doc = " This is merely incremented once per every time that an upstream `elect` is called."] - pub fn round( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "Round", - vec![], - [ - 16u8, 49u8, 176u8, 52u8, 202u8, 111u8, 120u8, 8u8, 217u8, 96u8, 35u8, - 14u8, 233u8, 130u8, 47u8, 98u8, 34u8, 44u8, 166u8, 188u8, 199u8, 210u8, - 21u8, 19u8, 70u8, 96u8, 139u8, 8u8, 53u8, 82u8, 165u8, 239u8, - ], - ) - } - #[doc = " Current phase."] - pub fn current_phase( + #[doc = " The set of open multisig operations."] + pub fn multisigs( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _1: impl ::std::borrow::Borrow<[::core::primitive::u8; 32usize]>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_election_provider_multi_phase::Phase< + runtime_types::pallet_multisig::Multisig< ::core::primitive::u32, + ::core::primitive::u128, + ::subxt::utils::AccountId32, >, ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "CurrentPhase", - vec![], + "Multisig", + "Multisigs", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], [ - 236u8, 101u8, 8u8, 52u8, 68u8, 240u8, 74u8, 159u8, 181u8, 53u8, 153u8, - 101u8, 228u8, 81u8, 96u8, 161u8, 34u8, 67u8, 35u8, 28u8, 121u8, 44u8, - 229u8, 45u8, 196u8, 87u8, 73u8, 125u8, 216u8, 245u8, 255u8, 15u8, + 69u8, 153u8, 186u8, 204u8, 117u8, 95u8, 119u8, 182u8, 220u8, 87u8, 8u8, + 15u8, 123u8, 83u8, 5u8, 188u8, 115u8, 121u8, 163u8, 96u8, 218u8, 3u8, + 106u8, 44u8, 44u8, 187u8, 46u8, 238u8, 80u8, 203u8, 175u8, 155u8, ], ) } - #[doc = " Current best solution, signed or unsigned, queued to be returned upon `elect`."] - pub fn queued_solution( + #[doc = " The set of open multisig operations."] + pub fn multisigs_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_election_provider_multi_phase::ReadySolution, - ::subxt::storage::address::Yes, + runtime_types::pallet_multisig::Multisig< + ::core::primitive::u32, + ::core::primitive::u128, + ::subxt::utils::AccountId32, + >, (), (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "QueuedSolution", - vec![], + "Multisig", + "Multisigs", + Vec::new(), [ - 11u8, 152u8, 13u8, 167u8, 204u8, 209u8, 171u8, 249u8, 59u8, 250u8, - 58u8, 152u8, 164u8, 121u8, 146u8, 112u8, 241u8, 16u8, 159u8, 251u8, - 209u8, 251u8, 114u8, 29u8, 188u8, 30u8, 84u8, 71u8, 136u8, 173u8, - 145u8, 236u8, + 69u8, 153u8, 186u8, 204u8, 117u8, 95u8, 119u8, 182u8, 220u8, 87u8, 8u8, + 15u8, 123u8, 83u8, 5u8, 188u8, 115u8, 121u8, 163u8, 96u8, 218u8, 3u8, + 106u8, 44u8, 44u8, 187u8, 46u8, 238u8, 80u8, 203u8, 175u8, 155u8, ], ) } - #[doc = " Snapshot data of the round."] + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The base amount of currency needed to reserve for creating a multisig execution or to"] + #[doc = " store a dispatch call for later."] #[doc = ""] - #[doc = " This is created at the beginning of the signed phase and cleared upon calling `elect`."] - pub fn snapshot( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_election_provider_multi_phase::RoundSnapshot, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "Snapshot", - vec![], + #[doc = " This is held for an additional storage item whose value size is"] + #[doc = " `4 + sizeof((BlockNumber, Balance, AccountId))` bytes and whose key size is"] + #[doc = " `32 + sizeof(AccountId)` bytes."] + pub fn deposit_base(&self) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Multisig", + "DepositBase", [ - 239u8, 56u8, 191u8, 77u8, 150u8, 224u8, 248u8, 88u8, 132u8, 224u8, - 164u8, 83u8, 253u8, 36u8, 46u8, 156u8, 72u8, 152u8, 36u8, 206u8, 72u8, - 27u8, 226u8, 87u8, 146u8, 220u8, 93u8, 178u8, 26u8, 115u8, 232u8, 71u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = " Desired number of targets to elect for this round."] + #[doc = " The amount of currency needed per unit threshold when creating a multisig execution."] #[doc = ""] - #[doc = " Only exists when [`Snapshot`] is present."] - pub fn desired_targets( + #[doc = " This is held for adding 32 bytes more into a pre-existing storage value."] + pub fn deposit_factor( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "DesiredTargets", - vec![], + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Multisig", + "DepositFactor", [ - 16u8, 247u8, 4u8, 181u8, 93u8, 79u8, 12u8, 212u8, 146u8, 167u8, 80u8, - 58u8, 118u8, 52u8, 68u8, 87u8, 90u8, 140u8, 31u8, 210u8, 2u8, 116u8, - 220u8, 231u8, 115u8, 112u8, 118u8, 118u8, 68u8, 34u8, 151u8, 165u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = " The metadata of the [`RoundSnapshot`]"] - #[doc = ""] - #[doc = " Only exists when [`Snapshot`] is present."] - pub fn snapshot_metadata( + #[doc = " The maximum amount of signatories allowed in the multisig."] + pub fn max_signatories( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_election_provider_multi_phase::SolutionOrSnapshotSize, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "SnapshotMetadata", - vec![], + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Multisig", + "MaxSignatories", [ - 135u8, 122u8, 60u8, 75u8, 194u8, 240u8, 187u8, 96u8, 240u8, 203u8, - 192u8, 22u8, 117u8, 148u8, 118u8, 24u8, 240u8, 213u8, 94u8, 22u8, - 194u8, 47u8, 181u8, 245u8, 77u8, 149u8, 11u8, 251u8, 117u8, 220u8, - 205u8, 78u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = " The next index to be assigned to an incoming signed submission."] - #[doc = ""] - #[doc = " Every accepted submission is assigned a unique index; that index is bound to that particular"] - #[doc = " submission for the duration of the election. On election finalization, the next index is"] - #[doc = " reset to 0."] - #[doc = ""] - #[doc = " We can't just use `SignedSubmissionIndices.len()`, because that's a bounded set; past its"] - #[doc = " capacity, it will simply saturate. We can't just iterate over `SignedSubmissionsMap`,"] - #[doc = " because iteration is slow. Instead, we store the value here."] - pub fn signed_submission_next_index( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "SignedSubmissionNextIndex", - vec![], - [ - 242u8, 11u8, 157u8, 105u8, 96u8, 7u8, 31u8, 20u8, 51u8, 141u8, 182u8, - 180u8, 13u8, 172u8, 155u8, 59u8, 42u8, 238u8, 115u8, 8u8, 6u8, 137u8, - 45u8, 2u8, 123u8, 187u8, 53u8, 215u8, 19u8, 129u8, 54u8, 22u8, - ], - ) - } - #[doc = " A sorted, bounded vector of `(score, block_number, index)`, where each `index` points to a"] - #[doc = " value in `SignedSubmissions`."] + } + } + } + pub mod bounties { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_bounties::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProposeBounty { + #[codec(compact)] + pub value: ::core::primitive::u128, + pub description: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ApproveBounty { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProposeCurator { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub fee: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UnassignCurator { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AcceptCurator { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AwardBounty { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClaimBounty { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CloseBounty { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ExtendBountyExpiry { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + pub remark: ::std::vec::Vec<::core::primitive::u8>, + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Propose a new bounty."] #[doc = ""] - #[doc = " We never need to process more than a single signed submission at a time. Signed submissions"] - #[doc = " can be quite large, so we're willing to pay the cost of multiple database accesses to access"] - #[doc = " them one at a time instead of reading and decoding all of them at once."] - pub fn signed_submission_indices( + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "Payment: `TipReportDepositBase` will be reserved from the origin account, as well as"] + #[doc = "`DataDepositPerByte` for each byte in `reason`. It will be unreserved upon approval,"] + #[doc = "or slashed when rejected."] + #[doc = ""] + #[doc = "- `curator`: The curator account whom will manage this bounty."] + #[doc = "- `fee`: The curator fee."] + #[doc = "- `value`: The total payment amount of this bounty, curator fee included."] + #[doc = "- `description`: The description of this bounty."] + pub fn propose_bounty( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec<( - runtime_types::sp_npos_elections::ElectionScore, - ::core::primitive::u32, - ::core::primitive::u32, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "SignedSubmissionIndices", - vec![], + value: ::core::primitive::u128, + description: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "propose_bounty", + ProposeBounty { value, description }, [ - 228u8, 166u8, 94u8, 248u8, 71u8, 26u8, 125u8, 81u8, 32u8, 22u8, 46u8, - 185u8, 209u8, 123u8, 46u8, 17u8, 152u8, 149u8, 222u8, 125u8, 112u8, - 230u8, 29u8, 177u8, 162u8, 214u8, 66u8, 38u8, 170u8, 121u8, 129u8, - 100u8, + 99u8, 160u8, 94u8, 74u8, 105u8, 161u8, 123u8, 239u8, 241u8, 117u8, + 97u8, 99u8, 84u8, 101u8, 87u8, 3u8, 88u8, 175u8, 75u8, 59u8, 114u8, + 87u8, 18u8, 113u8, 126u8, 26u8, 42u8, 104u8, 201u8, 128u8, 102u8, + 219u8, ], ) } - #[doc = " Unchecked, signed solutions."] + #[doc = "Approve a bounty proposal. At a later time, the bounty will be funded and become active"] + #[doc = "and the original deposit will be returned."] #[doc = ""] - #[doc = " Together with `SubmissionIndices`, this stores a bounded set of `SignedSubmissions` while"] - #[doc = " allowing us to keep only a single one in memory at a time."] + #[doc = "May only be called from `T::SpendOrigin`."] #[doc = ""] - #[doc = " Twox note: the key of the map is an auto-incrementing index which users cannot inspect or"] - #[doc = " affect; we shouldn't need a cryptographically secure hasher."] - pub fn signed_submissions_map( + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn approve_bounty( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_election_provider_multi_phase::signed::SignedSubmission< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - runtime_types::polkadot_runtime::NposCompactSolution16, - >, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "SignedSubmissionsMap", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "approve_bounty", + ApproveBounty { bounty_id }, [ - 84u8, 65u8, 205u8, 191u8, 143u8, 246u8, 239u8, 27u8, 243u8, 54u8, - 250u8, 8u8, 125u8, 32u8, 241u8, 141u8, 210u8, 225u8, 56u8, 101u8, - 241u8, 52u8, 157u8, 29u8, 13u8, 155u8, 73u8, 132u8, 118u8, 53u8, 2u8, - 135u8, + 82u8, 228u8, 232u8, 103u8, 198u8, 173u8, 190u8, 148u8, 159u8, 86u8, + 48u8, 4u8, 32u8, 169u8, 1u8, 129u8, 96u8, 145u8, 235u8, 68u8, 48u8, + 34u8, 5u8, 1u8, 76u8, 26u8, 100u8, 228u8, 92u8, 198u8, 183u8, 173u8, ], ) } - #[doc = " Unchecked, signed solutions."] + #[doc = "Assign a curator to a funded bounty."] #[doc = ""] - #[doc = " Together with `SubmissionIndices`, this stores a bounded set of `SignedSubmissions` while"] - #[doc = " allowing us to keep only a single one in memory at a time."] + #[doc = "May only be called from `T::SpendOrigin`."] #[doc = ""] - #[doc = " Twox note: the key of the map is an auto-incrementing index which users cannot inspect or"] - #[doc = " affect; we shouldn't need a cryptographically secure hasher."] - pub fn signed_submissions_map_root( + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn propose_curator( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_election_provider_multi_phase::signed::SignedSubmission< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - runtime_types::polkadot_runtime::NposCompactSolution16, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "SignedSubmissionsMap", - Vec::new(), + bounty_id: ::core::primitive::u32, + curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + fee: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "propose_curator", + ProposeCurator { + bounty_id, + curator, + fee, + }, [ - 84u8, 65u8, 205u8, 191u8, 143u8, 246u8, 239u8, 27u8, 243u8, 54u8, - 250u8, 8u8, 125u8, 32u8, 241u8, 141u8, 210u8, 225u8, 56u8, 101u8, - 241u8, 52u8, 157u8, 29u8, 13u8, 155u8, 73u8, 132u8, 118u8, 53u8, 2u8, - 135u8, + 123u8, 148u8, 21u8, 204u8, 216u8, 6u8, 47u8, 83u8, 182u8, 30u8, 171u8, + 48u8, 193u8, 200u8, 197u8, 147u8, 111u8, 88u8, 14u8, 242u8, 66u8, + 175u8, 241u8, 208u8, 95u8, 151u8, 41u8, 46u8, 213u8, 188u8, 65u8, + 196u8, ], ) } - #[doc = " The minimum score that each 'untrusted' solution must attain in order to be considered"] - #[doc = " feasible."] + #[doc = "Unassign curator from a bounty."] #[doc = ""] - #[doc = " Can be set via `set_minimum_untrusted_score`."] - pub fn minimum_untrusted_score( + #[doc = "This function can only be called by the `RejectOrigin` a signed origin."] + #[doc = ""] + #[doc = "If this function is called by the `RejectOrigin`, we assume that the curator is"] + #[doc = "malicious or inactive. As a result, we will slash the curator when possible."] + #[doc = ""] + #[doc = "If the origin is the curator, we take this as a sign they are unable to do their job and"] + #[doc = "they willingly give up. We could slash them, but for now we allow them to recover their"] + #[doc = "deposit and exit without issue. (We may want to change this if it is abused.)"] + #[doc = ""] + #[doc = "Finally, the origin can be anyone if and only if the curator is \"inactive\". This allows"] + #[doc = "anyone in the community to call out that a curator is not doing their due diligence, and"] + #[doc = "we should pick a new curator. In this case the curator should also be slashed."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn unassign_curator( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_npos_elections::ElectionScore, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "MinimumUntrustedScore", - vec![], + bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "unassign_curator", + UnassignCurator { bounty_id }, [ - 77u8, 235u8, 181u8, 45u8, 230u8, 12u8, 0u8, 179u8, 152u8, 38u8, 74u8, - 199u8, 47u8, 84u8, 85u8, 55u8, 171u8, 226u8, 217u8, 125u8, 17u8, 194u8, - 95u8, 157u8, 73u8, 245u8, 75u8, 130u8, 248u8, 7u8, 53u8, 226u8, + 218u8, 241u8, 247u8, 89u8, 95u8, 120u8, 93u8, 18u8, 85u8, 114u8, 158u8, + 254u8, 68u8, 77u8, 230u8, 186u8, 230u8, 201u8, 63u8, 223u8, 28u8, + 173u8, 244u8, 82u8, 113u8, 177u8, 99u8, 27u8, 207u8, 247u8, 207u8, + 213u8, ], ) } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Duration of the unsigned phase."] - pub fn unsigned_phase( + #[doc = "Accept the curator role for a bounty."] + #[doc = "A deposit will be reserved from curator and refund upon successful payout."] + #[doc = ""] + #[doc = "May only be called from the curator."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn accept_curator( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "UnsignedPhase", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Duration of the signed phase."] - pub fn signed_phase(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedPhase", + bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "accept_curator", + AcceptCurator { bounty_id }, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 106u8, 96u8, 22u8, 67u8, 52u8, 109u8, 180u8, 225u8, 122u8, 253u8, + 209u8, 214u8, 132u8, 131u8, 247u8, 131u8, 162u8, 51u8, 144u8, 30u8, + 12u8, 126u8, 50u8, 152u8, 229u8, 119u8, 54u8, 116u8, 112u8, 235u8, + 34u8, 166u8, ], ) } - #[doc = " The minimum amount of improvement to the solution score that defines a solution as"] - #[doc = " \"better\" in the Signed phase."] - pub fn better_signed_threshold( + #[doc = "Award bounty to a beneficiary account. The beneficiary will be able to claim the funds"] + #[doc = "after a delay."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be the curator of this bounty."] + #[doc = ""] + #[doc = "- `bounty_id`: Bounty ID to award."] + #[doc = "- `beneficiary`: The beneficiary account whom will receive the payout."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn award_bounty( &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "BetterSignedThreshold", + bounty_id: ::core::primitive::u32, + beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "award_bounty", + AwardBounty { + bounty_id, + beneficiary, + }, [ - 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, - 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, - 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, + 203u8, 164u8, 214u8, 242u8, 1u8, 11u8, 217u8, 32u8, 189u8, 136u8, 29u8, + 230u8, 88u8, 17u8, 134u8, 189u8, 15u8, 204u8, 223u8, 20u8, 168u8, + 182u8, 129u8, 48u8, 83u8, 25u8, 125u8, 25u8, 209u8, 155u8, 170u8, 68u8, ], ) } - #[doc = " The minimum amount of improvement to the solution score that defines a solution as"] - #[doc = " \"better\" in the Unsigned phase."] - pub fn better_unsigned_threshold( + #[doc = "Claim the payout from an awarded bounty after payout delay."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be the beneficiary of this bounty."] + #[doc = ""] + #[doc = "- `bounty_id`: Bounty ID to claim."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn claim_bounty( &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "BetterUnsignedThreshold", + bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "claim_bounty", + ClaimBounty { bounty_id }, [ - 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, - 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, - 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, + 102u8, 95u8, 8u8, 89u8, 4u8, 126u8, 189u8, 28u8, 241u8, 16u8, 125u8, + 218u8, 42u8, 92u8, 177u8, 91u8, 8u8, 235u8, 33u8, 48u8, 64u8, 115u8, + 177u8, 95u8, 242u8, 97u8, 181u8, 50u8, 68u8, 37u8, 59u8, 85u8, ], ) } - #[doc = " The repeat threshold of the offchain worker."] + #[doc = "Cancel a proposed or active bounty. All the funds will be sent to treasury and"] + #[doc = "the curator deposit will be unreserved if possible."] #[doc = ""] - #[doc = " For example, if it is 5, that means that at least 5 blocks will elapse between attempts"] - #[doc = " to submit the worker's solution."] - pub fn offchain_repeat( + #[doc = "Only `T::RejectOrigin` is able to cancel a bounty."] + #[doc = ""] + #[doc = "- `bounty_id`: Bounty ID to cancel."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn close_bounty( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "OffchainRepeat", + bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "close_bounty", + CloseBounty { bounty_id }, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 64u8, 113u8, 151u8, 228u8, 90u8, 55u8, 251u8, 63u8, 27u8, 211u8, 119u8, + 229u8, 137u8, 137u8, 183u8, 240u8, 241u8, 146u8, 69u8, 169u8, 124u8, + 220u8, 236u8, 111u8, 98u8, 188u8, 100u8, 52u8, 127u8, 245u8, 244u8, + 92u8, ], ) } - #[doc = " The priority of the unsigned transaction submitted in the unsigned-phase"] - pub fn miner_tx_priority( + #[doc = "Extend the expiry time of an active bounty."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be the curator of this bounty."] + #[doc = ""] + #[doc = "- `bounty_id`: Bounty ID to extend."] + #[doc = "- `remark`: additional information."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn extend_bounty_expiry( &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MinerTxPriority", + bounty_id: ::core::primitive::u32, + remark: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "extend_bounty_expiry", + ExtendBountyExpiry { bounty_id, remark }, [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, - ], - ) - } - #[doc = " Maximum number of signed submissions that can be queued."] - #[doc = ""] - #[doc = " It is best to avoid adjusting this during an election, as it impacts downstream data"] - #[doc = " structures. In particular, `SignedSubmissionIndices` is bounded on this value. If you"] - #[doc = " update this value during an election, you _must_ ensure that"] - #[doc = " `SignedSubmissionIndices.len()` is less than or equal to the new value. Otherwise,"] - #[doc = " attempts to submit new solutions may cause a runtime panic."] - pub fn signed_max_submissions( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedMaxSubmissions", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Maximum weight of a signed solution."] - #[doc = ""] - #[doc = " If [`Config::MinerConfig`] is being implemented to submit signed solutions (outside of"] - #[doc = " this pallet), then [`MinerConfig::solution_weight`] is used to compare against"] - #[doc = " this value."] - pub fn signed_max_weight( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedMaxWeight", - [ - 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, - 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, - 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, - 106u8, 76u8, - ], - ) - } - #[doc = " The maximum amount of unchecked solutions to refund the call fee for."] - pub fn signed_max_refunds( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedMaxRefunds", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Base reward for a signed solution"] - pub fn signed_reward_base( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedRewardBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Base deposit for a signed solution."] - pub fn signed_deposit_base( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedDepositBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Per-byte deposit for a signed solution."] - pub fn signed_deposit_byte( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedDepositByte", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Per-weight deposit for a signed solution."] - pub fn signed_deposit_weight( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedDepositWeight", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum number of electing voters to put in the snapshot. At the moment, snapshots"] - #[doc = " are only over a single block, but once multi-block elections are introduced they will"] - #[doc = " take place over multiple blocks."] - pub fn max_electing_voters( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MaxElectingVoters", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of electable targets to put in the snapshot."] - pub fn max_electable_targets( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u16> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MaxElectableTargets", - [ - 116u8, 33u8, 2u8, 170u8, 181u8, 147u8, 171u8, 169u8, 167u8, 227u8, - 41u8, 144u8, 11u8, 236u8, 82u8, 100u8, 74u8, 60u8, 184u8, 72u8, 169u8, - 90u8, 208u8, 135u8, 15u8, 117u8, 10u8, 123u8, 128u8, 193u8, 29u8, 70u8, - ], - ) - } - #[doc = " The maximum number of winners that can be elected by this `ElectionProvider`"] - #[doc = " implementation."] - #[doc = ""] - #[doc = " Note: This must always be greater or equal to `T::DataProvider::desired_targets()`."] - pub fn max_winners(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MaxWinners", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - pub fn miner_max_length( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MinerMaxLength", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - pub fn miner_max_weight( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MinerMaxWeight", - [ - 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, - 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, - 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, - 106u8, 76u8, - ], - ) - } - pub fn miner_max_votes_per_voter( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MinerMaxVotesPerVoter", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 97u8, 69u8, 157u8, 39u8, 59u8, 72u8, 79u8, 88u8, 104u8, 119u8, 91u8, + 26u8, 73u8, 216u8, 174u8, 95u8, 254u8, 214u8, 63u8, 138u8, 100u8, + 112u8, 185u8, 81u8, 159u8, 247u8, 221u8, 60u8, 87u8, 40u8, 80u8, 202u8, ], ) } } } - } - pub mod voter_list { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_bags_list::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_bounties::pallet::Event; + pub mod events { use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -21418,8 +20765,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Rebag { - pub dislocated: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[doc = "New bounty proposal."] + pub struct BountyProposed { + pub index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for BountyProposed { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyProposed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -21431,68 +20783,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PutInFrontOf { - pub lighter: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[doc = "A bounty proposal was rejected; funds were slashed."] + pub struct BountyRejected { + pub index: ::core::primitive::u32, + pub bond: ::core::primitive::u128, } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Declare that some `dislocated` account has, through rewards or penalties, sufficiently"] - #[doc = "changed its score that it should properly fall into a different bag than its current"] - #[doc = "one."] - #[doc = ""] - #[doc = "Anyone can call this function about any potentially dislocated account."] - #[doc = ""] - #[doc = "Will always update the stored score of `dislocated` to the correct score, based on"] - #[doc = "`ScoreProvider`."] - #[doc = ""] - #[doc = "If `dislocated` does not exists, it returns an error."] - pub fn rebag( - &self, - dislocated: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "VoterList", - "rebag", - Rebag { dislocated }, - [ - 35u8, 182u8, 31u8, 22u8, 190u8, 187u8, 31u8, 138u8, 60u8, 48u8, 236u8, - 16u8, 191u8, 143u8, 52u8, 110u8, 228u8, 43u8, 116u8, 13u8, 171u8, - 108u8, 112u8, 123u8, 252u8, 231u8, 132u8, 97u8, 195u8, 148u8, 252u8, - 241u8, - ], - ) - } - #[doc = "Move the caller's Id directly in front of `lighter`."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and can only be called by the Id of"] - #[doc = "the account going in front of `lighter`."] - #[doc = ""] - #[doc = "Only works if"] - #[doc = "- both nodes are within the same bag,"] - #[doc = "- and `origin` has a greater `Score` than `lighter`."] - pub fn put_in_front_of( - &self, - lighter: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "VoterList", - "put_in_front_of", - PutInFrontOf { lighter }, - [ - 184u8, 194u8, 39u8, 91u8, 28u8, 220u8, 76u8, 199u8, 64u8, 252u8, 233u8, - 241u8, 74u8, 19u8, 246u8, 190u8, 108u8, 227u8, 77u8, 162u8, 225u8, - 230u8, 101u8, 72u8, 159u8, 217u8, 133u8, 107u8, 84u8, 83u8, 81u8, - 227u8, - ], - ) - } + impl ::subxt::events::StaticEvent for BountyRejected { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyRejected"; } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_bags_list::pallet::Event; - pub mod events { - use super::runtime_types; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -21502,15 +20803,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Moved an account from one bag to another."] - pub struct Rebagged { - pub who: ::subxt::utils::AccountId32, - pub from: ::core::primitive::u64, - pub to: ::core::primitive::u64, + #[doc = "A bounty proposal is funded and became active."] + pub struct BountyBecameActive { + pub index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for Rebagged { - const PALLET: &'static str = "VoterList"; - const EVENT: &'static str = "Rebagged"; + impl ::subxt::events::StaticEvent for BountyBecameActive { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyBecameActive"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -21522,136 +20821,223 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Updated the score of some account to the given amount."] - pub struct ScoreUpdated { - pub who: ::subxt::utils::AccountId32, - pub new_score: ::core::primitive::u64, + #[doc = "A bounty is awarded to a beneficiary."] + pub struct BountyAwarded { + pub index: ::core::primitive::u32, + pub beneficiary: ::subxt::utils::AccountId32, } - impl ::subxt::events::StaticEvent for ScoreUpdated { - const PALLET: &'static str = "VoterList"; - const EVENT: &'static str = "ScoreUpdated"; + impl ::subxt::events::StaticEvent for BountyAwarded { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyAwarded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A bounty is claimed by beneficiary."] + pub struct BountyClaimed { + pub index: ::core::primitive::u32, + pub payout: ::core::primitive::u128, + pub beneficiary: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for BountyClaimed { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyClaimed"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A bounty is cancelled."] + pub struct BountyCanceled { + pub index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for BountyCanceled { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyCanceled"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A bounty expiry is extended."] + pub struct BountyExtended { + pub index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for BountyExtended { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyExtended"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " A single node, within some bag."] - #[doc = ""] - #[doc = " Nodes store links forward and back within their respective bags."] - pub fn list_nodes( + #[doc = " Number of bounty proposals that have been made."] + pub fn bounty_count( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bags_list::list::Node, + ::core::primitive::u32, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "VoterList", - "ListNodes", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Bounties", + "BountyCount", + vec![], [ - 176u8, 186u8, 93u8, 51u8, 100u8, 184u8, 240u8, 29u8, 70u8, 3u8, 117u8, - 47u8, 23u8, 66u8, 231u8, 234u8, 53u8, 8u8, 234u8, 175u8, 181u8, 8u8, - 161u8, 154u8, 48u8, 178u8, 147u8, 227u8, 122u8, 115u8, 57u8, 97u8, + 5u8, 188u8, 134u8, 220u8, 64u8, 49u8, 188u8, 98u8, 185u8, 186u8, 230u8, + 65u8, 247u8, 199u8, 28u8, 178u8, 202u8, 193u8, 41u8, 83u8, 115u8, + 253u8, 182u8, 123u8, 92u8, 138u8, 12u8, 31u8, 31u8, 213u8, 23u8, 118u8, ], ) } - #[doc = " A single node, within some bag."] - #[doc = ""] - #[doc = " Nodes store links forward and back within their respective bags."] - pub fn list_nodes_root( + #[doc = " Bounties that have been made."] + pub fn bounties( &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bags_list::list::Node, - (), + runtime_types::pallet_bounties::Bounty< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "VoterList", - "ListNodes", - Vec::new(), + "Bounties", + "Bounties", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 176u8, 186u8, 93u8, 51u8, 100u8, 184u8, 240u8, 29u8, 70u8, 3u8, 117u8, - 47u8, 23u8, 66u8, 231u8, 234u8, 53u8, 8u8, 234u8, 175u8, 181u8, 8u8, - 161u8, 154u8, 48u8, 178u8, 147u8, 227u8, 122u8, 115u8, 57u8, 97u8, + 111u8, 149u8, 33u8, 54u8, 172u8, 143u8, 41u8, 231u8, 184u8, 255u8, + 238u8, 206u8, 87u8, 142u8, 84u8, 10u8, 236u8, 141u8, 190u8, 193u8, + 72u8, 170u8, 19u8, 110u8, 135u8, 136u8, 220u8, 11u8, 99u8, 126u8, + 225u8, 208u8, ], ) } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_list_nodes( + #[doc = " Bounties that have been made."] + pub fn bounties_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + runtime_types::pallet_bounties::Bounty< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + >, + (), (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "VoterList", - "CounterForListNodes", - vec![], + "Bounties", + "Bounties", + Vec::new(), [ - 156u8, 168u8, 97u8, 33u8, 84u8, 117u8, 220u8, 89u8, 62u8, 182u8, 24u8, - 88u8, 231u8, 244u8, 41u8, 19u8, 210u8, 131u8, 87u8, 0u8, 241u8, 230u8, - 160u8, 142u8, 128u8, 153u8, 83u8, 36u8, 88u8, 247u8, 70u8, 130u8, + 111u8, 149u8, 33u8, 54u8, 172u8, 143u8, 41u8, 231u8, 184u8, 255u8, + 238u8, 206u8, 87u8, 142u8, 84u8, 10u8, 236u8, 141u8, 190u8, 193u8, + 72u8, 170u8, 19u8, 110u8, 135u8, 136u8, 220u8, 11u8, 99u8, 126u8, + 225u8, 208u8, ], ) } - #[doc = " A bag stored in storage."] - #[doc = ""] - #[doc = " Stores a `Bag` struct, which stores head and tail pointers to itself."] - pub fn list_bags( + #[doc = " The description of each bounty."] + pub fn bounty_descriptions( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u64>, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bags_list::list::Bag, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "VoterList", - "ListBags", + "Bounties", + "BountyDescriptions", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 38u8, 86u8, 63u8, 92u8, 85u8, 59u8, 225u8, 244u8, 14u8, 155u8, 76u8, - 249u8, 153u8, 140u8, 179u8, 7u8, 96u8, 170u8, 236u8, 179u8, 4u8, 18u8, - 232u8, 146u8, 216u8, 51u8, 135u8, 116u8, 196u8, 117u8, 143u8, 153u8, + 252u8, 0u8, 9u8, 225u8, 13u8, 135u8, 7u8, 121u8, 154u8, 155u8, 116u8, + 83u8, 160u8, 37u8, 72u8, 11u8, 72u8, 0u8, 248u8, 73u8, 158u8, 84u8, + 125u8, 221u8, 176u8, 231u8, 100u8, 239u8, 111u8, 22u8, 29u8, 13u8, ], ) } - #[doc = " A bag stored in storage."] - #[doc = ""] - #[doc = " Stores a `Bag` struct, which stores head and tail pointers to itself."] - pub fn list_bags_root( + #[doc = " The description of each bounty."] + pub fn bounty_descriptions_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bags_list::list::Bag, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "VoterList", - "ListBags", + "Bounties", + "BountyDescriptions", Vec::new(), [ - 38u8, 86u8, 63u8, 92u8, 85u8, 59u8, 225u8, 244u8, 14u8, 155u8, 76u8, - 249u8, 153u8, 140u8, 179u8, 7u8, 96u8, 170u8, 236u8, 179u8, 4u8, 18u8, - 232u8, 146u8, 216u8, 51u8, 135u8, 116u8, 196u8, 117u8, 143u8, 153u8, + 252u8, 0u8, 9u8, 225u8, 13u8, 135u8, 7u8, 121u8, 154u8, 155u8, 116u8, + 83u8, 160u8, 37u8, 72u8, 11u8, 72u8, 0u8, 248u8, 73u8, 158u8, 84u8, + 125u8, 221u8, 176u8, 231u8, 100u8, 239u8, 111u8, 22u8, 29u8, 13u8, + ], + ) + } + #[doc = " Bounty indices that have been approved but not yet funded."] + pub fn bounty_approvals( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Bounties", + "BountyApprovals", + vec![], + [ + 64u8, 93u8, 54u8, 94u8, 122u8, 9u8, 246u8, 86u8, 234u8, 30u8, 125u8, + 132u8, 49u8, 128u8, 1u8, 219u8, 241u8, 13u8, 217u8, 186u8, 48u8, 21u8, + 5u8, 227u8, 71u8, 157u8, 128u8, 226u8, 214u8, 49u8, 249u8, 183u8, ], ) } @@ -21661,71 +21047,153 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " The list of thresholds separating the various bags."] - #[doc = ""] - #[doc = " Ids are separated into unsorted bags according to their score. This specifies the"] - #[doc = " thresholds separating the bags. An id's bag is the largest bag for which the id's score"] - #[doc = " is less than or equal to its upper threshold."] - #[doc = ""] - #[doc = " When ids are iterated, higher bags are iterated completely before lower bags. This means"] - #[doc = " that iteration is _semi-sorted_: ids of higher score tend to come before ids of lower"] - #[doc = " score, but peer ids within a particular bag are sorted in insertion order."] - #[doc = ""] - #[doc = " # Expressing the constant"] - #[doc = ""] - #[doc = " This constant must be sorted in strictly increasing order. Duplicate items are not"] - #[doc = " permitted."] - #[doc = ""] - #[doc = " There is an implied upper limit of `Score::MAX`; that value does not need to be"] - #[doc = " specified within the bag. For any two threshold lists, if one ends with"] - #[doc = " `Score::MAX`, the other one does not, and they are otherwise equal, the two"] - #[doc = " lists will behave identically."] - #[doc = ""] - #[doc = " # Calculation"] - #[doc = ""] - #[doc = " It is recommended to generate the set of thresholds in a geometric series, such that"] - #[doc = " there exists some constant ratio such that `threshold[k + 1] == (threshold[k] *"] - #[doc = " constant_ratio).max(threshold[k] + 1)` for all `k`."] - #[doc = ""] - #[doc = " The helpers in the `/utils/frame/generate-bags` module can simplify this calculation."] - #[doc = ""] - #[doc = " # Examples"] - #[doc = ""] - #[doc = " - If `BagThresholds::get().is_empty()`, then all ids are put into the same bag, and"] - #[doc = " iteration is strictly in insertion order."] - #[doc = " - If `BagThresholds::get().len() == 64`, and the thresholds are determined according to"] - #[doc = " the procedure given above, then the constant ratio is equal to 2."] - #[doc = " - If `BagThresholds::get().len() == 200`, and the thresholds are determined according to"] - #[doc = " the procedure given above, then the constant ratio is approximately equal to 1.248."] - #[doc = " - If the threshold list begins `[1, 2, 3, ...]`, then an id with score 0 or 1 will fall"] - #[doc = " into bag 0, an id with score 2 will fall into bag 1, etc."] - #[doc = ""] - #[doc = " # Migration"] + #[doc = " The amount held on deposit for placing a bounty proposal."] + pub fn bounty_deposit_base( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Bounties", + "BountyDepositBase", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The delay period for which a bounty beneficiary need to wait before claim the payout."] + pub fn bounty_deposit_payout_delay( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Bounties", + "BountyDepositPayoutDelay", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " Bounty duration in blocks."] + pub fn bounty_update_period( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Bounties", + "BountyUpdatePeriod", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The curator deposit is calculated as a percentage of the curator fee."] #[doc = ""] - #[doc = " In the event that this list ever changes, a copy of the old bags list must be retained."] - #[doc = " With that `List::migrate` can be called, which will perform the appropriate migration."] - pub fn bag_thresholds( + #[doc = " This deposit has optional upper and lower bounds with `CuratorDepositMax` and"] + #[doc = " `CuratorDepositMin`."] + pub fn curator_deposit_multiplier( &self, - ) -> ::subxt::constants::Address<::std::vec::Vec<::core::primitive::u64>> + ) -> ::subxt::constants::Address { ::subxt::constants::Address::new_static( - "VoterList", - "BagThresholds", + "Bounties", + "CuratorDepositMultiplier", [ - 103u8, 102u8, 255u8, 165u8, 124u8, 54u8, 5u8, 172u8, 112u8, 234u8, - 25u8, 175u8, 178u8, 19u8, 251u8, 73u8, 91u8, 192u8, 227u8, 81u8, 249u8, - 45u8, 126u8, 116u8, 7u8, 37u8, 9u8, 200u8, 167u8, 182u8, 12u8, 131u8, + 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, + 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, + 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, + ], + ) + } + #[doc = " Maximum amount of funds that should be placed in a deposit for making a proposal."] + pub fn curator_deposit_max( + &self, + ) -> ::subxt::constants::Address<::core::option::Option<::core::primitive::u128>> + { + ::subxt::constants::Address::new_static( + "Bounties", + "CuratorDepositMax", + [ + 84u8, 154u8, 218u8, 83u8, 84u8, 189u8, 32u8, 20u8, 120u8, 194u8, 88u8, + 205u8, 109u8, 216u8, 114u8, 193u8, 120u8, 198u8, 154u8, 237u8, 134u8, + 204u8, 102u8, 247u8, 52u8, 103u8, 231u8, 43u8, 243u8, 122u8, 60u8, + 216u8, + ], + ) + } + #[doc = " Minimum amount of funds that should be placed in a deposit for making a proposal."] + pub fn curator_deposit_min( + &self, + ) -> ::subxt::constants::Address<::core::option::Option<::core::primitive::u128>> + { + ::subxt::constants::Address::new_static( + "Bounties", + "CuratorDepositMin", + [ + 84u8, 154u8, 218u8, 83u8, 84u8, 189u8, 32u8, 20u8, 120u8, 194u8, 88u8, + 205u8, 109u8, 216u8, 114u8, 193u8, 120u8, 198u8, 154u8, 237u8, 134u8, + 204u8, 102u8, 247u8, 52u8, 103u8, 231u8, 43u8, 243u8, 122u8, 60u8, + 216u8, + ], + ) + } + #[doc = " Minimum value for a bounty."] + pub fn bounty_value_minimum( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Bounties", + "BountyValueMinimum", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The amount held on deposit per byte within the tip report reason or bounty description."] + pub fn data_deposit_per_byte( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Bounties", + "DataDepositPerByte", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " Maximum acceptable reason length."] + #[doc = ""] + #[doc = " Benchmarks depend on this value, be sure to update weights file when changing this value"] + pub fn maximum_reason_length( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Bounties", + "MaximumReasonLength", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } } } } - pub mod nomination_pools { + pub mod child_bounties { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_nomination_pools::pallet::Error; + pub type Error = runtime_types::pallet_child_bounties::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -21741,78 +21209,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Join { + pub struct AddChildBounty { #[codec(compact)] - pub amount: ::core::primitive::u128, - pub pool_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BondExtra { - pub extra: - runtime_types::pallet_nomination_pools::BondExtra<::core::primitive::u128>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimPayout; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Unbond { - pub member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub parent_bounty_id: ::core::primitive::u32, #[codec(compact)] - pub unbonding_points: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PoolWithdrawUnbonded { - pub pool_id: ::core::primitive::u32, - pub num_slashing_spans: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WithdrawUnbonded { - pub member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub num_slashing_spans: ::core::primitive::u32, + pub value: ::core::primitive::u128, + pub description: ::std::vec::Vec<::core::primitive::u8>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -21824,44 +21226,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Create { + pub struct ProposeCurator { #[codec(compact)] - pub amount: ::core::primitive::u128, - pub root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub state_toggler: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CreateWithPoolId { + pub parent_bounty_id: ::core::primitive::u32, #[codec(compact)] - pub amount: ::core::primitive::u128, - pub root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub state_toggler: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub pool_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Nominate { - pub pool_id: ::core::primitive::u32, - pub validators: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub child_bounty_id: ::core::primitive::u32, + pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub fee: ::core::primitive::u128, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -21873,9 +21245,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetState { - pub pool_id: ::core::primitive::u32, - pub state: runtime_types::pallet_nomination_pools::PoolState, + pub struct AcceptCurator { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -21887,9 +21261,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMetadata { - pub pool_id: ::core::primitive::u32, - pub metadata: ::std::vec::Vec<::core::primitive::u8>, + pub struct UnassignCurator { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -21901,17 +21277,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetConfigs { - pub min_join_bond: - runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u128>, - pub min_create_bond: - runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u128>, - pub max_pools: - runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u32>, - pub max_members: - runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u32>, - pub max_members_per_pool: - runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u32>, + pub struct AwardChildBounty { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, + pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -21923,17 +21294,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UpdateRoles { - pub pool_id: ::core::primitive::u32, - pub new_root: - runtime_types::pallet_nomination_pools::ConfigOp<::subxt::utils::AccountId32>, - pub new_nominator: - runtime_types::pallet_nomination_pools::ConfigOp<::subxt::utils::AccountId32>, - pub new_state_toggler: - runtime_types::pallet_nomination_pools::ConfigOp<::subxt::utils::AccountId32>, + pub struct ClaimChildBounty { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -21943,443 +21310,305 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Chill { - pub pool_id: ::core::primitive::u32, + pub struct CloseChildBounty { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, } pub struct TransactionApi; impl TransactionApi { - #[doc = "Stake funds with a pool. The amount to bond is transferred from the member to the"] - #[doc = "pools account and immediately increases the pools bond."] + #[doc = "Add a new child-bounty."] #[doc = ""] - #[doc = "# Note"] + #[doc = "The dispatch origin for this call must be the curator of parent"] + #[doc = "bounty and the parent bounty must be in \"active\" state."] #[doc = ""] - #[doc = "* An account can only be a member of a single pool."] - #[doc = "* An account cannot join the same pool multiple times."] - #[doc = "* This call will *not* dust the member account, so the member must have at least"] - #[doc = " `existential deposit + amount` in their account."] - #[doc = "* Only a pool with [`PoolState::Open`] can be joined"] - pub fn join( - &self, - amount: ::core::primitive::u128, - pool_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NominationPools", - "join", - Join { amount, pool_id }, - [ - 205u8, 66u8, 42u8, 72u8, 146u8, 148u8, 119u8, 162u8, 101u8, 183u8, - 46u8, 176u8, 221u8, 204u8, 197u8, 20u8, 75u8, 226u8, 29u8, 118u8, - 208u8, 60u8, 192u8, 247u8, 222u8, 100u8, 69u8, 80u8, 172u8, 13u8, 69u8, - 250u8, - ], - ) - } - #[doc = "Bond `extra` more funds from `origin` into the pool to which they already belong."] + #[doc = "Child-bounty gets added successfully & fund gets transferred from"] + #[doc = "parent bounty to child-bounty account, if parent bounty has enough"] + #[doc = "funds, else the call fails."] #[doc = ""] - #[doc = "Additional funds can come from either the free balance of the account, of from the"] - #[doc = "accumulated rewards, see [`BondExtra`]."] + #[doc = "Upper bound to maximum number of active child bounties that can be"] + #[doc = "added are managed via runtime trait config"] + #[doc = "[`Config::MaxActiveChildBountyCount`]."] #[doc = ""] - #[doc = "Bonding extra funds implies an automatic payout of all pending rewards as well."] - pub fn bond_extra( + #[doc = "If the call is success, the status of child-bounty is updated to"] + #[doc = "\"Added\"."] + #[doc = ""] + #[doc = "- `parent_bounty_id`: Index of parent bounty for which child-bounty is being added."] + #[doc = "- `value`: Value for executing the proposal."] + #[doc = "- `description`: Text description for the child-bounty."] + pub fn add_child_bounty( &self, - extra: runtime_types::pallet_nomination_pools::BondExtra< - ::core::primitive::u128, - >, - ) -> ::subxt::tx::Payload { + parent_bounty_id: ::core::primitive::u32, + value: ::core::primitive::u128, + description: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "bond_extra", - BondExtra { extra }, + "ChildBounties", + "add_child_bounty", + AddChildBounty { + parent_bounty_id, + value, + description, + }, [ - 50u8, 72u8, 181u8, 216u8, 249u8, 27u8, 250u8, 177u8, 253u8, 22u8, - 240u8, 100u8, 184u8, 202u8, 197u8, 34u8, 21u8, 188u8, 248u8, 191u8, - 11u8, 10u8, 236u8, 161u8, 168u8, 37u8, 38u8, 238u8, 61u8, 183u8, 86u8, - 55u8, + 210u8, 156u8, 242u8, 121u8, 28u8, 214u8, 212u8, 203u8, 46u8, 45u8, + 110u8, 25u8, 33u8, 138u8, 136u8, 71u8, 23u8, 102u8, 203u8, 122u8, 77u8, + 162u8, 112u8, 133u8, 43u8, 73u8, 201u8, 176u8, 102u8, 68u8, 188u8, 8u8, ], ) } - #[doc = "A bonded member can use this to claim their payout based on the rewards that the pool"] - #[doc = "has accumulated since their last claimed payout (OR since joining if this is there first"] - #[doc = "time claiming rewards). The payout will be transferred to the member's account."] + #[doc = "Propose curator for funded child-bounty."] #[doc = ""] - #[doc = "The member will earn rewards pro rata based on the members stake vs the sum of the"] - #[doc = "members in the pools stake. Rewards do not \"expire\"."] - pub fn claim_payout(&self) -> ::subxt::tx::Payload { + #[doc = "The dispatch origin for this call must be curator of parent bounty."] + #[doc = ""] + #[doc = "Parent bounty must be in active state, for this child-bounty call to"] + #[doc = "work."] + #[doc = ""] + #[doc = "Child-bounty must be in \"Added\" state, for processing the call. And"] + #[doc = "state of child-bounty is moved to \"CuratorProposed\" on successful"] + #[doc = "call completion."] + #[doc = ""] + #[doc = "- `parent_bounty_id`: Index of parent bounty."] + #[doc = "- `child_bounty_id`: Index of child bounty."] + #[doc = "- `curator`: Address of child-bounty curator."] + #[doc = "- `fee`: payment fee to child-bounty curator for execution."] + pub fn propose_curator( + &self, + parent_bounty_id: ::core::primitive::u32, + child_bounty_id: ::core::primitive::u32, + curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + fee: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "claim_payout", - ClaimPayout {}, + "ChildBounties", + "propose_curator", + ProposeCurator { + parent_bounty_id, + child_bounty_id, + curator, + fee, + }, [ - 128u8, 58u8, 138u8, 55u8, 64u8, 16u8, 129u8, 25u8, 211u8, 229u8, 193u8, - 115u8, 47u8, 45u8, 155u8, 221u8, 218u8, 1u8, 222u8, 5u8, 236u8, 32u8, - 88u8, 0u8, 198u8, 72u8, 196u8, 181u8, 104u8, 16u8, 212u8, 29u8, + 37u8, 101u8, 96u8, 75u8, 254u8, 212u8, 42u8, 140u8, 72u8, 107u8, 157u8, + 110u8, 147u8, 236u8, 17u8, 138u8, 161u8, 153u8, 119u8, 177u8, 225u8, + 22u8, 83u8, 5u8, 123u8, 38u8, 30u8, 240u8, 134u8, 208u8, 183u8, 247u8, ], ) } - #[doc = "Unbond up to `unbonding_points` of the `member_account`'s funds from the pool. It"] - #[doc = "implicitly collects the rewards one last time, since not doing so would mean some"] - #[doc = "rewards would be forfeited."] - #[doc = ""] - #[doc = "Under certain conditions, this call can be dispatched permissionlessly (i.e. by any"] - #[doc = "account)."] + #[doc = "Accept the curator role for the child-bounty."] #[doc = ""] - #[doc = "# Conditions for a permissionless dispatch."] + #[doc = "The dispatch origin for this call must be the curator of this"] + #[doc = "child-bounty."] #[doc = ""] - #[doc = "* The pool is blocked and the caller is either the root or state-toggler. This is"] - #[doc = " refereed to as a kick."] - #[doc = "* The pool is destroying and the member is not the depositor."] - #[doc = "* The pool is destroying, the member is the depositor and no other members are in the"] - #[doc = " pool."] + #[doc = "A deposit will be reserved from the curator and refund upon"] + #[doc = "successful payout or cancellation."] #[doc = ""] - #[doc = "## Conditions for permissioned dispatch (i.e. the caller is also the"] - #[doc = "`member_account`):"] + #[doc = "Fee for curator is deducted from curator fee of parent bounty."] #[doc = ""] - #[doc = "* The caller is not the depositor."] - #[doc = "* The caller is the depositor, the pool is destroying and no other members are in the"] - #[doc = " pool."] + #[doc = "Parent bounty must be in active state, for this child-bounty call to"] + #[doc = "work."] #[doc = ""] - #[doc = "# Note"] + #[doc = "Child-bounty must be in \"CuratorProposed\" state, for processing the"] + #[doc = "call. And state of child-bounty is moved to \"Active\" on successful"] + #[doc = "call completion."] #[doc = ""] - #[doc = "If there are too many unlocking chunks to unbond with the pool account,"] - #[doc = "[`Call::pool_withdraw_unbonded`] can be called to try and minimize unlocking chunks. If"] - #[doc = "there are too many unlocking chunks, the result of this call will likely be the"] - #[doc = "`NoMoreChunks` error from the staking system."] - pub fn unbond( + #[doc = "- `parent_bounty_id`: Index of parent bounty."] + #[doc = "- `child_bounty_id`: Index of child bounty."] + pub fn accept_curator( &self, - member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - unbonding_points: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + parent_bounty_id: ::core::primitive::u32, + child_bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "unbond", - Unbond { - member_account, - unbonding_points, + "ChildBounties", + "accept_curator", + AcceptCurator { + parent_bounty_id, + child_bounty_id, }, [ - 78u8, 15u8, 37u8, 18u8, 129u8, 63u8, 31u8, 3u8, 68u8, 10u8, 12u8, 12u8, - 166u8, 179u8, 38u8, 232u8, 97u8, 1u8, 83u8, 53u8, 26u8, 59u8, 42u8, - 219u8, 176u8, 246u8, 169u8, 28u8, 35u8, 67u8, 139u8, 81u8, + 112u8, 175u8, 238u8, 54u8, 132u8, 20u8, 206u8, 59u8, 220u8, 228u8, + 207u8, 222u8, 132u8, 240u8, 188u8, 0u8, 210u8, 225u8, 234u8, 142u8, + 232u8, 53u8, 64u8, 89u8, 220u8, 29u8, 28u8, 123u8, 125u8, 207u8, 10u8, + 52u8, ], ) } - #[doc = "Call `withdraw_unbonded` for the pools account. This call can be made by any account."] + #[doc = "Unassign curator from a child-bounty."] #[doc = ""] - #[doc = "This is useful if their are too many unlocking chunks to call `unbond`, and some"] - #[doc = "can be cleared by withdrawing. In the case there are too many unlocking chunks, the user"] - #[doc = "would probably see an error like `NoMoreChunks` emitted from the staking system when"] - #[doc = "they attempt to unbond."] - pub fn pool_withdraw_unbonded( - &self, - pool_id: ::core::primitive::u32, - num_slashing_spans: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NominationPools", - "pool_withdraw_unbonded", - PoolWithdrawUnbonded { - pool_id, - num_slashing_spans, - }, - [ - 152u8, 245u8, 131u8, 247u8, 106u8, 214u8, 154u8, 8u8, 7u8, 210u8, - 149u8, 218u8, 118u8, 46u8, 242u8, 182u8, 191u8, 119u8, 28u8, 199u8, - 36u8, 49u8, 219u8, 123u8, 58u8, 203u8, 211u8, 226u8, 217u8, 36u8, 56u8, - 0u8, - ], - ) - } - #[doc = "Withdraw unbonded funds from `member_account`. If no bonded funds can be unbonded, an"] - #[doc = "error is returned."] + #[doc = "The dispatch origin for this call can be either `RejectOrigin`, or"] + #[doc = "the curator of the parent bounty, or any signed origin."] #[doc = ""] - #[doc = "Under certain conditions, this call can be dispatched permissionlessly (i.e. by any"] - #[doc = "account)."] + #[doc = "For the origin other than T::RejectOrigin and the child-bounty"] + #[doc = "curator, parent bounty must be in active state, for this call to"] + #[doc = "work. We allow child-bounty curator and T::RejectOrigin to execute"] + #[doc = "this call irrespective of the parent bounty state."] #[doc = ""] - #[doc = "# Conditions for a permissionless dispatch"] + #[doc = "If this function is called by the `RejectOrigin` or the"] + #[doc = "parent bounty curator, we assume that the child-bounty curator is"] + #[doc = "malicious or inactive. As a result, child-bounty curator deposit is"] + #[doc = "slashed."] #[doc = ""] - #[doc = "* The pool is in destroy mode and the target is not the depositor."] - #[doc = "* The target is the depositor and they are the only member in the sub pools."] - #[doc = "* The pool is blocked and the caller is either the root or state-toggler."] + #[doc = "If the origin is the child-bounty curator, we take this as a sign"] + #[doc = "that they are unable to do their job, and are willingly giving up."] + #[doc = "We could slash the deposit, but for now we allow them to unreserve"] + #[doc = "their deposit and exit without issue. (We may want to change this if"] + #[doc = "it is abused.)"] #[doc = ""] - #[doc = "# Conditions for permissioned dispatch"] + #[doc = "Finally, the origin can be anyone iff the child-bounty curator is"] + #[doc = "\"inactive\". Expiry update due of parent bounty is used to estimate"] + #[doc = "inactive state of child-bounty curator."] #[doc = ""] - #[doc = "* The caller is the target and they are not the depositor."] + #[doc = "This allows anyone in the community to call out that a child-bounty"] + #[doc = "curator is not doing their due diligence, and we should pick a new"] + #[doc = "one. In this case the child-bounty curator deposit is slashed."] #[doc = ""] - #[doc = "# Note"] + #[doc = "State of child-bounty is moved to Added state on successful call"] + #[doc = "completion."] #[doc = ""] - #[doc = "If the target is the depositor, the pool will be destroyed."] - pub fn withdraw_unbonded( + #[doc = "- `parent_bounty_id`: Index of parent bounty."] + #[doc = "- `child_bounty_id`: Index of child bounty."] + pub fn unassign_curator( &self, - member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - num_slashing_spans: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + parent_bounty_id: ::core::primitive::u32, + child_bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "withdraw_unbonded", - WithdrawUnbonded { - member_account, - num_slashing_spans, + "ChildBounties", + "unassign_curator", + UnassignCurator { + parent_bounty_id, + child_bounty_id, }, [ - 61u8, 216u8, 214u8, 166u8, 59u8, 42u8, 186u8, 141u8, 47u8, 50u8, 135u8, - 236u8, 166u8, 88u8, 90u8, 244u8, 57u8, 106u8, 193u8, 211u8, 215u8, - 131u8, 203u8, 33u8, 195u8, 120u8, 213u8, 94u8, 213u8, 66u8, 79u8, - 140u8, + 228u8, 189u8, 46u8, 75u8, 121u8, 161u8, 150u8, 87u8, 207u8, 86u8, + 192u8, 50u8, 52u8, 61u8, 49u8, 88u8, 178u8, 182u8, 89u8, 72u8, 203u8, + 45u8, 41u8, 26u8, 149u8, 114u8, 154u8, 169u8, 118u8, 128u8, 13u8, + 211u8, ], ) } - #[doc = "Create a new delegation pool."] - #[doc = ""] - #[doc = "# Arguments"] + #[doc = "Award child-bounty to a beneficiary."] #[doc = ""] - #[doc = "* `amount` - The amount of funds to delegate to the pool. This also acts of a sort of"] - #[doc = " deposit since the pools creator cannot fully unbond funds until the pool is being"] - #[doc = " destroyed."] - #[doc = "* `index` - A disambiguation index for creating the account. Likely only useful when"] - #[doc = " creating multiple pools in the same extrinsic."] - #[doc = "* `root` - The account to set as [`PoolRoles::root`]."] - #[doc = "* `nominator` - The account to set as the [`PoolRoles::nominator`]."] - #[doc = "* `state_toggler` - The account to set as the [`PoolRoles::state_toggler`]."] + #[doc = "The beneficiary will be able to claim the funds after a delay."] #[doc = ""] - #[doc = "# Note"] + #[doc = "The dispatch origin for this call must be the parent curator or"] + #[doc = "curator of this child-bounty."] #[doc = ""] - #[doc = "In addition to `amount`, the caller will transfer the existential deposit; so the caller"] - #[doc = "needs at have at least `amount + existential_deposit` transferrable."] - pub fn create( - &self, - amount: ::core::primitive::u128, - root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - state_toggler: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NominationPools", - "create", - Create { - amount, - root, - nominator, - state_toggler, - }, - [ - 176u8, 210u8, 154u8, 87u8, 218u8, 250u8, 117u8, 90u8, 80u8, 191u8, - 252u8, 146u8, 29u8, 228u8, 36u8, 15u8, 125u8, 102u8, 87u8, 50u8, 146u8, - 108u8, 96u8, 145u8, 135u8, 189u8, 18u8, 159u8, 21u8, 74u8, 165u8, 33u8, - ], - ) - } - #[doc = "Create a new delegation pool with a previously used pool id"] + #[doc = "Parent bounty must be in active state, for this child-bounty call to"] + #[doc = "work."] #[doc = ""] - #[doc = "# Arguments"] + #[doc = "Child-bounty must be in active state, for processing the call. And"] + #[doc = "state of child-bounty is moved to \"PendingPayout\" on successful call"] + #[doc = "completion."] #[doc = ""] - #[doc = "same as `create` with the inclusion of"] - #[doc = "* `pool_id` - `A valid PoolId."] - pub fn create_with_pool_id( + #[doc = "- `parent_bounty_id`: Index of parent bounty."] + #[doc = "- `child_bounty_id`: Index of child bounty."] + #[doc = "- `beneficiary`: Beneficiary account."] + pub fn award_child_bounty( &self, - amount: ::core::primitive::u128, - root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - state_toggler: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pool_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + parent_bounty_id: ::core::primitive::u32, + child_bounty_id: ::core::primitive::u32, + beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "create_with_pool_id", - CreateWithPoolId { - amount, - root, - nominator, - state_toggler, - pool_id, + "ChildBounties", + "award_child_bounty", + AwardChildBounty { + parent_bounty_id, + child_bounty_id, + beneficiary, }, [ - 234u8, 228u8, 116u8, 171u8, 77u8, 41u8, 166u8, 254u8, 20u8, 78u8, 38u8, - 28u8, 144u8, 58u8, 2u8, 64u8, 11u8, 27u8, 124u8, 215u8, 8u8, 10u8, - 172u8, 189u8, 118u8, 131u8, 102u8, 191u8, 251u8, 208u8, 167u8, 103u8, + 231u8, 185u8, 73u8, 232u8, 92u8, 116u8, 204u8, 165u8, 216u8, 194u8, + 151u8, 21u8, 127u8, 239u8, 78u8, 45u8, 27u8, 252u8, 119u8, 23u8, 71u8, + 140u8, 137u8, 209u8, 189u8, 128u8, 126u8, 247u8, 13u8, 42u8, 68u8, + 134u8, ], ) } - #[doc = "Nominate on behalf of the pool."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be signed by the pool nominator or the pool"] - #[doc = "root role."] + #[doc = "Claim the payout from an awarded child-bounty after payout delay."] #[doc = ""] - #[doc = "This directly forward the call to the staking pallet, on behalf of the pool bonded"] - #[doc = "account."] - pub fn nominate( - &self, - pool_id: ::core::primitive::u32, - validators: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NominationPools", - "nominate", - Nominate { - pool_id, - validators, - }, - [ - 10u8, 235u8, 64u8, 157u8, 36u8, 249u8, 186u8, 27u8, 79u8, 172u8, 25u8, - 3u8, 203u8, 19u8, 192u8, 182u8, 36u8, 103u8, 13u8, 20u8, 89u8, 140u8, - 159u8, 4u8, 132u8, 242u8, 192u8, 146u8, 55u8, 251u8, 216u8, 255u8, - ], - ) - } - #[doc = "Set a new state for the pool."] + #[doc = "The dispatch origin for this call may be any signed origin."] #[doc = ""] - #[doc = "If a pool is already in the `Destroying` state, then under no condition can its state"] - #[doc = "change again."] + #[doc = "Call works independent of parent bounty state, No need for parent"] + #[doc = "bounty to be in active state."] #[doc = ""] - #[doc = "The dispatch origin of this call must be either:"] + #[doc = "The Beneficiary is paid out with agreed bounty value. Curator fee is"] + #[doc = "paid & curator deposit is unreserved."] #[doc = ""] - #[doc = "1. signed by the state toggler, or the root role of the pool,"] - #[doc = "2. if the pool conditions to be open are NOT met (as described by `ok_to_be_open`), and"] - #[doc = " then the state of the pool can be permissionlessly changed to `Destroying`."] - pub fn set_state( - &self, - pool_id: ::core::primitive::u32, - state: runtime_types::pallet_nomination_pools::PoolState, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NominationPools", - "set_state", - SetState { pool_id, state }, - [ - 104u8, 40u8, 213u8, 88u8, 159u8, 115u8, 35u8, 249u8, 78u8, 180u8, 99u8, - 1u8, 225u8, 218u8, 192u8, 151u8, 25u8, 194u8, 192u8, 187u8, 39u8, - 170u8, 212u8, 125u8, 75u8, 250u8, 248u8, 175u8, 159u8, 161u8, 151u8, - 162u8, - ], - ) - } - #[doc = "Set a new metadata for the pool."] + #[doc = "Child-bounty must be in \"PendingPayout\" state, for processing the"] + #[doc = "call. And instance of child-bounty is removed from the state on"] + #[doc = "successful call completion."] #[doc = ""] - #[doc = "The dispatch origin of this call must be signed by the state toggler, or the root role"] - #[doc = "of the pool."] - pub fn set_metadata( + #[doc = "- `parent_bounty_id`: Index of parent bounty."] + #[doc = "- `child_bounty_id`: Index of child bounty."] + pub fn claim_child_bounty( &self, - pool_id: ::core::primitive::u32, - metadata: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + parent_bounty_id: ::core::primitive::u32, + child_bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "set_metadata", - SetMetadata { pool_id, metadata }, + "ChildBounties", + "claim_child_bounty", + ClaimChildBounty { + parent_bounty_id, + child_bounty_id, + }, [ - 156u8, 81u8, 170u8, 161u8, 34u8, 100u8, 183u8, 174u8, 5u8, 81u8, 31u8, - 76u8, 12u8, 42u8, 77u8, 1u8, 6u8, 26u8, 168u8, 7u8, 8u8, 115u8, 158u8, - 151u8, 30u8, 211u8, 52u8, 177u8, 234u8, 87u8, 125u8, 127u8, + 134u8, 243u8, 151u8, 228u8, 38u8, 174u8, 96u8, 140u8, 104u8, 124u8, + 166u8, 206u8, 126u8, 211u8, 17u8, 100u8, 172u8, 5u8, 234u8, 171u8, + 125u8, 2u8, 191u8, 163u8, 72u8, 29u8, 163u8, 107u8, 65u8, 92u8, 41u8, + 45u8, ], ) } - #[doc = "Update configurations for the nomination pools. The origin for this call must be"] - #[doc = "Root."] + #[doc = "Cancel a proposed or active child-bounty. Child-bounty account funds"] + #[doc = "are transferred to parent bounty account. The child-bounty curator"] + #[doc = "deposit may be unreserved if possible."] #[doc = ""] - #[doc = "# Arguments"] + #[doc = "The dispatch origin for this call must be either parent curator or"] + #[doc = "`T::RejectOrigin`."] #[doc = ""] - #[doc = "* `min_join_bond` - Set [`MinJoinBond`]."] - #[doc = "* `min_create_bond` - Set [`MinCreateBond`]."] - #[doc = "* `max_pools` - Set [`MaxPools`]."] - #[doc = "* `max_members` - Set [`MaxPoolMembers`]."] - #[doc = "* `max_members_per_pool` - Set [`MaxPoolMembersPerPool`]."] - pub fn set_configs( - &self, - min_join_bond: runtime_types::pallet_nomination_pools::ConfigOp< - ::core::primitive::u128, - >, - min_create_bond: runtime_types::pallet_nomination_pools::ConfigOp< - ::core::primitive::u128, - >, - max_pools: runtime_types::pallet_nomination_pools::ConfigOp< - ::core::primitive::u32, - >, - max_members: runtime_types::pallet_nomination_pools::ConfigOp< - ::core::primitive::u32, - >, - max_members_per_pool: runtime_types::pallet_nomination_pools::ConfigOp< - ::core::primitive::u32, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NominationPools", - "set_configs", - SetConfigs { - min_join_bond, - min_create_bond, - max_pools, - max_members, - max_members_per_pool, - }, - [ - 143u8, 196u8, 211u8, 30u8, 71u8, 15u8, 150u8, 243u8, 7u8, 178u8, 179u8, - 168u8, 40u8, 116u8, 220u8, 140u8, 18u8, 206u8, 6u8, 189u8, 190u8, 37u8, - 68u8, 41u8, 45u8, 233u8, 247u8, 172u8, 185u8, 34u8, 243u8, 187u8, - ], - ) - } - #[doc = "Update the roles of the pool."] + #[doc = "If the state of child-bounty is `Active`, curator deposit is"] + #[doc = "unreserved."] #[doc = ""] - #[doc = "The root is the only entity that can change any of the roles, including itself,"] - #[doc = "excluding the depositor, who can never change."] + #[doc = "If the state of child-bounty is `PendingPayout`, call fails &"] + #[doc = "returns `PendingPayout` error."] #[doc = ""] - #[doc = "It emits an event, notifying UIs of the role change. This event is quite relevant to"] - #[doc = "most pool members and they should be informed of changes to pool roles."] - pub fn update_roles( - &self, - pool_id: ::core::primitive::u32, - new_root: runtime_types::pallet_nomination_pools::ConfigOp< - ::subxt::utils::AccountId32, - >, - new_nominator: runtime_types::pallet_nomination_pools::ConfigOp< - ::subxt::utils::AccountId32, - >, - new_state_toggler: runtime_types::pallet_nomination_pools::ConfigOp< - ::subxt::utils::AccountId32, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NominationPools", - "update_roles", - UpdateRoles { - pool_id, - new_root, - new_nominator, - new_state_toggler, - }, - [ - 247u8, 95u8, 234u8, 56u8, 181u8, 229u8, 158u8, 97u8, 69u8, 165u8, 38u8, - 17u8, 27u8, 209u8, 204u8, 250u8, 91u8, 193u8, 35u8, 93u8, 215u8, 131u8, - 148u8, 73u8, 67u8, 188u8, 92u8, 32u8, 34u8, 37u8, 113u8, 93u8, - ], - ) - } - #[doc = "Chill on behalf of the pool."] + #[doc = "For the origin other than T::RejectOrigin, parent bounty must be in"] + #[doc = "active state, for this child-bounty call to work. For origin"] + #[doc = "T::RejectOrigin execution is forced."] #[doc = ""] - #[doc = "The dispatch origin of this call must be signed by the pool nominator or the pool"] - #[doc = "root role, same as [`Pallet::nominate`]."] + #[doc = "Instance of child-bounty is removed from the state on successful"] + #[doc = "call completion."] #[doc = ""] - #[doc = "This directly forward the call to the staking pallet, on behalf of the pool bonded"] - #[doc = "account."] - pub fn chill( + #[doc = "- `parent_bounty_id`: Index of parent bounty."] + #[doc = "- `child_bounty_id`: Index of child bounty."] + pub fn close_child_bounty( &self, - pool_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + parent_bounty_id: ::core::primitive::u32, + child_bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "chill", - Chill { pool_id }, + "ChildBounties", + "close_child_bounty", + CloseChildBounty { + parent_bounty_id, + child_bounty_id, + }, [ - 41u8, 114u8, 128u8, 121u8, 244u8, 15u8, 15u8, 52u8, 129u8, 88u8, 239u8, - 167u8, 216u8, 38u8, 123u8, 240u8, 172u8, 229u8, 132u8, 64u8, 175u8, - 87u8, 217u8, 27u8, 11u8, 124u8, 1u8, 140u8, 40u8, 191u8, 187u8, 36u8, + 40u8, 0u8, 235u8, 75u8, 36u8, 196u8, 29u8, 26u8, 30u8, 172u8, 240u8, + 44u8, 129u8, 243u8, 55u8, 211u8, 96u8, 159u8, 72u8, 96u8, 142u8, 68u8, + 41u8, 238u8, 157u8, 167u8, 90u8, 141u8, 213u8, 249u8, 222u8, 22u8, ], ) } } } - #[doc = "Events of this pallet."] - pub type Event = runtime_types::pallet_nomination_pools::pallet::Event; + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_child_bounties::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -22392,14 +21621,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A pool has been created."] - pub struct Created { - pub depositor: ::subxt::utils::AccountId32, - pub pool_id: ::core::primitive::u32, + #[doc = "A child-bounty is added."] + pub struct Added { + pub index: ::core::primitive::u32, + pub child_index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for Created { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "Created"; + impl ::subxt::events::StaticEvent for Added { + const PALLET: &'static str = "ChildBounties"; + const EVENT: &'static str = "Added"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -22411,16 +21640,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A member has became bonded in a pool."] - pub struct Bonded { - pub member: ::subxt::utils::AccountId32, - pub pool_id: ::core::primitive::u32, - pub bonded: ::core::primitive::u128, - pub joined: ::core::primitive::bool, + #[doc = "A child-bounty is awarded to a beneficiary."] + pub struct Awarded { + pub index: ::core::primitive::u32, + pub child_index: ::core::primitive::u32, + pub beneficiary: ::subxt::utils::AccountId32, } - impl ::subxt::events::StaticEvent for Bonded { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "Bonded"; + impl ::subxt::events::StaticEvent for Awarded { + const PALLET: &'static str = "ChildBounties"; + const EVENT: &'static str = "Awarded"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -22432,92 +21660,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A payout has been made to a member."] - pub struct PaidOut { - pub member: ::subxt::utils::AccountId32, - pub pool_id: ::core::primitive::u32, + #[doc = "A child-bounty is claimed by beneficiary."] + pub struct Claimed { + pub index: ::core::primitive::u32, + pub child_index: ::core::primitive::u32, pub payout: ::core::primitive::u128, + pub beneficiary: ::subxt::utils::AccountId32, } - impl ::subxt::events::StaticEvent for PaidOut { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "PaidOut"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A member has unbonded from their pool."] - #[doc = ""] - #[doc = "- `balance` is the corresponding balance of the number of points that has been"] - #[doc = " requested to be unbonded (the argument of the `unbond` transaction) from the bonded"] - #[doc = " pool."] - #[doc = "- `points` is the number of points that are issued as a result of `balance` being"] - #[doc = "dissolved into the corresponding unbonding pool."] - #[doc = "- `era` is the era in which the balance will be unbonded."] - #[doc = "In the absence of slashing, these values will match. In the presence of slashing, the"] - #[doc = "number of points that are issued in the unbonding pool will be less than the amount"] - #[doc = "requested to be unbonded."] - pub struct Unbonded { - pub member: ::subxt::utils::AccountId32, - pub pool_id: ::core::primitive::u32, - pub balance: ::core::primitive::u128, - pub points: ::core::primitive::u128, - pub era: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Unbonded { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "Unbonded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A member has withdrawn from their pool."] - #[doc = ""] - #[doc = "The given number of `points` have been dissolved in return of `balance`."] - #[doc = ""] - #[doc = "Similar to `Unbonded` event, in the absence of slashing, the ratio of point to balance"] - #[doc = "will be 1."] - pub struct Withdrawn { - pub member: ::subxt::utils::AccountId32, - pub pool_id: ::core::primitive::u32, - pub balance: ::core::primitive::u128, - pub points: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Withdrawn { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "Withdrawn"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A pool has been destroyed."] - pub struct Destroyed { - pub pool_id: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Destroyed { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "Destroyed"; + impl ::subxt::events::StaticEvent for Claimed { + const PALLET: &'static str = "ChildBounties"; + const EVENT: &'static str = "Claimed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -22529,710 +21681,286 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The state of a pool has changed"] - pub struct StateChanged { - pub pool_id: ::core::primitive::u32, - pub new_state: runtime_types::pallet_nomination_pools::PoolState, + #[doc = "A child-bounty is cancelled."] + pub struct Canceled { + pub index: ::core::primitive::u32, + pub child_index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for StateChanged { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "StateChanged"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A member has been removed from a pool."] - #[doc = ""] - #[doc = "The removal can be voluntary (withdrawn all unbonded funds) or involuntary (kicked)."] - pub struct MemberRemoved { - pub pool_id: ::core::primitive::u32, - pub member: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for MemberRemoved { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "MemberRemoved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The roles of a pool have been updated to the given new roles. Note that the depositor"] - #[doc = "can never change."] - pub struct RolesUpdated { - pub root: ::core::option::Option<::subxt::utils::AccountId32>, - pub state_toggler: ::core::option::Option<::subxt::utils::AccountId32>, - pub nominator: ::core::option::Option<::subxt::utils::AccountId32>, - } - impl ::subxt::events::StaticEvent for RolesUpdated { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "RolesUpdated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The active balance of pool `pool_id` has been slashed to `balance`."] - pub struct PoolSlashed { - pub pool_id: ::core::primitive::u32, - pub balance: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for PoolSlashed { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "PoolSlashed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The unbond pool at `era` of pool `pool_id` has been slashed to `balance`."] - pub struct UnbondingPoolSlashed { - pub pool_id: ::core::primitive::u32, - pub era: ::core::primitive::u32, - pub balance: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for UnbondingPoolSlashed { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "UnbondingPoolSlashed"; + impl ::subxt::events::StaticEvent for Canceled { + const PALLET: &'static str = "ChildBounties"; + const EVENT: &'static str = "Canceled"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " Minimum amount to bond to join a pool."] - pub fn min_join_bond( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "MinJoinBond", - vec![], - [ - 125u8, 239u8, 45u8, 225u8, 74u8, 129u8, 247u8, 184u8, 205u8, 58u8, - 45u8, 186u8, 126u8, 170u8, 112u8, 120u8, 23u8, 190u8, 247u8, 97u8, - 131u8, 126u8, 215u8, 44u8, 147u8, 122u8, 132u8, 212u8, 217u8, 84u8, - 240u8, 91u8, - ], - ) - } - #[doc = " Minimum bond required to create a pool."] - #[doc = ""] - #[doc = " This is the amount that the depositor must put as their initial stake in the pool, as an"] - #[doc = " indication of \"skin in the game\"."] - #[doc = ""] - #[doc = " This is the value that will always exist in the staking ledger of the pool bonded account"] - #[doc = " while all other accounts leave."] - pub fn min_create_bond( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "MinCreateBond", - vec![], - [ - 31u8, 208u8, 240u8, 158u8, 23u8, 218u8, 212u8, 138u8, 92u8, 210u8, - 207u8, 170u8, 32u8, 60u8, 5u8, 21u8, 84u8, 162u8, 1u8, 111u8, 181u8, - 243u8, 24u8, 148u8, 193u8, 253u8, 248u8, 190u8, 16u8, 222u8, 219u8, - 67u8, - ], - ) - } - #[doc = " Maximum number of nomination pools that can exist. If `None`, then an unbounded number of"] - #[doc = " pools can exist."] - pub fn max_pools( + #[doc = " Number of total child bounties."] + pub fn child_bounty_count( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, ::core::primitive::u32, ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "MaxPools", - vec![], - [ - 216u8, 111u8, 68u8, 103u8, 33u8, 50u8, 109u8, 3u8, 176u8, 195u8, 23u8, - 73u8, 112u8, 138u8, 9u8, 194u8, 233u8, 73u8, 68u8, 215u8, 162u8, 255u8, - 217u8, 173u8, 141u8, 27u8, 72u8, 199u8, 7u8, 240u8, 25u8, 34u8, - ], - ) - } - #[doc = " Maximum number of members that can exist in the system. If `None`, then the count"] - #[doc = " members are not bound on a system wide basis."] - pub fn max_pool_members( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, ::subxt::storage::address::Yes, (), - (), > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "MaxPoolMembers", + "ChildBounties", + "ChildBountyCount", vec![], [ - 82u8, 217u8, 26u8, 234u8, 223u8, 241u8, 66u8, 182u8, 43u8, 233u8, 59u8, - 242u8, 202u8, 254u8, 69u8, 50u8, 254u8, 196u8, 166u8, 89u8, 120u8, - 87u8, 76u8, 148u8, 31u8, 197u8, 49u8, 88u8, 206u8, 41u8, 242u8, 62u8, + 46u8, 10u8, 183u8, 160u8, 98u8, 215u8, 39u8, 253u8, 81u8, 94u8, 114u8, + 147u8, 115u8, 162u8, 33u8, 117u8, 160u8, 214u8, 167u8, 7u8, 109u8, + 143u8, 158u8, 1u8, 200u8, 205u8, 17u8, 93u8, 89u8, 26u8, 30u8, 95u8, ], ) } - #[doc = " Maximum number of members that may belong to pool. If `None`, then the count of"] - #[doc = " members is not bound on a per pool basis."] - pub fn max_pool_members_per_pool( + #[doc = " Number of child bounties per parent bounty."] + #[doc = " Map of parent bounty index to number of child bounties."] + pub fn parent_child_bounties( &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, ::core::primitive::u32, ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "MaxPoolMembersPerPool", - vec![], - [ - 93u8, 241u8, 16u8, 169u8, 138u8, 199u8, 128u8, 149u8, 65u8, 30u8, 55u8, - 11u8, 41u8, 252u8, 83u8, 250u8, 9u8, 33u8, 152u8, 239u8, 195u8, 147u8, - 16u8, 248u8, 180u8, 153u8, 88u8, 231u8, 248u8, 169u8, 186u8, 48u8, - ], - ) - } - #[doc = " Active members."] - pub fn pool_members( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::PoolMember, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "PoolMembers", + "ChildBounties", + "ParentChildBounties", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 252u8, 236u8, 201u8, 127u8, 219u8, 1u8, 19u8, 144u8, 5u8, 108u8, 70u8, - 30u8, 177u8, 232u8, 253u8, 237u8, 211u8, 91u8, 63u8, 62u8, 155u8, - 151u8, 153u8, 165u8, 206u8, 53u8, 111u8, 31u8, 60u8, 120u8, 100u8, - 249u8, - ], - ) - } - #[doc = " Active members."] - pub fn pool_members_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::PoolMember, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "PoolMembers", - Vec::new(), - [ - 252u8, 236u8, 201u8, 127u8, 219u8, 1u8, 19u8, 144u8, 5u8, 108u8, 70u8, - 30u8, 177u8, 232u8, 253u8, 237u8, 211u8, 91u8, 63u8, 62u8, 155u8, - 151u8, 153u8, 165u8, 206u8, 53u8, 111u8, 31u8, 60u8, 120u8, 100u8, - 249u8, + 127u8, 161u8, 181u8, 79u8, 235u8, 196u8, 252u8, 162u8, 39u8, 15u8, + 251u8, 49u8, 125u8, 80u8, 101u8, 24u8, 234u8, 88u8, 212u8, 126u8, 63u8, + 63u8, 19u8, 75u8, 137u8, 125u8, 38u8, 250u8, 77u8, 49u8, 76u8, 188u8, ], ) } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_pool_members( + #[doc = " Number of child bounties per parent bounty."] + #[doc = " Map of parent bounty index to number of child bounties."] + pub fn parent_child_bounties_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "CounterForPoolMembers", - vec![], - [ - 114u8, 126u8, 27u8, 138u8, 119u8, 44u8, 45u8, 129u8, 84u8, 107u8, - 171u8, 206u8, 117u8, 141u8, 20u8, 75u8, 229u8, 237u8, 31u8, 229u8, - 124u8, 190u8, 27u8, 124u8, 63u8, 59u8, 167u8, 42u8, 62u8, 212u8, 160u8, - 2u8, - ], - ) - } - #[doc = " Storage for bonded pools."] - pub fn bonded_pools( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::BondedPoolInner, ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "BondedPools", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 34u8, 51u8, 86u8, 95u8, 237u8, 118u8, 40u8, 212u8, 128u8, 227u8, 113u8, - 6u8, 116u8, 28u8, 96u8, 223u8, 63u8, 249u8, 33u8, 152u8, 61u8, 7u8, - 205u8, 220u8, 221u8, 174u8, 207u8, 39u8, 53u8, 176u8, 13u8, 74u8, - ], - ) - } - #[doc = " Storage for bonded pools."] - pub fn bonded_pools_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::BondedPoolInner, - (), - (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "BondedPools", + "ChildBounties", + "ParentChildBounties", Vec::new(), [ - 34u8, 51u8, 86u8, 95u8, 237u8, 118u8, 40u8, 212u8, 128u8, 227u8, 113u8, - 6u8, 116u8, 28u8, 96u8, 223u8, 63u8, 249u8, 33u8, 152u8, 61u8, 7u8, - 205u8, 220u8, 221u8, 174u8, 207u8, 39u8, 53u8, 176u8, 13u8, 74u8, - ], - ) - } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_bonded_pools( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "CounterForBondedPools", - vec![], - [ - 134u8, 94u8, 199u8, 73u8, 174u8, 253u8, 66u8, 242u8, 233u8, 244u8, - 140u8, 170u8, 242u8, 40u8, 41u8, 185u8, 183u8, 151u8, 58u8, 111u8, - 221u8, 225u8, 81u8, 71u8, 169u8, 219u8, 223u8, 135u8, 8u8, 171u8, - 180u8, 236u8, + 127u8, 161u8, 181u8, 79u8, 235u8, 196u8, 252u8, 162u8, 39u8, 15u8, + 251u8, 49u8, 125u8, 80u8, 101u8, 24u8, 234u8, 88u8, 212u8, 126u8, 63u8, + 63u8, 19u8, 75u8, 137u8, 125u8, 38u8, 250u8, 77u8, 49u8, 76u8, 188u8, ], ) } - #[doc = " Reward pools. This is where there rewards for each pool accumulate. When a members payout"] - #[doc = " is claimed, the balance comes out fo the reward pool. Keyed by the bonded pools account."] - pub fn reward_pools( + #[doc = " Child bounties that have been added."] + pub fn child_bounties( &self, _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::RewardPool, + runtime_types::pallet_child_bounties::ChildBounty< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + >, ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "RewardPools", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "ChildBounties", + "ChildBounties", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], [ - 139u8, 123u8, 46u8, 107u8, 9u8, 83u8, 141u8, 12u8, 188u8, 225u8, 170u8, - 215u8, 154u8, 21u8, 100u8, 95u8, 237u8, 245u8, 46u8, 216u8, 199u8, - 184u8, 187u8, 155u8, 8u8, 16u8, 34u8, 177u8, 153u8, 65u8, 109u8, 198u8, + 66u8, 132u8, 251u8, 223u8, 216u8, 52u8, 162u8, 150u8, 229u8, 239u8, + 219u8, 182u8, 211u8, 228u8, 181u8, 46u8, 243u8, 151u8, 111u8, 235u8, + 105u8, 40u8, 39u8, 10u8, 245u8, 113u8, 78u8, 116u8, 219u8, 186u8, + 165u8, 91u8, ], ) } - #[doc = " Reward pools. This is where there rewards for each pool accumulate. When a members payout"] - #[doc = " is claimed, the balance comes out fo the reward pool. Keyed by the bonded pools account."] - pub fn reward_pools_root( + #[doc = " Child bounties that have been added."] + pub fn child_bounties_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::RewardPool, + runtime_types::pallet_child_bounties::ChildBounty< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + >, (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "RewardPools", + "ChildBounties", + "ChildBounties", Vec::new(), [ - 139u8, 123u8, 46u8, 107u8, 9u8, 83u8, 141u8, 12u8, 188u8, 225u8, 170u8, - 215u8, 154u8, 21u8, 100u8, 95u8, 237u8, 245u8, 46u8, 216u8, 199u8, - 184u8, 187u8, 155u8, 8u8, 16u8, 34u8, 177u8, 153u8, 65u8, 109u8, 198u8, - ], - ) - } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_reward_pools( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "CounterForRewardPools", - vec![], - [ - 209u8, 139u8, 212u8, 116u8, 210u8, 178u8, 213u8, 38u8, 75u8, 23u8, - 188u8, 57u8, 253u8, 213u8, 95u8, 118u8, 182u8, 250u8, 45u8, 205u8, - 17u8, 175u8, 17u8, 201u8, 234u8, 14u8, 98u8, 49u8, 143u8, 135u8, 201u8, - 81u8, + 66u8, 132u8, 251u8, 223u8, 216u8, 52u8, 162u8, 150u8, 229u8, 239u8, + 219u8, 182u8, 211u8, 228u8, 181u8, 46u8, 243u8, 151u8, 111u8, 235u8, + 105u8, 40u8, 39u8, 10u8, 245u8, 113u8, 78u8, 116u8, 219u8, 186u8, + 165u8, 91u8, ], ) } - #[doc = " Groups of unbonding pools. Each group of unbonding pools belongs to a bonded pool,"] - #[doc = " hence the name sub-pools. Keyed by the bonded pools account."] - pub fn sub_pools_storage( + #[doc = " The description of each child-bounty."] + pub fn child_bounty_descriptions( &self, _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::SubPools, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "SubPoolsStorage", + "ChildBounties", + "ChildBountyDescriptions", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 231u8, 13u8, 111u8, 248u8, 1u8, 208u8, 179u8, 134u8, 224u8, 196u8, - 94u8, 201u8, 229u8, 29u8, 155u8, 211u8, 163u8, 150u8, 157u8, 34u8, - 68u8, 238u8, 55u8, 4u8, 222u8, 96u8, 186u8, 29u8, 205u8, 237u8, 80u8, - 42u8, + 193u8, 200u8, 40u8, 30u8, 14u8, 71u8, 90u8, 42u8, 58u8, 253u8, 225u8, + 158u8, 172u8, 10u8, 45u8, 238u8, 36u8, 144u8, 184u8, 153u8, 11u8, + 157u8, 125u8, 220u8, 175u8, 31u8, 28u8, 93u8, 207u8, 212u8, 141u8, + 74u8, ], ) } - #[doc = " Groups of unbonding pools. Each group of unbonding pools belongs to a bonded pool,"] - #[doc = " hence the name sub-pools. Keyed by the bonded pools account."] - pub fn sub_pools_storage_root( + #[doc = " The description of each child-bounty."] + pub fn child_bounty_descriptions_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::SubPools, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "SubPoolsStorage", + "ChildBounties", + "ChildBountyDescriptions", Vec::new(), [ - 231u8, 13u8, 111u8, 248u8, 1u8, 208u8, 179u8, 134u8, 224u8, 196u8, - 94u8, 201u8, 229u8, 29u8, 155u8, 211u8, 163u8, 150u8, 157u8, 34u8, - 68u8, 238u8, 55u8, 4u8, 222u8, 96u8, 186u8, 29u8, 205u8, 237u8, 80u8, - 42u8, - ], - ) - } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_sub_pools_storage( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "CounterForSubPoolsStorage", - vec![], - [ - 212u8, 145u8, 212u8, 226u8, 234u8, 31u8, 26u8, 240u8, 107u8, 91u8, - 171u8, 120u8, 41u8, 195u8, 16u8, 86u8, 55u8, 127u8, 103u8, 93u8, 128u8, - 48u8, 69u8, 104u8, 168u8, 236u8, 81u8, 54u8, 2u8, 184u8, 215u8, 51u8, + 193u8, 200u8, 40u8, 30u8, 14u8, 71u8, 90u8, 42u8, 58u8, 253u8, 225u8, + 158u8, 172u8, 10u8, 45u8, 238u8, 36u8, 144u8, 184u8, 153u8, 11u8, + 157u8, 125u8, 220u8, 175u8, 31u8, 28u8, 93u8, 207u8, 212u8, 141u8, + 74u8, ], ) } - #[doc = " Metadata for the pool."] - pub fn metadata( + #[doc = " The cumulative child-bounty curator fee for each parent bounty."] + pub fn children_curator_fees( &self, _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec<::core::primitive::u8>, + ::core::primitive::u128, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "Metadata", + "ChildBounties", + "ChildrenCuratorFees", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 108u8, 250u8, 163u8, 54u8, 192u8, 143u8, 239u8, 62u8, 97u8, 163u8, - 161u8, 215u8, 171u8, 225u8, 49u8, 18u8, 37u8, 200u8, 143u8, 254u8, - 136u8, 26u8, 54u8, 187u8, 39u8, 3u8, 216u8, 24u8, 188u8, 25u8, 243u8, - 251u8, + 174u8, 128u8, 86u8, 179u8, 133u8, 76u8, 98u8, 169u8, 234u8, 166u8, + 249u8, 214u8, 172u8, 171u8, 8u8, 161u8, 105u8, 69u8, 148u8, 151u8, + 35u8, 174u8, 118u8, 139u8, 101u8, 56u8, 85u8, 211u8, 121u8, 168u8, 0u8, + 216u8, ], ) } - #[doc = " Metadata for the pool."] - pub fn metadata_root( + #[doc = " The cumulative child-bounty curator fee for each parent bounty."] + pub fn children_curator_fees_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec<::core::primitive::u8>, + ::core::primitive::u128, (), ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "Metadata", + "ChildBounties", + "ChildrenCuratorFees", Vec::new(), [ - 108u8, 250u8, 163u8, 54u8, 192u8, 143u8, 239u8, 62u8, 97u8, 163u8, - 161u8, 215u8, 171u8, 225u8, 49u8, 18u8, 37u8, 200u8, 143u8, 254u8, - 136u8, 26u8, 54u8, 187u8, 39u8, 3u8, 216u8, 24u8, 188u8, 25u8, 243u8, - 251u8, + 174u8, 128u8, 86u8, 179u8, 133u8, 76u8, 98u8, 169u8, 234u8, 166u8, + 249u8, 214u8, 172u8, 171u8, 8u8, 161u8, 105u8, 69u8, 148u8, 151u8, + 35u8, 174u8, 118u8, 139u8, 101u8, 56u8, 85u8, 211u8, 121u8, 168u8, 0u8, + 216u8, ], ) } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_metadata( + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " Maximum number of child bounties that can be added to a parent bounty."] + pub fn max_active_child_bounty_count( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "CounterForMetadata", - vec![], + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ChildBounties", + "MaxActiveChildBountyCount", [ - 190u8, 232u8, 77u8, 134u8, 245u8, 89u8, 160u8, 187u8, 163u8, 68u8, - 188u8, 204u8, 31u8, 145u8, 219u8, 165u8, 213u8, 1u8, 167u8, 90u8, - 175u8, 218u8, 147u8, 144u8, 158u8, 226u8, 23u8, 233u8, 55u8, 168u8, - 161u8, 237u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = " Ever increasing number of all pools created so far."] - pub fn last_pool_id( + #[doc = " Minimum value for a child-bounty."] + pub fn child_bounty_value_minimum( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "LastPoolId", - vec![], + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "ChildBounties", + "ChildBountyValueMinimum", [ - 50u8, 254u8, 218u8, 41u8, 213u8, 184u8, 170u8, 166u8, 31u8, 29u8, - 196u8, 57u8, 215u8, 20u8, 40u8, 40u8, 19u8, 22u8, 9u8, 184u8, 11u8, - 21u8, 21u8, 125u8, 97u8, 38u8, 219u8, 209u8, 2u8, 238u8, 247u8, 51u8, - ], - ) - } - #[doc = " A reverse lookup from the pool's account id to its id."] - #[doc = ""] - #[doc = " This is only used for slashing. In all other instances, the pool id is used, and the"] - #[doc = " accounts are deterministically derived from it."] - pub fn reverse_pool_id_lookup( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "ReversePoolIdLookup", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 178u8, 161u8, 51u8, 220u8, 128u8, 1u8, 135u8, 83u8, 236u8, 159u8, 36u8, - 237u8, 120u8, 128u8, 6u8, 191u8, 41u8, 159u8, 94u8, 178u8, 174u8, - 235u8, 221u8, 173u8, 44u8, 81u8, 211u8, 255u8, 231u8, 81u8, 16u8, 87u8, - ], - ) - } - #[doc = " A reverse lookup from the pool's account id to its id."] - #[doc = ""] - #[doc = " This is only used for slashing. In all other instances, the pool id is used, and the"] - #[doc = " accounts are deterministically derived from it."] - pub fn reverse_pool_id_lookup_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "ReversePoolIdLookup", - Vec::new(), - [ - 178u8, 161u8, 51u8, 220u8, 128u8, 1u8, 135u8, 83u8, 236u8, 159u8, 36u8, - 237u8, 120u8, 128u8, 6u8, 191u8, 41u8, 159u8, 94u8, 178u8, 174u8, - 235u8, 221u8, 173u8, 44u8, 81u8, 211u8, 255u8, 231u8, 81u8, 16u8, 87u8, - ], - ) - } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_reverse_pool_id_lookup( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "CounterForReversePoolIdLookup", - vec![], - [ - 148u8, 83u8, 81u8, 33u8, 188u8, 72u8, 148u8, 208u8, 245u8, 178u8, 52u8, - 245u8, 229u8, 140u8, 100u8, 152u8, 8u8, 217u8, 161u8, 80u8, 226u8, - 42u8, 15u8, 252u8, 90u8, 197u8, 120u8, 114u8, 144u8, 90u8, 199u8, - 123u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The nomination pool's pallet id."] - pub fn pallet_id( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "NominationPools", - "PalletId", - [ - 139u8, 109u8, 228u8, 151u8, 252u8, 32u8, 130u8, 69u8, 112u8, 154u8, - 174u8, 45u8, 83u8, 245u8, 51u8, 132u8, 173u8, 5u8, 186u8, 24u8, 243u8, - 9u8, 12u8, 214u8, 80u8, 74u8, 69u8, 189u8, 30u8, 94u8, 22u8, 39u8, - ], - ) - } - #[doc = " The maximum pool points-to-balance ratio that an `open` pool can have."] - #[doc = ""] - #[doc = " This is important in the event slashing takes place and the pool's points-to-balance"] - #[doc = " ratio becomes disproportional."] - #[doc = ""] - #[doc = " Moreover, this relates to the `RewardCounter` type as well, as the arithmetic operations"] - #[doc = " are a function of number of points, and by setting this value to e.g. 10, you ensure"] - #[doc = " that the total number of points in the system are at most 10 times the total_issuance of"] - #[doc = " the chain, in the absolute worse case."] - #[doc = ""] - #[doc = " For a value of 10, the threshold would be a pool points-to-balance ratio of 10:1."] - #[doc = " Such a scenario would also be the equivalent of the pool being 90% slashed."] - pub fn max_points_to_balance( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u8> { - ::subxt::constants::Address::new_static( - "NominationPools", - "MaxPointsToBalance", - [ - 141u8, 130u8, 11u8, 35u8, 226u8, 114u8, 92u8, 179u8, 168u8, 110u8, - 28u8, 91u8, 221u8, 64u8, 4u8, 148u8, 201u8, 193u8, 185u8, 66u8, 226u8, - 114u8, 97u8, 79u8, 62u8, 212u8, 202u8, 114u8, 237u8, 228u8, 183u8, - 165u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } } } } - pub mod fast_unstake { + pub mod tips { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_fast_unstake::pallet::Error; + pub type Error = runtime_types::pallet_tips::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -23248,7 +21976,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RegisterFastUnstake; + pub struct ReportAwesome { + pub reason: ::std::vec::Vec<::core::primitive::u8>, + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -23259,9 +21990,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Deregister; + pub struct RetractTip { + pub hash: ::subxt::utils::H256, + } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -23271,86 +22003,254 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Control { - pub unchecked_eras_to_check: ::core::primitive::u32, + pub struct TipNew { + pub reason: ::std::vec::Vec<::core::primitive::u8>, + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub tip_value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Tip { + pub hash: ::subxt::utils::H256, + #[codec(compact)] + pub tip_value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CloseTip { + pub hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SlashTip { + pub hash: ::subxt::utils::H256, } pub struct TransactionApi; impl TransactionApi { - #[doc = "Register oneself for fast-unstake."] + #[doc = "Report something `reason` that deserves a tip and claim any eventual the finder's fee."] #[doc = ""] - #[doc = "The dispatch origin of this call must be signed by the controller account, similar to"] - #[doc = "`staking::unbond`."] + #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] - #[doc = "The stash associated with the origin must have no ongoing unlocking chunks. If"] - #[doc = "successful, this will fully unbond and chill the stash. Then, it will enqueue the stash"] - #[doc = "to be checked in further blocks."] + #[doc = "Payment: `TipReportDepositBase` will be reserved from the origin account, as well as"] + #[doc = "`DataDepositPerByte` for each byte in `reason`."] #[doc = ""] - #[doc = "If by the time this is called, the stash is actually eligible for fast-unstake, then"] - #[doc = "they are guaranteed to remain eligible, because the call will chill them as well."] + #[doc = "- `reason`: The reason for, or the thing that deserves, the tip; generally this will be"] + #[doc = " a UTF-8-encoded URL."] + #[doc = "- `who`: The account which should be credited for the tip."] #[doc = ""] - #[doc = "If the check works, the entire staking data is removed, i.e. the stash is fully"] - #[doc = "unstaked."] + #[doc = "Emits `NewTip` if successful."] #[doc = ""] - #[doc = "If the check fails, the stash remains chilled and waiting for being unbonded as in with"] - #[doc = "the normal staking system, but they lose part of their unbonding chunks due to consuming"] - #[doc = "the chain's resources."] - pub fn register_fast_unstake(&self) -> ::subxt::tx::Payload { + #[doc = "## Complexity"] + #[doc = "- `O(R)` where `R` length of `reason`."] + #[doc = " - encoding and hashing of 'reason'"] + pub fn report_awesome( + &self, + reason: ::std::vec::Vec<::core::primitive::u8>, + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "FastUnstake", - "register_fast_unstake", - RegisterFastUnstake {}, + "Tips", + "report_awesome", + ReportAwesome { reason, who }, [ - 254u8, 85u8, 128u8, 135u8, 172u8, 170u8, 34u8, 145u8, 79u8, 117u8, - 234u8, 90u8, 16u8, 174u8, 159u8, 197u8, 27u8, 239u8, 180u8, 85u8, - 116u8, 23u8, 254u8, 30u8, 197u8, 110u8, 48u8, 184u8, 177u8, 129u8, - 42u8, 122u8, + 126u8, 68u8, 2u8, 54u8, 195u8, 15u8, 43u8, 27u8, 183u8, 254u8, 157u8, + 163u8, 252u8, 14u8, 207u8, 251u8, 215u8, 111u8, 98u8, 209u8, 150u8, + 11u8, 240u8, 177u8, 106u8, 93u8, 191u8, 31u8, 62u8, 11u8, 223u8, 79u8, ], ) } - #[doc = "Deregister oneself from the fast-unstake."] + #[doc = "Retract a prior tip-report from `report_awesome`, and cancel the process of tipping."] #[doc = ""] - #[doc = "This is useful if one is registered, they are still waiting, and they change their mind."] + #[doc = "If successful, the original deposit will be unreserved."] #[doc = ""] - #[doc = "Note that the associated stash is still fully unbonded and chilled as a consequence of"] - #[doc = "calling `register_fast_unstake`. This should probably be followed by a call to"] - #[doc = "`Staking::rebond`."] - pub fn deregister(&self) -> ::subxt::tx::Payload { + #[doc = "The dispatch origin for this call must be _Signed_ and the tip identified by `hash`"] + #[doc = "must have been reported by the signing account through `report_awesome` (and not"] + #[doc = "through `tip_new`)."] + #[doc = ""] + #[doc = "- `hash`: The identity of the open tip for which a tip value is declared. This is formed"] + #[doc = " as the hash of the tuple of the original tip `reason` and the beneficiary account ID."] + #[doc = ""] + #[doc = "Emits `TipRetracted` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(1)`"] + #[doc = " - Depends on the length of `T::Hash` which is fixed."] + pub fn retract_tip( + &self, + hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "FastUnstake", - "deregister", - Deregister {}, + "Tips", + "retract_tip", + RetractTip { hash }, [ - 198u8, 180u8, 253u8, 148u8, 124u8, 145u8, 175u8, 121u8, 42u8, 181u8, - 41u8, 155u8, 229u8, 181u8, 66u8, 140u8, 103u8, 86u8, 242u8, 155u8, - 192u8, 34u8, 157u8, 107u8, 211u8, 162u8, 1u8, 144u8, 35u8, 252u8, 88u8, - 21u8, + 137u8, 42u8, 229u8, 188u8, 157u8, 195u8, 184u8, 176u8, 64u8, 142u8, + 67u8, 175u8, 185u8, 207u8, 214u8, 71u8, 165u8, 29u8, 137u8, 227u8, + 132u8, 195u8, 255u8, 66u8, 186u8, 57u8, 34u8, 184u8, 187u8, 65u8, + 129u8, 131u8, ], ) } - #[doc = "Control the operation of this pallet."] + #[doc = "Give a tip for something new; no finder's fee will be taken."] #[doc = ""] - #[doc = "Dispatch origin must be signed by the [`Config::ControlOrigin`]."] - pub fn control( + #[doc = "The dispatch origin for this call must be _Signed_ and the signing account must be a"] + #[doc = "member of the `Tippers` set."] + #[doc = ""] + #[doc = "- `reason`: The reason for, or the thing that deserves, the tip; generally this will be"] + #[doc = " a UTF-8-encoded URL."] + #[doc = "- `who`: The account which should be credited for the tip."] + #[doc = "- `tip_value`: The amount of tip that the sender would like to give. The median tip"] + #[doc = " value of active tippers will be given to the `who`."] + #[doc = ""] + #[doc = "Emits `NewTip` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(R + T)` where `R` length of `reason`, `T` is the number of tippers."] + #[doc = " - `O(T)`: decoding `Tipper` vec of length `T`. `T` is charged as upper bound given by"] + #[doc = " `ContainsLengthBound`. The actual cost depends on the implementation of"] + #[doc = " `T::Tippers`."] + #[doc = " - `O(R)`: hashing and encoding of reason of length `R`"] + pub fn tip_new( &self, - unchecked_eras_to_check: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + reason: ::std::vec::Vec<::core::primitive::u8>, + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + tip_value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "FastUnstake", - "control", - Control { - unchecked_eras_to_check, + "Tips", + "tip_new", + TipNew { + reason, + who, + tip_value, }, [ - 134u8, 85u8, 43u8, 231u8, 209u8, 34u8, 248u8, 0u8, 238u8, 73u8, 175u8, - 105u8, 40u8, 128u8, 186u8, 40u8, 211u8, 106u8, 107u8, 206u8, 124u8, - 155u8, 220u8, 125u8, 143u8, 10u8, 162u8, 20u8, 99u8, 142u8, 243u8, 5u8, + 217u8, 15u8, 70u8, 80u8, 193u8, 110u8, 212u8, 110u8, 212u8, 45u8, + 197u8, 150u8, 43u8, 116u8, 115u8, 231u8, 148u8, 102u8, 202u8, 28u8, + 55u8, 88u8, 166u8, 238u8, 11u8, 238u8, 229u8, 189u8, 89u8, 115u8, + 196u8, 95u8, + ], + ) + } + #[doc = "Declare a tip value for an already-open tip."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the signing account must be a"] + #[doc = "member of the `Tippers` set."] + #[doc = ""] + #[doc = "- `hash`: The identity of the open tip for which a tip value is declared. This is formed"] + #[doc = " as the hash of the tuple of the hash of the original tip `reason` and the beneficiary"] + #[doc = " account ID."] + #[doc = "- `tip_value`: The amount of tip that the sender would like to give. The median tip"] + #[doc = " value of active tippers will be given to the `who`."] + #[doc = ""] + #[doc = "Emits `TipClosing` if the threshold of tippers has been reached and the countdown period"] + #[doc = "has started."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(T)` where `T` is the number of tippers. decoding `Tipper` vec of length `T`, insert"] + #[doc = " tip and check closing, `T` is charged as upper bound given by `ContainsLengthBound`."] + #[doc = " The actual cost depends on the implementation of `T::Tippers`."] + #[doc = ""] + #[doc = " Actually weight could be lower as it depends on how many tips are in `OpenTip` but it"] + #[doc = " is weighted as if almost full i.e of length `T-1`."] + pub fn tip( + &self, + hash: ::subxt::utils::H256, + tip_value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Tips", + "tip", + Tip { hash, tip_value }, + [ + 133u8, 52u8, 131u8, 14u8, 71u8, 232u8, 254u8, 31u8, 33u8, 206u8, 50u8, + 76u8, 56u8, 167u8, 228u8, 202u8, 195u8, 0u8, 164u8, 107u8, 170u8, 98u8, + 192u8, 37u8, 209u8, 199u8, 130u8, 15u8, 168u8, 63u8, 181u8, 134u8, + ], + ) + } + #[doc = "Close and payout a tip."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "The tip identified by `hash` must have finished its countdown period."] + #[doc = ""] + #[doc = "- `hash`: The identity of the open tip for which a tip value is declared. This is formed"] + #[doc = " as the hash of the tuple of the original tip `reason` and the beneficiary account ID."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- : `O(T)` where `T` is the number of tippers. decoding `Tipper` vec of length `T`. `T`"] + #[doc = " is charged as upper bound given by `ContainsLengthBound`. The actual cost depends on"] + #[doc = " the implementation of `T::Tippers`."] + pub fn close_tip( + &self, + hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Tips", + "close_tip", + CloseTip { hash }, + [ + 32u8, 53u8, 0u8, 222u8, 45u8, 157u8, 107u8, 174u8, 203u8, 50u8, 81u8, + 230u8, 6u8, 111u8, 79u8, 55u8, 49u8, 151u8, 107u8, 114u8, 81u8, 200u8, + 144u8, 175u8, 29u8, 142u8, 115u8, 184u8, 102u8, 116u8, 156u8, 173u8, + ], + ) + } + #[doc = "Remove and slash an already-open tip."] + #[doc = ""] + #[doc = "May only be called from `T::RejectOrigin`."] + #[doc = ""] + #[doc = "As a result, the finder is slashed and the deposits are lost."] + #[doc = ""] + #[doc = "Emits `TipSlashed` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn slash_tip( + &self, + hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Tips", + "slash_tip", + SlashTip { hash }, + [ + 222u8, 209u8, 22u8, 47u8, 114u8, 230u8, 81u8, 200u8, 131u8, 0u8, 209u8, + 54u8, 17u8, 200u8, 175u8, 125u8, 100u8, 254u8, 41u8, 178u8, 20u8, 27u8, + 9u8, 184u8, 79u8, 93u8, 208u8, 148u8, 27u8, 190u8, 176u8, 169u8, ], ) } } } - #[doc = "The events of this pallet."] - pub type Event = runtime_types::pallet_fast_unstake::pallet::Event; + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_tips::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -23363,14 +22263,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A staker was unstaked."] - pub struct Unstaked { - pub stash: ::subxt::utils::AccountId32, - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + #[doc = "A new tip suggestion has been opened."] + pub struct NewTip { + pub tip_hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for Unstaked { - const PALLET: &'static str = "FastUnstake"; - const EVENT: &'static str = "Unstaked"; + impl ::subxt::events::StaticEvent for NewTip { + const PALLET: &'static str = "Tips"; + const EVENT: &'static str = "NewTip"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -23382,14 +22281,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A staker was slashed for requesting fast-unstake whilst being exposed."] - pub struct Slashed { - pub stash: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, + #[doc = "A tip suggestion has reached threshold and is closing."] + pub struct TipClosing { + pub tip_hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for Slashed { - const PALLET: &'static str = "FastUnstake"; - const EVENT: &'static str = "Slashed"; + impl ::subxt::events::StaticEvent for TipClosing { + const PALLET: &'static str = "Tips"; + const EVENT: &'static str = "TipClosing"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -23401,30 +22299,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some internal error happened while migrating stash. They are removed as head as a"] - #[doc = "consequence."] - pub struct Errored { - pub stash: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Errored { - const PALLET: &'static str = "FastUnstake"; - const EVENT: &'static str = "Errored"; + #[doc = "A tip suggestion has been closed."] + pub struct TipClosed { + pub tip_hash: ::subxt::utils::H256, + pub who: ::subxt::utils::AccountId32, + pub payout: ::core::primitive::u128, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An internal error happened. Operations will be paused now."] - pub struct InternalError; - impl ::subxt::events::StaticEvent for InternalError { - const PALLET: &'static str = "FastUnstake"; - const EVENT: &'static str = "InternalError"; + impl ::subxt::events::StaticEvent for TipClosed { + const PALLET: &'static str = "Tips"; + const EVENT: &'static str = "TipClosed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -23436,13 +22319,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A batch was partially checked for the given eras, but the process did not finish."] - pub struct BatchChecked { - pub eras: ::std::vec::Vec<::core::primitive::u32>, + #[doc = "A tip suggestion has been retracted."] + pub struct TipRetracted { + pub tip_hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for BatchChecked { - const PALLET: &'static str = "FastUnstake"; - const EVENT: &'static str = "BatchChecked"; + impl ::subxt::events::StaticEvent for TipRetracted { + const PALLET: &'static str = "Tips"; + const EVENT: &'static str = "TipRetracted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -23454,184 +22337,221 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A batch was terminated."] - #[doc = ""] - #[doc = "This is always follows by a number of `Unstaked` or `Slashed` events, marking the end"] - #[doc = "of the batch. A new batch will be created upon next block."] - pub struct BatchFinished; - impl ::subxt::events::StaticEvent for BatchFinished { - const PALLET: &'static str = "FastUnstake"; - const EVENT: &'static str = "BatchFinished"; + #[doc = "A tip suggestion has been slashed."] + pub struct TipSlashed { + pub tip_hash: ::subxt::utils::H256, + pub finder: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for TipSlashed { + const PALLET: &'static str = "Tips"; + const EVENT: &'static str = "TipSlashed"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " The current \"head of the queue\" being unstaked."] - pub fn head( + #[doc = " TipsMap that are not yet completed. Keyed by the hash of `(reason, who)` from the value."] + #[doc = " This has the insecure enumerable hash function since the key itself is already"] + #[doc = " guaranteed to be a secure hash."] + pub fn tips( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_fast_unstake::types::UnstakeRequest, + runtime_types::pallet_tips::OpenTip< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + ::subxt::utils::H256, + >, ::subxt::storage::address::Yes, (), - (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "FastUnstake", - "Head", - vec![], + "Tips", + "Tips", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 206u8, 19u8, 169u8, 239u8, 214u8, 136u8, 16u8, 102u8, 82u8, 110u8, - 128u8, 205u8, 102u8, 96u8, 148u8, 190u8, 67u8, 75u8, 2u8, 213u8, 134u8, - 143u8, 40u8, 57u8, 54u8, 66u8, 170u8, 42u8, 135u8, 212u8, 108u8, 177u8, + 241u8, 196u8, 105u8, 248u8, 29u8, 66u8, 86u8, 98u8, 6u8, 159u8, 191u8, + 0u8, 227u8, 232u8, 147u8, 248u8, 173u8, 20u8, 225u8, 12u8, 232u8, 5u8, + 93u8, 78u8, 18u8, 154u8, 130u8, 38u8, 142u8, 36u8, 66u8, 0u8, ], ) } - #[doc = " The map of all accounts wishing to be unstaked."] - #[doc = ""] - #[doc = " Keeps track of `AccountId` wishing to unstake and it's corresponding deposit."] - pub fn queue( + #[doc = " TipsMap that are not yet completed. Keyed by the hash of `(reason, who)` from the value."] + #[doc = " This has the insecure enumerable hash function since the key itself is already"] + #[doc = " guaranteed to be a secure hash."] + pub fn tips_root( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, + runtime_types::pallet_tips::OpenTip< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + ::subxt::utils::H256, + >, + (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "FastUnstake", - "Queue", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Tips", + "Tips", + Vec::new(), [ - 250u8, 208u8, 88u8, 68u8, 8u8, 87u8, 27u8, 59u8, 120u8, 242u8, 79u8, - 54u8, 108u8, 15u8, 62u8, 143u8, 126u8, 66u8, 159u8, 159u8, 55u8, 212u8, - 190u8, 26u8, 171u8, 90u8, 156u8, 205u8, 173u8, 189u8, 230u8, 71u8, + 241u8, 196u8, 105u8, 248u8, 29u8, 66u8, 86u8, 98u8, 6u8, 159u8, 191u8, + 0u8, 227u8, 232u8, 147u8, 248u8, 173u8, 20u8, 225u8, 12u8, 232u8, 5u8, + 93u8, 78u8, 18u8, 154u8, 130u8, 38u8, 142u8, 36u8, 66u8, 0u8, ], ) } - #[doc = " The map of all accounts wishing to be unstaked."] - #[doc = ""] - #[doc = " Keeps track of `AccountId` wishing to unstake and it's corresponding deposit."] - pub fn queue_root( + #[doc = " Simple preimage lookup from the reason's hash to the original data. Again, has an"] + #[doc = " insecure enumerable hash since the key is guaranteed to be the result of a secure hash."] + pub fn reasons( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - (), + ::std::vec::Vec<::core::primitive::u8>, + ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "FastUnstake", - "Queue", - Vec::new(), + "Tips", + "Reasons", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 250u8, 208u8, 88u8, 68u8, 8u8, 87u8, 27u8, 59u8, 120u8, 242u8, 79u8, - 54u8, 108u8, 15u8, 62u8, 143u8, 126u8, 66u8, 159u8, 159u8, 55u8, 212u8, - 190u8, 26u8, 171u8, 90u8, 156u8, 205u8, 173u8, 189u8, 230u8, 71u8, + 202u8, 191u8, 36u8, 162u8, 156u8, 102u8, 115u8, 10u8, 203u8, 35u8, + 201u8, 70u8, 195u8, 151u8, 89u8, 82u8, 202u8, 35u8, 210u8, 176u8, 82u8, + 1u8, 77u8, 94u8, 31u8, 70u8, 252u8, 194u8, 166u8, 91u8, 189u8, 134u8, ], ) } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_queue( + #[doc = " Simple preimage lookup from the reason's hash to the original data. Again, has an"] + #[doc = " insecure enumerable hash since the key is guaranteed to be the result of a secure hash."] + pub fn reasons_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + ::std::vec::Vec<::core::primitive::u8>, + (), (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "FastUnstake", - "CounterForQueue", - vec![], + "Tips", + "Reasons", + Vec::new(), [ - 241u8, 174u8, 224u8, 214u8, 204u8, 37u8, 117u8, 62u8, 114u8, 63u8, - 123u8, 121u8, 201u8, 128u8, 26u8, 60u8, 170u8, 24u8, 112u8, 5u8, 248u8, - 7u8, 143u8, 17u8, 150u8, 91u8, 23u8, 90u8, 237u8, 4u8, 138u8, 210u8, + 202u8, 191u8, 36u8, 162u8, 156u8, 102u8, 115u8, 10u8, 203u8, 35u8, + 201u8, 70u8, 195u8, 151u8, 89u8, 82u8, 202u8, 35u8, 210u8, 176u8, 82u8, + 1u8, 77u8, 94u8, 31u8, 70u8, 252u8, 194u8, 166u8, 91u8, 189u8, 134u8, ], ) } - #[doc = " Number of eras to check per block."] - #[doc = ""] - #[doc = " If set to 0, this pallet does absolutely nothing."] + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " Maximum acceptable reason length."] #[doc = ""] - #[doc = " Based on the amount of weight available at `on_idle`, up to this many eras of a single"] - #[doc = " nominator might be checked."] - pub fn eras_to_check_per_block( + #[doc = " Benchmarks depend on this value, be sure to update weights file when changing this value"] + pub fn maximum_reason_length( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "FastUnstake", - "ErasToCheckPerBlock", - vec![], + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Tips", + "MaximumReasonLength", [ - 85u8, 55u8, 18u8, 11u8, 75u8, 176u8, 36u8, 253u8, 183u8, 250u8, 203u8, - 178u8, 201u8, 79u8, 101u8, 89u8, 51u8, 142u8, 254u8, 23u8, 49u8, 140u8, - 195u8, 116u8, 66u8, 124u8, 165u8, 161u8, 151u8, 174u8, 37u8, 51u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The amount held on deposit per byte within the tip report reason or bounty description."] + pub fn data_deposit_per_byte( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Tips", + "DataDepositPerByte", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The period for which a tip remains open after is has achieved threshold tippers."] + pub fn tip_countdown(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Tips", + "TipCountdown", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The percent of the final tip which goes to the original reporter of the tip."] + pub fn tip_finders_fee( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "Tips", + "TipFindersFee", + [ + 99u8, 121u8, 176u8, 172u8, 235u8, 159u8, 116u8, 114u8, 179u8, 91u8, + 129u8, 117u8, 204u8, 135u8, 53u8, 7u8, 151u8, 26u8, 124u8, 151u8, + 202u8, 171u8, 171u8, 207u8, 183u8, 177u8, 24u8, 53u8, 109u8, 185u8, + 71u8, 183u8, + ], + ) + } + #[doc = " The amount held on deposit for placing a tip report."] + pub fn tip_report_deposit_base( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Tips", + "TipReportDepositBase", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } } } } - pub mod parachains_origin { - use super::root_mod; - use super::runtime_types; - } - pub mod configuration { + pub mod election_provider_multi_phase { use super::root_mod; use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_parachains::configuration::pallet::Error; + #[doc = "Error of the pallet that can be returned in response to dispatches."] + pub type Error = runtime_types::pallet_election_provider_multi_phase::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetValidationUpgradeCooldown { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetValidationUpgradeDelay { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -23641,11 +22561,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCodeRetentionPeriod { - pub new: ::core::primitive::u32, + pub struct SubmitUnsigned { + pub raw_solution: ::std::boxed::Box< + runtime_types::pallet_election_provider_multi_phase::RawSolution< + runtime_types::polkadot_runtime::NposCompactSolution16, + >, + >, + pub witness: + runtime_types::pallet_election_provider_multi_phase::SolutionOrSnapshotSize, } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -23655,11 +22580,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxCodeSize { - pub new: ::core::primitive::u32, + pub struct SetMinimumUntrustedScore { + pub maybe_next_score: + ::core::option::Option, } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -23669,11 +22594,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxPovSize { - pub new: ::core::primitive::u32, + pub struct SetEmergencyElectionResult { + pub supports: ::std::vec::Vec<( + ::subxt::utils::AccountId32, + runtime_types::sp_npos_elections::Support<::subxt::utils::AccountId32>, + )>, } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -23683,11 +22610,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxHeadDataSize { - pub new: ::core::primitive::u32, + pub struct Submit { + pub raw_solution: ::std::boxed::Box< + runtime_types::pallet_election_provider_multi_phase::RawSolution< + runtime_types::polkadot_runtime::NposCompactSolution16, + >, + >, } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -23697,25 +22627,154 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetParathreadCores { - pub new: ::core::primitive::u32, + pub struct GovernanceFallback { + pub maybe_max_voters: ::core::option::Option<::core::primitive::u32>, + pub maybe_max_targets: ::core::option::Option<::core::primitive::u32>, } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetParathreadRetries { - pub new: ::core::primitive::u32, + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Submit a solution for the unsigned phase."] + #[doc = ""] + #[doc = "The dispatch origin fo this call must be __none__."] + #[doc = ""] + #[doc = "This submission is checked on the fly. Moreover, this unsigned solution is only"] + #[doc = "validated when submitted to the pool from the **local** node. Effectively, this means"] + #[doc = "that only active validators can submit this transaction when authoring a block (similar"] + #[doc = "to an inherent)."] + #[doc = ""] + #[doc = "To prevent any incorrect solution (and thus wasted time/weight), this transaction will"] + #[doc = "panic if the solution submitted by the validator is invalid in any way, effectively"] + #[doc = "putting their authoring reward at risk."] + #[doc = ""] + #[doc = "No deposit or reward is associated with this submission."] + pub fn submit_unsigned( + &self, + raw_solution: runtime_types::pallet_election_provider_multi_phase::RawSolution< + runtime_types::polkadot_runtime::NposCompactSolution16, + >, + witness : runtime_types :: pallet_election_provider_multi_phase :: SolutionOrSnapshotSize, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ElectionProviderMultiPhase", + "submit_unsigned", + SubmitUnsigned { + raw_solution: ::std::boxed::Box::new(raw_solution), + witness, + }, + [ + 100u8, 240u8, 31u8, 34u8, 93u8, 98u8, 93u8, 57u8, 41u8, 197u8, 97u8, + 58u8, 242u8, 10u8, 69u8, 250u8, 185u8, 169u8, 21u8, 8u8, 202u8, 61u8, + 36u8, 25u8, 4u8, 148u8, 82u8, 56u8, 242u8, 18u8, 27u8, 219u8, + ], + ) + } + #[doc = "Set a new value for `MinimumUntrustedScore`."] + #[doc = ""] + #[doc = "Dispatch origin must be aligned with `T::ForceOrigin`."] + #[doc = ""] + #[doc = "This check can be turned off by setting the value to `None`."] + pub fn set_minimum_untrusted_score( + &self, + maybe_next_score: ::core::option::Option< + runtime_types::sp_npos_elections::ElectionScore, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ElectionProviderMultiPhase", + "set_minimum_untrusted_score", + SetMinimumUntrustedScore { maybe_next_score }, + [ + 63u8, 101u8, 105u8, 146u8, 133u8, 162u8, 149u8, 112u8, 150u8, 219u8, + 183u8, 213u8, 234u8, 211u8, 144u8, 74u8, 106u8, 15u8, 62u8, 196u8, + 247u8, 49u8, 20u8, 48u8, 3u8, 105u8, 85u8, 46u8, 76u8, 4u8, 67u8, 81u8, + ], + ) + } + #[doc = "Set a solution in the queue, to be handed out to the client of this pallet in the next"] + #[doc = "call to `ElectionProvider::elect`."] + #[doc = ""] + #[doc = "This can only be set by `T::ForceOrigin`, and only when the phase is `Emergency`."] + #[doc = ""] + #[doc = "The solution is not checked for any feasibility and is assumed to be trustworthy, as any"] + #[doc = "feasibility check itself can in principle cause the election process to fail (due to"] + #[doc = "memory/weight constrains)."] + pub fn set_emergency_election_result( + &self, + supports: ::std::vec::Vec<( + ::subxt::utils::AccountId32, + runtime_types::sp_npos_elections::Support<::subxt::utils::AccountId32>, + )>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ElectionProviderMultiPhase", + "set_emergency_election_result", + SetEmergencyElectionResult { supports }, + [ + 115u8, 255u8, 205u8, 58u8, 153u8, 1u8, 246u8, 8u8, 225u8, 36u8, 66u8, + 144u8, 250u8, 145u8, 70u8, 76u8, 54u8, 63u8, 251u8, 51u8, 214u8, 204u8, + 55u8, 112u8, 46u8, 228u8, 255u8, 250u8, 151u8, 5u8, 44u8, 133u8, + ], + ) + } + #[doc = "Submit a solution for the signed phase."] + #[doc = ""] + #[doc = "The dispatch origin fo this call must be __signed__."] + #[doc = ""] + #[doc = "The solution is potentially queued, based on the claimed score and processed at the end"] + #[doc = "of the signed phase."] + #[doc = ""] + #[doc = "A deposit is reserved and recorded for the solution. Based on the outcome, the solution"] + #[doc = "might be rewarded, slashed, or get all or a part of the deposit back."] + pub fn submit( + &self, + raw_solution: runtime_types::pallet_election_provider_multi_phase::RawSolution< + runtime_types::polkadot_runtime::NposCompactSolution16, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ElectionProviderMultiPhase", + "submit", + Submit { + raw_solution: ::std::boxed::Box::new(raw_solution), + }, + [ + 220u8, 167u8, 40u8, 47u8, 253u8, 244u8, 72u8, 124u8, 30u8, 123u8, + 127u8, 227u8, 2u8, 66u8, 119u8, 64u8, 211u8, 200u8, 210u8, 98u8, 248u8, + 132u8, 68u8, 25u8, 34u8, 182u8, 230u8, 225u8, 241u8, 58u8, 193u8, + 134u8, + ], + ) + } + #[doc = "Trigger the governance fallback."] + #[doc = ""] + #[doc = "This can only be called when [`Phase::Emergency`] is enabled, as an alternative to"] + #[doc = "calling [`Call::set_emergency_election_result`]."] + pub fn governance_fallback( + &self, + maybe_max_voters: ::core::option::Option<::core::primitive::u32>, + maybe_max_targets: ::core::option::Option<::core::primitive::u32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ElectionProviderMultiPhase", + "governance_fallback", + GovernanceFallback { + maybe_max_voters, + maybe_max_targets, + }, + [ + 206u8, 247u8, 76u8, 85u8, 7u8, 24u8, 231u8, 226u8, 192u8, 143u8, 43u8, + 67u8, 91u8, 202u8, 88u8, 176u8, 130u8, 1u8, 83u8, 229u8, 227u8, 200u8, + 179u8, 4u8, 113u8, 60u8, 99u8, 190u8, 53u8, 226u8, 142u8, 182u8, + ], + ) + } } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_election_provider_multi_phase::pallet::Event; + pub mod events { + use super::runtime_types; #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -23725,25 +22784,23 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetGroupRotationFrequency { - pub new: ::core::primitive::u32, + #[doc = "A solution was stored with the given compute."] + #[doc = ""] + #[doc = "The `origin` indicates the origin of the solution. If `origin` is `Some(AccountId)`,"] + #[doc = "the stored solution was submited in the signed phase by a miner with the `AccountId`."] + #[doc = "Otherwise, the solution was stored either during the unsigned phase or by"] + #[doc = "`T::ForceOrigin`. The `bool` is `true` when a previous solution was ejected to make"] + #[doc = "room for this one."] + pub struct SolutionStored { + pub compute: runtime_types::pallet_election_provider_multi_phase::ElectionCompute, + pub origin: ::core::option::Option<::subxt::utils::AccountId32>, + pub prev_ejected: ::core::primitive::bool, } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetChainAvailabilityPeriod { - pub new: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for SolutionStored { + const PALLET: &'static str = "ElectionProviderMultiPhase"; + const EVENT: &'static str = "SolutionStored"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -23753,22 +22810,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetThreadAvailabilityPeriod { - pub new: ::core::primitive::u32, + #[doc = "The election has been finalized, with the given computation and score."] + pub struct ElectionFinalized { + pub compute: runtime_types::pallet_election_provider_multi_phase::ElectionCompute, + pub score: runtime_types::sp_npos_elections::ElectionScore, } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetSchedulingLookahead { - pub new: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for ElectionFinalized { + const PALLET: &'static str = "ElectionProviderMultiPhase"; + const EVENT: &'static str = "ElectionFinalized"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -23780,8 +22829,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxValidatorsPerCore { - pub new: ::core::option::Option<::core::primitive::u32>, + #[doc = "An election failed."] + #[doc = ""] + #[doc = "Not much can be said about which computes failed in the process."] + pub struct ElectionFailed; + impl ::subxt::events::StaticEvent for ElectionFailed { + const PALLET: &'static str = "ElectionProviderMultiPhase"; + const EVENT: &'static str = "ElectionFailed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -23793,25 +22847,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxValidators { - pub new: ::core::option::Option<::core::primitive::u32>, + #[doc = "An account has been rewarded for their signed submission being finalized."] + pub struct Rewarded { + pub account: ::subxt::utils::AccountId32, + pub value: ::core::primitive::u128, } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetDisputePeriod { - pub new: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for Rewarded { + const PALLET: &'static str = "ElectionProviderMultiPhase"; + const EVENT: &'static str = "Rewarded"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -23821,25 +22866,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetDisputePostConclusionAcceptancePeriod { - pub new: ::core::primitive::u32, + #[doc = "An account has been slashed for submitting an invalid signed submission."] + pub struct Slashed { + pub account: ::subxt::utils::AccountId32, + pub value: ::core::primitive::u128, } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetDisputeMaxSpamSlots { - pub new: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for Slashed { + const PALLET: &'static str = "ElectionProviderMultiPhase"; + const EVENT: &'static str = "Slashed"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -23849,1306 +22885,977 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetDisputeConclusionByTimeOutPeriod { - pub new: ::core::primitive::u32, + #[doc = "There was a phase transition in a given round."] + pub struct PhaseTransitioned { + pub from: runtime_types::pallet_election_provider_multi_phase::Phase< + ::core::primitive::u32, + >, + pub to: runtime_types::pallet_election_provider_multi_phase::Phase< + ::core::primitive::u32, + >, + pub round: ::core::primitive::u32, } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetNoShowSlots { - pub new: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for PhaseTransitioned { + const PALLET: &'static str = "ElectionProviderMultiPhase"; + const EVENT: &'static str = "PhaseTransitioned"; } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetNDelayTranches { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetZerothDelayTrancheWidth { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetNeededApprovals { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetRelayVrfModuloSamples { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxUpwardQueueCount { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxUpwardQueueSize { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxDownwardMessageSize { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetUmpServiceTotalWeight { - pub new: runtime_types::sp_weights::weight_v2::Weight, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxUpwardMessageSize { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxUpwardMessageNumPerCandidate { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpOpenRequestTtl { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpSenderDeposit { - pub new: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpRecipientDeposit { - pub new: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpChannelMaxCapacity { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpChannelMaxTotalSize { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpMaxParachainInboundChannels { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpMaxParathreadInboundChannels { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpChannelMaxMessageSize { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpMaxParachainOutboundChannels { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpMaxParathreadOutboundChannels { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpMaxMessageNumPerCandidate { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetUmpMaxIndividualWeight { - pub new: runtime_types::sp_weights::weight_v2::Weight, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetPvfCheckingEnabled { - pub new: ::core::primitive::bool, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetPvfVotingTtl { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMinimumValidationUpgradeDelay { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetBypassConsistencyCheck { - pub new: ::core::primitive::bool, - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Set the validation upgrade cooldown."] - pub fn set_validation_upgrade_cooldown( + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Internal counter for the number of rounds."] + #[doc = ""] + #[doc = " This is useful for de-duplication of transactions submitted to the pool, and general"] + #[doc = " diagnostics of the pallet."] + #[doc = ""] + #[doc = " This is merely incremented once per every time that an upstream `elect` is called."] + pub fn round( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_validation_upgrade_cooldown", - SetValidationUpgradeCooldown { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "Round", + vec![], [ - 109u8, 185u8, 0u8, 59u8, 177u8, 198u8, 76u8, 90u8, 108u8, 190u8, 56u8, - 126u8, 147u8, 110u8, 76u8, 111u8, 38u8, 200u8, 230u8, 144u8, 42u8, - 167u8, 175u8, 220u8, 102u8, 37u8, 60u8, 10u8, 118u8, 79u8, 146u8, - 203u8, + 16u8, 49u8, 176u8, 52u8, 202u8, 111u8, 120u8, 8u8, 217u8, 96u8, 35u8, + 14u8, 233u8, 130u8, 47u8, 98u8, 34u8, 44u8, 166u8, 188u8, 199u8, 210u8, + 21u8, 19u8, 70u8, 96u8, 139u8, 8u8, 53u8, 82u8, 165u8, 239u8, ], ) } - #[doc = "Set the validation upgrade delay."] - pub fn set_validation_upgrade_delay( + #[doc = " Current phase."] + pub fn current_phase( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_validation_upgrade_delay", - SetValidationUpgradeDelay { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_election_provider_multi_phase::Phase< + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "CurrentPhase", + vec![], [ - 18u8, 130u8, 158u8, 253u8, 160u8, 194u8, 220u8, 120u8, 9u8, 68u8, - 232u8, 176u8, 34u8, 81u8, 200u8, 236u8, 141u8, 139u8, 62u8, 110u8, - 76u8, 9u8, 218u8, 69u8, 55u8, 2u8, 233u8, 109u8, 83u8, 117u8, 141u8, - 253u8, + 236u8, 101u8, 8u8, 52u8, 68u8, 240u8, 74u8, 159u8, 181u8, 53u8, 153u8, + 101u8, 228u8, 81u8, 96u8, 161u8, 34u8, 67u8, 35u8, 28u8, 121u8, 44u8, + 229u8, 45u8, 196u8, 87u8, 73u8, 125u8, 216u8, 245u8, 255u8, 15u8, ], ) } - #[doc = "Set the acceptance period for an included candidate."] - pub fn set_code_retention_period( + #[doc = " Current best solution, signed or unsigned, queued to be returned upon `elect`."] + pub fn queued_solution( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_code_retention_period", - SetCodeRetentionPeriod { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_election_provider_multi_phase::ReadySolution, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "QueuedSolution", + vec![], [ - 221u8, 140u8, 253u8, 111u8, 64u8, 236u8, 93u8, 52u8, 214u8, 245u8, - 178u8, 30u8, 77u8, 166u8, 242u8, 252u8, 203u8, 106u8, 12u8, 195u8, - 27u8, 159u8, 96u8, 197u8, 145u8, 69u8, 241u8, 59u8, 74u8, 220u8, 62u8, - 205u8, + 11u8, 152u8, 13u8, 167u8, 204u8, 209u8, 171u8, 249u8, 59u8, 250u8, + 58u8, 152u8, 164u8, 121u8, 146u8, 112u8, 241u8, 16u8, 159u8, 251u8, + 209u8, 251u8, 114u8, 29u8, 188u8, 30u8, 84u8, 71u8, 136u8, 173u8, + 145u8, 236u8, ], ) } - #[doc = "Set the max validation code size for incoming upgrades."] - pub fn set_max_code_size( + #[doc = " Snapshot data of the round."] + #[doc = ""] + #[doc = " This is created at the beginning of the signed phase and cleared upon calling `elect`."] + pub fn snapshot( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_code_size", - SetMaxCodeSize { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_election_provider_multi_phase::RoundSnapshot< + ::subxt::utils::AccountId32, + ( + ::subxt::utils::AccountId32, + ::core::primitive::u64, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::AccountId32, + >, + ), + >, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "Snapshot", + vec![], [ - 232u8, 106u8, 45u8, 195u8, 27u8, 162u8, 188u8, 213u8, 137u8, 13u8, - 123u8, 89u8, 215u8, 141u8, 231u8, 82u8, 205u8, 215u8, 73u8, 142u8, - 115u8, 109u8, 132u8, 118u8, 194u8, 211u8, 82u8, 20u8, 75u8, 55u8, - 218u8, 46u8, + 239u8, 56u8, 191u8, 77u8, 150u8, 224u8, 248u8, 88u8, 132u8, 224u8, + 164u8, 83u8, 253u8, 36u8, 46u8, 156u8, 72u8, 152u8, 36u8, 206u8, 72u8, + 27u8, 226u8, 87u8, 146u8, 220u8, 93u8, 178u8, 26u8, 115u8, 232u8, 71u8, ], ) } - #[doc = "Set the max POV block size for incoming upgrades."] - pub fn set_max_pov_size( + #[doc = " Desired number of targets to elect for this round."] + #[doc = ""] + #[doc = " Only exists when [`Snapshot`] is present."] + pub fn desired_targets( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_pov_size", - SetMaxPovSize { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "DesiredTargets", + vec![], [ - 15u8, 176u8, 13u8, 19u8, 177u8, 160u8, 211u8, 238u8, 29u8, 194u8, - 187u8, 235u8, 244u8, 65u8, 158u8, 47u8, 102u8, 221u8, 95u8, 10u8, 21u8, - 33u8, 219u8, 234u8, 82u8, 122u8, 75u8, 53u8, 14u8, 126u8, 218u8, 23u8, + 16u8, 247u8, 4u8, 181u8, 93u8, 79u8, 12u8, 212u8, 146u8, 167u8, 80u8, + 58u8, 118u8, 52u8, 68u8, 87u8, 90u8, 140u8, 31u8, 210u8, 2u8, 116u8, + 220u8, 231u8, 115u8, 112u8, 118u8, 118u8, 68u8, 34u8, 151u8, 165u8, ], ) } - #[doc = "Set the max head data size for paras."] - pub fn set_max_head_data_size( + #[doc = " The metadata of the [`RoundSnapshot`]"] + #[doc = ""] + #[doc = " Only exists when [`Snapshot`] is present."] + pub fn snapshot_metadata( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_head_data_size", - SetMaxHeadDataSize { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_election_provider_multi_phase::SolutionOrSnapshotSize, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "SnapshotMetadata", + vec![], [ - 219u8, 128u8, 213u8, 65u8, 190u8, 224u8, 87u8, 80u8, 172u8, 112u8, - 160u8, 229u8, 52u8, 1u8, 189u8, 125u8, 177u8, 139u8, 103u8, 39u8, 21u8, - 125u8, 62u8, 177u8, 74u8, 25u8, 41u8, 11u8, 200u8, 79u8, 139u8, 171u8, + 135u8, 122u8, 60u8, 75u8, 194u8, 240u8, 187u8, 96u8, 240u8, 203u8, + 192u8, 22u8, 117u8, 148u8, 118u8, 24u8, 240u8, 213u8, 94u8, 22u8, + 194u8, 47u8, 181u8, 245u8, 77u8, 149u8, 11u8, 251u8, 117u8, 220u8, + 205u8, 78u8, ], ) } - #[doc = "Set the number of parathread execution cores."] - pub fn set_parathread_cores( + #[doc = " The next index to be assigned to an incoming signed submission."] + #[doc = ""] + #[doc = " Every accepted submission is assigned a unique index; that index is bound to that particular"] + #[doc = " submission for the duration of the election. On election finalization, the next index is"] + #[doc = " reset to 0."] + #[doc = ""] + #[doc = " We can't just use `SignedSubmissionIndices.len()`, because that's a bounded set; past its"] + #[doc = " capacity, it will simply saturate. We can't just iterate over `SignedSubmissionsMap`,"] + #[doc = " because iteration is slow. Instead, we store the value here."] + pub fn signed_submission_next_index( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_parathread_cores", - SetParathreadCores { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "SignedSubmissionNextIndex", + vec![], [ - 155u8, 102u8, 168u8, 202u8, 236u8, 87u8, 16u8, 128u8, 141u8, 99u8, - 154u8, 162u8, 216u8, 198u8, 236u8, 233u8, 104u8, 230u8, 137u8, 132u8, - 41u8, 106u8, 167u8, 81u8, 195u8, 172u8, 107u8, 28u8, 138u8, 254u8, - 180u8, 61u8, + 242u8, 11u8, 157u8, 105u8, 96u8, 7u8, 31u8, 20u8, 51u8, 141u8, 182u8, + 180u8, 13u8, 172u8, 155u8, 59u8, 42u8, 238u8, 115u8, 8u8, 6u8, 137u8, + 45u8, 2u8, 123u8, 187u8, 53u8, 215u8, 19u8, 129u8, 54u8, 22u8, ], ) } - #[doc = "Set the number of retries for a particular parathread."] - pub fn set_parathread_retries( + #[doc = " A sorted, bounded vector of `(score, block_number, index)`, where each `index` points to a"] + #[doc = " value in `SignedSubmissions`."] + #[doc = ""] + #[doc = " We never need to process more than a single signed submission at a time. Signed submissions"] + #[doc = " can be quite large, so we're willing to pay the cost of multiple database accesses to access"] + #[doc = " them one at a time instead of reading and decoding all of them at once."] + pub fn signed_submission_indices( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_parathread_retries", - SetParathreadRetries { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + runtime_types::sp_npos_elections::ElectionScore, + ::core::primitive::u32, + ::core::primitive::u32, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "SignedSubmissionIndices", + vec![], [ - 192u8, 81u8, 152u8, 41u8, 40u8, 3u8, 251u8, 205u8, 244u8, 133u8, 42u8, - 197u8, 21u8, 221u8, 80u8, 196u8, 222u8, 69u8, 153u8, 39u8, 161u8, 90u8, - 4u8, 38u8, 167u8, 131u8, 237u8, 42u8, 135u8, 37u8, 156u8, 108u8, + 228u8, 166u8, 94u8, 248u8, 71u8, 26u8, 125u8, 81u8, 32u8, 22u8, 46u8, + 185u8, 209u8, 123u8, 46u8, 17u8, 152u8, 149u8, 222u8, 125u8, 112u8, + 230u8, 29u8, 177u8, 162u8, 214u8, 66u8, 38u8, 170u8, 121u8, 129u8, + 100u8, ], ) } - #[doc = "Set the parachain validator-group rotation frequency"] - pub fn set_group_rotation_frequency( + #[doc = " Unchecked, signed solutions."] + #[doc = ""] + #[doc = " Together with `SubmissionIndices`, this stores a bounded set of `SignedSubmissions` while"] + #[doc = " allowing us to keep only a single one in memory at a time."] + #[doc = ""] + #[doc = " Twox note: the key of the map is an auto-incrementing index which users cannot inspect or"] + #[doc = " affect; we shouldn't need a cryptographically secure hasher."] + pub fn signed_submissions_map( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_group_rotation_frequency", - SetGroupRotationFrequency { new }, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_election_provider_multi_phase::signed::SignedSubmission< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + runtime_types::polkadot_runtime::NposCompactSolution16, + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "SignedSubmissionsMap", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 205u8, 222u8, 129u8, 36u8, 136u8, 186u8, 114u8, 70u8, 214u8, 22u8, - 112u8, 65u8, 56u8, 42u8, 103u8, 93u8, 108u8, 242u8, 188u8, 229u8, - 150u8, 19u8, 12u8, 222u8, 25u8, 254u8, 48u8, 218u8, 200u8, 208u8, - 132u8, 251u8, + 84u8, 65u8, 205u8, 191u8, 143u8, 246u8, 239u8, 27u8, 243u8, 54u8, + 250u8, 8u8, 125u8, 32u8, 241u8, 141u8, 210u8, 225u8, 56u8, 101u8, + 241u8, 52u8, 157u8, 29u8, 13u8, 155u8, 73u8, 132u8, 118u8, 53u8, 2u8, + 135u8, ], ) } - #[doc = "Set the availability period for parachains."] - pub fn set_chain_availability_period( + #[doc = " Unchecked, signed solutions."] + #[doc = ""] + #[doc = " Together with `SubmissionIndices`, this stores a bounded set of `SignedSubmissions` while"] + #[doc = " allowing us to keep only a single one in memory at a time."] + #[doc = ""] + #[doc = " Twox note: the key of the map is an auto-incrementing index which users cannot inspect or"] + #[doc = " affect; we shouldn't need a cryptographically secure hasher."] + pub fn signed_submissions_map_root( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_chain_availability_period", - SetChainAvailabilityPeriod { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_election_provider_multi_phase::signed::SignedSubmission< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + runtime_types::polkadot_runtime::NposCompactSolution16, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "SignedSubmissionsMap", + Vec::new(), [ - 171u8, 21u8, 54u8, 241u8, 19u8, 100u8, 54u8, 143u8, 97u8, 191u8, 193u8, - 96u8, 7u8, 86u8, 255u8, 109u8, 255u8, 93u8, 113u8, 28u8, 182u8, 75u8, - 120u8, 208u8, 91u8, 125u8, 156u8, 38u8, 56u8, 230u8, 24u8, 139u8, + 84u8, 65u8, 205u8, 191u8, 143u8, 246u8, 239u8, 27u8, 243u8, 54u8, + 250u8, 8u8, 125u8, 32u8, 241u8, 141u8, 210u8, 225u8, 56u8, 101u8, + 241u8, 52u8, 157u8, 29u8, 13u8, 155u8, 73u8, 132u8, 118u8, 53u8, 2u8, + 135u8, ], ) } - #[doc = "Set the availability period for parathreads."] - pub fn set_thread_availability_period( + #[doc = " The minimum score that each 'untrusted' solution must attain in order to be considered"] + #[doc = " feasible."] + #[doc = ""] + #[doc = " Can be set via `set_minimum_untrusted_score`."] + pub fn minimum_untrusted_score( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_thread_availability_period", - SetThreadAvailabilityPeriod { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_npos_elections::ElectionScore, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "MinimumUntrustedScore", + vec![], [ - 208u8, 27u8, 246u8, 33u8, 90u8, 200u8, 75u8, 177u8, 19u8, 107u8, 236u8, - 43u8, 159u8, 156u8, 184u8, 10u8, 146u8, 71u8, 212u8, 129u8, 44u8, 19u8, - 162u8, 172u8, 162u8, 46u8, 166u8, 10u8, 67u8, 112u8, 206u8, 50u8, + 77u8, 235u8, 181u8, 45u8, 230u8, 12u8, 0u8, 179u8, 152u8, 38u8, 74u8, + 199u8, 47u8, 84u8, 85u8, 55u8, 171u8, 226u8, 217u8, 125u8, 17u8, 194u8, + 95u8, 157u8, 73u8, 245u8, 75u8, 130u8, 248u8, 7u8, 53u8, 226u8, ], ) } - #[doc = "Set the scheduling lookahead, in expected number of blocks at peak throughput."] - pub fn set_scheduling_lookahead( + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " Duration of the unsigned phase."] + pub fn unsigned_phase( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_scheduling_lookahead", - SetSchedulingLookahead { new }, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "UnsignedPhase", [ - 220u8, 74u8, 0u8, 150u8, 45u8, 29u8, 56u8, 210u8, 66u8, 12u8, 119u8, - 176u8, 103u8, 24u8, 216u8, 55u8, 211u8, 120u8, 233u8, 204u8, 167u8, - 100u8, 199u8, 157u8, 186u8, 174u8, 40u8, 218u8, 19u8, 230u8, 253u8, - 7u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Set the maximum number of validators to assign to any core."] - pub fn set_max_validators_per_core( - &self, - new: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_validators_per_core", - SetMaxValidatorsPerCore { new }, + #[doc = " Duration of the signed phase."] + pub fn signed_phase(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedPhase", [ - 227u8, 113u8, 192u8, 116u8, 114u8, 171u8, 27u8, 22u8, 84u8, 117u8, - 146u8, 152u8, 94u8, 101u8, 14u8, 52u8, 228u8, 170u8, 163u8, 82u8, - 248u8, 130u8, 32u8, 103u8, 225u8, 151u8, 145u8, 36u8, 98u8, 158u8, 6u8, - 245u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Set the maximum number of validators to use in parachain consensus."] - pub fn set_max_validators( + #[doc = " The minimum amount of improvement to the solution score that defines a solution as"] + #[doc = " \"better\" in the Signed phase."] + pub fn better_signed_threshold( &self, - new: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_validators", - SetMaxValidators { new }, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "BetterSignedThreshold", [ - 143u8, 212u8, 59u8, 147u8, 4u8, 55u8, 142u8, 209u8, 237u8, 76u8, 7u8, - 178u8, 41u8, 81u8, 4u8, 203u8, 184u8, 149u8, 32u8, 1u8, 106u8, 180u8, - 121u8, 20u8, 137u8, 169u8, 144u8, 77u8, 38u8, 53u8, 243u8, 127u8, + 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, + 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, + 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, ], ) } - #[doc = "Set the dispute period, in number of sessions to keep for disputes."] - pub fn set_dispute_period( + #[doc = " The minimum amount of improvement to the solution score that defines a solution as"] + #[doc = " \"better\" in the Unsigned phase."] + pub fn better_unsigned_threshold( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_dispute_period", - SetDisputePeriod { new }, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "BetterUnsignedThreshold", [ - 36u8, 191u8, 142u8, 240u8, 48u8, 101u8, 10u8, 197u8, 117u8, 125u8, - 156u8, 189u8, 130u8, 77u8, 242u8, 130u8, 205u8, 154u8, 152u8, 47u8, - 75u8, 56u8, 63u8, 61u8, 33u8, 163u8, 151u8, 97u8, 105u8, 99u8, 55u8, - 180u8, + 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, + 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, + 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, ], ) } - #[doc = "Set the dispute post conclusion acceptance period."] - pub fn set_dispute_post_conclusion_acceptance_period( + #[doc = " The repeat threshold of the offchain worker."] + #[doc = ""] + #[doc = " For example, if it is 5, that means that at least 5 blocks will elapse between attempts"] + #[doc = " to submit the worker's solution."] + pub fn offchain_repeat( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload - { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_dispute_post_conclusion_acceptance_period", - SetDisputePostConclusionAcceptancePeriod { new }, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "OffchainRepeat", [ - 66u8, 56u8, 45u8, 87u8, 51u8, 49u8, 91u8, 95u8, 255u8, 185u8, 54u8, - 165u8, 85u8, 142u8, 238u8, 251u8, 174u8, 81u8, 3u8, 61u8, 92u8, 97u8, - 203u8, 20u8, 107u8, 50u8, 208u8, 250u8, 208u8, 159u8, 225u8, 175u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Set the maximum number of dispute spam slots."] - pub fn set_dispute_max_spam_slots( + #[doc = " The priority of the unsigned transaction submitted in the unsigned-phase"] + pub fn miner_tx_priority( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_dispute_max_spam_slots", - SetDisputeMaxSpamSlots { new }, + ) -> ::subxt::constants::Address<::core::primitive::u64> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MinerTxPriority", [ - 177u8, 58u8, 3u8, 205u8, 145u8, 85u8, 160u8, 162u8, 13u8, 171u8, 124u8, - 54u8, 58u8, 209u8, 88u8, 131u8, 230u8, 248u8, 142u8, 18u8, 121u8, - 129u8, 196u8, 121u8, 25u8, 15u8, 252u8, 229u8, 89u8, 230u8, 14u8, 68u8, + 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, + 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, + 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, + 246u8, ], ) } - #[doc = "Set the dispute conclusion by time out period."] - pub fn set_dispute_conclusion_by_time_out_period( + #[doc = " Maximum number of signed submissions that can be queued."] + #[doc = ""] + #[doc = " It is best to avoid adjusting this during an election, as it impacts downstream data"] + #[doc = " structures. In particular, `SignedSubmissionIndices` is bounded on this value. If you"] + #[doc = " update this value during an election, you _must_ ensure that"] + #[doc = " `SignedSubmissionIndices.len()` is less than or equal to the new value. Otherwise,"] + #[doc = " attempts to submit new solutions may cause a runtime panic."] + pub fn signed_max_submissions( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_dispute_conclusion_by_time_out_period", - SetDisputeConclusionByTimeOutPeriod { new }, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedMaxSubmissions", [ - 238u8, 102u8, 27u8, 169u8, 68u8, 116u8, 198u8, 64u8, 190u8, 33u8, 36u8, - 98u8, 176u8, 157u8, 123u8, 148u8, 126u8, 85u8, 32u8, 19u8, 49u8, 40u8, - 172u8, 41u8, 195u8, 182u8, 44u8, 255u8, 136u8, 204u8, 250u8, 6u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Set the no show slots, in number of number of consensus slots."] - #[doc = "Must be at least 1."] - pub fn set_no_show_slots( + #[doc = " Maximum weight of a signed solution."] + #[doc = ""] + #[doc = " If [`Config::MinerConfig`] is being implemented to submit signed solutions (outside of"] + #[doc = " this pallet), then [`MinerConfig::solution_weight`] is used to compare against"] + #[doc = " this value."] + pub fn signed_max_weight( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_no_show_slots", - SetNoShowSlots { new }, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedMaxWeight", [ - 94u8, 230u8, 89u8, 131u8, 188u8, 246u8, 251u8, 34u8, 249u8, 16u8, - 134u8, 63u8, 238u8, 115u8, 19u8, 97u8, 97u8, 218u8, 238u8, 115u8, - 126u8, 140u8, 236u8, 17u8, 177u8, 192u8, 210u8, 239u8, 126u8, 107u8, - 117u8, 207u8, + 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, + 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, + 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, + 106u8, 76u8, ], ) } - #[doc = "Set the total number of delay tranches."] - pub fn set_n_delay_tranches( + #[doc = " The maximum amount of unchecked solutions to refund the call fee for."] + pub fn signed_max_refunds( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_n_delay_tranches", - SetNDelayTranches { new }, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedMaxRefunds", [ - 195u8, 168u8, 178u8, 51u8, 20u8, 107u8, 227u8, 236u8, 57u8, 30u8, - 130u8, 93u8, 149u8, 2u8, 161u8, 66u8, 48u8, 37u8, 71u8, 108u8, 195u8, - 65u8, 153u8, 30u8, 181u8, 181u8, 158u8, 252u8, 120u8, 119u8, 36u8, - 146u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Set the zeroth delay tranche width."] - pub fn set_zeroth_delay_tranche_width( + #[doc = " Base reward for a signed solution"] + pub fn signed_reward_base( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_zeroth_delay_tranche_width", - SetZerothDelayTrancheWidth { new }, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedRewardBase", [ - 69u8, 56u8, 125u8, 24u8, 181u8, 62u8, 99u8, 92u8, 166u8, 107u8, 91u8, - 134u8, 230u8, 128u8, 214u8, 135u8, 245u8, 64u8, 62u8, 78u8, 96u8, - 231u8, 195u8, 29u8, 158u8, 113u8, 46u8, 96u8, 29u8, 0u8, 154u8, 80u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = "Set the number of validators needed to approve a block."] - pub fn set_needed_approvals( + #[doc = " Base deposit for a signed solution."] + pub fn signed_deposit_base( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_needed_approvals", - SetNeededApprovals { new }, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedDepositBase", [ - 238u8, 55u8, 134u8, 30u8, 67u8, 153u8, 150u8, 5u8, 226u8, 227u8, 185u8, - 188u8, 66u8, 60u8, 147u8, 118u8, 46u8, 174u8, 104u8, 100u8, 26u8, - 162u8, 65u8, 58u8, 162u8, 52u8, 211u8, 66u8, 242u8, 177u8, 230u8, 98u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = "Set the number of samples to do of the `RelayVRFModulo` approval assignment criterion."] - pub fn set_relay_vrf_modulo_samples( + #[doc = " Per-byte deposit for a signed solution."] + pub fn signed_deposit_byte( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_relay_vrf_modulo_samples", - SetRelayVrfModuloSamples { new }, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedDepositByte", [ - 76u8, 101u8, 207u8, 184u8, 211u8, 8u8, 43u8, 4u8, 165u8, 147u8, 166u8, - 3u8, 189u8, 42u8, 125u8, 130u8, 21u8, 43u8, 189u8, 120u8, 239u8, 131u8, - 235u8, 35u8, 151u8, 15u8, 30u8, 81u8, 0u8, 2u8, 64u8, 21u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = "Sets the maximum items that can present in a upward dispatch queue at once."] - pub fn set_max_upward_queue_count( + #[doc = " Per-weight deposit for a signed solution."] + pub fn signed_deposit_weight( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_upward_queue_count", - SetMaxUpwardQueueCount { new }, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedDepositWeight", [ - 116u8, 186u8, 216u8, 17u8, 150u8, 187u8, 86u8, 154u8, 92u8, 122u8, - 178u8, 167u8, 215u8, 165u8, 55u8, 86u8, 229u8, 114u8, 10u8, 149u8, - 50u8, 183u8, 165u8, 32u8, 233u8, 105u8, 82u8, 177u8, 120u8, 25u8, 44u8, - 130u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = "Sets the maximum total size of items that can present in a upward dispatch queue at once."] - pub fn set_max_upward_queue_size( + #[doc = " The maximum number of electing voters to put in the snapshot. At the moment, snapshots"] + #[doc = " are only over a single block, but once multi-block elections are introduced they will"] + #[doc = " take place over multiple blocks."] + pub fn max_electing_voters( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_upward_queue_size", - SetMaxUpwardQueueSize { new }, - [ - 18u8, 60u8, 141u8, 57u8, 134u8, 96u8, 140u8, 85u8, 137u8, 9u8, 209u8, - 123u8, 10u8, 165u8, 33u8, 184u8, 34u8, 82u8, 59u8, 60u8, 30u8, 47u8, - 22u8, 163u8, 119u8, 200u8, 197u8, 192u8, 112u8, 243u8, 156u8, 12u8, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MaxElectingVoters", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Set the critical downward message size."] - pub fn set_max_downward_message_size( + #[doc = " The maximum number of electable targets to put in the snapshot."] + pub fn max_electable_targets( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_downward_message_size", - SetMaxDownwardMessageSize { new }, + ) -> ::subxt::constants::Address<::core::primitive::u16> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MaxElectableTargets", [ - 104u8, 25u8, 229u8, 184u8, 53u8, 246u8, 206u8, 180u8, 13u8, 156u8, - 14u8, 224u8, 215u8, 115u8, 104u8, 127u8, 167u8, 189u8, 239u8, 183u8, - 68u8, 124u8, 55u8, 211u8, 186u8, 115u8, 70u8, 195u8, 61u8, 151u8, 32u8, - 218u8, + 116u8, 33u8, 2u8, 170u8, 181u8, 147u8, 171u8, 169u8, 167u8, 227u8, + 41u8, 144u8, 11u8, 236u8, 82u8, 100u8, 74u8, 60u8, 184u8, 72u8, 169u8, + 90u8, 208u8, 135u8, 15u8, 117u8, 10u8, 123u8, 128u8, 193u8, 29u8, 70u8, ], ) } - #[doc = "Sets the soft limit for the phase of dispatching dispatchable upward messages."] - pub fn set_ump_service_total_weight( - &self, - new: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_ump_service_total_weight", - SetUmpServiceTotalWeight { new }, + #[doc = " The maximum number of winners that can be elected by this `ElectionProvider`"] + #[doc = " implementation."] + #[doc = ""] + #[doc = " Note: This must always be greater or equal to `T::DataProvider::desired_targets()`."] + pub fn max_winners(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MaxWinners", [ - 178u8, 63u8, 233u8, 183u8, 160u8, 109u8, 10u8, 162u8, 150u8, 110u8, - 66u8, 166u8, 197u8, 207u8, 91u8, 208u8, 137u8, 106u8, 140u8, 184u8, - 35u8, 85u8, 138u8, 49u8, 32u8, 15u8, 150u8, 136u8, 50u8, 197u8, 21u8, - 99u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Sets the maximum size of an upward message that can be sent by a candidate."] - pub fn set_max_upward_message_size( + pub fn miner_max_length( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_upward_message_size", - SetMaxUpwardMessageSize { new }, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MinerMaxLength", [ - 213u8, 120u8, 21u8, 247u8, 101u8, 21u8, 164u8, 228u8, 33u8, 115u8, - 20u8, 138u8, 28u8, 174u8, 247u8, 39u8, 194u8, 113u8, 34u8, 73u8, 142u8, - 94u8, 116u8, 151u8, 113u8, 92u8, 151u8, 227u8, 116u8, 250u8, 101u8, - 179u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Sets the maximum number of messages that a candidate can contain."] - pub fn set_max_upward_message_num_per_candidate( + pub fn miner_max_weight( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_upward_message_num_per_candidate", - SetMaxUpwardMessageNumPerCandidate { new }, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MinerMaxWeight", [ - 54u8, 133u8, 226u8, 138u8, 184u8, 27u8, 130u8, 153u8, 130u8, 196u8, - 54u8, 79u8, 124u8, 10u8, 37u8, 139u8, 59u8, 190u8, 169u8, 87u8, 255u8, - 211u8, 38u8, 142u8, 37u8, 74u8, 144u8, 204u8, 75u8, 94u8, 154u8, 149u8, + 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, + 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, + 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, + 106u8, 76u8, ], ) } - #[doc = "Sets the number of sessions after which an HRMP open channel request expires."] - pub fn set_hrmp_open_request_ttl( + pub fn miner_max_votes_per_voter( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_open_request_ttl", - SetHrmpOpenRequestTtl { new }, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MinerMaxVotesPerVoter", [ - 192u8, 113u8, 113u8, 133u8, 197u8, 75u8, 88u8, 67u8, 130u8, 207u8, - 37u8, 192u8, 157u8, 159u8, 114u8, 75u8, 83u8, 180u8, 194u8, 180u8, - 96u8, 129u8, 7u8, 138u8, 110u8, 14u8, 229u8, 98u8, 71u8, 22u8, 229u8, - 247u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Sets the amount of funds that the sender should provide for opening an HRMP channel."] - pub fn set_hrmp_sender_deposit( + pub fn miner_max_winners( &self, - new: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_sender_deposit", - SetHrmpSenderDeposit { new }, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MinerMaxWinners", [ - 49u8, 38u8, 173u8, 114u8, 66u8, 140u8, 15u8, 151u8, 193u8, 54u8, 128u8, - 108u8, 72u8, 71u8, 28u8, 65u8, 129u8, 199u8, 105u8, 61u8, 96u8, 119u8, - 16u8, 53u8, 115u8, 120u8, 152u8, 122u8, 182u8, 171u8, 233u8, 48u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Sets the amount of funds that the recipient should provide for accepting opening an HRMP"] - #[doc = "channel."] - pub fn set_hrmp_recipient_deposit( + } + } + } + pub mod voter_list { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_bags_list::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Rebag { + pub dislocated: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PutInFrontOf { + pub lighter: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Declare that some `dislocated` account has, through rewards or penalties, sufficiently"] + #[doc = "changed its score that it should properly fall into a different bag than its current"] + #[doc = "one."] + #[doc = ""] + #[doc = "Anyone can call this function about any potentially dislocated account."] + #[doc = ""] + #[doc = "Will always update the stored score of `dislocated` to the correct score, based on"] + #[doc = "`ScoreProvider`."] + #[doc = ""] + #[doc = "If `dislocated` does not exists, it returns an error."] + pub fn rebag( &self, - new: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + dislocated: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_recipient_deposit", - SetHrmpRecipientDeposit { new }, + "VoterList", + "rebag", + Rebag { dislocated }, [ - 209u8, 212u8, 164u8, 56u8, 71u8, 215u8, 98u8, 250u8, 202u8, 150u8, - 228u8, 6u8, 166u8, 94u8, 171u8, 142u8, 10u8, 253u8, 89u8, 43u8, 6u8, - 173u8, 8u8, 235u8, 52u8, 18u8, 78u8, 129u8, 227u8, 61u8, 74u8, 83u8, + 35u8, 182u8, 31u8, 22u8, 190u8, 187u8, 31u8, 138u8, 60u8, 48u8, 236u8, + 16u8, 191u8, 143u8, 52u8, 110u8, 228u8, 43u8, 116u8, 13u8, 171u8, + 108u8, 112u8, 123u8, 252u8, 231u8, 132u8, 97u8, 195u8, 148u8, 252u8, + 241u8, ], ) } - #[doc = "Sets the maximum number of messages allowed in an HRMP channel at once."] - pub fn set_hrmp_channel_max_capacity( + #[doc = "Move the caller's Id directly in front of `lighter`."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and can only be called by the Id of"] + #[doc = "the account going in front of `lighter`."] + #[doc = ""] + #[doc = "Only works if"] + #[doc = "- both nodes are within the same bag,"] + #[doc = "- and `origin` has a greater `Score` than `lighter`."] + pub fn put_in_front_of( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + lighter: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_channel_max_capacity", - SetHrmpChannelMaxCapacity { new }, + "VoterList", + "put_in_front_of", + PutInFrontOf { lighter }, [ - 148u8, 109u8, 67u8, 220u8, 1u8, 115u8, 70u8, 93u8, 138u8, 190u8, 60u8, - 220u8, 80u8, 137u8, 246u8, 230u8, 115u8, 162u8, 30u8, 197u8, 11u8, - 33u8, 211u8, 224u8, 49u8, 165u8, 149u8, 155u8, 197u8, 44u8, 6u8, 167u8, + 184u8, 194u8, 39u8, 91u8, 28u8, 220u8, 76u8, 199u8, 64u8, 252u8, 233u8, + 241u8, 74u8, 19u8, 246u8, 190u8, 108u8, 227u8, 77u8, 162u8, 225u8, + 230u8, 101u8, 72u8, 159u8, 217u8, 133u8, 107u8, 84u8, 83u8, 81u8, + 227u8, ], ) } - #[doc = "Sets the maximum total size of messages in bytes allowed in an HRMP channel at once."] - pub fn set_hrmp_channel_max_total_size( + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_bags_list::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Moved an account from one bag to another."] + pub struct Rebagged { + pub who: ::subxt::utils::AccountId32, + pub from: ::core::primitive::u64, + pub to: ::core::primitive::u64, + } + impl ::subxt::events::StaticEvent for Rebagged { + const PALLET: &'static str = "VoterList"; + const EVENT: &'static str = "Rebagged"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Updated the score of some account to the given amount."] + pub struct ScoreUpdated { + pub who: ::subxt::utils::AccountId32, + pub new_score: ::core::primitive::u64, + } + impl ::subxt::events::StaticEvent for ScoreUpdated { + const PALLET: &'static str = "VoterList"; + const EVENT: &'static str = "ScoreUpdated"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " A single node, within some bag."] + #[doc = ""] + #[doc = " Nodes store links forward and back within their respective bags."] + pub fn list_nodes( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_channel_max_total_size", - SetHrmpChannelMaxTotalSize { new }, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_bags_list::list::Node, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "VoterList", + "ListNodes", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 79u8, 40u8, 207u8, 173u8, 168u8, 143u8, 130u8, 240u8, 205u8, 34u8, - 61u8, 217u8, 215u8, 106u8, 61u8, 181u8, 8u8, 21u8, 105u8, 64u8, 183u8, - 235u8, 39u8, 133u8, 70u8, 77u8, 233u8, 201u8, 222u8, 8u8, 43u8, 159u8, + 176u8, 186u8, 93u8, 51u8, 100u8, 184u8, 240u8, 29u8, 70u8, 3u8, 117u8, + 47u8, 23u8, 66u8, 231u8, 234u8, 53u8, 8u8, 234u8, 175u8, 181u8, 8u8, + 161u8, 154u8, 48u8, 178u8, 147u8, 227u8, 122u8, 115u8, 57u8, 97u8, ], ) } - #[doc = "Sets the maximum number of inbound HRMP channels a parachain is allowed to accept."] - pub fn set_hrmp_max_parachain_inbound_channels( + #[doc = " A single node, within some bag."] + #[doc = ""] + #[doc = " Nodes store links forward and back within their respective bags."] + pub fn list_nodes_root( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_max_parachain_inbound_channels", - SetHrmpMaxParachainInboundChannels { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_bags_list::list::Node, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "VoterList", + "ListNodes", + Vec::new(), [ - 91u8, 215u8, 212u8, 131u8, 140u8, 185u8, 119u8, 184u8, 61u8, 121u8, - 120u8, 73u8, 202u8, 98u8, 124u8, 187u8, 171u8, 84u8, 136u8, 77u8, - 103u8, 169u8, 185u8, 8u8, 214u8, 214u8, 23u8, 195u8, 100u8, 72u8, 45u8, - 12u8, + 176u8, 186u8, 93u8, 51u8, 100u8, 184u8, 240u8, 29u8, 70u8, 3u8, 117u8, + 47u8, 23u8, 66u8, 231u8, 234u8, 53u8, 8u8, 234u8, 175u8, 181u8, 8u8, + 161u8, 154u8, 48u8, 178u8, 147u8, 227u8, 122u8, 115u8, 57u8, 97u8, ], ) } - #[doc = "Sets the maximum number of inbound HRMP channels a parathread is allowed to accept."] - pub fn set_hrmp_max_parathread_inbound_channels( + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_list_nodes( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_max_parathread_inbound_channels", - SetHrmpMaxParathreadInboundChannels { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "VoterList", + "CounterForListNodes", + vec![], [ - 209u8, 66u8, 180u8, 20u8, 87u8, 242u8, 219u8, 71u8, 22u8, 145u8, 220u8, - 48u8, 44u8, 42u8, 77u8, 69u8, 255u8, 82u8, 27u8, 125u8, 231u8, 111u8, - 23u8, 32u8, 239u8, 28u8, 200u8, 255u8, 91u8, 207u8, 99u8, 107u8, + 156u8, 168u8, 97u8, 33u8, 84u8, 117u8, 220u8, 89u8, 62u8, 182u8, 24u8, + 88u8, 231u8, 244u8, 41u8, 19u8, 210u8, 131u8, 87u8, 0u8, 241u8, 230u8, + 160u8, 142u8, 128u8, 153u8, 83u8, 36u8, 88u8, 247u8, 70u8, 130u8, ], ) } - #[doc = "Sets the maximum size of a message that could ever be put into an HRMP channel."] - pub fn set_hrmp_channel_max_message_size( + #[doc = " A bag stored in storage."] + #[doc = ""] + #[doc = " Stores a `Bag` struct, which stores head and tail pointers to itself."] + pub fn list_bags( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_channel_max_message_size", - SetHrmpChannelMaxMessageSize { new }, + _0: impl ::std::borrow::Borrow<::core::primitive::u64>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_bags_list::list::Bag, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "VoterList", + "ListBags", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 17u8, 224u8, 230u8, 9u8, 114u8, 221u8, 138u8, 46u8, 234u8, 151u8, 27u8, - 34u8, 179u8, 67u8, 113u8, 228u8, 128u8, 212u8, 209u8, 125u8, 122u8, - 1u8, 79u8, 28u8, 10u8, 14u8, 83u8, 65u8, 253u8, 173u8, 116u8, 209u8, + 38u8, 86u8, 63u8, 92u8, 85u8, 59u8, 225u8, 244u8, 14u8, 155u8, 76u8, + 249u8, 153u8, 140u8, 179u8, 7u8, 96u8, 170u8, 236u8, 179u8, 4u8, 18u8, + 232u8, 146u8, 216u8, 51u8, 135u8, 116u8, 196u8, 117u8, 143u8, 153u8, ], ) } - #[doc = "Sets the maximum number of outbound HRMP channels a parachain is allowed to open."] - pub fn set_hrmp_max_parachain_outbound_channels( + #[doc = " A bag stored in storage."] + #[doc = ""] + #[doc = " Stores a `Bag` struct, which stores head and tail pointers to itself."] + pub fn list_bags_root( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_max_parachain_outbound_channels", - SetHrmpMaxParachainOutboundChannels { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_bags_list::list::Bag, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "VoterList", + "ListBags", + Vec::new(), [ - 26u8, 146u8, 150u8, 88u8, 236u8, 8u8, 63u8, 103u8, 71u8, 11u8, 20u8, - 210u8, 205u8, 106u8, 101u8, 112u8, 116u8, 73u8, 116u8, 136u8, 149u8, - 181u8, 207u8, 95u8, 151u8, 7u8, 98u8, 17u8, 224u8, 157u8, 117u8, 88u8, + 38u8, 86u8, 63u8, 92u8, 85u8, 59u8, 225u8, 244u8, 14u8, 155u8, 76u8, + 249u8, 153u8, 140u8, 179u8, 7u8, 96u8, 170u8, 236u8, 179u8, 4u8, 18u8, + 232u8, 146u8, 216u8, 51u8, 135u8, 116u8, 196u8, 117u8, 143u8, 153u8, ], ) } - #[doc = "Sets the maximum number of outbound HRMP channels a parathread is allowed to open."] - pub fn set_hrmp_max_parathread_outbound_channels( + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The list of thresholds separating the various bags."] + #[doc = ""] + #[doc = " Ids are separated into unsorted bags according to their score. This specifies the"] + #[doc = " thresholds separating the bags. An id's bag is the largest bag for which the id's score"] + #[doc = " is less than or equal to its upper threshold."] + #[doc = ""] + #[doc = " When ids are iterated, higher bags are iterated completely before lower bags. This means"] + #[doc = " that iteration is _semi-sorted_: ids of higher score tend to come before ids of lower"] + #[doc = " score, but peer ids within a particular bag are sorted in insertion order."] + #[doc = ""] + #[doc = " # Expressing the constant"] + #[doc = ""] + #[doc = " This constant must be sorted in strictly increasing order. Duplicate items are not"] + #[doc = " permitted."] + #[doc = ""] + #[doc = " There is an implied upper limit of `Score::MAX`; that value does not need to be"] + #[doc = " specified within the bag. For any two threshold lists, if one ends with"] + #[doc = " `Score::MAX`, the other one does not, and they are otherwise equal, the two"] + #[doc = " lists will behave identically."] + #[doc = ""] + #[doc = " # Calculation"] + #[doc = ""] + #[doc = " It is recommended to generate the set of thresholds in a geometric series, such that"] + #[doc = " there exists some constant ratio such that `threshold[k + 1] == (threshold[k] *"] + #[doc = " constant_ratio).max(threshold[k] + 1)` for all `k`."] + #[doc = ""] + #[doc = " The helpers in the `/utils/frame/generate-bags` module can simplify this calculation."] + #[doc = ""] + #[doc = " # Examples"] + #[doc = ""] + #[doc = " - If `BagThresholds::get().is_empty()`, then all ids are put into the same bag, and"] + #[doc = " iteration is strictly in insertion order."] + #[doc = " - If `BagThresholds::get().len() == 64`, and the thresholds are determined according to"] + #[doc = " the procedure given above, then the constant ratio is equal to 2."] + #[doc = " - If `BagThresholds::get().len() == 200`, and the thresholds are determined according to"] + #[doc = " the procedure given above, then the constant ratio is approximately equal to 1.248."] + #[doc = " - If the threshold list begins `[1, 2, 3, ...]`, then an id with score 0 or 1 will fall"] + #[doc = " into bag 0, an id with score 2 will fall into bag 1, etc."] + #[doc = ""] + #[doc = " # Migration"] + #[doc = ""] + #[doc = " In the event that this list ever changes, a copy of the old bags list must be retained."] + #[doc = " With that `List::migrate` can be called, which will perform the appropriate migration."] + pub fn bag_thresholds( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_max_parathread_outbound_channels", - SetHrmpMaxParathreadOutboundChannels { new }, + ) -> ::subxt::constants::Address<::std::vec::Vec<::core::primitive::u64>> + { + ::subxt::constants::Address::new_static( + "VoterList", + "BagThresholds", [ - 31u8, 72u8, 93u8, 21u8, 180u8, 156u8, 101u8, 24u8, 145u8, 220u8, 194u8, - 93u8, 176u8, 164u8, 53u8, 123u8, 36u8, 113u8, 152u8, 13u8, 222u8, 54u8, - 175u8, 170u8, 235u8, 68u8, 236u8, 130u8, 178u8, 56u8, 140u8, 31u8, - ], - ) - } - #[doc = "Sets the maximum number of outbound HRMP messages can be sent by a candidate."] - pub fn set_hrmp_max_message_num_per_candidate( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_max_message_num_per_candidate", - SetHrmpMaxMessageNumPerCandidate { new }, - [ - 244u8, 94u8, 225u8, 194u8, 133u8, 116u8, 202u8, 238u8, 8u8, 57u8, - 122u8, 125u8, 6u8, 131u8, 84u8, 102u8, 180u8, 67u8, 250u8, 136u8, 30u8, - 29u8, 110u8, 105u8, 219u8, 166u8, 91u8, 140u8, 44u8, 192u8, 37u8, - 185u8, - ], - ) - } - #[doc = "Sets the maximum amount of weight any individual upward message may consume."] - pub fn set_ump_max_individual_weight( - &self, - new: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_ump_max_individual_weight", - SetUmpMaxIndividualWeight { new }, - [ - 66u8, 190u8, 15u8, 172u8, 67u8, 16u8, 117u8, 247u8, 176u8, 25u8, 163u8, - 130u8, 147u8, 224u8, 226u8, 101u8, 219u8, 173u8, 176u8, 49u8, 90u8, - 133u8, 12u8, 223u8, 220u8, 18u8, 83u8, 232u8, 137u8, 52u8, 206u8, 71u8, - ], - ) - } - #[doc = "Enable or disable PVF pre-checking. Consult the field documentation prior executing."] - pub fn set_pvf_checking_enabled( - &self, - new: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_pvf_checking_enabled", - SetPvfCheckingEnabled { new }, - [ - 123u8, 76u8, 1u8, 112u8, 174u8, 245u8, 18u8, 67u8, 13u8, 29u8, 219u8, - 197u8, 201u8, 112u8, 230u8, 191u8, 37u8, 148u8, 73u8, 125u8, 54u8, - 236u8, 3u8, 80u8, 114u8, 155u8, 244u8, 132u8, 57u8, 63u8, 158u8, 248u8, - ], - ) - } - #[doc = "Set the number of session changes after which a PVF pre-checking voting is rejected."] - pub fn set_pvf_voting_ttl( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_pvf_voting_ttl", - SetPvfVotingTtl { new }, - [ - 17u8, 11u8, 98u8, 217u8, 208u8, 102u8, 238u8, 83u8, 118u8, 123u8, 20u8, - 18u8, 46u8, 212u8, 21u8, 164u8, 61u8, 104u8, 208u8, 204u8, 91u8, 210u8, - 40u8, 6u8, 201u8, 147u8, 46u8, 166u8, 219u8, 227u8, 121u8, 187u8, - ], - ) - } - #[doc = "Sets the minimum delay between announcing the upgrade block for a parachain until the"] - #[doc = "upgrade taking place."] - #[doc = ""] - #[doc = "See the field documentation for information and constraints for the new value."] - pub fn set_minimum_validation_upgrade_delay( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_minimum_validation_upgrade_delay", - SetMinimumValidationUpgradeDelay { new }, - [ - 205u8, 188u8, 75u8, 136u8, 228u8, 26u8, 112u8, 27u8, 119u8, 37u8, - 252u8, 109u8, 23u8, 145u8, 21u8, 212u8, 7u8, 28u8, 242u8, 210u8, 182u8, - 111u8, 121u8, 109u8, 50u8, 130u8, 46u8, 127u8, 122u8, 40u8, 141u8, - 242u8, - ], - ) - } - #[doc = "Setting this to true will disable consistency checks for the configuration setters."] - #[doc = "Use with caution."] - pub fn set_bypass_consistency_check( - &self, - new: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_bypass_consistency_check", - SetBypassConsistencyCheck { new }, - [ - 80u8, 66u8, 200u8, 98u8, 54u8, 207u8, 64u8, 99u8, 162u8, 121u8, 26u8, - 173u8, 113u8, 224u8, 240u8, 106u8, 69u8, 191u8, 177u8, 107u8, 34u8, - 74u8, 103u8, 128u8, 252u8, 160u8, 169u8, 246u8, 125u8, 127u8, 153u8, - 129u8, - ], - ) - } - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The active configuration for the current session."] - pub fn active_config( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::configuration::HostConfiguration< - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Configuration", - "ActiveConfig", - vec![], - [ - 152u8, 7u8, 210u8, 144u8, 253u8, 1u8, 141u8, 200u8, 122u8, 214u8, - 104u8, 100u8, 228u8, 235u8, 16u8, 86u8, 213u8, 212u8, 204u8, 46u8, - 74u8, 95u8, 217u8, 3u8, 40u8, 28u8, 149u8, 175u8, 7u8, 146u8, 24u8, - 3u8, - ], - ) - } - #[doc = " Pending configuration changes."] - #[doc = ""] - #[doc = " This is a list of configuration changes, each with a session index at which it should"] - #[doc = " be applied."] - #[doc = ""] - #[doc = " The list is sorted ascending by session index. Also, this list can only contain at most"] - #[doc = " 2 items: for the next session and for the `scheduled_session`."] pub fn pending_configs (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , :: std :: vec :: Vec < (:: core :: primitive :: u32 , runtime_types :: polkadot_runtime_parachains :: configuration :: HostConfiguration < :: core :: primitive :: u32 > ,) > , :: subxt :: storage :: address :: Yes , :: subxt :: storage :: address :: Yes , () >{ - ::subxt::storage::address::Address::new_static( - "Configuration", - "PendingConfigs", - vec![], - [ - 206u8, 161u8, 39u8, 154u8, 62u8, 215u8, 33u8, 93u8, 214u8, 37u8, 29u8, - 71u8, 32u8, 176u8, 87u8, 166u8, 39u8, 11u8, 81u8, 155u8, 174u8, 118u8, - 138u8, 76u8, 22u8, 248u8, 148u8, 210u8, 243u8, 41u8, 111u8, 216u8, - ], - ) - } - #[doc = " If this is set, then the configuration setters will bypass the consistency checks. This"] - #[doc = " is meant to be used only as the last resort."] - pub fn bypass_consistency_check( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Configuration", - "BypassConsistencyCheck", - vec![], - [ - 42u8, 191u8, 122u8, 163u8, 112u8, 2u8, 148u8, 59u8, 79u8, 219u8, 184u8, - 172u8, 246u8, 136u8, 185u8, 251u8, 189u8, 226u8, 83u8, 129u8, 162u8, - 109u8, 148u8, 75u8, 120u8, 216u8, 44u8, 28u8, 221u8, 78u8, 177u8, 94u8, - ], - ) - } - } - } - } - pub mod paras_shared { - use super::root_mod; - use super::runtime_types; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub struct TransactionApi; - impl TransactionApi {} - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The current session index."] - pub fn current_session_index( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasShared", - "CurrentSessionIndex", - vec![], - [ - 83u8, 15u8, 20u8, 55u8, 103u8, 65u8, 76u8, 202u8, 69u8, 14u8, 221u8, - 93u8, 38u8, 163u8, 167u8, 83u8, 18u8, 245u8, 33u8, 175u8, 7u8, 97u8, - 67u8, 186u8, 96u8, 57u8, 147u8, 120u8, 107u8, 91u8, 147u8, 64u8, - ], - ) - } - #[doc = " All the validators actively participating in parachain consensus."] - #[doc = " Indices are into the broader validator set."] - pub fn active_validator_indices( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasShared", - "ActiveValidatorIndices", - vec![], - [ - 123u8, 26u8, 202u8, 53u8, 219u8, 42u8, 54u8, 92u8, 144u8, 74u8, 228u8, - 234u8, 129u8, 216u8, 161u8, 98u8, 199u8, 12u8, 13u8, 231u8, 23u8, - 166u8, 185u8, 209u8, 191u8, 33u8, 231u8, 252u8, 232u8, 44u8, 213u8, - 221u8, - ], - ) - } - #[doc = " The parachain attestation keys of the validators actively participating in parachain consensus."] - #[doc = " This should be the same length as `ActiveValidatorIndices`."] - pub fn active_validator_keys( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasShared", - "ActiveValidatorKeys", - vec![], - [ - 33u8, 14u8, 54u8, 86u8, 184u8, 171u8, 194u8, 35u8, 187u8, 252u8, 181u8, - 79u8, 229u8, 134u8, 50u8, 235u8, 162u8, 216u8, 108u8, 160u8, 175u8, - 172u8, 239u8, 114u8, 57u8, 238u8, 9u8, 54u8, 57u8, 196u8, 105u8, 15u8, + 103u8, 102u8, 255u8, 165u8, 124u8, 54u8, 5u8, 172u8, 112u8, 234u8, + 25u8, 175u8, 178u8, 19u8, 251u8, 73u8, 91u8, 192u8, 227u8, 81u8, 249u8, + 45u8, 126u8, 116u8, 7u8, 37u8, 9u8, 200u8, 167u8, 182u8, 12u8, 131u8, ], ) } } } } - pub mod para_inclusion { + pub mod nomination_pools { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_parachains::inclusion::pallet::Error; + pub type Error = runtime_types::pallet_nomination_pools::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - pub struct TransactionApi; - impl TransactionApi {} - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::polkadot_runtime_parachains::inclusion::pallet::Event; - pub mod events { - use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -25159,16 +23866,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A candidate was backed. `[candidate, head_data]`"] - pub struct CandidateBacked( - pub runtime_types::polkadot_primitives::v2::CandidateReceipt<::subxt::utils::H256>, - pub runtime_types::polkadot_parachain::primitives::HeadData, - pub runtime_types::polkadot_primitives::v2::CoreIndex, - pub runtime_types::polkadot_primitives::v2::GroupIndex, - ); - impl ::subxt::events::StaticEvent for CandidateBacked { - const PALLET: &'static str = "ParaInclusion"; - const EVENT: &'static str = "CandidateBacked"; + pub struct Join { + #[codec(compact)] + pub amount: ::core::primitive::u128, + pub pool_id: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25180,16 +23881,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A candidate was included. `[candidate, head_data]`"] - pub struct CandidateIncluded( - pub runtime_types::polkadot_primitives::v2::CandidateReceipt<::subxt::utils::H256>, - pub runtime_types::polkadot_parachain::primitives::HeadData, - pub runtime_types::polkadot_primitives::v2::CoreIndex, - pub runtime_types::polkadot_primitives::v2::GroupIndex, - ); - impl ::subxt::events::StaticEvent for CandidateIncluded { - const PALLET: &'static str = "ParaInclusion"; - const EVENT: &'static str = "CandidateIncluded"; + pub struct BondExtra { + pub extra: + runtime_types::pallet_nomination_pools::BondExtra<::core::primitive::u128>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25201,139 +23895,36 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A candidate timed out. `[candidate, head_data]`"] - pub struct CandidateTimedOut( - pub runtime_types::polkadot_primitives::v2::CandidateReceipt<::subxt::utils::H256>, - pub runtime_types::polkadot_parachain::primitives::HeadData, - pub runtime_types::polkadot_primitives::v2::CoreIndex, - ); - impl ::subxt::events::StaticEvent for CandidateTimedOut { - const PALLET: &'static str = "ParaInclusion"; - const EVENT: &'static str = "CandidateTimedOut"; + pub struct ClaimPayout; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Unbond { + pub member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub unbonding_points: ::core::primitive::u128, } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The latest bitfield for each validator, referred to by their index in the validator set."] pub fn availability_bitfields (& self , _0 : impl :: std :: borrow :: Borrow < runtime_types :: polkadot_primitives :: v2 :: ValidatorIndex > ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: inclusion :: AvailabilityBitfieldRecord < :: core :: primitive :: u32 > , :: subxt :: storage :: address :: Yes , () , :: subxt :: storage :: address :: Yes >{ - ::subxt::storage::address::Address::new_static( - "ParaInclusion", - "AvailabilityBitfields", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 149u8, 215u8, 123u8, 226u8, 73u8, 240u8, 102u8, 39u8, 243u8, 232u8, - 226u8, 116u8, 65u8, 180u8, 110u8, 4u8, 194u8, 50u8, 60u8, 193u8, 142u8, - 62u8, 20u8, 148u8, 106u8, 162u8, 96u8, 114u8, 215u8, 250u8, 111u8, - 225u8, - ], - ) - } - #[doc = " The latest bitfield for each validator, referred to by their index in the validator set."] pub fn availability_bitfields_root (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: inclusion :: AvailabilityBitfieldRecord < :: core :: primitive :: u32 > , () , () , :: subxt :: storage :: address :: Yes >{ - ::subxt::storage::address::Address::new_static( - "ParaInclusion", - "AvailabilityBitfields", - Vec::new(), - [ - 149u8, 215u8, 123u8, 226u8, 73u8, 240u8, 102u8, 39u8, 243u8, 232u8, - 226u8, 116u8, 65u8, 180u8, 110u8, 4u8, 194u8, 50u8, 60u8, 193u8, 142u8, - 62u8, 20u8, 148u8, 106u8, 162u8, 96u8, 114u8, 215u8, 250u8, 111u8, - 225u8, - ], - ) - } - #[doc = " Candidates pending availability by `ParaId`."] pub fn pending_availability (& self , _0 : impl :: std :: borrow :: Borrow < runtime_types :: polkadot_parachain :: primitives :: Id > ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: inclusion :: CandidatePendingAvailability < :: subxt :: utils :: H256 , :: core :: primitive :: u32 > , :: subxt :: storage :: address :: Yes , () , :: subxt :: storage :: address :: Yes >{ - ::subxt::storage::address::Address::new_static( - "ParaInclusion", - "PendingAvailability", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 54u8, 166u8, 18u8, 56u8, 51u8, 241u8, 31u8, 165u8, 220u8, 138u8, 67u8, - 171u8, 23u8, 101u8, 109u8, 26u8, 211u8, 237u8, 81u8, 143u8, 192u8, - 214u8, 49u8, 42u8, 69u8, 30u8, 168u8, 113u8, 72u8, 12u8, 140u8, 242u8, - ], - ) - } - #[doc = " Candidates pending availability by `ParaId`."] pub fn pending_availability_root (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: inclusion :: CandidatePendingAvailability < :: subxt :: utils :: H256 , :: core :: primitive :: u32 > , () , () , :: subxt :: storage :: address :: Yes >{ - ::subxt::storage::address::Address::new_static( - "ParaInclusion", - "PendingAvailability", - Vec::new(), - [ - 54u8, 166u8, 18u8, 56u8, 51u8, 241u8, 31u8, 165u8, 220u8, 138u8, 67u8, - 171u8, 23u8, 101u8, 109u8, 26u8, 211u8, 237u8, 81u8, 143u8, 192u8, - 214u8, 49u8, 42u8, 69u8, 30u8, 168u8, 113u8, 72u8, 12u8, 140u8, 242u8, - ], - ) - } - #[doc = " The commitments of candidates pending availability, by `ParaId`."] - pub fn pending_availability_commitments( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v2::CandidateCommitments< - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParaInclusion", - "PendingAvailabilityCommitments", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 146u8, 206u8, 148u8, 102u8, 55u8, 101u8, 144u8, 33u8, 197u8, 232u8, - 64u8, 205u8, 216u8, 21u8, 247u8, 170u8, 237u8, 115u8, 144u8, 43u8, - 106u8, 87u8, 82u8, 39u8, 11u8, 87u8, 149u8, 195u8, 56u8, 59u8, 54u8, - 8u8, - ], - ) - } - #[doc = " The commitments of candidates pending availability, by `ParaId`."] - pub fn pending_availability_commitments_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v2::CandidateCommitments< - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParaInclusion", - "PendingAvailabilityCommitments", - Vec::new(), - [ - 146u8, 206u8, 148u8, 102u8, 55u8, 101u8, 144u8, 33u8, 197u8, 232u8, - 64u8, 205u8, 216u8, 21u8, 247u8, 170u8, 237u8, 115u8, 144u8, 43u8, - 106u8, 87u8, 82u8, 39u8, 11u8, 87u8, 149u8, 195u8, 56u8, 59u8, 54u8, - 8u8, - ], - ) - } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PoolWithdrawUnbonded { + pub pool_id: ::core::primitive::u32, + pub num_slashing_spans: ::core::primitive::u32, } - } - } - pub mod para_inherent { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_parachains::paras_inherent::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -25344,294 +23935,26 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Enter { - pub data: runtime_types::polkadot_primitives::v2::InherentData< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - >, + pub struct WithdrawUnbonded { + pub member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub num_slashing_spans: ::core::primitive::u32, } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Enter the paras inherent. This will process bitfields and backed candidates."] - pub fn enter( - &self, - data: runtime_types::polkadot_primitives::v2::InherentData< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParaInherent", - "enter", - Enter { data }, - [ - 92u8, 247u8, 59u8, 6u8, 2u8, 102u8, 76u8, 147u8, 46u8, 232u8, 38u8, - 191u8, 145u8, 155u8, 23u8, 39u8, 228u8, 95u8, 57u8, 249u8, 247u8, 20u8, - 9u8, 189u8, 156u8, 187u8, 207u8, 107u8, 0u8, 13u8, 228u8, 6u8, - ], - ) - } - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Whether the paras inherent was included within this block."] - #[doc = ""] - #[doc = " The `Option<()>` is effectively a `bool`, but it never hits storage in the `None` variant"] - #[doc = " due to the guarantees of FRAME's storage APIs."] - #[doc = ""] - #[doc = " If this is `None` at the end of the block, we panic and render the block invalid."] - pub fn included( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaInherent", - "Included", - vec![], - [ - 208u8, 213u8, 76u8, 64u8, 90u8, 141u8, 144u8, 52u8, 220u8, 35u8, 143u8, - 171u8, 45u8, 59u8, 9u8, 218u8, 29u8, 186u8, 139u8, 203u8, 205u8, 12u8, - 10u8, 2u8, 27u8, 167u8, 182u8, 244u8, 167u8, 220u8, 44u8, 16u8, - ], - ) - } - #[doc = " Scraped on chain data for extracting resolved disputes as well as backing votes."] - pub fn on_chain_votes( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v2::ScrapedOnChainVotes< - ::subxt::utils::H256, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaInherent", - "OnChainVotes", - vec![], - [ - 187u8, 34u8, 219u8, 197u8, 202u8, 214u8, 140u8, 152u8, 253u8, 65u8, - 206u8, 217u8, 36u8, 40u8, 107u8, 215u8, 135u8, 115u8, 35u8, 61u8, - 180u8, 131u8, 0u8, 184u8, 193u8, 76u8, 165u8, 63u8, 106u8, 222u8, - 126u8, 113u8, - ], - ) - } - } - } - } - pub mod para_scheduler { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " All the validator groups. One for each core. Indices are into `ActiveValidators` - not the"] - #[doc = " broader set of Polkadot validators, but instead just the subset used for parachains during"] - #[doc = " this session."] - #[doc = ""] - #[doc = " Bound: The number of cores is the sum of the numbers of parachains and parathread multiplexers."] - #[doc = " Reasonably, 100-1000. The dominant factor is the number of validators: safe upper bound at 10k."] - pub fn validator_groups( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - ::std::vec::Vec, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaScheduler", - "ValidatorGroups", - vec![], - [ - 175u8, 187u8, 69u8, 76u8, 211u8, 36u8, 162u8, 147u8, 83u8, 65u8, 83u8, - 44u8, 241u8, 112u8, 246u8, 14u8, 237u8, 255u8, 248u8, 58u8, 44u8, - 207u8, 159u8, 112u8, 31u8, 90u8, 15u8, 85u8, 4u8, 212u8, 215u8, 211u8, - ], - ) - } - #[doc = " A queue of upcoming claims and which core they should be mapped onto."] - #[doc = ""] - #[doc = " The number of queued claims is bounded at the `scheduling_lookahead`"] - #[doc = " multiplied by the number of parathread multiplexer cores. Reasonably, 10 * 50 = 500."] - pub fn parathread_queue( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::scheduler::ParathreadClaimQueue, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaScheduler", - "ParathreadQueue", - vec![], - [ - 79u8, 144u8, 191u8, 114u8, 235u8, 55u8, 133u8, 208u8, 73u8, 97u8, 73u8, - 148u8, 96u8, 185u8, 110u8, 95u8, 132u8, 54u8, 244u8, 86u8, 50u8, 218u8, - 121u8, 226u8, 153u8, 58u8, 232u8, 202u8, 132u8, 147u8, 168u8, 48u8, - ], - ) - } - #[doc = " One entry for each availability core. Entries are `None` if the core is not currently occupied. Can be"] - #[doc = " temporarily `Some` if scheduled but not occupied."] - #[doc = " The i'th parachain belongs to the i'th core, with the remaining cores all being"] - #[doc = " parathread-multiplexers."] - #[doc = ""] - #[doc = " Bounded by the maximum of either of these two values:"] - #[doc = " * The number of parachains and parathread multiplexers"] - #[doc = " * The number of validators divided by `configuration.max_validators_per_core`."] - pub fn availability_cores( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - ::core::option::Option< - runtime_types::polkadot_primitives::v2::CoreOccupied, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaScheduler", - "AvailabilityCores", - vec![], - [ - 103u8, 94u8, 52u8, 17u8, 118u8, 25u8, 254u8, 190u8, 74u8, 91u8, 64u8, - 205u8, 243u8, 113u8, 143u8, 166u8, 193u8, 110u8, 214u8, 151u8, 24u8, - 112u8, 69u8, 131u8, 235u8, 78u8, 240u8, 120u8, 240u8, 68u8, 56u8, - 215u8, - ], - ) - } - #[doc = " An index used to ensure that only one claim on a parathread exists in the queue or is"] - #[doc = " currently being handled by an occupied core."] - #[doc = ""] - #[doc = " Bounded by the number of parathread cores and scheduling lookahead. Reasonably, 10 * 50 = 500."] - pub fn parathread_claim_index( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaScheduler", - "ParathreadClaimIndex", - vec![], - [ - 64u8, 17u8, 173u8, 35u8, 14u8, 16u8, 149u8, 200u8, 118u8, 211u8, 130u8, - 15u8, 124u8, 112u8, 44u8, 220u8, 156u8, 132u8, 119u8, 148u8, 24u8, - 120u8, 252u8, 246u8, 204u8, 119u8, 206u8, 85u8, 44u8, 210u8, 135u8, - 83u8, - ], - ) - } - #[doc = " The block number where the session start occurred. Used to track how many group rotations have occurred."] - #[doc = ""] - #[doc = " Note that in the context of parachains modules the session change is signaled during"] - #[doc = " the block and enacted at the end of the block (at the finalization stage, to be exact)."] - #[doc = " Thus for all intents and purposes the effect of the session change is observed at the"] - #[doc = " block following the session change, block number of which we save in this storage value."] - pub fn session_start_block( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaScheduler", - "SessionStartBlock", - vec![], - [ - 122u8, 37u8, 150u8, 1u8, 185u8, 201u8, 168u8, 67u8, 55u8, 17u8, 101u8, - 18u8, 133u8, 212u8, 6u8, 73u8, 191u8, 204u8, 229u8, 22u8, 185u8, 120u8, - 24u8, 245u8, 121u8, 215u8, 124u8, 210u8, 49u8, 28u8, 26u8, 80u8, - ], - ) - } - #[doc = " Currently scheduled cores - free but up to be occupied."] - #[doc = ""] - #[doc = " Bounded by the number of cores: one for each parachain and parathread multiplexer."] - #[doc = ""] - #[doc = " The value contained here will not be valid after the end of a block. Runtime APIs should be used to determine scheduled cores/"] - #[doc = " for the upcoming block."] - pub fn scheduled( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_runtime_parachains::scheduler::CoreAssignment, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaScheduler", - "Scheduled", - vec![], - [ - 246u8, 105u8, 102u8, 107u8, 143u8, 92u8, 220u8, 69u8, 71u8, 102u8, - 212u8, 157u8, 56u8, 112u8, 42u8, 179u8, 183u8, 139u8, 128u8, 81u8, - 239u8, 84u8, 103u8, 126u8, 82u8, 247u8, 39u8, 39u8, 231u8, 218u8, - 131u8, 53u8, - ], - ) - } - } - } - } - pub mod paras { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_parachains::paras::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSetCurrentCode { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Create { + #[codec(compact)] + pub amount: ::core::primitive::u128, + pub root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25643,24 +23966,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSetCurrentHead { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub new_head: runtime_types::polkadot_parachain::primitives::HeadData, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceScheduleCodeUpgrade { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - pub relay_parent_number: ::core::primitive::u32, + pub struct CreateWithPoolId { + #[codec(compact)] + pub amount: ::core::primitive::u128, + pub root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub pool_id: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25672,9 +23984,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceNoteNewHead { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub new_head: runtime_types::polkadot_parachain::primitives::HeadData, + pub struct Nominate { + pub pool_id: ::core::primitive::u32, + pub validators: ::std::vec::Vec<::subxt::utils::AccountId32>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25686,8 +23998,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceQueueAction { - pub para: runtime_types::polkadot_parachain::primitives::Id, + pub struct SetState { + pub pool_id: ::core::primitive::u32, + pub state: runtime_types::pallet_nomination_pools::PoolState, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25699,8 +24012,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddTrustedValidationCode { - pub validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + pub struct SetMetadata { + pub pool_id: ::core::primitive::u32, + pub metadata: ::std::vec::Vec<::core::primitive::u8>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25712,9 +24026,20 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PokeUnusedValidationCode { - pub validation_code_hash: - runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + pub struct SetConfigs { + pub min_join_bond: + runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u128>, + pub min_create_bond: + runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u128>, + pub max_pools: + runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u32>, + pub max_members: + runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u32>, + pub max_members_per_pool: + runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u32>, + pub global_max_commission: runtime_types::pallet_nomination_pools::ConfigOp< + runtime_types::sp_arithmetic::per_things::Perbill, + >, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25726,180 +24051,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct IncludePvfCheckStatement { - pub stmt: runtime_types::polkadot_primitives::v2::PvfCheckStatement, - pub signature: runtime_types::polkadot_primitives::v2::validator_app::Signature, - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Set the storage for the parachain validation code immediately."] - pub fn force_set_current_code( - &self, - para: runtime_types::polkadot_parachain::primitives::Id, - new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "force_set_current_code", - ForceSetCurrentCode { para, new_code }, - [ - 56u8, 59u8, 48u8, 185u8, 106u8, 99u8, 250u8, 32u8, 207u8, 2u8, 4u8, - 110u8, 165u8, 131u8, 22u8, 33u8, 248u8, 175u8, 186u8, 6u8, 118u8, 51u8, - 74u8, 239u8, 68u8, 122u8, 148u8, 242u8, 193u8, 131u8, 6u8, 135u8, - ], - ) - } - #[doc = "Set the storage for the current parachain head data immediately."] - pub fn force_set_current_head( - &self, - para: runtime_types::polkadot_parachain::primitives::Id, - new_head: runtime_types::polkadot_parachain::primitives::HeadData, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "force_set_current_head", - ForceSetCurrentHead { para, new_head }, - [ - 203u8, 70u8, 33u8, 168u8, 133u8, 64u8, 146u8, 137u8, 156u8, 104u8, - 183u8, 26u8, 74u8, 227u8, 154u8, 224u8, 75u8, 85u8, 143u8, 51u8, 60u8, - 194u8, 59u8, 94u8, 100u8, 84u8, 194u8, 100u8, 153u8, 9u8, 222u8, 63u8, - ], - ) - } - #[doc = "Schedule an upgrade as if it was scheduled in the given relay parent block."] - pub fn force_schedule_code_upgrade( - &self, - para: runtime_types::polkadot_parachain::primitives::Id, - new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - relay_parent_number: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "force_schedule_code_upgrade", - ForceScheduleCodeUpgrade { - para, - new_code, - relay_parent_number, - }, - [ - 30u8, 210u8, 178u8, 31u8, 48u8, 144u8, 167u8, 117u8, 220u8, 36u8, - 175u8, 220u8, 145u8, 193u8, 20u8, 98u8, 149u8, 130u8, 66u8, 54u8, 20u8, - 204u8, 231u8, 116u8, 203u8, 179u8, 253u8, 106u8, 55u8, 58u8, 116u8, - 109u8, - ], - ) - } - #[doc = "Note a new block head for para within the context of the current block."] - pub fn force_note_new_head( - &self, - para: runtime_types::polkadot_parachain::primitives::Id, - new_head: runtime_types::polkadot_parachain::primitives::HeadData, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "force_note_new_head", - ForceNoteNewHead { para, new_head }, - [ - 83u8, 93u8, 166u8, 142u8, 213u8, 1u8, 243u8, 73u8, 192u8, 164u8, 104u8, - 206u8, 99u8, 250u8, 31u8, 222u8, 231u8, 54u8, 12u8, 45u8, 92u8, 74u8, - 248u8, 50u8, 180u8, 86u8, 251u8, 172u8, 227u8, 88u8, 45u8, 127u8, - ], - ) - } - #[doc = "Put a parachain directly into the next session's action queue."] - #[doc = "We can't queue it any sooner than this without going into the"] - #[doc = "initializer..."] - pub fn force_queue_action( - &self, - para: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "force_queue_action", - ForceQueueAction { para }, - [ - 195u8, 243u8, 79u8, 34u8, 111u8, 246u8, 109u8, 90u8, 251u8, 137u8, - 48u8, 23u8, 117u8, 29u8, 26u8, 200u8, 37u8, 64u8, 36u8, 254u8, 224u8, - 99u8, 165u8, 246u8, 8u8, 76u8, 250u8, 36u8, 141u8, 67u8, 185u8, 17u8, - ], - ) - } - #[doc = "Adds the validation code to the storage."] - #[doc = ""] - #[doc = "The code will not be added if it is already present. Additionally, if PVF pre-checking"] - #[doc = "is running for that code, it will be instantly accepted."] - #[doc = ""] - #[doc = "Otherwise, the code will be added into the storage. Note that the code will be added"] - #[doc = "into storage with reference count 0. This is to account the fact that there are no users"] - #[doc = "for this code yet. The caller will have to make sure that this code eventually gets"] - #[doc = "used by some parachain or removed from the storage to avoid storage leaks. For the latter"] - #[doc = "prefer to use the `poke_unused_validation_code` dispatchable to raw storage manipulation."] - #[doc = ""] - #[doc = "This function is mainly meant to be used for upgrading parachains that do not follow"] - #[doc = "the go-ahead signal while the PVF pre-checking feature is enabled."] - pub fn add_trusted_validation_code( - &self, - validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "add_trusted_validation_code", - AddTrustedValidationCode { validation_code }, - [ - 160u8, 199u8, 245u8, 178u8, 58u8, 65u8, 79u8, 199u8, 53u8, 60u8, 84u8, - 225u8, 2u8, 145u8, 154u8, 204u8, 165u8, 171u8, 173u8, 223u8, 59u8, - 196u8, 37u8, 12u8, 243u8, 158u8, 77u8, 184u8, 58u8, 64u8, 133u8, 71u8, - ], - ) - } - #[doc = "Remove the validation code from the storage iff the reference count is 0."] - #[doc = ""] - #[doc = "This is better than removing the storage directly, because it will not remove the code"] - #[doc = "that was suddenly got used by some parachain while this dispatchable was pending"] - #[doc = "dispatching."] - pub fn poke_unused_validation_code( - &self, - validation_code_hash : runtime_types :: polkadot_parachain :: primitives :: ValidationCodeHash, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "poke_unused_validation_code", - PokeUnusedValidationCode { - validation_code_hash, - }, - [ - 98u8, 9u8, 24u8, 180u8, 8u8, 144u8, 36u8, 28u8, 111u8, 83u8, 162u8, - 160u8, 66u8, 119u8, 177u8, 117u8, 143u8, 233u8, 241u8, 128u8, 189u8, - 118u8, 241u8, 30u8, 74u8, 171u8, 193u8, 177u8, 233u8, 12u8, 254u8, - 146u8, - ], - ) - } - #[doc = "Includes a statement for a PVF pre-checking vote. Potentially, finalizes the vote and"] - #[doc = "enacts the results if that was the last vote before achieving the supermajority."] - pub fn include_pvf_check_statement( - &self, - stmt: runtime_types::polkadot_primitives::v2::PvfCheckStatement, - signature: runtime_types::polkadot_primitives::v2::validator_app::Signature, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "include_pvf_check_statement", - IncludePvfCheckStatement { stmt, signature }, - [ - 22u8, 136u8, 241u8, 59u8, 36u8, 249u8, 239u8, 255u8, 169u8, 117u8, - 19u8, 58u8, 214u8, 16u8, 135u8, 65u8, 13u8, 250u8, 5u8, 41u8, 144u8, - 29u8, 207u8, 73u8, 215u8, 221u8, 1u8, 253u8, 123u8, 110u8, 6u8, 196u8, - ], - ) - } + pub struct UpdateRoles { + pub pool_id: ::core::primitive::u32, + pub new_root: + runtime_types::pallet_nomination_pools::ConfigOp<::subxt::utils::AccountId32>, + pub new_nominator: + runtime_types::pallet_nomination_pools::ConfigOp<::subxt::utils::AccountId32>, + pub new_bouncer: + runtime_types::pallet_nomination_pools::ConfigOp<::subxt::utils::AccountId32>, } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::polkadot_runtime_parachains::paras::pallet::Event; - pub mod events { - use super::runtime_types; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -25909,11 +24071,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Current code has been updated for a Para. `para_id`"] - pub struct CurrentCodeUpdated(pub runtime_types::polkadot_parachain::primitives::Id); - impl ::subxt::events::StaticEvent for CurrentCodeUpdated { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "CurrentCodeUpdated"; + pub struct Chill { + pub pool_id: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25925,11 +24084,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Current head has been updated for a Para. `para_id`"] - pub struct CurrentHeadUpdated(pub runtime_types::polkadot_parachain::primitives::Id); - impl ::subxt::events::StaticEvent for CurrentHeadUpdated { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "CurrentHeadUpdated"; + pub struct BondExtraOther { + pub member: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub extra: + runtime_types::pallet_nomination_pools::BondExtra<::core::primitive::u128>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25941,11 +24099,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A code upgrade has been scheduled for a Para. `para_id`"] - pub struct CodeUpgradeScheduled(pub runtime_types::polkadot_parachain::primitives::Id); - impl ::subxt::events::StaticEvent for CodeUpgradeScheduled { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "CodeUpgradeScheduled"; + pub struct SetClaimPermission { + pub permission: runtime_types::pallet_nomination_pools::ClaimPermission, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25957,11 +24112,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new head has been noted for a Para. `para_id`"] - pub struct NewHeadNoted(pub runtime_types::polkadot_parachain::primitives::Id); - impl ::subxt::events::StaticEvent for NewHeadNoted { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "NewHeadNoted"; + pub struct ClaimPayoutOther { + pub other: ::subxt::utils::AccountId32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25973,14 +24125,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A para has been queued to execute pending actions. `para_id`"] - pub struct ActionQueued( - pub runtime_types::polkadot_parachain::primitives::Id, - pub ::core::primitive::u32, - ); - impl ::subxt::events::StaticEvent for ActionQueued { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "ActionQueued"; + pub struct SetCommission { + pub pool_id: ::core::primitive::u32, + pub new_commission: ::core::option::Option<( + runtime_types::sp_arithmetic::per_things::Perbill, + ::subxt::utils::AccountId32, + )>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25992,15 +24142,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The given para either initiated or subscribed to a PVF check for the given validation"] - #[doc = "code. `code_hash` `para_id`"] - pub struct PvfCheckStarted( - pub runtime_types::polkadot_parachain::primitives::ValidationCodeHash, - pub runtime_types::polkadot_parachain::primitives::Id, - ); - impl ::subxt::events::StaticEvent for PvfCheckStarted { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "PvfCheckStarted"; + pub struct SetCommissionMax { + pub pool_id: ::core::primitive::u32, + pub max_commission: runtime_types::sp_arithmetic::per_things::Perbill, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -26012,17 +24156,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The given validation code was accepted by the PVF pre-checking vote."] - #[doc = "`code_hash` `para_id`"] - pub struct PvfCheckAccepted( - pub runtime_types::polkadot_parachain::primitives::ValidationCodeHash, - pub runtime_types::polkadot_parachain::primitives::Id, - ); - impl ::subxt::events::StaticEvent for PvfCheckAccepted { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "PvfCheckAccepted"; + pub struct SetCommissionChangeRate { + pub pool_id: ::core::primitive::u32, + pub change_rate: runtime_types::pallet_nomination_pools::CommissionChangeRate< + ::core::primitive::u32, + >, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -26032,920 +24173,631 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The given validation code was rejected by the PVF pre-checking vote."] - #[doc = "`code_hash` `para_id`"] - pub struct PvfCheckRejected( - pub runtime_types::polkadot_parachain::primitives::ValidationCodeHash, - pub runtime_types::polkadot_parachain::primitives::Id, - ); - impl ::subxt::events::StaticEvent for PvfCheckRejected { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "PvfCheckRejected"; + pub struct ClaimCommission { + pub pool_id: ::core::primitive::u32, } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " All currently active PVF pre-checking votes."] + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Stake funds with a pool. The amount to bond is transferred from the member to the"] + #[doc = "pools account and immediately increases the pools bond."] #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - There are no PVF pre-checking votes that exists in list but not in the set and vice versa."] - pub fn pvf_active_vote_map( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain::primitives::ValidationCodeHash, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::PvfCheckActiveVoteState< - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PvfActiveVoteMap", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 84u8, 214u8, 221u8, 221u8, 244u8, 56u8, 135u8, 87u8, 252u8, 39u8, - 188u8, 13u8, 196u8, 25u8, 214u8, 186u8, 152u8, 181u8, 190u8, 39u8, - 235u8, 211u8, 236u8, 114u8, 67u8, 85u8, 138u8, 43u8, 248u8, 134u8, - 124u8, 73u8, - ], - ) - } - #[doc = " All currently active PVF pre-checking votes."] + #[doc = "# Note"] #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - There are no PVF pre-checking votes that exists in list but not in the set and vice versa."] - pub fn pvf_active_vote_map_root( + #[doc = "* An account can only be a member of a single pool."] + #[doc = "* An account cannot join the same pool multiple times."] + #[doc = "* This call will *not* dust the member account, so the member must have at least"] + #[doc = " `existential deposit + amount` in their account."] + #[doc = "* Only a pool with [`PoolState::Open`] can be joined"] + pub fn join( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::PvfCheckActiveVoteState< - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PvfActiveVoteMap", - Vec::new(), + amount: ::core::primitive::u128, + pool_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "join", + Join { amount, pool_id }, [ - 84u8, 214u8, 221u8, 221u8, 244u8, 56u8, 135u8, 87u8, 252u8, 39u8, - 188u8, 13u8, 196u8, 25u8, 214u8, 186u8, 152u8, 181u8, 190u8, 39u8, - 235u8, 211u8, 236u8, 114u8, 67u8, 85u8, 138u8, 43u8, 248u8, 134u8, - 124u8, 73u8, + 205u8, 66u8, 42u8, 72u8, 146u8, 148u8, 119u8, 162u8, 101u8, 183u8, + 46u8, 176u8, 221u8, 204u8, 197u8, 20u8, 75u8, 226u8, 29u8, 118u8, + 208u8, 60u8, 192u8, 247u8, 222u8, 100u8, 69u8, 80u8, 172u8, 13u8, 69u8, + 250u8, ], ) } - #[doc = " The list of all currently active PVF votes. Auxiliary to `PvfActiveVoteMap`."] - pub fn pvf_active_vote_list( + #[doc = "Bond `extra` more funds from `origin` into the pool to which they already belong."] + #[doc = ""] + #[doc = "Additional funds can come from either the free balance of the account, of from the"] + #[doc = "accumulated rewards, see [`BondExtra`]."] + #[doc = ""] + #[doc = "Bonding extra funds implies an automatic payout of all pending rewards as well."] + #[doc = "See `bond_extra_other` to bond pending rewards of `other` members."] + pub fn bond_extra( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + extra: runtime_types::pallet_nomination_pools::BondExtra< + ::core::primitive::u128, >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PvfActiveVoteList", - vec![], + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "bond_extra", + BondExtra { extra }, [ - 196u8, 23u8, 108u8, 162u8, 29u8, 33u8, 49u8, 219u8, 127u8, 26u8, 241u8, - 58u8, 102u8, 43u8, 156u8, 3u8, 87u8, 153u8, 195u8, 96u8, 68u8, 132u8, - 170u8, 162u8, 18u8, 156u8, 121u8, 63u8, 53u8, 91u8, 68u8, 69u8, + 50u8, 72u8, 181u8, 216u8, 249u8, 27u8, 250u8, 177u8, 253u8, 22u8, + 240u8, 100u8, 184u8, 202u8, 197u8, 34u8, 21u8, 188u8, 248u8, 191u8, + 11u8, 10u8, 236u8, 161u8, 168u8, 37u8, 38u8, 238u8, 61u8, 183u8, 86u8, + 55u8, ], ) } - #[doc = " All parachains. Ordered ascending by `ParaId`. Parathreads are not included."] + #[doc = "A bonded member can use this to claim their payout based on the rewards that the pool"] + #[doc = "has accumulated since their last claimed payout (OR since joining if this is their first"] + #[doc = "time claiming rewards). The payout will be transferred to the member's account."] #[doc = ""] - #[doc = " Consider using the [`ParachainsCache`] type of modifying."] - pub fn parachains( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "Parachains", - vec![], + #[doc = "The member will earn rewards pro rata based on the members stake vs the sum of the"] + #[doc = "members in the pools stake. Rewards do not \"expire\"."] + #[doc = ""] + #[doc = "See `claim_payout_other` to caim rewards on bahalf of some `other` pool member."] + pub fn claim_payout(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "claim_payout", + ClaimPayout {}, [ - 85u8, 234u8, 218u8, 69u8, 20u8, 169u8, 235u8, 6u8, 69u8, 126u8, 28u8, - 18u8, 57u8, 93u8, 238u8, 7u8, 167u8, 221u8, 75u8, 35u8, 36u8, 4u8, - 46u8, 55u8, 234u8, 123u8, 122u8, 173u8, 13u8, 205u8, 58u8, 226u8, + 128u8, 58u8, 138u8, 55u8, 64u8, 16u8, 129u8, 25u8, 211u8, 229u8, 193u8, + 115u8, 47u8, 45u8, 155u8, 221u8, 218u8, 1u8, 222u8, 5u8, 236u8, 32u8, + 88u8, 0u8, 198u8, 72u8, 196u8, 181u8, 104u8, 16u8, 212u8, 29u8, ], ) } - #[doc = " The current lifecycle of a all known Para IDs."] - pub fn para_lifecycles( + #[doc = "Unbond up to `unbonding_points` of the `member_account`'s funds from the pool. It"] + #[doc = "implicitly collects the rewards one last time, since not doing so would mean some"] + #[doc = "rewards would be forfeited."] + #[doc = ""] + #[doc = "Under certain conditions, this call can be dispatched permissionlessly (i.e. by any"] + #[doc = "account)."] + #[doc = ""] + #[doc = "# Conditions for a permissionless dispatch."] + #[doc = ""] + #[doc = "* The pool is blocked and the caller is either the root or bouncer. This is refereed to"] + #[doc = " as a kick."] + #[doc = "* The pool is destroying and the member is not the depositor."] + #[doc = "* The pool is destroying, the member is the depositor and no other members are in the"] + #[doc = " pool."] + #[doc = ""] + #[doc = "## Conditions for permissioned dispatch (i.e. the caller is also the"] + #[doc = "`member_account`):"] + #[doc = ""] + #[doc = "* The caller is not the depositor."] + #[doc = "* The caller is the depositor, the pool is destroying and no other members are in the"] + #[doc = " pool."] + #[doc = ""] + #[doc = "# Note"] + #[doc = ""] + #[doc = "If there are too many unlocking chunks to unbond with the pool account,"] + #[doc = "[`Call::pool_withdraw_unbonded`] can be called to try and minimize unlocking chunks."] + #[doc = "The [`StakingInterface::unbond`] will implicitly call [`Call::pool_withdraw_unbonded`]"] + #[doc = "to try to free chunks if necessary (ie. if unbound was called and no unlocking chunks"] + #[doc = "are available). However, it may not be possible to release the current unlocking chunks,"] + #[doc = "in which case, the result of this call will likely be the `NoMoreChunks` error from the"] + #[doc = "staking system."] + pub fn unbond( &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::ParaLifecycle, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "ParaLifecycles", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + unbonding_points: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "unbond", + Unbond { + member_account, + unbonding_points, + }, [ - 221u8, 103u8, 112u8, 222u8, 86u8, 2u8, 172u8, 187u8, 174u8, 106u8, 4u8, - 253u8, 35u8, 73u8, 18u8, 78u8, 25u8, 31u8, 124u8, 110u8, 81u8, 62u8, - 215u8, 228u8, 183u8, 132u8, 138u8, 213u8, 186u8, 209u8, 191u8, 186u8, + 78u8, 15u8, 37u8, 18u8, 129u8, 63u8, 31u8, 3u8, 68u8, 10u8, 12u8, 12u8, + 166u8, 179u8, 38u8, 232u8, 97u8, 1u8, 83u8, 53u8, 26u8, 59u8, 42u8, + 219u8, 176u8, 246u8, 169u8, 28u8, 35u8, 67u8, 139u8, 81u8, ], ) } - #[doc = " The current lifecycle of a all known Para IDs."] - pub fn para_lifecycles_root( + #[doc = "Call `withdraw_unbonded` for the pools account. This call can be made by any account."] + #[doc = ""] + #[doc = "This is useful if their are too many unlocking chunks to call `unbond`, and some"] + #[doc = "can be cleared by withdrawing. In the case there are too many unlocking chunks, the user"] + #[doc = "would probably see an error like `NoMoreChunks` emitted from the staking system when"] + #[doc = "they attempt to unbond."] + pub fn pool_withdraw_unbonded( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::ParaLifecycle, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "ParaLifecycles", - Vec::new(), + pool_id: ::core::primitive::u32, + num_slashing_spans: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "pool_withdraw_unbonded", + PoolWithdrawUnbonded { + pool_id, + num_slashing_spans, + }, [ - 221u8, 103u8, 112u8, 222u8, 86u8, 2u8, 172u8, 187u8, 174u8, 106u8, 4u8, - 253u8, 35u8, 73u8, 18u8, 78u8, 25u8, 31u8, 124u8, 110u8, 81u8, 62u8, - 215u8, 228u8, 183u8, 132u8, 138u8, 213u8, 186u8, 209u8, 191u8, 186u8, + 152u8, 245u8, 131u8, 247u8, 106u8, 214u8, 154u8, 8u8, 7u8, 210u8, + 149u8, 218u8, 118u8, 46u8, 242u8, 182u8, 191u8, 119u8, 28u8, 199u8, + 36u8, 49u8, 219u8, 123u8, 58u8, 203u8, 211u8, 226u8, 217u8, 36u8, 56u8, + 0u8, ], ) } - #[doc = " The head-data of every registered para."] - pub fn heads( + #[doc = "Withdraw unbonded funds from `member_account`. If no bonded funds can be unbonded, an"] + #[doc = "error is returned."] + #[doc = ""] + #[doc = "Under certain conditions, this call can be dispatched permissionlessly (i.e. by any"] + #[doc = "account)."] + #[doc = ""] + #[doc = "# Conditions for a permissionless dispatch"] + #[doc = ""] + #[doc = "* The pool is in destroy mode and the target is not the depositor."] + #[doc = "* The target is the depositor and they are the only member in the sub pools."] + #[doc = "* The pool is blocked and the caller is either the root or bouncer."] + #[doc = ""] + #[doc = "# Conditions for permissioned dispatch"] + #[doc = ""] + #[doc = "* The caller is the target and they are not the depositor."] + #[doc = ""] + #[doc = "# Note"] + #[doc = ""] + #[doc = "If the target is the depositor, the pool will be destroyed."] + pub fn withdraw_unbonded( &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::HeadData, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "Heads", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + num_slashing_spans: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "withdraw_unbonded", + WithdrawUnbonded { + member_account, + num_slashing_spans, + }, [ - 122u8, 38u8, 181u8, 121u8, 245u8, 100u8, 136u8, 233u8, 237u8, 248u8, - 127u8, 2u8, 147u8, 41u8, 202u8, 242u8, 238u8, 70u8, 55u8, 200u8, 15u8, - 106u8, 138u8, 108u8, 192u8, 61u8, 158u8, 134u8, 131u8, 142u8, 70u8, - 3u8, + 61u8, 216u8, 214u8, 166u8, 59u8, 42u8, 186u8, 141u8, 47u8, 50u8, 135u8, + 236u8, 166u8, 88u8, 90u8, 244u8, 57u8, 106u8, 193u8, 211u8, 215u8, + 131u8, 203u8, 33u8, 195u8, 120u8, 213u8, 94u8, 213u8, 66u8, 79u8, + 140u8, ], ) } - #[doc = " The head-data of every registered para."] - pub fn heads_root( + #[doc = "Create a new delegation pool."] + #[doc = ""] + #[doc = "# Arguments"] + #[doc = ""] + #[doc = "* `amount` - The amount of funds to delegate to the pool. This also acts of a sort of"] + #[doc = " deposit since the pools creator cannot fully unbond funds until the pool is being"] + #[doc = " destroyed."] + #[doc = "* `index` - A disambiguation index for creating the account. Likely only useful when"] + #[doc = " creating multiple pools in the same extrinsic."] + #[doc = "* `root` - The account to set as [`PoolRoles::root`]."] + #[doc = "* `nominator` - The account to set as the [`PoolRoles::nominator`]."] + #[doc = "* `bouncer` - The account to set as the [`PoolRoles::bouncer`]."] + #[doc = ""] + #[doc = "# Note"] + #[doc = ""] + #[doc = "In addition to `amount`, the caller will transfer the existential deposit; so the caller"] + #[doc = "needs at have at least `amount + existential_deposit` transferrable."] + pub fn create( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::HeadData, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "Heads", - Vec::new(), + amount: ::core::primitive::u128, + root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "create", + Create { + amount, + root, + nominator, + bouncer, + }, [ - 122u8, 38u8, 181u8, 121u8, 245u8, 100u8, 136u8, 233u8, 237u8, 248u8, - 127u8, 2u8, 147u8, 41u8, 202u8, 242u8, 238u8, 70u8, 55u8, 200u8, 15u8, - 106u8, 138u8, 108u8, 192u8, 61u8, 158u8, 134u8, 131u8, 142u8, 70u8, - 3u8, + 182u8, 114u8, 123u8, 215u8, 240u8, 217u8, 208u8, 165u8, 237u8, 1u8, + 215u8, 183u8, 218u8, 125u8, 71u8, 229u8, 68u8, 142u8, 60u8, 76u8, + 101u8, 242u8, 218u8, 61u8, 165u8, 203u8, 233u8, 241u8, 130u8, 13u8, + 76u8, 214u8, ], ) } - #[doc = " The validation code hash of every live para."] + #[doc = "Create a new delegation pool with a previously used pool id"] #[doc = ""] - #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] - pub fn current_code_hash( + #[doc = "# Arguments"] + #[doc = ""] + #[doc = "same as `create` with the inclusion of"] + #[doc = "* `pool_id` - `A valid PoolId."] + pub fn create_with_pool_id( &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::ValidationCodeHash, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "CurrentCodeHash", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + amount: ::core::primitive::u128, + root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pool_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "create_with_pool_id", + CreateWithPoolId { + amount, + root, + nominator, + bouncer, + pool_id, + }, [ - 179u8, 145u8, 45u8, 44u8, 130u8, 240u8, 50u8, 128u8, 190u8, 133u8, - 66u8, 85u8, 47u8, 141u8, 56u8, 87u8, 131u8, 99u8, 170u8, 203u8, 8u8, - 51u8, 123u8, 73u8, 206u8, 30u8, 173u8, 35u8, 157u8, 195u8, 104u8, - 236u8, + 76u8, 77u8, 158u8, 172u8, 4u8, 68u8, 53u8, 249u8, 156u8, 91u8, 19u8, + 151u8, 58u8, 199u8, 179u8, 0u8, 186u8, 152u8, 157u8, 28u8, 65u8, 227u8, + 133u8, 101u8, 102u8, 205u8, 68u8, 245u8, 104u8, 151u8, 146u8, 76u8, ], ) } - #[doc = " The validation code hash of every live para."] + #[doc = "Nominate on behalf of the pool."] #[doc = ""] - #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] - pub fn current_code_hash_root( + #[doc = "The dispatch origin of this call must be signed by the pool nominator or the pool"] + #[doc = "root role."] + #[doc = ""] + #[doc = "This directly forward the call to the staking pallet, on behalf of the pool bonded"] + #[doc = "account."] + pub fn nominate( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::ValidationCodeHash, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "CurrentCodeHash", - Vec::new(), + pool_id: ::core::primitive::u32, + validators: ::std::vec::Vec<::subxt::utils::AccountId32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "nominate", + Nominate { + pool_id, + validators, + }, [ - 179u8, 145u8, 45u8, 44u8, 130u8, 240u8, 50u8, 128u8, 190u8, 133u8, - 66u8, 85u8, 47u8, 141u8, 56u8, 87u8, 131u8, 99u8, 170u8, 203u8, 8u8, - 51u8, 123u8, 73u8, 206u8, 30u8, 173u8, 35u8, 157u8, 195u8, 104u8, - 236u8, + 10u8, 235u8, 64u8, 157u8, 36u8, 249u8, 186u8, 27u8, 79u8, 172u8, 25u8, + 3u8, 203u8, 19u8, 192u8, 182u8, 36u8, 103u8, 13u8, 20u8, 89u8, 140u8, + 159u8, 4u8, 132u8, 242u8, 192u8, 146u8, 55u8, 251u8, 216u8, 255u8, ], ) } - #[doc = " Actual past code hash, indicated by the para id as well as the block number at which it"] - #[doc = " became outdated."] + #[doc = "Set a new state for the pool."] #[doc = ""] - #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] - pub fn past_code_hash( + #[doc = "If a pool is already in the `Destroying` state, then under no condition can its state"] + #[doc = "change again."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be either:"] + #[doc = ""] + #[doc = "1. signed by the bouncer, or the root role of the pool,"] + #[doc = "2. if the pool conditions to be open are NOT met (as described by `ok_to_be_open`), and"] + #[doc = " then the state of the pool can be permissionlessly changed to `Destroying`."] + pub fn set_state( &self, - _0: impl ::std::borrow::Borrow, - _1: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::ValidationCodeHash, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PastCodeHash", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + pool_id: ::core::primitive::u32, + state: runtime_types::pallet_nomination_pools::PoolState, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_state", + SetState { pool_id, state }, [ - 241u8, 112u8, 128u8, 226u8, 163u8, 193u8, 77u8, 78u8, 177u8, 146u8, - 31u8, 143u8, 44u8, 140u8, 159u8, 134u8, 221u8, 129u8, 36u8, 224u8, - 46u8, 119u8, 245u8, 253u8, 55u8, 22u8, 137u8, 187u8, 71u8, 94u8, 88u8, - 124u8, + 104u8, 40u8, 213u8, 88u8, 159u8, 115u8, 35u8, 249u8, 78u8, 180u8, 99u8, + 1u8, 225u8, 218u8, 192u8, 151u8, 25u8, 194u8, 192u8, 187u8, 39u8, + 170u8, 212u8, 125u8, 75u8, 250u8, 248u8, 175u8, 159u8, 161u8, 151u8, + 162u8, ], ) } - #[doc = " Actual past code hash, indicated by the para id as well as the block number at which it"] - #[doc = " became outdated."] + #[doc = "Set a new metadata for the pool."] #[doc = ""] - #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] - pub fn past_code_hash_root( + #[doc = "The dispatch origin of this call must be signed by the bouncer, or the root role of the"] + #[doc = "pool."] + pub fn set_metadata( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::ValidationCodeHash, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PastCodeHash", - Vec::new(), + pool_id: ::core::primitive::u32, + metadata: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_metadata", + SetMetadata { pool_id, metadata }, [ - 241u8, 112u8, 128u8, 226u8, 163u8, 193u8, 77u8, 78u8, 177u8, 146u8, - 31u8, 143u8, 44u8, 140u8, 159u8, 134u8, 221u8, 129u8, 36u8, 224u8, - 46u8, 119u8, 245u8, 253u8, 55u8, 22u8, 137u8, 187u8, 71u8, 94u8, 88u8, - 124u8, + 156u8, 81u8, 170u8, 161u8, 34u8, 100u8, 183u8, 174u8, 5u8, 81u8, 31u8, + 76u8, 12u8, 42u8, 77u8, 1u8, 6u8, 26u8, 168u8, 7u8, 8u8, 115u8, 158u8, + 151u8, 30u8, 211u8, 52u8, 177u8, 234u8, 87u8, 125u8, 127u8, ], ) } - #[doc = " Past code of parachains. The parachains themselves may not be registered anymore,"] - #[doc = " but we also keep their code on-chain for the same amount of time as outdated code"] - #[doc = " to keep it available for secondary checkers."] - pub fn past_code_meta( + #[doc = "Update configurations for the nomination pools. The origin for this call must be"] + #[doc = "Root."] + #[doc = ""] + #[doc = "# Arguments"] + #[doc = ""] + #[doc = "* `min_join_bond` - Set [`MinJoinBond`]."] + #[doc = "* `min_create_bond` - Set [`MinCreateBond`]."] + #[doc = "* `max_pools` - Set [`MaxPools`]."] + #[doc = "* `max_members` - Set [`MaxPoolMembers`]."] + #[doc = "* `max_members_per_pool` - Set [`MaxPoolMembersPerPool`]."] + #[doc = "* `global_max_commission` - Set [`GlobalMaxCommission`]."] + pub fn set_configs( &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::ParaPastCodeMeta< - ::core::primitive::u32, + min_join_bond: runtime_types::pallet_nomination_pools::ConfigOp< + ::core::primitive::u128, >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PastCodeMeta", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 251u8, 52u8, 126u8, 12u8, 21u8, 178u8, 151u8, 195u8, 153u8, 17u8, - 215u8, 242u8, 118u8, 192u8, 86u8, 72u8, 36u8, 97u8, 245u8, 134u8, - 155u8, 117u8, 85u8, 93u8, 225u8, 209u8, 63u8, 164u8, 168u8, 72u8, - 171u8, 228u8, - ], - ) - } - #[doc = " Past code of parachains. The parachains themselves may not be registered anymore,"] - #[doc = " but we also keep their code on-chain for the same amount of time as outdated code"] - #[doc = " to keep it available for secondary checkers."] - pub fn past_code_meta_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::ParaPastCodeMeta< + min_create_bond: runtime_types::pallet_nomination_pools::ConfigOp< + ::core::primitive::u128, + >, + max_pools: runtime_types::pallet_nomination_pools::ConfigOp< ::core::primitive::u32, >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PastCodeMeta", - Vec::new(), - [ - 251u8, 52u8, 126u8, 12u8, 21u8, 178u8, 151u8, 195u8, 153u8, 17u8, - 215u8, 242u8, 118u8, 192u8, 86u8, 72u8, 36u8, 97u8, 245u8, 134u8, - 155u8, 117u8, 85u8, 93u8, 225u8, 209u8, 63u8, 164u8, 168u8, 72u8, - 171u8, 228u8, - ], - ) - } - #[doc = " Which paras have past code that needs pruning and the relay-chain block at which the code was replaced."] - #[doc = " Note that this is the actual height of the included block, not the expected height at which the"] - #[doc = " code upgrade would be applied, although they may be equal."] - #[doc = " This is to ensure the entire acceptance period is covered, not an offset acceptance period starting"] - #[doc = " from the time at which the parachain perceives a code upgrade as having occurred."] - #[doc = " Multiple entries for a single para are permitted. Ordered ascending by block number."] - pub fn past_code_pruning( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<( - runtime_types::polkadot_parachain::primitives::Id, + max_members: runtime_types::pallet_nomination_pools::ConfigOp< ::core::primitive::u32, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PastCodePruning", - vec![], - [ - 59u8, 26u8, 175u8, 129u8, 174u8, 27u8, 239u8, 77u8, 38u8, 130u8, 37u8, - 134u8, 62u8, 28u8, 218u8, 176u8, 16u8, 137u8, 175u8, 90u8, 248u8, 44u8, - 248u8, 172u8, 231u8, 6u8, 36u8, 190u8, 109u8, 237u8, 228u8, 135u8, - ], - ) - } - #[doc = " The block number at which the planned code change is expected for a para."] - #[doc = " The change will be applied after the first parablock for this ID included which executes"] - #[doc = " in the context of a relay chain block with a number >= `expected_at`."] - pub fn future_code_upgrades( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "FutureCodeUpgrades", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 40u8, 134u8, 185u8, 28u8, 48u8, 105u8, 152u8, 229u8, 166u8, 235u8, - 32u8, 173u8, 64u8, 63u8, 151u8, 157u8, 190u8, 214u8, 7u8, 8u8, 6u8, - 128u8, 21u8, 104u8, 175u8, 71u8, 130u8, 207u8, 158u8, 115u8, 172u8, - 149u8, - ], - ) - } - #[doc = " The block number at which the planned code change is expected for a para."] - #[doc = " The change will be applied after the first parablock for this ID included which executes"] - #[doc = " in the context of a relay chain block with a number >= `expected_at`."] - pub fn future_code_upgrades_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "FutureCodeUpgrades", - Vec::new(), + >, + max_members_per_pool: runtime_types::pallet_nomination_pools::ConfigOp< + ::core::primitive::u32, + >, + global_max_commission: runtime_types::pallet_nomination_pools::ConfigOp< + runtime_types::sp_arithmetic::per_things::Perbill, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_configs", + SetConfigs { + min_join_bond, + min_create_bond, + max_pools, + max_members, + max_members_per_pool, + global_max_commission, + }, [ - 40u8, 134u8, 185u8, 28u8, 48u8, 105u8, 152u8, 229u8, 166u8, 235u8, - 32u8, 173u8, 64u8, 63u8, 151u8, 157u8, 190u8, 214u8, 7u8, 8u8, 6u8, - 128u8, 21u8, 104u8, 175u8, 71u8, 130u8, 207u8, 158u8, 115u8, 172u8, - 149u8, + 20u8, 66u8, 112u8, 172u8, 143u8, 78u8, 60u8, 159u8, 240u8, 102u8, + 245u8, 10u8, 207u8, 27u8, 99u8, 138u8, 217u8, 239u8, 101u8, 190u8, + 222u8, 253u8, 53u8, 77u8, 230u8, 225u8, 101u8, 109u8, 50u8, 144u8, + 31u8, 121u8, ], ) } - #[doc = " The actual future code hash of a para."] + #[doc = "Update the roles of the pool."] #[doc = ""] - #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] - pub fn future_code_hash( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::ValidationCodeHash, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "FutureCodeHash", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 252u8, 24u8, 95u8, 200u8, 207u8, 91u8, 66u8, 103u8, 54u8, 171u8, 191u8, - 187u8, 73u8, 170u8, 132u8, 59u8, 205u8, 125u8, 68u8, 194u8, 122u8, - 124u8, 190u8, 53u8, 241u8, 225u8, 131u8, 53u8, 44u8, 145u8, 244u8, - 216u8, - ], - ) - } - #[doc = " The actual future code hash of a para."] + #[doc = "The root is the only entity that can change any of the roles, including itself,"] + #[doc = "excluding the depositor, who can never change."] #[doc = ""] - #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] - pub fn future_code_hash_root( + #[doc = "It emits an event, notifying UIs of the role change. This event is quite relevant to"] + #[doc = "most pool members and they should be informed of changes to pool roles."] + pub fn update_roles( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::ValidationCodeHash, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "FutureCodeHash", - Vec::new(), + pool_id: ::core::primitive::u32, + new_root: runtime_types::pallet_nomination_pools::ConfigOp< + ::subxt::utils::AccountId32, + >, + new_nominator: runtime_types::pallet_nomination_pools::ConfigOp< + ::subxt::utils::AccountId32, + >, + new_bouncer: runtime_types::pallet_nomination_pools::ConfigOp< + ::subxt::utils::AccountId32, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "update_roles", + UpdateRoles { + pool_id, + new_root, + new_nominator, + new_bouncer, + }, [ - 252u8, 24u8, 95u8, 200u8, 207u8, 91u8, 66u8, 103u8, 54u8, 171u8, 191u8, - 187u8, 73u8, 170u8, 132u8, 59u8, 205u8, 125u8, 68u8, 194u8, 122u8, - 124u8, 190u8, 53u8, 241u8, 225u8, 131u8, 53u8, 44u8, 145u8, 244u8, - 216u8, + 15u8, 154u8, 204u8, 28u8, 204u8, 120u8, 174u8, 203u8, 186u8, 33u8, + 123u8, 201u8, 143u8, 120u8, 193u8, 49u8, 164u8, 178u8, 55u8, 234u8, + 126u8, 247u8, 123u8, 73u8, 147u8, 107u8, 43u8, 72u8, 217u8, 4u8, 199u8, + 253u8, ], ) } - #[doc = " This is used by the relay-chain to communicate to a parachain a go-ahead with in the upgrade procedure."] + #[doc = "Chill on behalf of the pool."] #[doc = ""] - #[doc = " This value is absent when there are no upgrades scheduled or during the time the relay chain"] - #[doc = " performs the checks. It is set at the first relay-chain block when the corresponding parachain"] - #[doc = " can switch its upgrade function. As soon as the parachain's block is included, the value"] - #[doc = " gets reset to `None`."] + #[doc = "The dispatch origin of this call must be signed by the pool nominator or the pool"] + #[doc = "root role, same as [`Pallet::nominate`]."] #[doc = ""] - #[doc = " NOTE that this field is used by parachains via merkle storage proofs, therefore changing"] - #[doc = " the format will require migration of parachains."] - pub fn upgrade_go_ahead_signal( + #[doc = "This directly forward the call to the staking pallet, on behalf of the pool bonded"] + #[doc = "account."] + pub fn chill( &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v2::UpgradeGoAhead, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpgradeGoAheadSignal", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + pool_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "chill", + Chill { pool_id }, [ - 159u8, 47u8, 247u8, 154u8, 54u8, 20u8, 235u8, 49u8, 74u8, 41u8, 65u8, - 51u8, 52u8, 187u8, 242u8, 6u8, 84u8, 144u8, 200u8, 176u8, 222u8, 232u8, - 70u8, 50u8, 70u8, 97u8, 61u8, 249u8, 245u8, 120u8, 98u8, 183u8, + 41u8, 114u8, 128u8, 121u8, 244u8, 15u8, 15u8, 52u8, 129u8, 88u8, 239u8, + 167u8, 216u8, 38u8, 123u8, 240u8, 172u8, 229u8, 132u8, 64u8, 175u8, + 87u8, 217u8, 27u8, 11u8, 124u8, 1u8, 140u8, 40u8, 191u8, 187u8, 36u8, ], ) } - #[doc = " This is used by the relay-chain to communicate to a parachain a go-ahead with in the upgrade procedure."] + #[doc = "`origin` bonds funds from `extra` for some pool member `member` into their respective"] + #[doc = "pools."] #[doc = ""] - #[doc = " This value is absent when there are no upgrades scheduled or during the time the relay chain"] - #[doc = " performs the checks. It is set at the first relay-chain block when the corresponding parachain"] - #[doc = " can switch its upgrade function. As soon as the parachain's block is included, the value"] - #[doc = " gets reset to `None`."] + #[doc = "`origin` can bond extra funds from free balance or pending rewards when `origin =="] + #[doc = "other`."] #[doc = ""] - #[doc = " NOTE that this field is used by parachains via merkle storage proofs, therefore changing"] - #[doc = " the format will require migration of parachains."] - pub fn upgrade_go_ahead_signal_root( + #[doc = "In the case of `origin != other`, `origin` can only bond extra pending rewards of"] + #[doc = "`other` members assuming set_claim_permission for the given member is"] + #[doc = "`PermissionlessAll` or `PermissionlessCompound`."] + pub fn bond_extra_other( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v2::UpgradeGoAhead, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpgradeGoAheadSignal", - Vec::new(), + member: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + extra: runtime_types::pallet_nomination_pools::BondExtra< + ::core::primitive::u128, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "bond_extra_other", + BondExtraOther { member, extra }, [ - 159u8, 47u8, 247u8, 154u8, 54u8, 20u8, 235u8, 49u8, 74u8, 41u8, 65u8, - 51u8, 52u8, 187u8, 242u8, 6u8, 84u8, 144u8, 200u8, 176u8, 222u8, 232u8, - 70u8, 50u8, 70u8, 97u8, 61u8, 249u8, 245u8, 120u8, 98u8, 183u8, + 13u8, 60u8, 161u8, 6u8, 191u8, 248u8, 61u8, 226u8, 192u8, 37u8, 44u8, + 146u8, 250u8, 213u8, 235u8, 147u8, 0u8, 14u8, 147u8, 11u8, 14u8, 126u8, + 70u8, 240u8, 83u8, 26u8, 95u8, 49u8, 52u8, 15u8, 185u8, 162u8, ], ) } - #[doc = " This is used by the relay-chain to communicate that there are restrictions for performing"] - #[doc = " an upgrade for this parachain."] - #[doc = ""] - #[doc = " This may be a because the parachain waits for the upgrade cooldown to expire. Another"] - #[doc = " potential use case is when we want to perform some maintenance (such as storage migration)"] - #[doc = " we could restrict upgrades to make the process simpler."] + #[doc = "Allows a pool member to set a claim permission to allow or disallow permissionless"] + #[doc = "bonding and withdrawing."] #[doc = ""] - #[doc = " NOTE that this field is used by parachains via merkle storage proofs, therefore changing"] - #[doc = " the format will require migration of parachains."] - pub fn upgrade_restriction_signal( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v2::UpgradeRestriction, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpgradeRestrictionSignal", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 86u8, 190u8, 41u8, 79u8, 66u8, 68u8, 46u8, 87u8, 212u8, 176u8, 255u8, - 134u8, 104u8, 121u8, 44u8, 143u8, 248u8, 100u8, 35u8, 157u8, 91u8, - 165u8, 118u8, 38u8, 49u8, 171u8, 158u8, 163u8, 45u8, 92u8, 44u8, 11u8, - ], - ) - } - #[doc = " This is used by the relay-chain to communicate that there are restrictions for performing"] - #[doc = " an upgrade for this parachain."] + #[doc = "By default, this is `Permissioned`, which implies only the pool member themselves can"] + #[doc = "claim their pending rewards. If a pool member wishes so, they can set this to"] + #[doc = "`PermissionlessAll` to allow any account to claim their rewards and bond extra to the"] + #[doc = "pool."] #[doc = ""] - #[doc = " This may be a because the parachain waits for the upgrade cooldown to expire. Another"] - #[doc = " potential use case is when we want to perform some maintenance (such as storage migration)"] - #[doc = " we could restrict upgrades to make the process simpler."] + #[doc = "# Arguments"] #[doc = ""] - #[doc = " NOTE that this field is used by parachains via merkle storage proofs, therefore changing"] - #[doc = " the format will require migration of parachains."] - pub fn upgrade_restriction_signal_root( + #[doc = "* `origin` - Member of a pool."] + #[doc = "* `actor` - Account to claim reward. // improve this"] + pub fn set_claim_permission( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v2::UpgradeRestriction, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpgradeRestrictionSignal", - Vec::new(), + permission: runtime_types::pallet_nomination_pools::ClaimPermission, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_claim_permission", + SetClaimPermission { permission }, [ - 86u8, 190u8, 41u8, 79u8, 66u8, 68u8, 46u8, 87u8, 212u8, 176u8, 255u8, - 134u8, 104u8, 121u8, 44u8, 143u8, 248u8, 100u8, 35u8, 157u8, 91u8, - 165u8, 118u8, 38u8, 49u8, 171u8, 158u8, 163u8, 45u8, 92u8, 44u8, 11u8, + 23u8, 253u8, 135u8, 53u8, 83u8, 71u8, 182u8, 223u8, 123u8, 57u8, 93u8, + 154u8, 110u8, 91u8, 63u8, 241u8, 144u8, 218u8, 129u8, 238u8, 169u8, + 9u8, 215u8, 76u8, 65u8, 168u8, 103u8, 44u8, 40u8, 39u8, 34u8, 16u8, ], ) } - #[doc = " The list of parachains that are awaiting for their upgrade restriction to cooldown."] + #[doc = "`origin` can claim payouts on some pool member `other`'s behalf."] #[doc = ""] - #[doc = " Ordered ascending by block number."] - pub fn upgrade_cooldowns( + #[doc = "Pool member `other` must have a `PermissionlessAll` or `PermissionlessWithdraw` in order"] + #[doc = "for this call to be successful."] + pub fn claim_payout_other( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<( - runtime_types::polkadot_parachain::primitives::Id, - ::core::primitive::u32, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpgradeCooldowns", - vec![], + other: ::subxt::utils::AccountId32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "claim_payout_other", + ClaimPayoutOther { other }, [ - 205u8, 236u8, 140u8, 145u8, 241u8, 245u8, 60u8, 68u8, 23u8, 175u8, - 226u8, 174u8, 154u8, 107u8, 243u8, 197u8, 61u8, 218u8, 7u8, 24u8, - 109u8, 221u8, 178u8, 80u8, 242u8, 123u8, 33u8, 119u8, 5u8, 241u8, - 179u8, 13u8, + 52u8, 165u8, 191u8, 125u8, 180u8, 54u8, 27u8, 235u8, 195u8, 22u8, 55u8, + 183u8, 209u8, 63u8, 116u8, 88u8, 154u8, 74u8, 100u8, 103u8, 88u8, 76u8, + 35u8, 14u8, 39u8, 156u8, 219u8, 253u8, 123u8, 104u8, 168u8, 76u8, ], ) } - #[doc = " The list of upcoming code upgrades. Each item is a pair of which para performs a code"] - #[doc = " upgrade and at which relay-chain block it is expected at."] + #[doc = "Set the commission of a pool."] + #[doc = "Both a commission percentage and a commission payee must be provided in the `current`"] + #[doc = "tuple. Where a `current` of `None` is provided, any current commission will be removed."] #[doc = ""] - #[doc = " Ordered ascending by block number."] - pub fn upcoming_upgrades( + #[doc = "- If a `None` is supplied to `new_commission`, existing commission will be removed."] + pub fn set_commission( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<( - runtime_types::polkadot_parachain::primitives::Id, - ::core::primitive::u32, + pool_id: ::core::primitive::u32, + new_commission: ::core::option::Option<( + runtime_types::sp_arithmetic::per_things::Perbill, + ::subxt::utils::AccountId32, )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpcomingUpgrades", - vec![], - [ - 165u8, 112u8, 215u8, 149u8, 125u8, 175u8, 206u8, 195u8, 214u8, 173u8, - 0u8, 144u8, 46u8, 197u8, 55u8, 204u8, 144u8, 68u8, 158u8, 156u8, 145u8, - 230u8, 173u8, 101u8, 255u8, 108u8, 52u8, 199u8, 142u8, 37u8, 55u8, - 32u8, - ], - ) - } - #[doc = " The actions to perform during the start of a specific session index."] - pub fn actions_queue( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "ActionsQueue", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 209u8, 106u8, 198u8, 228u8, 148u8, 75u8, 246u8, 248u8, 12u8, 143u8, - 175u8, 56u8, 168u8, 243u8, 67u8, 166u8, 59u8, 92u8, 219u8, 184u8, 1u8, - 34u8, 241u8, 66u8, 245u8, 48u8, 174u8, 41u8, 123u8, 16u8, 178u8, 161u8, - ], - ) - } - #[doc = " The actions to perform during the start of a specific session index."] - pub fn actions_queue_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "ActionsQueue", - Vec::new(), + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_commission", + SetCommission { + pool_id, + new_commission, + }, [ - 209u8, 106u8, 198u8, 228u8, 148u8, 75u8, 246u8, 248u8, 12u8, 143u8, - 175u8, 56u8, 168u8, 243u8, 67u8, 166u8, 59u8, 92u8, 219u8, 184u8, 1u8, - 34u8, 241u8, 66u8, 245u8, 48u8, 174u8, 41u8, 123u8, 16u8, 178u8, 161u8, + 118u8, 240u8, 166u8, 40u8, 247u8, 44u8, 23u8, 92u8, 4u8, 78u8, 156u8, + 21u8, 178u8, 97u8, 197u8, 148u8, 61u8, 234u8, 15u8, 94u8, 248u8, 188u8, + 211u8, 13u8, 134u8, 10u8, 75u8, 59u8, 218u8, 13u8, 104u8, 115u8, ], ) } - #[doc = " Upcoming paras instantiation arguments."] + #[doc = "Set the maximum commission of a pool."] #[doc = ""] - #[doc = " NOTE that after PVF pre-checking is enabled the para genesis arg will have it's code set"] - #[doc = " to empty. Instead, the code will be saved into the storage right away via `CodeByHash`."] - pub fn upcoming_paras_genesis( + #[doc = "- Initial max can be set to any `Perbill`, and only smaller values thereafter."] + #[doc = "- Current commission will be lowered in the event it is higher than a new max"] + #[doc = " commission."] + pub fn set_commission_max( &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::ParaGenesisArgs, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpcomingParasGenesis", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + pool_id: ::core::primitive::u32, + max_commission: runtime_types::sp_arithmetic::per_things::Perbill, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_commission_max", + SetCommissionMax { + pool_id, + max_commission, + }, [ - 134u8, 111u8, 59u8, 49u8, 28u8, 111u8, 6u8, 57u8, 109u8, 75u8, 75u8, - 53u8, 91u8, 150u8, 86u8, 38u8, 223u8, 50u8, 107u8, 75u8, 200u8, 61u8, - 211u8, 7u8, 105u8, 251u8, 243u8, 18u8, 220u8, 195u8, 216u8, 167u8, + 115u8, 90u8, 156u8, 35u8, 7u8, 125u8, 184u8, 123u8, 149u8, 232u8, 59u8, + 21u8, 42u8, 120u8, 14u8, 152u8, 184u8, 167u8, 18u8, 22u8, 148u8, 83u8, + 16u8, 81u8, 93u8, 182u8, 154u8, 182u8, 46u8, 40u8, 179u8, 187u8, ], ) } - #[doc = " Upcoming paras instantiation arguments."] + #[doc = "Set the commission change rate for a pool."] #[doc = ""] - #[doc = " NOTE that after PVF pre-checking is enabled the para genesis arg will have it's code set"] - #[doc = " to empty. Instead, the code will be saved into the storage right away via `CodeByHash`."] - pub fn upcoming_paras_genesis_root( + #[doc = "Initial change rate is not bounded, whereas subsequent updates can only be more"] + #[doc = "restrictive than the current."] + pub fn set_commission_change_rate( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::ParaGenesisArgs, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpcomingParasGenesis", - Vec::new(), + pool_id: ::core::primitive::u32, + change_rate: runtime_types::pallet_nomination_pools::CommissionChangeRate< + ::core::primitive::u32, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_commission_change_rate", + SetCommissionChangeRate { + pool_id, + change_rate, + }, [ - 134u8, 111u8, 59u8, 49u8, 28u8, 111u8, 6u8, 57u8, 109u8, 75u8, 75u8, - 53u8, 91u8, 150u8, 86u8, 38u8, 223u8, 50u8, 107u8, 75u8, 200u8, 61u8, - 211u8, 7u8, 105u8, 251u8, 243u8, 18u8, 220u8, 195u8, 216u8, 167u8, + 118u8, 194u8, 114u8, 197u8, 214u8, 246u8, 23u8, 237u8, 10u8, 90u8, + 230u8, 123u8, 172u8, 174u8, 98u8, 198u8, 160u8, 71u8, 113u8, 76u8, + 201u8, 201u8, 153u8, 92u8, 222u8, 252u8, 7u8, 184u8, 236u8, 235u8, + 126u8, 201u8, ], ) } - #[doc = " The number of reference on the validation code in [`CodeByHash`] storage."] - pub fn code_by_hash_refs( + #[doc = "Claim pending commission."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be signed by the `root` role of the pool. Pending"] + #[doc = "commission is paid out and added to total claimed commission`. Total pending commission"] + #[doc = "is reset to zero. the current."] + pub fn claim_commission( &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain::primitives::ValidationCodeHash, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "CodeByHashRefs", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + pool_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "claim_commission", + ClaimCommission { pool_id }, [ - 24u8, 6u8, 23u8, 50u8, 105u8, 203u8, 126u8, 161u8, 0u8, 5u8, 121u8, - 165u8, 204u8, 106u8, 68u8, 91u8, 84u8, 126u8, 29u8, 239u8, 236u8, - 138u8, 32u8, 237u8, 241u8, 226u8, 190u8, 233u8, 160u8, 143u8, 88u8, - 168u8, - ], - ) - } - #[doc = " The number of reference on the validation code in [`CodeByHash`] storage."] - pub fn code_by_hash_refs_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "CodeByHashRefs", - Vec::new(), - [ - 24u8, 6u8, 23u8, 50u8, 105u8, 203u8, 126u8, 161u8, 0u8, 5u8, 121u8, - 165u8, 204u8, 106u8, 68u8, 91u8, 84u8, 126u8, 29u8, 239u8, 236u8, - 138u8, 32u8, 237u8, 241u8, 226u8, 190u8, 233u8, 160u8, 143u8, 88u8, - 168u8, - ], - ) - } - #[doc = " Validation code stored by its hash."] - #[doc = ""] - #[doc = " This storage is consistent with [`FutureCodeHash`], [`CurrentCodeHash`] and"] - #[doc = " [`PastCodeHash`]."] - pub fn code_by_hash( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain::primitives::ValidationCodeHash, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::ValidationCode, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "CodeByHash", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 58u8, 104u8, 36u8, 34u8, 226u8, 210u8, 253u8, 90u8, 23u8, 3u8, 6u8, - 202u8, 9u8, 44u8, 107u8, 108u8, 41u8, 149u8, 255u8, 173u8, 119u8, - 206u8, 201u8, 180u8, 32u8, 193u8, 44u8, 232u8, 73u8, 15u8, 210u8, - 226u8, - ], - ) - } - #[doc = " Validation code stored by its hash."] - #[doc = ""] - #[doc = " This storage is consistent with [`FutureCodeHash`], [`CurrentCodeHash`] and"] - #[doc = " [`PastCodeHash`]."] - pub fn code_by_hash_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::ValidationCode, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "CodeByHash", - Vec::new(), - [ - 58u8, 104u8, 36u8, 34u8, 226u8, 210u8, 253u8, 90u8, 23u8, 3u8, 6u8, - 202u8, 9u8, 44u8, 107u8, 108u8, 41u8, 149u8, 255u8, 173u8, 119u8, - 206u8, 201u8, 180u8, 32u8, 193u8, 44u8, 232u8, 73u8, 15u8, 210u8, - 226u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - pub fn unsigned_priority( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "Paras", - "UnsignedPriority", - [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, + 139u8, 126u8, 219u8, 117u8, 140u8, 51u8, 163u8, 32u8, 83u8, 60u8, + 250u8, 44u8, 186u8, 194u8, 225u8, 84u8, 61u8, 181u8, 212u8, 160u8, + 156u8, 93u8, 16u8, 255u8, 165u8, 178u8, 25u8, 64u8, 187u8, 29u8, 169u8, + 174u8, ], ) } } } - } - pub mod initializer { - use super::root_mod; - use super::runtime_types; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; + #[doc = "Events of this pallet."] + pub type Event = runtime_types::pallet_nomination_pools::pallet::Event; + pub mod events { use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -26955,226 +24807,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceApprove { - pub up_to: ::core::primitive::u32, - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Issue a signal to the consensus engine to forcibly act as though all parachain"] - #[doc = "blocks in all relay chain blocks up to and including the given number in the current"] - #[doc = "chain are valid and should be finalized."] - pub fn force_approve( - &self, - up_to: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Initializer", - "force_approve", - ForceApprove { up_to }, - [ - 28u8, 117u8, 86u8, 182u8, 19u8, 127u8, 43u8, 17u8, 153u8, 80u8, 193u8, - 53u8, 120u8, 41u8, 205u8, 23u8, 252u8, 148u8, 77u8, 227u8, 138u8, 35u8, - 182u8, 122u8, 112u8, 232u8, 246u8, 69u8, 173u8, 97u8, 42u8, 103u8, - ], - ) - } - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Whether the parachains modules have been initialized within this block."] - #[doc = ""] - #[doc = " Semantically a `bool`, but this guarantees it should never hit the trie,"] - #[doc = " as this is cleared in `on_finalize` and Frame optimizes `None` values to be empty values."] - #[doc = ""] - #[doc = " As a `bool`, `set(false)` and `remove()` both lead to the next `get()` being false, but one of"] - #[doc = " them writes to the trie and one does not. This confusion makes `Option<()>` more suitable for"] - #[doc = " the semantics of this variable."] - pub fn has_initialized( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Initializer", - "HasInitialized", - vec![], - [ - 251u8, 135u8, 247u8, 61u8, 139u8, 102u8, 12u8, 122u8, 227u8, 123u8, - 11u8, 232u8, 120u8, 80u8, 81u8, 48u8, 216u8, 115u8, 159u8, 131u8, - 133u8, 105u8, 200u8, 122u8, 114u8, 6u8, 109u8, 4u8, 164u8, 204u8, - 214u8, 111u8, - ], - ) - } - #[doc = " Buffered session changes along with the block number at which they should be applied."] - #[doc = ""] - #[doc = " Typically this will be empty or one element long. Apart from that this item never hits"] - #[doc = " the storage."] - #[doc = ""] - #[doc = " However this is a `Vec` regardless to handle various edge cases that may occur at runtime"] - #[doc = " upgrade boundaries or if governance intervenes."] pub fn buffered_session_changes (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , :: std :: vec :: Vec < runtime_types :: polkadot_runtime_parachains :: initializer :: BufferedSessionChange > , :: subxt :: storage :: address :: Yes , :: subxt :: storage :: address :: Yes , () >{ - ::subxt::storage::address::Address::new_static( - "Initializer", - "BufferedSessionChanges", - vec![], - [ - 176u8, 60u8, 165u8, 138u8, 99u8, 140u8, 22u8, 169u8, 121u8, 65u8, - 203u8, 85u8, 39u8, 198u8, 91u8, 167u8, 118u8, 49u8, 129u8, 128u8, - 171u8, 232u8, 249u8, 39u8, 6u8, 101u8, 57u8, 193u8, 85u8, 143u8, 105u8, - 29u8, - ], - ) - } + #[doc = "A pool has been created."] + pub struct Created { + pub depositor: ::subxt::utils::AccountId32, + pub pool_id: ::core::primitive::u32, } - } - } - pub mod dmp { - use super::root_mod; - use super::runtime_types; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub struct TransactionApi; - impl TransactionApi {} - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The downward messages addressed for a certain para."] - pub fn downward_message_queues( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundDownwardMessage< - ::core::primitive::u32, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Dmp", - "DownwardMessageQueues", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 57u8, 115u8, 112u8, 195u8, 25u8, 43u8, 104u8, 199u8, 107u8, 238u8, - 93u8, 129u8, 141u8, 167u8, 167u8, 9u8, 85u8, 34u8, 53u8, 117u8, 148u8, - 246u8, 196u8, 46u8, 96u8, 114u8, 15u8, 88u8, 94u8, 40u8, 18u8, 31u8, - ], - ) - } - #[doc = " The downward messages addressed for a certain para."] - pub fn downward_message_queues_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundDownwardMessage< - ::core::primitive::u32, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Dmp", - "DownwardMessageQueues", - Vec::new(), - [ - 57u8, 115u8, 112u8, 195u8, 25u8, 43u8, 104u8, 199u8, 107u8, 238u8, - 93u8, 129u8, 141u8, 167u8, 167u8, 9u8, 85u8, 34u8, 53u8, 117u8, 148u8, - 246u8, 196u8, 46u8, 96u8, 114u8, 15u8, 88u8, 94u8, 40u8, 18u8, 31u8, - ], - ) - } - #[doc = " A mapping that stores the downward message queue MQC head for each para."] - #[doc = ""] - #[doc = " Each link in this chain has a form:"] - #[doc = " `(prev_head, B, H(M))`, where"] - #[doc = " - `prev_head`: is the previous head hash or zero if none."] - #[doc = " - `B`: is the relay-chain block number in which a message was appended."] - #[doc = " - `H(M)`: is the hash of the message being appended."] - pub fn downward_message_queue_heads( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Dmp", - "DownwardMessageQueueHeads", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 137u8, 70u8, 108u8, 184u8, 177u8, 204u8, 17u8, 187u8, 250u8, 134u8, - 85u8, 18u8, 239u8, 185u8, 167u8, 224u8, 70u8, 18u8, 38u8, 245u8, 176u8, - 122u8, 254u8, 251u8, 204u8, 126u8, 34u8, 207u8, 163u8, 104u8, 103u8, - 38u8, - ], - ) - } - #[doc = " A mapping that stores the downward message queue MQC head for each para."] - #[doc = ""] - #[doc = " Each link in this chain has a form:"] - #[doc = " `(prev_head, B, H(M))`, where"] - #[doc = " - `prev_head`: is the previous head hash or zero if none."] - #[doc = " - `B`: is the relay-chain block number in which a message was appended."] - #[doc = " - `H(M)`: is the hash of the message being appended."] - pub fn downward_message_queue_heads_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Dmp", - "DownwardMessageQueueHeads", - Vec::new(), - [ - 137u8, 70u8, 108u8, 184u8, 177u8, 204u8, 17u8, 187u8, 250u8, 134u8, - 85u8, 18u8, 239u8, 185u8, 167u8, 224u8, 70u8, 18u8, 38u8, 245u8, 176u8, - 122u8, 254u8, 251u8, 204u8, 126u8, 34u8, 207u8, 163u8, 104u8, 103u8, - 38u8, - ], - ) - } + impl ::subxt::events::StaticEvent for Created { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "Created"; } - } - } - pub mod ump { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_parachains::ump::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -27185,50 +24826,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ServiceOverweight { - pub index: ::core::primitive::u64, - pub weight_limit: runtime_types::sp_weights::weight_v2::Weight, + #[doc = "A member has became bonded in a pool."] + pub struct Bonded { + pub member: ::subxt::utils::AccountId32, + pub pool_id: ::core::primitive::u32, + pub bonded: ::core::primitive::u128, + pub joined: ::core::primitive::bool, } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Service a single overweight upward message."] - #[doc = ""] - #[doc = "- `origin`: Must pass `ExecuteOverweightOrigin`."] - #[doc = "- `index`: The index of the overweight message to service."] - #[doc = "- `weight_limit`: The amount of weight that message execution may take."] - #[doc = ""] - #[doc = "Errors:"] - #[doc = "- `UnknownMessageIndex`: Message of `index` is unknown."] - #[doc = "- `WeightOverLimit`: Message execution may use greater than `weight_limit`."] - #[doc = ""] - #[doc = "Events:"] - #[doc = "- `OverweightServiced`: On success."] - pub fn service_overweight( - &self, - index: ::core::primitive::u64, - weight_limit: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Ump", - "service_overweight", - ServiceOverweight { - index, - weight_limit, - }, - [ - 121u8, 236u8, 235u8, 23u8, 210u8, 238u8, 238u8, 122u8, 15u8, 86u8, - 34u8, 119u8, 105u8, 100u8, 214u8, 236u8, 117u8, 39u8, 254u8, 235u8, - 189u8, 15u8, 72u8, 74u8, 225u8, 134u8, 148u8, 126u8, 31u8, 203u8, - 144u8, 106u8, - ], - ) - } + impl ::subxt::events::StaticEvent for Bonded { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "Bonded"; } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::polkadot_runtime_parachains::ump::pallet::Event; - pub mod events { - use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -27239,12 +24847,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Upward message is invalid XCM."] - #[doc = "\\[ id \\]"] - pub struct InvalidFormat(pub [::core::primitive::u8; 32usize]); - impl ::subxt::events::StaticEvent for InvalidFormat { - const PALLET: &'static str = "Ump"; - const EVENT: &'static str = "InvalidFormat"; + #[doc = "A payout has been made to a member."] + pub struct PaidOut { + pub member: ::subxt::utils::AccountId32, + pub pool_id: ::core::primitive::u32, + pub payout: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for PaidOut { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "PaidOut"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -27256,12 +24867,27 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Upward message is unsupported version of XCM."] - #[doc = "\\[ id \\]"] - pub struct UnsupportedVersion(pub [::core::primitive::u8; 32usize]); - impl ::subxt::events::StaticEvent for UnsupportedVersion { - const PALLET: &'static str = "Ump"; - const EVENT: &'static str = "UnsupportedVersion"; + #[doc = "A member has unbonded from their pool."] + #[doc = ""] + #[doc = "- `balance` is the corresponding balance of the number of points that has been"] + #[doc = " requested to be unbonded (the argument of the `unbond` transaction) from the bonded"] + #[doc = " pool."] + #[doc = "- `points` is the number of points that are issued as a result of `balance` being"] + #[doc = "dissolved into the corresponding unbonding pool."] + #[doc = "- `era` is the era in which the balance will be unbonded."] + #[doc = "In the absence of slashing, these values will match. In the presence of slashing, the"] + #[doc = "number of points that are issued in the unbonding pool will be less than the amount"] + #[doc = "requested to be unbonded."] + pub struct Unbonded { + pub member: ::subxt::utils::AccountId32, + pub pool_id: ::core::primitive::u32, + pub balance: ::core::primitive::u128, + pub points: ::core::primitive::u128, + pub era: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Unbonded { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "Unbonded"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -27273,17 +24899,24 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Upward message executed with the given outcome."] - #[doc = "\\[ id, outcome \\]"] - pub struct ExecutedUpward( - pub [::core::primitive::u8; 32usize], - pub runtime_types::xcm::v2::traits::Outcome, - ); - impl ::subxt::events::StaticEvent for ExecutedUpward { - const PALLET: &'static str = "Ump"; - const EVENT: &'static str = "ExecutedUpward"; + #[doc = "A member has withdrawn from their pool."] + #[doc = ""] + #[doc = "The given number of `points` have been dissolved in return of `balance`."] + #[doc = ""] + #[doc = "Similar to `Unbonded` event, in the absence of slashing, the ratio of point to balance"] + #[doc = "will be 1."] + pub struct Withdrawn { + pub member: ::subxt::utils::AccountId32, + pub pool_id: ::core::primitive::u32, + pub balance: ::core::primitive::u128, + pub points: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Withdrawn { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "Withdrawn"; } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -27293,16 +24926,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The weight limit for handling upward messages was reached."] - #[doc = "\\[ id, remaining, required \\]"] - pub struct WeightExhausted( - pub [::core::primitive::u8; 32usize], - pub runtime_types::sp_weights::weight_v2::Weight, - pub runtime_types::sp_weights::weight_v2::Weight, - ); - impl ::subxt::events::StaticEvent for WeightExhausted { - const PALLET: &'static str = "Ump"; - const EVENT: &'static str = "WeightExhausted"; + #[doc = "A pool has been destroyed."] + pub struct Destroyed { + pub pool_id: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Destroyed { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "Destroyed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -27314,16 +24944,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some upward messages have been received and will be processed."] - #[doc = "\\[ para, count, size \\]"] - pub struct UpwardMessagesReceived( - pub runtime_types::polkadot_parachain::primitives::Id, - pub ::core::primitive::u32, - pub ::core::primitive::u32, - ); - impl ::subxt::events::StaticEvent for UpwardMessagesReceived { - const PALLET: &'static str = "Ump"; - const EVENT: &'static str = "UpwardMessagesReceived"; + #[doc = "The state of a pool has changed"] + pub struct StateChanged { + pub pool_id: ::core::primitive::u32, + pub new_state: runtime_types::pallet_nomination_pools::PoolState, + } + impl ::subxt::events::StaticEvent for StateChanged { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "StateChanged"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -27335,21 +24963,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The weight budget was exceeded for an individual upward message."] - #[doc = ""] - #[doc = "This message can be later dispatched manually using `service_overweight` dispatchable"] - #[doc = "using the assigned `overweight_index`."] + #[doc = "A member has been removed from a pool."] #[doc = ""] - #[doc = "\\[ para, id, overweight_index, required \\]"] - pub struct OverweightEnqueued( - pub runtime_types::polkadot_parachain::primitives::Id, - pub [::core::primitive::u8; 32usize], - pub ::core::primitive::u64, - pub runtime_types::sp_weights::weight_v2::Weight, - ); - impl ::subxt::events::StaticEvent for OverweightEnqueued { - const PALLET: &'static str = "Ump"; - const EVENT: &'static str = "OverweightEnqueued"; + #[doc = "The removal can be voluntary (withdrawn all unbonded funds) or involuntary (kicked)."] + pub struct MemberRemoved { + pub pool_id: ::core::primitive::u32, + pub member: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for MemberRemoved { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "MemberRemoved"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -27361,300 +24984,850 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Upward message from the overweight queue was executed with the given actual weight"] - #[doc = "used."] - #[doc = ""] - #[doc = "\\[ overweight_index, used \\]"] - pub struct OverweightServiced( - pub ::core::primitive::u64, - pub runtime_types::sp_weights::weight_v2::Weight, - ); - impl ::subxt::events::StaticEvent for OverweightServiced { - const PALLET: &'static str = "Ump"; - const EVENT: &'static str = "OverweightServiced"; + #[doc = "The roles of a pool have been updated to the given new roles. Note that the depositor"] + #[doc = "can never change."] + pub struct RolesUpdated { + pub root: ::core::option::Option<::subxt::utils::AccountId32>, + pub bouncer: ::core::option::Option<::subxt::utils::AccountId32>, + pub nominator: ::core::option::Option<::subxt::utils::AccountId32>, } - } - pub mod storage { + impl ::subxt::events::StaticEvent for RolesUpdated { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "RolesUpdated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The active balance of pool `pool_id` has been slashed to `balance`."] + pub struct PoolSlashed { + pub pool_id: ::core::primitive::u32, + pub balance: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for PoolSlashed { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "PoolSlashed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The unbond pool at `era` of pool `pool_id` has been slashed to `balance`."] + pub struct UnbondingPoolSlashed { + pub pool_id: ::core::primitive::u32, + pub era: ::core::primitive::u32, + pub balance: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for UnbondingPoolSlashed { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "UnbondingPoolSlashed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A pool's commission setting has been changed."] + pub struct PoolCommissionUpdated { + pub pool_id: ::core::primitive::u32, + pub current: ::core::option::Option<( + runtime_types::sp_arithmetic::per_things::Perbill, + ::subxt::utils::AccountId32, + )>, + } + impl ::subxt::events::StaticEvent for PoolCommissionUpdated { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "PoolCommissionUpdated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A pool's maximum commission setting has been changed."] + pub struct PoolMaxCommissionUpdated { + pub pool_id: ::core::primitive::u32, + pub max_commission: runtime_types::sp_arithmetic::per_things::Perbill, + } + impl ::subxt::events::StaticEvent for PoolMaxCommissionUpdated { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "PoolMaxCommissionUpdated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A pool's commission `change_rate` has been changed."] + pub struct PoolCommissionChangeRateUpdated { + pub pool_id: ::core::primitive::u32, + pub change_rate: runtime_types::pallet_nomination_pools::CommissionChangeRate< + ::core::primitive::u32, + >, + } + impl ::subxt::events::StaticEvent for PoolCommissionChangeRateUpdated { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "PoolCommissionChangeRateUpdated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Pool commission has been claimed."] + pub struct PoolCommissionClaimed { + pub pool_id: ::core::primitive::u32, + pub commission: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for PoolCommissionClaimed { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "PoolCommissionClaimed"; + } + } + pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " The messages waiting to be handled by the relay-chain originating from a certain parachain."] + #[doc = " Minimum amount to bond to join a pool."] + pub fn min_join_bond( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "MinJoinBond", + vec![], + [ + 125u8, 239u8, 45u8, 225u8, 74u8, 129u8, 247u8, 184u8, 205u8, 58u8, + 45u8, 186u8, 126u8, 170u8, 112u8, 120u8, 23u8, 190u8, 247u8, 97u8, + 131u8, 126u8, 215u8, 44u8, 147u8, 122u8, 132u8, 212u8, 217u8, 84u8, + 240u8, 91u8, + ], + ) + } + #[doc = " Minimum bond required to create a pool."] #[doc = ""] - #[doc = " Note that some upward messages might have been already processed by the inclusion logic. E.g."] - #[doc = " channel management messages."] + #[doc = " This is the amount that the depositor must put as their initial stake in the pool, as an"] + #[doc = " indication of \"skin in the game\"."] #[doc = ""] - #[doc = " The messages are processed in FIFO order."] - pub fn relay_dispatch_queues( + #[doc = " This is the value that will always exist in the staking ledger of the pool bonded account"] + #[doc = " while all other accounts leave."] + pub fn min_create_bond( &self, - _0: impl ::std::borrow::Borrow, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + ::core::primitive::u128, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "MinCreateBond", + vec![], + [ + 31u8, 208u8, 240u8, 158u8, 23u8, 218u8, 212u8, 138u8, 92u8, 210u8, + 207u8, 170u8, 32u8, 60u8, 5u8, 21u8, 84u8, 162u8, 1u8, 111u8, 181u8, + 243u8, 24u8, 148u8, 193u8, 253u8, 248u8, 190u8, 16u8, 222u8, 219u8, + 67u8, + ], + ) + } + #[doc = " Maximum number of nomination pools that can exist. If `None`, then an unbounded number of"] + #[doc = " pools can exist."] + pub fn max_pools( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "MaxPools", + vec![], + [ + 216u8, 111u8, 68u8, 103u8, 33u8, 50u8, 109u8, 3u8, 176u8, 195u8, 23u8, + 73u8, 112u8, 138u8, 9u8, 194u8, 233u8, 73u8, 68u8, 215u8, 162u8, 255u8, + 217u8, 173u8, 141u8, 27u8, 72u8, 199u8, 7u8, 240u8, 25u8, 34u8, + ], + ) + } + #[doc = " Maximum number of members that can exist in the system. If `None`, then the count"] + #[doc = " members are not bound on a system wide basis."] + pub fn max_pool_members( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, ::subxt::storage::address::Yes, + (), + (), > { ::subxt::storage::address::Address::new_static( - "Ump", - "RelayDispatchQueues", + "NominationPools", + "MaxPoolMembers", + vec![], + [ + 82u8, 217u8, 26u8, 234u8, 223u8, 241u8, 66u8, 182u8, 43u8, 233u8, 59u8, + 242u8, 202u8, 254u8, 69u8, 50u8, 254u8, 196u8, 166u8, 89u8, 120u8, + 87u8, 76u8, 148u8, 31u8, 197u8, 49u8, 88u8, 206u8, 41u8, 242u8, 62u8, + ], + ) + } + #[doc = " Maximum number of members that may belong to pool. If `None`, then the count of"] + #[doc = " members is not bound on a per pool basis."] + pub fn max_pool_members_per_pool( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "MaxPoolMembersPerPool", + vec![], + [ + 93u8, 241u8, 16u8, 169u8, 138u8, 199u8, 128u8, 149u8, 65u8, 30u8, 55u8, + 11u8, 41u8, 252u8, 83u8, 250u8, 9u8, 33u8, 152u8, 239u8, 195u8, 147u8, + 16u8, 248u8, 180u8, 153u8, 88u8, 231u8, 248u8, 169u8, 186u8, 48u8, + ], + ) + } + #[doc = " The maximum commission that can be charged by a pool. Used on commission payouts to bound"] + #[doc = " pool commissions that are > `GlobalMaxCommission`, necessary if a future"] + #[doc = " `GlobalMaxCommission` is lower than some current pool commissions."] + pub fn global_max_commission( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_arithmetic::per_things::Perbill, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "GlobalMaxCommission", + vec![], + [ + 142u8, 252u8, 92u8, 128u8, 162u8, 4u8, 216u8, 39u8, 118u8, 201u8, + 138u8, 171u8, 76u8, 90u8, 133u8, 176u8, 161u8, 138u8, 214u8, 183u8, + 193u8, 115u8, 245u8, 151u8, 216u8, 84u8, 99u8, 175u8, 144u8, 196u8, + 103u8, 190u8, + ], + ) + } + #[doc = " Active members."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn pool_members( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::PoolMember, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "PoolMembers", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 237u8, 72u8, 167u8, 6u8, 67u8, 106u8, 186u8, 191u8, 160u8, 9u8, 62u8, - 102u8, 229u8, 164u8, 100u8, 24u8, 202u8, 109u8, 90u8, 24u8, 192u8, - 233u8, 26u8, 239u8, 23u8, 127u8, 77u8, 191u8, 144u8, 14u8, 3u8, 141u8, + 252u8, 236u8, 201u8, 127u8, 219u8, 1u8, 19u8, 144u8, 5u8, 108u8, 70u8, + 30u8, 177u8, 232u8, 253u8, 237u8, 211u8, 91u8, 63u8, 62u8, 155u8, + 151u8, 153u8, 165u8, 206u8, 53u8, 111u8, 31u8, 60u8, 120u8, 100u8, + 249u8, ], ) } - #[doc = " The messages waiting to be handled by the relay-chain originating from a certain parachain."] - #[doc = ""] - #[doc = " Note that some upward messages might have been already processed by the inclusion logic. E.g."] - #[doc = " channel management messages."] + #[doc = " Active members."] #[doc = ""] - #[doc = " The messages are processed in FIFO order."] - pub fn relay_dispatch_queues_root( + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn pool_members_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + runtime_types::pallet_nomination_pools::PoolMember, + (), (), - ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Ump", - "RelayDispatchQueues", + "NominationPools", + "PoolMembers", Vec::new(), [ - 237u8, 72u8, 167u8, 6u8, 67u8, 106u8, 186u8, 191u8, 160u8, 9u8, 62u8, - 102u8, 229u8, 164u8, 100u8, 24u8, 202u8, 109u8, 90u8, 24u8, 192u8, - 233u8, 26u8, 239u8, 23u8, 127u8, 77u8, 191u8, 144u8, 14u8, 3u8, 141u8, + 252u8, 236u8, 201u8, 127u8, 219u8, 1u8, 19u8, 144u8, 5u8, 108u8, 70u8, + 30u8, 177u8, 232u8, 253u8, 237u8, 211u8, 91u8, 63u8, 62u8, 155u8, + 151u8, 153u8, 165u8, 206u8, 53u8, 111u8, 31u8, 60u8, 120u8, 100u8, + 249u8, ], ) } - #[doc = " Size of the dispatch queues. Caches sizes of the queues in `RelayDispatchQueue`."] - #[doc = ""] - #[doc = " First item in the tuple is the count of messages and second"] - #[doc = " is the total length (in bytes) of the message payloads."] - #[doc = ""] - #[doc = " Note that this is an auxiliary mapping: it's possible to tell the byte size and the number of"] - #[doc = " messages only looking at `RelayDispatchQueues`. This mapping is separate to avoid the cost of"] - #[doc = " loading the whole message queue if only the total size and count are required."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - The set of keys should exactly match the set of keys of `RelayDispatchQueues`."] - pub fn relay_dispatch_queue_size( + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_pool_members( &self, - _0: impl ::std::borrow::Borrow, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), + ::core::primitive::u32, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "CounterForPoolMembers", + vec![], + [ + 114u8, 126u8, 27u8, 138u8, 119u8, 44u8, 45u8, 129u8, 84u8, 107u8, + 171u8, 206u8, 117u8, 141u8, 20u8, 75u8, 229u8, 237u8, 31u8, 229u8, + 124u8, 190u8, 27u8, 124u8, 63u8, 59u8, 167u8, 42u8, 62u8, 212u8, 160u8, + 2u8, + ], + ) + } + #[doc = " Storage for bonded pools."] + pub fn bonded_pools( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::BondedPoolInner, + ::subxt::storage::address::Yes, + (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Ump", - "RelayDispatchQueueSize", + "NominationPools", + "BondedPools", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 243u8, 120u8, 70u8, 2u8, 208u8, 105u8, 180u8, 25u8, 86u8, 219u8, 151u8, - 227u8, 233u8, 53u8, 151u8, 29u8, 231u8, 40u8, 84u8, 163u8, 71u8, 254u8, - 19u8, 47u8, 174u8, 63u8, 200u8, 173u8, 86u8, 199u8, 207u8, 138u8, + 3u8, 183u8, 140u8, 154u8, 74u8, 225u8, 69u8, 243u8, 150u8, 132u8, + 163u8, 26u8, 101u8, 45u8, 231u8, 178u8, 85u8, 144u8, 9u8, 112u8, 212u8, + 167u8, 131u8, 188u8, 203u8, 50u8, 177u8, 218u8, 154u8, 182u8, 80u8, + 232u8, ], ) } - #[doc = " Size of the dispatch queues. Caches sizes of the queues in `RelayDispatchQueue`."] - #[doc = ""] - #[doc = " First item in the tuple is the count of messages and second"] - #[doc = " is the total length (in bytes) of the message payloads."] - #[doc = ""] - #[doc = " Note that this is an auxiliary mapping: it's possible to tell the byte size and the number of"] - #[doc = " messages only looking at `RelayDispatchQueues`. This mapping is separate to avoid the cost of"] - #[doc = " loading the whole message queue if only the total size and count are required."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - The set of keys should exactly match the set of keys of `RelayDispatchQueues`."] - pub fn relay_dispatch_queue_size_root( + #[doc = " Storage for bonded pools."] + pub fn bonded_pools_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), + runtime_types::pallet_nomination_pools::BondedPoolInner, + (), (), - ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Ump", - "RelayDispatchQueueSize", + "NominationPools", + "BondedPools", Vec::new(), [ - 243u8, 120u8, 70u8, 2u8, 208u8, 105u8, 180u8, 25u8, 86u8, 219u8, 151u8, - 227u8, 233u8, 53u8, 151u8, 29u8, 231u8, 40u8, 84u8, 163u8, 71u8, 254u8, - 19u8, 47u8, 174u8, 63u8, 200u8, 173u8, 86u8, 199u8, 207u8, 138u8, + 3u8, 183u8, 140u8, 154u8, 74u8, 225u8, 69u8, 243u8, 150u8, 132u8, + 163u8, 26u8, 101u8, 45u8, 231u8, 178u8, 85u8, 144u8, 9u8, 112u8, 212u8, + 167u8, 131u8, 188u8, 203u8, 50u8, 177u8, 218u8, 154u8, 182u8, 80u8, + 232u8, ], ) } - #[doc = " The ordered list of `ParaId`s that have a `RelayDispatchQueue` entry."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - The set of items from this vector should be exactly the set of the keys in"] - #[doc = " `RelayDispatchQueues` and `RelayDispatchQueueSize`."] - pub fn needs_dispatch( + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_bonded_pools( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, + ::core::primitive::u32, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "Ump", - "NeedsDispatch", + "NominationPools", + "CounterForBondedPools", vec![], [ - 176u8, 94u8, 152u8, 112u8, 46u8, 124u8, 89u8, 29u8, 92u8, 104u8, 192u8, - 58u8, 59u8, 186u8, 81u8, 150u8, 157u8, 61u8, 235u8, 182u8, 222u8, - 127u8, 109u8, 11u8, 104u8, 175u8, 141u8, 219u8, 15u8, 152u8, 255u8, - 40u8, + 134u8, 94u8, 199u8, 73u8, 174u8, 253u8, 66u8, 242u8, 233u8, 244u8, + 140u8, 170u8, 242u8, 40u8, 41u8, 185u8, 183u8, 151u8, 58u8, 111u8, + 221u8, 225u8, 81u8, 71u8, 169u8, 219u8, 223u8, 135u8, 8u8, 171u8, + 180u8, 236u8, ], ) } - #[doc = " This is the para that gets will get dispatched first during the next upward dispatchable queue"] - #[doc = " execution round."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - If `Some(para)`, then `para` must be present in `NeedsDispatch`."] - pub fn next_dispatch_round_start_with( + #[doc = " Reward pools. This is where there rewards for each pool accumulate. When a members payout is"] + #[doc = " claimed, the balance comes out fo the reward pool. Keyed by the bonded pools account."] + pub fn reward_pools( &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::Id, + runtime_types::pallet_nomination_pools::RewardPool, + ::subxt::storage::address::Yes, + (), ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "RewardPools", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 235u8, 6u8, 2u8, 103u8, 137u8, 31u8, 109u8, 165u8, 129u8, 48u8, 154u8, + 219u8, 110u8, 198u8, 241u8, 31u8, 174u8, 10u8, 92u8, 233u8, 161u8, + 76u8, 53u8, 136u8, 172u8, 214u8, 192u8, 12u8, 239u8, 165u8, 195u8, + 96u8, + ], + ) + } + #[doc = " Reward pools. This is where there rewards for each pool accumulate. When a members payout is"] + #[doc = " claimed, the balance comes out fo the reward pool. Keyed by the bonded pools account."] + pub fn reward_pools_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::RewardPool, (), (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Ump", - "NextDispatchRoundStartWith", + "NominationPools", + "RewardPools", + Vec::new(), + [ + 235u8, 6u8, 2u8, 103u8, 137u8, 31u8, 109u8, 165u8, 129u8, 48u8, 154u8, + 219u8, 110u8, 198u8, 241u8, 31u8, 174u8, 10u8, 92u8, 233u8, 161u8, + 76u8, 53u8, 136u8, 172u8, 214u8, 192u8, 12u8, 239u8, 165u8, 195u8, + 96u8, + ], + ) + } + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_reward_pools( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "CounterForRewardPools", vec![], [ - 157u8, 221u8, 6u8, 175u8, 61u8, 99u8, 250u8, 30u8, 177u8, 53u8, 37u8, - 191u8, 138u8, 65u8, 251u8, 216u8, 37u8, 84u8, 246u8, 76u8, 8u8, 29u8, - 18u8, 253u8, 143u8, 75u8, 129u8, 141u8, 48u8, 178u8, 135u8, 197u8, + 209u8, 139u8, 212u8, 116u8, 210u8, 178u8, 213u8, 38u8, 75u8, 23u8, + 188u8, 57u8, 253u8, 213u8, 95u8, 118u8, 182u8, 250u8, 45u8, 205u8, + 17u8, 175u8, 17u8, 201u8, 234u8, 14u8, 98u8, 49u8, 143u8, 135u8, 201u8, + 81u8, ], ) } - #[doc = " The messages that exceeded max individual message weight budget."] - #[doc = ""] - #[doc = " These messages stay there until manually dispatched."] - pub fn overweight( + #[doc = " Groups of unbonding pools. Each group of unbonding pools belongs to a"] + #[doc = " bonded pool, hence the name sub-pools. Keyed by the bonded pools account."] + pub fn sub_pools_storage( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u64>, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::polkadot_parachain::primitives::Id, - ::std::vec::Vec<::core::primitive::u8>, - ), + runtime_types::pallet_nomination_pools::SubPools, ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Ump", - "Overweight", + "NominationPools", + "SubPoolsStorage", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 49u8, 4u8, 221u8, 218u8, 249u8, 183u8, 49u8, 198u8, 48u8, 42u8, 110u8, - 67u8, 47u8, 50u8, 181u8, 141u8, 184u8, 47u8, 114u8, 3u8, 232u8, 132u8, - 32u8, 201u8, 13u8, 213u8, 175u8, 236u8, 111u8, 87u8, 146u8, 212u8, + 231u8, 13u8, 111u8, 248u8, 1u8, 208u8, 179u8, 134u8, 224u8, 196u8, + 94u8, 201u8, 229u8, 29u8, 155u8, 211u8, 163u8, 150u8, 157u8, 34u8, + 68u8, 238u8, 55u8, 4u8, 222u8, 96u8, 186u8, 29u8, 205u8, 237u8, 80u8, + 42u8, ], ) } - #[doc = " The messages that exceeded max individual message weight budget."] - #[doc = ""] - #[doc = " These messages stay there until manually dispatched."] - pub fn overweight_root( + #[doc = " Groups of unbonding pools. Each group of unbonding pools belongs to a"] + #[doc = " bonded pool, hence the name sub-pools. Keyed by the bonded pools account."] + pub fn sub_pools_storage_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::polkadot_parachain::primitives::Id, - ::std::vec::Vec<::core::primitive::u8>, - ), + runtime_types::pallet_nomination_pools::SubPools, (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Ump", - "Overweight", + "NominationPools", + "SubPoolsStorage", Vec::new(), [ - 49u8, 4u8, 221u8, 218u8, 249u8, 183u8, 49u8, 198u8, 48u8, 42u8, 110u8, - 67u8, 47u8, 50u8, 181u8, 141u8, 184u8, 47u8, 114u8, 3u8, 232u8, 132u8, - 32u8, 201u8, 13u8, 213u8, 175u8, 236u8, 111u8, 87u8, 146u8, 212u8, + 231u8, 13u8, 111u8, 248u8, 1u8, 208u8, 179u8, 134u8, 224u8, 196u8, + 94u8, 201u8, 229u8, 29u8, 155u8, 211u8, 163u8, 150u8, 157u8, 34u8, + 68u8, 238u8, 55u8, 4u8, 222u8, 96u8, 186u8, 29u8, 205u8, 237u8, 80u8, + 42u8, ], ) } - #[doc = " The number of overweight messages ever recorded in `Overweight` (and thus the lowest free"] - #[doc = " index)."] - pub fn overweight_count( + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_sub_pools_storage( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, + ::core::primitive::u32, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "Ump", - "OverweightCount", + "NominationPools", + "CounterForSubPoolsStorage", vec![], [ - 102u8, 180u8, 196u8, 148u8, 115u8, 62u8, 46u8, 238u8, 97u8, 116u8, - 117u8, 42u8, 14u8, 5u8, 72u8, 237u8, 230u8, 46u8, 150u8, 126u8, 89u8, - 64u8, 233u8, 166u8, 180u8, 137u8, 52u8, 233u8, 252u8, 255u8, 36u8, - 20u8, + 212u8, 145u8, 212u8, 226u8, 234u8, 31u8, 26u8, 240u8, 107u8, 91u8, + 171u8, 120u8, 41u8, 195u8, 16u8, 86u8, 55u8, 127u8, 103u8, 93u8, 128u8, + 48u8, 69u8, 104u8, 168u8, 236u8, 81u8, 54u8, 2u8, 184u8, 215u8, 51u8, ], ) } - } - } - } - pub mod hrmp { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_parachains::hrmp::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, + #[doc = " Metadata for the pool."] + pub fn metadata( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "Metadata", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 108u8, 250u8, 163u8, 54u8, 192u8, 143u8, 239u8, 62u8, 97u8, 163u8, + 161u8, 215u8, 171u8, 225u8, 49u8, 18u8, 37u8, 200u8, 143u8, 254u8, + 136u8, 26u8, 54u8, 187u8, 39u8, 3u8, 216u8, 24u8, 188u8, 25u8, 243u8, + 251u8, + ], + ) + } + #[doc = " Metadata for the pool."] + pub fn metadata_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "Metadata", + Vec::new(), + [ + 108u8, 250u8, 163u8, 54u8, 192u8, 143u8, 239u8, 62u8, 97u8, 163u8, + 161u8, 215u8, 171u8, 225u8, 49u8, 18u8, 37u8, 200u8, 143u8, 254u8, + 136u8, 26u8, 54u8, 187u8, 39u8, 3u8, 216u8, 24u8, 188u8, 25u8, 243u8, + 251u8, + ], + ) + } + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_metadata( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "CounterForMetadata", + vec![], + [ + 190u8, 232u8, 77u8, 134u8, 245u8, 89u8, 160u8, 187u8, 163u8, 68u8, + 188u8, 204u8, 31u8, 145u8, 219u8, 165u8, 213u8, 1u8, 167u8, 90u8, + 175u8, 218u8, 147u8, 144u8, 158u8, 226u8, 23u8, 233u8, 55u8, 168u8, + 161u8, 237u8, + ], + ) + } + #[doc = " Ever increasing number of all pools created so far."] + pub fn last_pool_id( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "LastPoolId", + vec![], + [ + 50u8, 254u8, 218u8, 41u8, 213u8, 184u8, 170u8, 166u8, 31u8, 29u8, + 196u8, 57u8, 215u8, 20u8, 40u8, 40u8, 19u8, 22u8, 9u8, 184u8, 11u8, + 21u8, 21u8, 125u8, 97u8, 38u8, 219u8, 209u8, 2u8, 238u8, 247u8, 51u8, + ], + ) + } + #[doc = " A reverse lookup from the pool's account id to its id."] + #[doc = ""] + #[doc = " This is only used for slashing. In all other instances, the pool id is used, and the"] + #[doc = " accounts are deterministically derived from it."] + pub fn reverse_pool_id_lookup( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "ReversePoolIdLookup", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 178u8, 161u8, 51u8, 220u8, 128u8, 1u8, 135u8, 83u8, 236u8, 159u8, 36u8, + 237u8, 120u8, 128u8, 6u8, 191u8, 41u8, 159u8, 94u8, 178u8, 174u8, + 235u8, 221u8, 173u8, 44u8, 81u8, 211u8, 255u8, 231u8, 81u8, 16u8, 87u8, + ], + ) + } + #[doc = " A reverse lookup from the pool's account id to its id."] + #[doc = ""] + #[doc = " This is only used for slashing. In all other instances, the pool id is used, and the"] + #[doc = " accounts are deterministically derived from it."] + pub fn reverse_pool_id_lookup_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "ReversePoolIdLookup", + Vec::new(), + [ + 178u8, 161u8, 51u8, 220u8, 128u8, 1u8, 135u8, 83u8, 236u8, 159u8, 36u8, + 237u8, 120u8, 128u8, 6u8, 191u8, 41u8, 159u8, 94u8, 178u8, 174u8, + 235u8, 221u8, 173u8, 44u8, 81u8, 211u8, 255u8, 231u8, 81u8, 16u8, 87u8, + ], + ) + } + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_reverse_pool_id_lookup( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "CounterForReversePoolIdLookup", + vec![], + [ + 148u8, 83u8, 81u8, 33u8, 188u8, 72u8, 148u8, 208u8, 245u8, 178u8, 52u8, + 245u8, 229u8, 140u8, 100u8, 152u8, 8u8, 217u8, 161u8, 80u8, 226u8, + 42u8, 15u8, 252u8, 90u8, 197u8, 120u8, 114u8, 144u8, 90u8, 199u8, + 123u8, + ], + ) + } + #[doc = " Map from a pool member account to their opted claim permission."] + pub fn claim_permissions( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::ClaimPermission, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "ClaimPermissions", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 23u8, 124u8, 83u8, 109u8, 174u8, 228u8, 170u8, 25u8, 124u8, 91u8, + 224u8, 66u8, 55u8, 127u8, 190u8, 226u8, 163u8, 16u8, 81u8, 231u8, + 241u8, 214u8, 209u8, 137u8, 101u8, 206u8, 104u8, 138u8, 49u8, 56u8, + 152u8, 228u8, + ], + ) + } + #[doc = " Map from a pool member account to their opted claim permission."] + pub fn claim_permissions_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::ClaimPermission, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "ClaimPermissions", + Vec::new(), + [ + 23u8, 124u8, 83u8, 109u8, 174u8, 228u8, 170u8, 25u8, 124u8, 91u8, + 224u8, 66u8, 55u8, 127u8, 190u8, 226u8, 163u8, 16u8, 81u8, 231u8, + 241u8, 214u8, 209u8, 137u8, 101u8, 206u8, 104u8, 138u8, 49u8, 56u8, + 152u8, 228u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The nomination pool's pallet id."] + pub fn pallet_id( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "NominationPools", + "PalletId", + [ + 139u8, 109u8, 228u8, 151u8, 252u8, 32u8, 130u8, 69u8, 112u8, 154u8, + 174u8, 45u8, 83u8, 245u8, 51u8, 132u8, 173u8, 5u8, 186u8, 24u8, 243u8, + 9u8, 12u8, 214u8, 80u8, 74u8, 69u8, 189u8, 30u8, 94u8, 22u8, 39u8, + ], + ) + } + #[doc = " The maximum pool points-to-balance ratio that an `open` pool can have."] + #[doc = ""] + #[doc = " This is important in the event slashing takes place and the pool's points-to-balance"] + #[doc = " ratio becomes disproportional."] + #[doc = ""] + #[doc = " Moreover, this relates to the `RewardCounter` type as well, as the arithmetic operations"] + #[doc = " are a function of number of points, and by setting this value to e.g. 10, you ensure"] + #[doc = " that the total number of points in the system are at most 10 times the total_issuance of"] + #[doc = " the chain, in the absolute worse case."] + #[doc = ""] + #[doc = " For a value of 10, the threshold would be a pool points-to-balance ratio of 10:1."] + #[doc = " Such a scenario would also be the equivalent of the pool being 90% slashed."] + pub fn max_points_to_balance( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u8> { + ::subxt::constants::Address::new_static( + "NominationPools", + "MaxPointsToBalance", + [ + 141u8, 130u8, 11u8, 35u8, 226u8, 114u8, 92u8, 179u8, 168u8, 110u8, + 28u8, 91u8, 221u8, 64u8, 4u8, 148u8, 201u8, 193u8, 185u8, 66u8, 226u8, + 114u8, 97u8, 79u8, 62u8, 212u8, 202u8, 114u8, 237u8, 228u8, 183u8, + 165u8, + ], + ) + } + } + } + } + pub mod fast_unstake { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_fast_unstake::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpInitOpenChannel { - pub recipient: runtime_types::polkadot_parachain::primitives::Id, - pub proposed_max_capacity: ::core::primitive::u32, - pub proposed_max_message_size: ::core::primitive::u32, - } + pub struct RegisterFastUnstake; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -27665,10 +25838,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpAcceptOpenChannel { - pub sender: runtime_types::polkadot_parachain::primitives::Id, - } + pub struct Deregister; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -27678,9 +25850,86 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpCloseChannel { - pub channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, + pub struct Control { + pub eras_to_check: ::core::primitive::u32, + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Register oneself for fast-unstake."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be signed by the controller account, similar to"] + #[doc = "`staking::unbond`."] + #[doc = ""] + #[doc = "The stash associated with the origin must have no ongoing unlocking chunks. If"] + #[doc = "successful, this will fully unbond and chill the stash. Then, it will enqueue the stash"] + #[doc = "to be checked in further blocks."] + #[doc = ""] + #[doc = "If by the time this is called, the stash is actually eligible for fast-unstake, then"] + #[doc = "they are guaranteed to remain eligible, because the call will chill them as well."] + #[doc = ""] + #[doc = "If the check works, the entire staking data is removed, i.e. the stash is fully"] + #[doc = "unstaked."] + #[doc = ""] + #[doc = "If the check fails, the stash remains chilled and waiting for being unbonded as in with"] + #[doc = "the normal staking system, but they lose part of their unbonding chunks due to consuming"] + #[doc = "the chain's resources."] + pub fn register_fast_unstake(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "FastUnstake", + "register_fast_unstake", + RegisterFastUnstake {}, + [ + 254u8, 85u8, 128u8, 135u8, 172u8, 170u8, 34u8, 145u8, 79u8, 117u8, + 234u8, 90u8, 16u8, 174u8, 159u8, 197u8, 27u8, 239u8, 180u8, 85u8, + 116u8, 23u8, 254u8, 30u8, 197u8, 110u8, 48u8, 184u8, 177u8, 129u8, + 42u8, 122u8, + ], + ) + } + #[doc = "Deregister oneself from the fast-unstake."] + #[doc = ""] + #[doc = "This is useful if one is registered, they are still waiting, and they change their mind."] + #[doc = ""] + #[doc = "Note that the associated stash is still fully unbonded and chilled as a consequence of"] + #[doc = "calling `register_fast_unstake`. This should probably be followed by a call to"] + #[doc = "`Staking::rebond`."] + pub fn deregister(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "FastUnstake", + "deregister", + Deregister {}, + [ + 198u8, 180u8, 253u8, 148u8, 124u8, 145u8, 175u8, 121u8, 42u8, 181u8, + 41u8, 155u8, 229u8, 181u8, 66u8, 140u8, 103u8, 86u8, 242u8, 155u8, + 192u8, 34u8, 157u8, 107u8, 211u8, 162u8, 1u8, 144u8, 35u8, 252u8, 88u8, + 21u8, + ], + ) + } + #[doc = "Control the operation of this pallet."] + #[doc = ""] + #[doc = "Dispatch origin must be signed by the [`Config::ControlOrigin`]."] + pub fn control( + &self, + eras_to_check: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "FastUnstake", + "control", + Control { eras_to_check }, + [ + 92u8, 241u8, 123u8, 251u8, 82u8, 36u8, 209u8, 87u8, 238u8, 56u8, 32u8, + 54u8, 190u8, 89u8, 167u8, 2u8, 36u8, 249u8, 131u8, 54u8, 217u8, 217u8, + 231u8, 167u8, 232u8, 35u8, 108u8, 193u8, 70u8, 224u8, 47u8, 142u8, + ], + ) + } } + } + #[doc = "The events of this pallet."] + pub type Event = runtime_types::pallet_fast_unstake::pallet::Event; + pub mod events { + use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -27691,13 +25940,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceCleanHrmp { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub inbound: ::core::primitive::u32, - pub outbound: ::core::primitive::u32, + #[doc = "A staker was unstaked."] + pub struct Unstaked { + pub stash: ::subxt::utils::AccountId32, + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + } + impl ::subxt::events::StaticEvent for Unstaked { + const PALLET: &'static str = "FastUnstake"; + const EVENT: &'static str = "Unstaked"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -27707,11 +25959,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceProcessHrmpOpen { - pub channels: ::core::primitive::u32, + #[doc = "A staker was slashed for requesting fast-unstake whilst being exposed."] + pub struct Slashed { + pub stash: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Slashed { + const PALLET: &'static str = "FastUnstake"; + const EVENT: &'static str = "Slashed"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -27721,8 +25978,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceProcessHrmpClose { - pub channels: ::core::primitive::u32, + #[doc = "An internal error happened. Operations will be paused now."] + pub struct InternalError; + impl ::subxt::events::StaticEvent for InternalError { + const PALLET: &'static str = "FastUnstake"; + const EVENT: &'static str = "InternalError"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -27734,11 +25994,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpCancelOpenRequest { - pub channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, - pub open_requests: ::core::primitive::u32, + #[doc = "A batch was partially checked for the given eras, but the process did not finish."] + pub struct BatchChecked { + pub eras: ::std::vec::Vec<::core::primitive::u32>, + } + impl ::subxt::events::StaticEvent for BatchChecked { + const PALLET: &'static str = "FastUnstake"; + const EVENT: &'static str = "BatchChecked"; } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -27748,220 +26013,181 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceOpenHrmpChannel { - pub sender: runtime_types::polkadot_parachain::primitives::Id, - pub recipient: runtime_types::polkadot_parachain::primitives::Id, - pub max_capacity: ::core::primitive::u32, - pub max_message_size: ::core::primitive::u32, + #[doc = "A batch of a given size was terminated."] + #[doc = ""] + #[doc = "This is always follows by a number of `Unstaked` or `Slashed` events, marking the end"] + #[doc = "of the batch. A new batch will be created upon next block."] + pub struct BatchFinished { + pub size: ::core::primitive::u32, } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Initiate opening a channel from a parachain to a given recipient with given channel"] - #[doc = "parameters."] - #[doc = ""] - #[doc = "- `proposed_max_capacity` - specifies how many messages can be in the channel at once."] - #[doc = "- `proposed_max_message_size` - specifies the maximum size of the messages."] - #[doc = ""] - #[doc = "These numbers are a subject to the relay-chain configuration limits."] - #[doc = ""] - #[doc = "The channel can be opened only after the recipient confirms it and only on a session"] - #[doc = "change."] - pub fn hrmp_init_open_channel( + impl ::subxt::events::StaticEvent for BatchFinished { + const PALLET: &'static str = "FastUnstake"; + const EVENT: &'static str = "BatchFinished"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The current \"head of the queue\" being unstaked."] + pub fn head( &self, - recipient: runtime_types::polkadot_parachain::primitives::Id, - proposed_max_capacity: ::core::primitive::u32, - proposed_max_message_size: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "hrmp_init_open_channel", - HrmpInitOpenChannel { - recipient, - proposed_max_capacity, - proposed_max_message_size, - }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_fast_unstake::types::UnstakeRequest, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "FastUnstake", + "Head", + vec![], [ - 170u8, 72u8, 58u8, 42u8, 38u8, 11u8, 110u8, 229u8, 239u8, 136u8, 99u8, - 230u8, 223u8, 225u8, 126u8, 61u8, 234u8, 185u8, 101u8, 156u8, 40u8, - 102u8, 253u8, 123u8, 77u8, 204u8, 217u8, 86u8, 162u8, 66u8, 25u8, - 214u8, + 206u8, 19u8, 169u8, 239u8, 214u8, 136u8, 16u8, 102u8, 82u8, 110u8, + 128u8, 205u8, 102u8, 96u8, 148u8, 190u8, 67u8, 75u8, 2u8, 213u8, 134u8, + 143u8, 40u8, 57u8, 54u8, 66u8, 170u8, 42u8, 135u8, 212u8, 108u8, 177u8, ], ) } - #[doc = "Accept a pending open channel request from the given sender."] + #[doc = " The map of all accounts wishing to be unstaked."] #[doc = ""] - #[doc = "The channel will be opened only on the next session boundary."] - pub fn hrmp_accept_open_channel( - &self, - sender: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "hrmp_accept_open_channel", - HrmpAcceptOpenChannel { sender }, - [ - 75u8, 111u8, 52u8, 164u8, 204u8, 100u8, 204u8, 111u8, 127u8, 84u8, - 60u8, 136u8, 95u8, 255u8, 48u8, 157u8, 189u8, 76u8, 33u8, 177u8, 223u8, - 27u8, 74u8, 221u8, 139u8, 1u8, 12u8, 128u8, 242u8, 7u8, 3u8, 53u8, - ], - ) - } - #[doc = "Initiate unilateral closing of a channel. The origin must be either the sender or the"] - #[doc = "recipient in the channel being closed."] + #[doc = " Keeps track of `AccountId` wishing to unstake and it's corresponding deposit."] #[doc = ""] - #[doc = "The closure can only happen on a session change."] - pub fn hrmp_close_channel( + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn queue( &self, - channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "hrmp_close_channel", - HrmpCloseChannel { channel_id }, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "FastUnstake", + "Queue", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 11u8, 202u8, 76u8, 107u8, 213u8, 21u8, 191u8, 190u8, 40u8, 229u8, 60u8, - 115u8, 232u8, 136u8, 41u8, 114u8, 21u8, 19u8, 238u8, 236u8, 202u8, - 56u8, 212u8, 232u8, 34u8, 84u8, 27u8, 70u8, 176u8, 252u8, 218u8, 52u8, + 250u8, 208u8, 88u8, 68u8, 8u8, 87u8, 27u8, 59u8, 120u8, 242u8, 79u8, + 54u8, 108u8, 15u8, 62u8, 143u8, 126u8, 66u8, 159u8, 159u8, 55u8, 212u8, + 190u8, 26u8, 171u8, 90u8, 156u8, 205u8, 173u8, 189u8, 230u8, 71u8, ], ) } - #[doc = "This extrinsic triggers the cleanup of all the HRMP storage items that"] - #[doc = "a para may have. Normally this happens once per session, but this allows"] - #[doc = "you to trigger the cleanup immediately for a specific parachain."] + #[doc = " The map of all accounts wishing to be unstaked."] #[doc = ""] - #[doc = "Origin must be Root."] + #[doc = " Keeps track of `AccountId` wishing to unstake and it's corresponding deposit."] #[doc = ""] - #[doc = "Number of inbound and outbound channels for `para` must be provided as witness data of weighing."] - pub fn force_clean_hrmp( + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn queue_root( &self, - para: runtime_types::polkadot_parachain::primitives::Id, - inbound: ::core::primitive::u32, - outbound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "force_clean_hrmp", - ForceCleanHrmp { - para, - inbound, - outbound, - }, - [ - 171u8, 109u8, 147u8, 49u8, 163u8, 107u8, 36u8, 169u8, 117u8, 193u8, - 231u8, 114u8, 207u8, 38u8, 240u8, 195u8, 155u8, 222u8, 244u8, 142u8, - 93u8, 79u8, 111u8, 43u8, 5u8, 33u8, 190u8, 30u8, 200u8, 225u8, 173u8, - 64u8, - ], - ) - } - #[doc = "Force process HRMP open channel requests."] - #[doc = ""] - #[doc = "If there are pending HRMP open channel requests, you can use this"] - #[doc = "function process all of those requests immediately."] - #[doc = ""] - #[doc = "Total number of opening channels must be provided as witness data of weighing."] - pub fn force_process_hrmp_open( - &self, - channels: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "force_process_hrmp_open", - ForceProcessHrmpOpen { channels }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "FastUnstake", + "Queue", + Vec::new(), [ - 231u8, 80u8, 233u8, 15u8, 131u8, 167u8, 223u8, 28u8, 182u8, 185u8, - 213u8, 24u8, 154u8, 160u8, 68u8, 94u8, 160u8, 59u8, 78u8, 85u8, 85u8, - 149u8, 130u8, 131u8, 9u8, 162u8, 169u8, 119u8, 165u8, 44u8, 150u8, - 50u8, + 250u8, 208u8, 88u8, 68u8, 8u8, 87u8, 27u8, 59u8, 120u8, 242u8, 79u8, + 54u8, 108u8, 15u8, 62u8, 143u8, 126u8, 66u8, 159u8, 159u8, 55u8, 212u8, + 190u8, 26u8, 171u8, 90u8, 156u8, 205u8, 173u8, 189u8, 230u8, 71u8, ], ) } - #[doc = "Force process HRMP close channel requests."] - #[doc = ""] - #[doc = "If there are pending HRMP close channel requests, you can use this"] - #[doc = "function process all of those requests immediately."] - #[doc = ""] - #[doc = "Total number of closing channels must be provided as witness data of weighing."] - pub fn force_process_hrmp_close( + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_queue( &self, - channels: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "force_process_hrmp_close", - ForceProcessHrmpClose { channels }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "FastUnstake", + "CounterForQueue", + vec![], [ - 248u8, 138u8, 30u8, 151u8, 53u8, 16u8, 44u8, 116u8, 51u8, 194u8, 173u8, - 252u8, 143u8, 53u8, 184u8, 129u8, 80u8, 80u8, 25u8, 118u8, 47u8, 183u8, - 249u8, 130u8, 8u8, 221u8, 56u8, 106u8, 182u8, 114u8, 186u8, 161u8, + 241u8, 174u8, 224u8, 214u8, 204u8, 37u8, 117u8, 62u8, 114u8, 63u8, + 123u8, 121u8, 201u8, 128u8, 26u8, 60u8, 170u8, 24u8, 112u8, 5u8, 248u8, + 7u8, 143u8, 17u8, 150u8, 91u8, 23u8, 90u8, 237u8, 4u8, 138u8, 210u8, ], ) } - #[doc = "This cancels a pending open channel request. It can be canceled by either of the sender"] - #[doc = "or the recipient for that request. The origin must be either of those."] + #[doc = " Number of eras to check per block."] #[doc = ""] - #[doc = "The cancellation happens immediately. It is not possible to cancel the request if it is"] - #[doc = "already accepted."] + #[doc = " If set to 0, this pallet does absolutely nothing."] #[doc = ""] - #[doc = "Total number of open requests (i.e. `HrmpOpenChannelRequestsList`) must be provided as"] - #[doc = "witness data."] - pub fn hrmp_cancel_open_request( + #[doc = " Based on the amount of weight available at `on_idle`, up to this many eras of a single"] + #[doc = " nominator might be checked."] + pub fn eras_to_check_per_block( &self, - channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, - open_requests: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "hrmp_cancel_open_request", - HrmpCancelOpenRequest { - channel_id, - open_requests, - }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "FastUnstake", + "ErasToCheckPerBlock", + vec![], [ - 136u8, 217u8, 56u8, 138u8, 227u8, 37u8, 120u8, 83u8, 116u8, 228u8, - 42u8, 111u8, 206u8, 210u8, 177u8, 235u8, 225u8, 98u8, 172u8, 184u8, - 87u8, 65u8, 77u8, 129u8, 7u8, 0u8, 232u8, 139u8, 134u8, 1u8, 59u8, - 19u8, + 85u8, 55u8, 18u8, 11u8, 75u8, 176u8, 36u8, 253u8, 183u8, 250u8, 203u8, + 178u8, 201u8, 79u8, 101u8, 89u8, 51u8, 142u8, 254u8, 23u8, 49u8, 140u8, + 195u8, 116u8, 66u8, 124u8, 165u8, 161u8, 151u8, 174u8, 37u8, 51u8, ], ) } - #[doc = "Open a channel from a `sender` to a `recipient` `ParaId` using the Root origin. Although"] - #[doc = "opened by Root, the `max_capacity` and `max_message_size` are still subject to the Relay"] - #[doc = "Chain's configured limits."] - #[doc = ""] - #[doc = "Expected use is when one of the `ParaId`s involved in the channel is governed by the"] - #[doc = "Relay Chain, e.g. a common good parachain."] - pub fn force_open_hrmp_channel( - &self, - sender: runtime_types::polkadot_parachain::primitives::Id, - recipient: runtime_types::polkadot_parachain::primitives::Id, - max_capacity: ::core::primitive::u32, - max_message_size: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "force_open_hrmp_channel", - ForceOpenHrmpChannel { - sender, - recipient, - max_capacity, - max_message_size, - }, + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " Deposit to take for unstaking, to make sure we're able to slash the it in order to cover"] + #[doc = " the costs of resources on unsuccessful unstake."] + pub fn deposit(&self) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "FastUnstake", + "Deposit", [ - 145u8, 23u8, 215u8, 75u8, 94u8, 119u8, 205u8, 222u8, 186u8, 149u8, - 11u8, 172u8, 211u8, 158u8, 247u8, 21u8, 125u8, 144u8, 91u8, 157u8, - 94u8, 143u8, 188u8, 20u8, 98u8, 136u8, 165u8, 70u8, 155u8, 14u8, 92u8, - 58u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } } } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::polkadot_runtime_parachains::hrmp::pallet::Event; - pub mod events { + } + pub mod parachains_origin { + use super::root_mod; + use super::runtime_types; + } + pub mod configuration { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::polkadot_runtime_parachains::configuration::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -27971,19 +26197,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Open HRMP channel requested."] - #[doc = "`[sender, recipient, proposed_max_capacity, proposed_max_message_size]`"] - pub struct OpenChannelRequested( - pub runtime_types::polkadot_parachain::primitives::Id, - pub runtime_types::polkadot_parachain::primitives::Id, - pub ::core::primitive::u32, - pub ::core::primitive::u32, - ); - impl ::subxt::events::StaticEvent for OpenChannelRequested { - const PALLET: &'static str = "Hrmp"; - const EVENT: &'static str = "OpenChannelRequested"; + pub struct SetValidationUpgradeCooldown { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -27993,17 +26211,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An HRMP channel request sent by the receiver was canceled by either party."] - #[doc = "`[by_parachain, channel_id]`"] - pub struct OpenChannelCanceled( - pub runtime_types::polkadot_parachain::primitives::Id, - pub runtime_types::polkadot_parachain::primitives::HrmpChannelId, - ); - impl ::subxt::events::StaticEvent for OpenChannelCanceled { - const PALLET: &'static str = "Hrmp"; - const EVENT: &'static str = "OpenChannelCanceled"; + pub struct SetValidationUpgradeDelay { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -28013,16 +26225,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Open HRMP channel accepted. `[sender, recipient]`"] - pub struct OpenChannelAccepted( - pub runtime_types::polkadot_parachain::primitives::Id, - pub runtime_types::polkadot_parachain::primitives::Id, - ); - impl ::subxt::events::StaticEvent for OpenChannelAccepted { - const PALLET: &'static str = "Hrmp"; - const EVENT: &'static str = "OpenChannelAccepted"; + pub struct SetCodeRetentionPeriod { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -28032,16 +26239,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "HRMP channel closed. `[by_parachain, channel_id]`"] - pub struct ChannelClosed( - pub runtime_types::polkadot_parachain::primitives::Id, - pub runtime_types::polkadot_parachain::primitives::HrmpChannelId, - ); - impl ::subxt::events::StaticEvent for ChannelClosed { - const PALLET: &'static str = "Hrmp"; - const EVENT: &'static str = "ChannelClosed"; + pub struct SetMaxCodeSize { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -28051,782 +26253,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An HRMP channel was opened via Root origin."] - #[doc = "`[sender, recipient, proposed_max_capacity, proposed_max_message_size]`"] - pub struct HrmpChannelForceOpened( - pub runtime_types::polkadot_parachain::primitives::Id, - pub runtime_types::polkadot_parachain::primitives::Id, - pub ::core::primitive::u32, - pub ::core::primitive::u32, - ); - impl ::subxt::events::StaticEvent for HrmpChannelForceOpened { - const PALLET: &'static str = "Hrmp"; - const EVENT: &'static str = "HrmpChannelForceOpened"; + pub struct SetMaxPovSize { + pub new: ::core::primitive::u32, } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The set of pending HRMP open channel requests."] - #[doc = ""] - #[doc = " The set is accompanied by a list for iteration."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - There are no channels that exists in list but not in the set and vice versa."] - pub fn hrmp_open_channel_requests( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain::primitives::HrmpChannelId, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::hrmp::HrmpOpenChannelRequest, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpOpenChannelRequests", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 226u8, 115u8, 207u8, 13u8, 5u8, 81u8, 64u8, 161u8, 246u8, 4u8, 17u8, - 207u8, 210u8, 109u8, 91u8, 54u8, 28u8, 53u8, 35u8, 74u8, 62u8, 91u8, - 196u8, 236u8, 18u8, 70u8, 13u8, 86u8, 235u8, 74u8, 181u8, 169u8, - ], - ) - } - #[doc = " The set of pending HRMP open channel requests."] - #[doc = ""] - #[doc = " The set is accompanied by a list for iteration."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - There are no channels that exists in list but not in the set and vice versa."] - pub fn hrmp_open_channel_requests_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::hrmp::HrmpOpenChannelRequest, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpOpenChannelRequests", - Vec::new(), - [ - 226u8, 115u8, 207u8, 13u8, 5u8, 81u8, 64u8, 161u8, 246u8, 4u8, 17u8, - 207u8, 210u8, 109u8, 91u8, 54u8, 28u8, 53u8, 35u8, 74u8, 62u8, 91u8, - 196u8, 236u8, 18u8, 70u8, 13u8, 86u8, 235u8, 74u8, 181u8, 169u8, - ], - ) - } - pub fn hrmp_open_channel_requests_list( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpOpenChannelRequestsList", - vec![], - [ - 187u8, 157u8, 7u8, 183u8, 88u8, 215u8, 128u8, 174u8, 244u8, 130u8, - 137u8, 13u8, 110u8, 126u8, 181u8, 165u8, 142u8, 69u8, 75u8, 37u8, 37u8, - 149u8, 46u8, 100u8, 140u8, 69u8, 234u8, 171u8, 103u8, 136u8, 223u8, - 193u8, - ], - ) - } - #[doc = " This mapping tracks how many open channel requests are initiated by a given sender para."] - #[doc = " Invariant: `HrmpOpenChannelRequests` should contain the same number of items that has"] - #[doc = " `(X, _)` as the number of `HrmpOpenChannelRequestCount` for `X`."] - pub fn hrmp_open_channel_request_count( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpOpenChannelRequestCount", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 156u8, 87u8, 232u8, 34u8, 30u8, 237u8, 159u8, 78u8, 212u8, 138u8, - 140u8, 206u8, 191u8, 117u8, 209u8, 218u8, 251u8, 146u8, 217u8, 56u8, - 93u8, 15u8, 131u8, 64u8, 126u8, 253u8, 126u8, 1u8, 12u8, 242u8, 176u8, - 217u8, - ], - ) - } - #[doc = " This mapping tracks how many open channel requests are initiated by a given sender para."] - #[doc = " Invariant: `HrmpOpenChannelRequests` should contain the same number of items that has"] - #[doc = " `(X, _)` as the number of `HrmpOpenChannelRequestCount` for `X`."] - pub fn hrmp_open_channel_request_count_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpOpenChannelRequestCount", - Vec::new(), - [ - 156u8, 87u8, 232u8, 34u8, 30u8, 237u8, 159u8, 78u8, 212u8, 138u8, - 140u8, 206u8, 191u8, 117u8, 209u8, 218u8, 251u8, 146u8, 217u8, 56u8, - 93u8, 15u8, 131u8, 64u8, 126u8, 253u8, 126u8, 1u8, 12u8, 242u8, 176u8, - 217u8, - ], - ) - } - #[doc = " This mapping tracks how many open channel requests were accepted by a given recipient para."] - #[doc = " Invariant: `HrmpOpenChannelRequests` should contain the same number of items `(_, X)` with"] - #[doc = " `confirmed` set to true, as the number of `HrmpAcceptedChannelRequestCount` for `X`."] - pub fn hrmp_accepted_channel_request_count( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpAcceptedChannelRequestCount", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 93u8, 183u8, 17u8, 253u8, 119u8, 213u8, 106u8, 205u8, 17u8, 10u8, - 230u8, 242u8, 5u8, 223u8, 49u8, 235u8, 41u8, 221u8, 80u8, 51u8, 153u8, - 62u8, 191u8, 3u8, 120u8, 224u8, 46u8, 164u8, 161u8, 6u8, 15u8, 15u8, - ], - ) - } - #[doc = " This mapping tracks how many open channel requests were accepted by a given recipient para."] - #[doc = " Invariant: `HrmpOpenChannelRequests` should contain the same number of items `(_, X)` with"] - #[doc = " `confirmed` set to true, as the number of `HrmpAcceptedChannelRequestCount` for `X`."] - pub fn hrmp_accepted_channel_request_count_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpAcceptedChannelRequestCount", - Vec::new(), - [ - 93u8, 183u8, 17u8, 253u8, 119u8, 213u8, 106u8, 205u8, 17u8, 10u8, - 230u8, 242u8, 5u8, 223u8, 49u8, 235u8, 41u8, 221u8, 80u8, 51u8, 153u8, - 62u8, 191u8, 3u8, 120u8, 224u8, 46u8, 164u8, 161u8, 6u8, 15u8, 15u8, - ], - ) - } - #[doc = " A set of pending HRMP close channel requests that are going to be closed during the session"] - #[doc = " change. Used for checking if a given channel is registered for closure."] - #[doc = ""] - #[doc = " The set is accompanied by a list for iteration."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - There are no channels that exists in list but not in the set and vice versa."] - pub fn hrmp_close_channel_requests( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain::primitives::HrmpChannelId, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (), - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpCloseChannelRequests", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 125u8, 131u8, 1u8, 231u8, 19u8, 207u8, 229u8, 72u8, 150u8, 100u8, - 165u8, 215u8, 241u8, 165u8, 91u8, 35u8, 230u8, 148u8, 127u8, 249u8, - 128u8, 221u8, 167u8, 172u8, 67u8, 30u8, 177u8, 176u8, 134u8, 223u8, - 39u8, 87u8, - ], - ) - } - #[doc = " A set of pending HRMP close channel requests that are going to be closed during the session"] - #[doc = " change. Used for checking if a given channel is registered for closure."] - #[doc = ""] - #[doc = " The set is accompanied by a list for iteration."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - There are no channels that exists in list but not in the set and vice versa."] - pub fn hrmp_close_channel_requests_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpCloseChannelRequests", - Vec::new(), - [ - 125u8, 131u8, 1u8, 231u8, 19u8, 207u8, 229u8, 72u8, 150u8, 100u8, - 165u8, 215u8, 241u8, 165u8, 91u8, 35u8, 230u8, 148u8, 127u8, 249u8, - 128u8, 221u8, 167u8, 172u8, 67u8, 30u8, 177u8, 176u8, 134u8, 223u8, - 39u8, 87u8, - ], - ) - } - pub fn hrmp_close_channel_requests_list( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpCloseChannelRequestsList", - vec![], - [ - 192u8, 165u8, 71u8, 70u8, 211u8, 233u8, 155u8, 146u8, 160u8, 58u8, - 103u8, 64u8, 123u8, 232u8, 157u8, 71u8, 199u8, 223u8, 158u8, 5u8, - 164u8, 93u8, 231u8, 153u8, 1u8, 63u8, 155u8, 4u8, 138u8, 89u8, 178u8, - 116u8, - ], - ) - } - #[doc = " The HRMP watermark associated with each para."] - #[doc = " Invariant:"] - #[doc = " - each para `P` used here as a key should satisfy `Paras::is_valid_para(P)` within a session."] - pub fn hrmp_watermarks( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpWatermarks", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 231u8, 195u8, 117u8, 35u8, 235u8, 18u8, 80u8, 28u8, 212u8, 37u8, 253u8, - 204u8, 71u8, 217u8, 12u8, 35u8, 219u8, 250u8, 45u8, 83u8, 102u8, 236u8, - 186u8, 149u8, 54u8, 31u8, 83u8, 19u8, 129u8, 51u8, 103u8, 155u8, - ], - ) - } - #[doc = " The HRMP watermark associated with each para."] - #[doc = " Invariant:"] - #[doc = " - each para `P` used here as a key should satisfy `Paras::is_valid_para(P)` within a session."] - pub fn hrmp_watermarks_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpWatermarks", - Vec::new(), - [ - 231u8, 195u8, 117u8, 35u8, 235u8, 18u8, 80u8, 28u8, 212u8, 37u8, 253u8, - 204u8, 71u8, 217u8, 12u8, 35u8, 219u8, 250u8, 45u8, 83u8, 102u8, 236u8, - 186u8, 149u8, 54u8, 31u8, 83u8, 19u8, 129u8, 51u8, 103u8, 155u8, - ], - ) - } - #[doc = " HRMP channel data associated with each para."] - #[doc = " Invariant:"] - #[doc = " - each participant in the channel should satisfy `Paras::is_valid_para(P)` within a session."] - pub fn hrmp_channels( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain::primitives::HrmpChannelId, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::hrmp::HrmpChannel, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpChannels", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 224u8, 252u8, 187u8, 122u8, 179u8, 193u8, 227u8, 250u8, 255u8, 216u8, - 107u8, 26u8, 224u8, 16u8, 178u8, 111u8, 77u8, 237u8, 177u8, 148u8, - 22u8, 17u8, 213u8, 99u8, 194u8, 140u8, 217u8, 211u8, 151u8, 51u8, 66u8, - 169u8, - ], - ) - } - #[doc = " HRMP channel data associated with each para."] - #[doc = " Invariant:"] - #[doc = " - each participant in the channel should satisfy `Paras::is_valid_para(P)` within a session."] - pub fn hrmp_channels_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::hrmp::HrmpChannel, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpChannels", - Vec::new(), - [ - 224u8, 252u8, 187u8, 122u8, 179u8, 193u8, 227u8, 250u8, 255u8, 216u8, - 107u8, 26u8, 224u8, 16u8, 178u8, 111u8, 77u8, 237u8, 177u8, 148u8, - 22u8, 17u8, 213u8, 99u8, 194u8, 140u8, 217u8, 211u8, 151u8, 51u8, 66u8, - 169u8, - ], - ) - } - #[doc = " Ingress/egress indexes allow to find all the senders and receivers given the opposite side."] - #[doc = " I.e."] - #[doc = ""] - #[doc = " (a) ingress index allows to find all the senders for a given recipient."] - #[doc = " (b) egress index allows to find all the recipients for a given sender."] - #[doc = ""] - #[doc = " Invariants:"] - #[doc = " - for each ingress index entry for `P` each item `I` in the index should present in"] - #[doc = " `HrmpChannels` as `(I, P)`."] - #[doc = " - for each egress index entry for `P` each item `E` in the index should present in"] - #[doc = " `HrmpChannels` as `(P, E)`."] - #[doc = " - there should be no other dangling channels in `HrmpChannels`."] - #[doc = " - the vectors are sorted."] - pub fn hrmp_ingress_channels_index( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpIngressChannelsIndex", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 58u8, 193u8, 212u8, 225u8, 48u8, 195u8, 119u8, 15u8, 61u8, 166u8, - 249u8, 1u8, 118u8, 67u8, 253u8, 40u8, 58u8, 220u8, 124u8, 152u8, 4u8, - 16u8, 155u8, 151u8, 195u8, 15u8, 205u8, 175u8, 234u8, 0u8, 101u8, 99u8, - ], - ) - } - #[doc = " Ingress/egress indexes allow to find all the senders and receivers given the opposite side."] - #[doc = " I.e."] - #[doc = ""] - #[doc = " (a) ingress index allows to find all the senders for a given recipient."] - #[doc = " (b) egress index allows to find all the recipients for a given sender."] - #[doc = ""] - #[doc = " Invariants:"] - #[doc = " - for each ingress index entry for `P` each item `I` in the index should present in"] - #[doc = " `HrmpChannels` as `(I, P)`."] - #[doc = " - for each egress index entry for `P` each item `E` in the index should present in"] - #[doc = " `HrmpChannels` as `(P, E)`."] - #[doc = " - there should be no other dangling channels in `HrmpChannels`."] - #[doc = " - the vectors are sorted."] - pub fn hrmp_ingress_channels_index_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpIngressChannelsIndex", - Vec::new(), - [ - 58u8, 193u8, 212u8, 225u8, 48u8, 195u8, 119u8, 15u8, 61u8, 166u8, - 249u8, 1u8, 118u8, 67u8, 253u8, 40u8, 58u8, 220u8, 124u8, 152u8, 4u8, - 16u8, 155u8, 151u8, 195u8, 15u8, 205u8, 175u8, 234u8, 0u8, 101u8, 99u8, - ], - ) - } - pub fn hrmp_egress_channels_index( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpEgressChannelsIndex", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 9u8, 242u8, 41u8, 234u8, 85u8, 193u8, 232u8, 245u8, 254u8, 26u8, 240u8, - 113u8, 184u8, 151u8, 150u8, 44u8, 43u8, 98u8, 84u8, 209u8, 145u8, - 175u8, 128u8, 68u8, 183u8, 112u8, 171u8, 236u8, 211u8, 32u8, 177u8, - 88u8, - ], - ) - } - pub fn hrmp_egress_channels_index_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpEgressChannelsIndex", - Vec::new(), - [ - 9u8, 242u8, 41u8, 234u8, 85u8, 193u8, 232u8, 245u8, 254u8, 26u8, 240u8, - 113u8, 184u8, 151u8, 150u8, 44u8, 43u8, 98u8, 84u8, 209u8, 145u8, - 175u8, 128u8, 68u8, 183u8, 112u8, 171u8, 236u8, 211u8, 32u8, 177u8, - 88u8, - ], - ) - } - #[doc = " Storage for the messages for each channel."] - #[doc = " Invariant: cannot be non-empty if the corresponding channel in `HrmpChannels` is `None`."] - pub fn hrmp_channel_contents( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain::primitives::HrmpChannelId, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundHrmpMessage< - ::core::primitive::u32, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpChannelContents", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 114u8, 86u8, 172u8, 88u8, 118u8, 243u8, 133u8, 147u8, 108u8, 60u8, - 128u8, 235u8, 45u8, 80u8, 225u8, 130u8, 89u8, 50u8, 40u8, 118u8, 63u8, - 3u8, 83u8, 222u8, 75u8, 167u8, 148u8, 150u8, 193u8, 90u8, 196u8, 225u8, - ], - ) - } - #[doc = " Storage for the messages for each channel."] - #[doc = " Invariant: cannot be non-empty if the corresponding channel in `HrmpChannels` is `None`."] - pub fn hrmp_channel_contents_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundHrmpMessage< - ::core::primitive::u32, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpChannelContents", - Vec::new(), - [ - 114u8, 86u8, 172u8, 88u8, 118u8, 243u8, 133u8, 147u8, 108u8, 60u8, - 128u8, 235u8, 45u8, 80u8, 225u8, 130u8, 89u8, 50u8, 40u8, 118u8, 63u8, - 3u8, 83u8, 222u8, 75u8, 167u8, 148u8, 150u8, 193u8, 90u8, 196u8, 225u8, - ], - ) - } - #[doc = " Maintains a mapping that can be used to answer the question: What paras sent a message at"] - #[doc = " the given block number for a given receiver. Invariants:"] - #[doc = " - The inner `Vec` is never empty."] - #[doc = " - The inner `Vec` cannot store two same `ParaId`."] - #[doc = " - The outer vector is sorted ascending by block number and cannot store two items with the"] - #[doc = " same block number."] - pub fn hrmp_channel_digests( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<( - ::core::primitive::u32, - ::std::vec::Vec, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpChannelDigests", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 205u8, 18u8, 60u8, 54u8, 123u8, 40u8, 160u8, 149u8, 174u8, 45u8, 135u8, - 213u8, 83u8, 44u8, 97u8, 243u8, 47u8, 200u8, 156u8, 131u8, 15u8, 63u8, - 170u8, 206u8, 101u8, 17u8, 244u8, 132u8, 73u8, 133u8, 79u8, 104u8, - ], - ) - } - #[doc = " Maintains a mapping that can be used to answer the question: What paras sent a message at"] - #[doc = " the given block number for a given receiver. Invariants:"] - #[doc = " - The inner `Vec` is never empty."] - #[doc = " - The inner `Vec` cannot store two same `ParaId`."] - #[doc = " - The outer vector is sorted ascending by block number and cannot store two items with the"] - #[doc = " same block number."] - pub fn hrmp_channel_digests_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<( - ::core::primitive::u32, - ::std::vec::Vec, - )>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpChannelDigests", - Vec::new(), - [ - 205u8, 18u8, 60u8, 54u8, 123u8, 40u8, 160u8, 149u8, 174u8, 45u8, 135u8, - 213u8, 83u8, 44u8, 97u8, 243u8, 47u8, 200u8, 156u8, 131u8, 15u8, 63u8, - 170u8, 206u8, 101u8, 17u8, 244u8, 132u8, 73u8, 133u8, 79u8, 104u8, - ], - ) - } - } - } - } - pub mod para_session_info { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Assignment keys for the current session."] - #[doc = " Note that this API is private due to it being prone to 'off-by-one' at session boundaries."] - #[doc = " When in doubt, use `Sessions` API instead."] - pub fn assignment_keys_unsafe( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "AssignmentKeysUnsafe", - vec![], - [ - 80u8, 24u8, 61u8, 132u8, 118u8, 225u8, 207u8, 75u8, 35u8, 240u8, 209u8, - 255u8, 19u8, 240u8, 114u8, 174u8, 86u8, 65u8, 65u8, 52u8, 135u8, 232u8, - 59u8, 208u8, 3u8, 107u8, 114u8, 241u8, 14u8, 98u8, 40u8, 226u8, - ], - ) - } - #[doc = " The earliest session for which previous session info is stored."] - pub fn earliest_stored_session( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "EarliestStoredSession", - vec![], - [ - 25u8, 143u8, 246u8, 184u8, 35u8, 166u8, 140u8, 147u8, 171u8, 5u8, - 164u8, 159u8, 228u8, 21u8, 248u8, 236u8, 48u8, 210u8, 133u8, 140u8, - 171u8, 3u8, 85u8, 250u8, 160u8, 102u8, 95u8, 46u8, 33u8, 81u8, 102u8, - 241u8, - ], - ) - } - #[doc = " Session information in a rolling window."] - #[doc = " Should have an entry in range `EarliestStoredSession..=CurrentSessionIndex`."] - #[doc = " Does not have any entries before the session index in the first session change notification."] - pub fn sessions( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v2::SessionInfo, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "Sessions", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 186u8, 220u8, 61u8, 52u8, 195u8, 40u8, 214u8, 113u8, 92u8, 109u8, - 221u8, 201u8, 122u8, 213u8, 124u8, 35u8, 244u8, 55u8, 244u8, 168u8, - 23u8, 0u8, 240u8, 109u8, 143u8, 90u8, 40u8, 87u8, 127u8, 64u8, 100u8, - 75u8, - ], - ) - } - #[doc = " Session information in a rolling window."] - #[doc = " Should have an entry in range `EarliestStoredSession..=CurrentSessionIndex`."] - #[doc = " Does not have any entries before the session index in the first session change notification."] - pub fn sessions_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v2::SessionInfo, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "Sessions", - Vec::new(), - [ - 186u8, 220u8, 61u8, 52u8, 195u8, 40u8, 214u8, 113u8, 92u8, 109u8, - 221u8, 201u8, 122u8, 213u8, 124u8, 35u8, 244u8, 55u8, 244u8, 168u8, - 23u8, 0u8, 240u8, 109u8, 143u8, 90u8, 40u8, 87u8, 127u8, 64u8, 100u8, - 75u8, - ], - ) - } - #[doc = " The validator account keys of the validators actively participating in parachain consensus."] - pub fn account_keys( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::AccountId32>, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "AccountKeys", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 48u8, 179u8, 139u8, 15u8, 144u8, 71u8, 92u8, 160u8, 254u8, 237u8, 98u8, - 60u8, 254u8, 208u8, 201u8, 32u8, 79u8, 55u8, 3u8, 33u8, 188u8, 134u8, - 18u8, 151u8, 132u8, 40u8, 192u8, 215u8, 94u8, 124u8, 148u8, 142u8, - ], - ) - } - #[doc = " The validator account keys of the validators actively participating in parachain consensus."] - pub fn account_keys_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::AccountId32>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "AccountKeys", - Vec::new(), - [ - 48u8, 179u8, 139u8, 15u8, 144u8, 71u8, 92u8, 160u8, 254u8, 237u8, 98u8, - 60u8, 254u8, 208u8, 201u8, 32u8, 79u8, 55u8, 3u8, 33u8, 188u8, 134u8, - 18u8, 151u8, 132u8, 40u8, 192u8, 215u8, 94u8, 124u8, 148u8, 142u8, - ], - ) - } - } - } - } - pub mod paras_disputes { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_parachains::disputes::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -28836,29 +26267,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceUnfreeze; - pub struct TransactionApi; - impl TransactionApi { - pub fn force_unfreeze(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParasDisputes", - "force_unfreeze", - ForceUnfreeze {}, - [ - 212u8, 211u8, 58u8, 159u8, 23u8, 220u8, 64u8, 175u8, 65u8, 50u8, 192u8, - 122u8, 113u8, 189u8, 74u8, 191u8, 48u8, 93u8, 251u8, 50u8, 237u8, - 240u8, 91u8, 139u8, 193u8, 114u8, 131u8, 125u8, 124u8, 236u8, 191u8, - 190u8, - ], - ) - } + pub struct SetMaxHeadDataSize { + pub new: ::core::primitive::u32, } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::polkadot_runtime_parachains::disputes::pallet::Event; - pub mod events { - use super::runtime_types; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -28868,16 +26281,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A dispute has been initiated. \\[candidate hash, dispute location\\]"] - pub struct DisputeInitiated( - pub runtime_types::polkadot_core_primitives::CandidateHash, - pub runtime_types::polkadot_runtime_parachains::disputes::DisputeLocation, - ); - impl ::subxt::events::StaticEvent for DisputeInitiated { - const PALLET: &'static str = "ParasDisputes"; - const EVENT: &'static str = "DisputeInitiated"; + pub struct SetParathreadCores { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -28887,17 +26295,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A dispute has concluded for or against a candidate."] - #[doc = "`\\[para id, candidate hash, dispute result\\]`"] - pub struct DisputeConcluded( - pub runtime_types::polkadot_core_primitives::CandidateHash, - pub runtime_types::polkadot_runtime_parachains::disputes::DisputeResult, - ); - impl ::subxt::events::StaticEvent for DisputeConcluded { - const PALLET: &'static str = "ParasDisputes"; - const EVENT: &'static str = "DisputeConcluded"; + pub struct SetParathreadRetries { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -28907,12 +26309,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A dispute has timed out due to insufficient participation."] - #[doc = "`\\[para id, candidate hash\\]`"] - pub struct DisputeTimedOut(pub runtime_types::polkadot_core_primitives::CandidateHash); - impl ::subxt::events::StaticEvent for DisputeTimedOut { - const PALLET: &'static str = "ParasDisputes"; - const EVENT: &'static str = "DisputeTimedOut"; + pub struct SetGroupRotationFrequency { + pub new: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: CompactAs, @@ -28925,240 +26323,25 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A dispute has concluded with supermajority against a candidate."] - #[doc = "Block authors should no longer build on top of this head and should"] - #[doc = "instead revert the block at the given height. This should be the"] - #[doc = "number of the child of the last known valid block in the chain."] - pub struct Revert(pub ::core::primitive::u32); - impl ::subxt::events::StaticEvent for Revert { - const PALLET: &'static str = "ParasDisputes"; - const EVENT: &'static str = "Revert"; + pub struct SetChainAvailabilityPeriod { + pub new: ::core::primitive::u32, } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The last pruned session, if any. All data stored by this module"] - #[doc = " references sessions."] - pub fn last_pruned_session( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "LastPrunedSession", - vec![], - [ - 125u8, 138u8, 99u8, 242u8, 9u8, 246u8, 215u8, 246u8, 141u8, 6u8, 129u8, - 87u8, 27u8, 58u8, 53u8, 121u8, 61u8, 119u8, 35u8, 104u8, 33u8, 43u8, - 179u8, 82u8, 244u8, 121u8, 174u8, 135u8, 87u8, 119u8, 236u8, 105u8, - ], - ) - } - #[doc = " All ongoing or concluded disputes for the last several sessions."] - pub fn disputes( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow< - runtime_types::polkadot_core_primitives::CandidateHash, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v2::DisputeState<::core::primitive::u32>, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "Disputes", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 192u8, 238u8, 255u8, 67u8, 169u8, 86u8, 99u8, 243u8, 228u8, 88u8, - 142u8, 138u8, 183u8, 117u8, 82u8, 22u8, 163u8, 30u8, 175u8, 247u8, - 50u8, 204u8, 12u8, 171u8, 57u8, 189u8, 151u8, 191u8, 196u8, 89u8, 94u8, - 165u8, - ], - ) - } - #[doc = " All ongoing or concluded disputes for the last several sessions."] - pub fn disputes_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v2::DisputeState<::core::primitive::u32>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "Disputes", - Vec::new(), - [ - 192u8, 238u8, 255u8, 67u8, 169u8, 86u8, 99u8, 243u8, 228u8, 88u8, - 142u8, 138u8, 183u8, 117u8, 82u8, 22u8, 163u8, 30u8, 175u8, 247u8, - 50u8, 204u8, 12u8, 171u8, 57u8, 189u8, 151u8, 191u8, 196u8, 89u8, 94u8, - 165u8, - ], - ) - } - #[doc = " All included blocks on the chain, as well as the block number in this chain that"] - #[doc = " should be reverted back to if the candidate is disputed and determined to be invalid."] - pub fn included( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow< - runtime_types::polkadot_core_primitives::CandidateHash, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "Included", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 129u8, 50u8, 76u8, 60u8, 82u8, 106u8, 248u8, 164u8, 152u8, 80u8, 58u8, - 185u8, 211u8, 225u8, 122u8, 100u8, 234u8, 241u8, 123u8, 205u8, 4u8, - 8u8, 193u8, 116u8, 167u8, 158u8, 252u8, 223u8, 204u8, 226u8, 74u8, - 195u8, - ], - ) - } - #[doc = " All included blocks on the chain, as well as the block number in this chain that"] - #[doc = " should be reverted back to if the candidate is disputed and determined to be invalid."] - pub fn included_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "Included", - Vec::new(), - [ - 129u8, 50u8, 76u8, 60u8, 82u8, 106u8, 248u8, 164u8, 152u8, 80u8, 58u8, - 185u8, 211u8, 225u8, 122u8, 100u8, 234u8, 241u8, 123u8, 205u8, 4u8, - 8u8, 193u8, 116u8, 167u8, 158u8, 252u8, 223u8, 204u8, 226u8, 74u8, - 195u8, - ], - ) - } - #[doc = " Maps session indices to a vector indicating the number of potentially-spam disputes"] - #[doc = " each validator is participating in. Potentially-spam disputes are remote disputes which have"] - #[doc = " fewer than `byzantine_threshold + 1` validators."] - #[doc = ""] - #[doc = " The i'th entry of the vector corresponds to the i'th validator in the session."] - pub fn spam_slots( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u32>, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "SpamSlots", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 172u8, 23u8, 120u8, 188u8, 71u8, 248u8, 252u8, 41u8, 132u8, 221u8, - 98u8, 215u8, 33u8, 242u8, 168u8, 196u8, 90u8, 123u8, 190u8, 27u8, - 147u8, 6u8, 196u8, 175u8, 198u8, 216u8, 50u8, 74u8, 138u8, 122u8, - 251u8, 238u8, - ], - ) - } - #[doc = " Maps session indices to a vector indicating the number of potentially-spam disputes"] - #[doc = " each validator is participating in. Potentially-spam disputes are remote disputes which have"] - #[doc = " fewer than `byzantine_threshold + 1` validators."] - #[doc = ""] - #[doc = " The i'th entry of the vector corresponds to the i'th validator in the session."] - pub fn spam_slots_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u32>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "SpamSlots", - Vec::new(), - [ - 172u8, 23u8, 120u8, 188u8, 71u8, 248u8, 252u8, 41u8, 132u8, 221u8, - 98u8, 215u8, 33u8, 242u8, 168u8, 196u8, 90u8, 123u8, 190u8, 27u8, - 147u8, 6u8, 196u8, 175u8, 198u8, 216u8, 50u8, 74u8, 138u8, 122u8, - 251u8, 238u8, - ], - ) - } - #[doc = " Whether the chain is frozen. Starts as `None`. When this is `Some`,"] - #[doc = " the chain will not accept any new parachain blocks for backing or inclusion,"] - #[doc = " and its value indicates the last valid block number in the chain."] - #[doc = " It can only be set back to `None` by governance intervention."] - pub fn frozen( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::option::Option<::core::primitive::u32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "Frozen", - vec![], - [ - 133u8, 100u8, 86u8, 220u8, 180u8, 189u8, 65u8, 131u8, 64u8, 56u8, - 219u8, 47u8, 130u8, 167u8, 210u8, 125u8, 49u8, 7u8, 153u8, 254u8, 20u8, - 53u8, 218u8, 177u8, 122u8, 148u8, 16u8, 198u8, 251u8, 50u8, 194u8, - 128u8, - ], - ) - } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetThreadAvailabilityPeriod { + pub new: ::core::primitive::u32, } - } - } - pub mod registrar { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_common::paras_registrar::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -29168,10 +26351,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Register { - pub id: runtime_types::polkadot_parachain::primitives::Id, - pub genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, - pub validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + pub struct SetSchedulingLookahead { + pub new: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -29183,12 +26364,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceRegister { - pub who: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - pub id: runtime_types::polkadot_parachain::primitives::Id, - pub genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, - pub validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + pub struct SetMaxValidatorsPerCore { + pub new: ::core::option::Option<::core::primitive::u32>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -29200,10 +26377,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Deregister { - pub id: runtime_types::polkadot_parachain::primitives::Id, + pub struct SetMaxValidators { + pub new: ::core::option::Option<::core::primitive::u32>, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -29213,11 +26391,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Swap { - pub id: runtime_types::polkadot_parachain::primitives::Id, - pub other: runtime_types::polkadot_parachain::primitives::Id, + pub struct SetDisputePeriod { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -29227,10 +26405,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveLock { - pub para: runtime_types::polkadot_parachain::primitives::Id, + pub struct SetDisputePostConclusionAcceptancePeriod { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -29240,8 +26419,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Reserve; + pub struct SetNoShowSlots { + pub new: ::core::primitive::u32, + } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -29251,10 +26433,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddLock { - pub para: runtime_types::polkadot_parachain::primitives::Id, + pub struct SetNDelayTranches { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -29264,11 +26447,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduleCodeUpgrade { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + pub struct SetZerothDelayTrancheWidth { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -29278,234 +26461,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCurrentHead { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub new_head: runtime_types::polkadot_parachain::primitives::HeadData, + pub struct SetNeededApprovals { + pub new: ::core::primitive::u32, } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Register head data and validation code for a reserved Para Id."] - #[doc = ""] - #[doc = "## Arguments"] - #[doc = "- `origin`: Must be called by a `Signed` origin."] - #[doc = "- `id`: The para ID. Must be owned/managed by the `origin` signing account."] - #[doc = "- `genesis_head`: The genesis head data of the parachain/thread."] - #[doc = "- `validation_code`: The initial validation code of the parachain/thread."] - #[doc = ""] - #[doc = "## Deposits/Fees"] - #[doc = "The origin signed account must reserve a corresponding deposit for the registration. Anything already"] - #[doc = "reserved previously for this para ID is accounted for."] - #[doc = ""] - #[doc = "## Events"] - #[doc = "The `Registered` event is emitted in case of success."] - pub fn register( - &self, - id: runtime_types::polkadot_parachain::primitives::Id, - genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, - validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "register", - Register { - id, - genesis_head, - validation_code, - }, - [ - 154u8, 84u8, 201u8, 125u8, 72u8, 69u8, 188u8, 42u8, 225u8, 14u8, 136u8, - 48u8, 78u8, 86u8, 99u8, 238u8, 252u8, 255u8, 226u8, 219u8, 214u8, 17u8, - 19u8, 9u8, 12u8, 13u8, 174u8, 243u8, 37u8, 134u8, 76u8, 23u8, - ], - ) - } - #[doc = "Force the registration of a Para Id on the relay chain."] - #[doc = ""] - #[doc = "This function must be called by a Root origin."] - #[doc = ""] - #[doc = "The deposit taken can be specified for this registration. Any `ParaId`"] - #[doc = "can be registered, including sub-1000 IDs which are System Parachains."] - pub fn force_register( - &self, - who: ::subxt::utils::AccountId32, - deposit: ::core::primitive::u128, - id: runtime_types::polkadot_parachain::primitives::Id, - genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, - validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "force_register", - ForceRegister { - who, - deposit, - id, - genesis_head, - validation_code, - }, - [ - 59u8, 24u8, 236u8, 163u8, 53u8, 49u8, 92u8, 199u8, 38u8, 76u8, 101u8, - 73u8, 166u8, 105u8, 145u8, 55u8, 89u8, 30u8, 30u8, 137u8, 151u8, 219u8, - 116u8, 226u8, 168u8, 220u8, 222u8, 6u8, 105u8, 91u8, 254u8, 216u8, - ], - ) - } - #[doc = "Deregister a Para Id, freeing all data and returning any deposit."] - #[doc = ""] - #[doc = "The caller must be Root, the `para` owner, or the `para` itself. The para must be a parathread."] - pub fn deregister( - &self, - id: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "deregister", - Deregister { id }, - [ - 137u8, 9u8, 146u8, 11u8, 126u8, 125u8, 186u8, 222u8, 246u8, 199u8, - 94u8, 229u8, 147u8, 245u8, 213u8, 51u8, 203u8, 181u8, 78u8, 87u8, 18u8, - 255u8, 79u8, 107u8, 234u8, 2u8, 21u8, 212u8, 1u8, 73u8, 173u8, 253u8, - ], - ) - } - #[doc = "Swap a parachain with another parachain or parathread."] - #[doc = ""] - #[doc = "The origin must be Root, the `para` owner, or the `para` itself."] - #[doc = ""] - #[doc = "The swap will happen only if there is already an opposite swap pending. If there is not,"] - #[doc = "the swap will be stored in the pending swaps map, ready for a later confirmatory swap."] - #[doc = ""] - #[doc = "The `ParaId`s remain mapped to the same head data and code so external code can rely on"] - #[doc = "`ParaId` to be a long-term identifier of a notional \"parachain\". However, their"] - #[doc = "scheduling info (i.e. whether they're a parathread or parachain), auction information"] - #[doc = "and the auction deposit are switched."] - pub fn swap( - &self, - id: runtime_types::polkadot_parachain::primitives::Id, - other: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "swap", - Swap { id, other }, - [ - 238u8, 154u8, 249u8, 250u8, 57u8, 242u8, 47u8, 17u8, 50u8, 70u8, 124u8, - 189u8, 193u8, 137u8, 107u8, 138u8, 216u8, 137u8, 160u8, 103u8, 192u8, - 133u8, 7u8, 130u8, 41u8, 39u8, 47u8, 139u8, 202u8, 7u8, 84u8, 214u8, - ], - ) - } - #[doc = "Remove a manager lock from a para. This will allow the manager of a"] - #[doc = "previously locked para to deregister or swap a para without using governance."] - #[doc = ""] - #[doc = "Can only be called by the Root origin or the parachain."] - pub fn remove_lock( - &self, - para: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "remove_lock", - RemoveLock { para }, - [ - 93u8, 50u8, 223u8, 180u8, 185u8, 3u8, 225u8, 27u8, 233u8, 205u8, 101u8, - 86u8, 122u8, 19u8, 147u8, 8u8, 202u8, 151u8, 80u8, 24u8, 196u8, 2u8, - 88u8, 250u8, 184u8, 96u8, 158u8, 70u8, 181u8, 201u8, 200u8, 213u8, - ], - ) - } - #[doc = "Reserve a Para Id on the relay chain."] - #[doc = ""] - #[doc = "This function will reserve a new Para Id to be owned/managed by the origin account."] - #[doc = "The origin account is able to register head data and validation code using `register` to create"] - #[doc = "a parathread. Using the Slots pallet, a parathread can then be upgraded to get a parachain slot."] - #[doc = ""] - #[doc = "## Arguments"] - #[doc = "- `origin`: Must be called by a `Signed` origin. Becomes the manager/owner of the new para ID."] - #[doc = ""] - #[doc = "## Deposits/Fees"] - #[doc = "The origin must reserve a deposit of `ParaDeposit` for the registration."] - #[doc = ""] - #[doc = "## Events"] - #[doc = "The `Reserved` event is emitted in case of success, which provides the ID reserved for use."] - pub fn reserve(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "reserve", - Reserve {}, - [ - 22u8, 210u8, 13u8, 54u8, 253u8, 13u8, 89u8, 174u8, 232u8, 119u8, 148u8, - 206u8, 130u8, 133u8, 199u8, 127u8, 201u8, 205u8, 8u8, 213u8, 108u8, - 93u8, 135u8, 88u8, 238u8, 171u8, 31u8, 193u8, 23u8, 113u8, 106u8, - 135u8, - ], - ) - } - #[doc = "Add a manager lock from a para. This will prevent the manager of a"] - #[doc = "para to deregister or swap a para."] - #[doc = ""] - #[doc = "Can be called by Root, the parachain, or the parachain manager if the parachain is unlocked."] - pub fn add_lock( - &self, - para: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "add_lock", - AddLock { para }, - [ - 99u8, 199u8, 192u8, 92u8, 180u8, 52u8, 86u8, 165u8, 249u8, 60u8, 72u8, - 79u8, 233u8, 5u8, 83u8, 194u8, 48u8, 83u8, 249u8, 218u8, 141u8, 234u8, - 232u8, 59u8, 9u8, 150u8, 147u8, 173u8, 91u8, 154u8, 81u8, 17u8, - ], - ) - } - #[doc = "Schedule a parachain upgrade."] - #[doc = ""] - #[doc = "Can be called by Root, the parachain, or the parachain manager if the parachain is unlocked."] - pub fn schedule_code_upgrade( - &self, - para: runtime_types::polkadot_parachain::primitives::Id, - new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "schedule_code_upgrade", - ScheduleCodeUpgrade { para, new_code }, - [ - 67u8, 11u8, 148u8, 83u8, 36u8, 106u8, 97u8, 77u8, 79u8, 114u8, 249u8, - 218u8, 207u8, 89u8, 209u8, 120u8, 45u8, 101u8, 69u8, 21u8, 61u8, 158u8, - 90u8, 83u8, 29u8, 143u8, 55u8, 9u8, 178u8, 75u8, 183u8, 25u8, - ], - ) - } - #[doc = "Set the parachain's current head."] - #[doc = ""] - #[doc = "Can be called by Root, the parachain, or the parachain manager if the parachain is unlocked."] - pub fn set_current_head( - &self, - para: runtime_types::polkadot_parachain::primitives::Id, - new_head: runtime_types::polkadot_parachain::primitives::HeadData, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "set_current_head", - SetCurrentHead { para, new_head }, - [ - 103u8, 240u8, 206u8, 26u8, 120u8, 189u8, 94u8, 221u8, 174u8, 225u8, - 210u8, 176u8, 217u8, 18u8, 94u8, 216u8, 77u8, 205u8, 86u8, 196u8, - 121u8, 4u8, 230u8, 147u8, 19u8, 224u8, 38u8, 254u8, 199u8, 254u8, - 245u8, 110u8, - ], - ) - } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::polkadot_runtime_common::paras_registrar::pallet::Event; - pub mod events { - use super::runtime_types; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -29515,15 +26475,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Registered { - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - pub manager: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Registered { - const PALLET: &'static str = "Registrar"; - const EVENT: &'static str = "Registered"; + pub struct SetRelayVrfModuloSamples { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -29533,14 +26489,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Deregistered { - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - } - impl ::subxt::events::StaticEvent for Deregistered { - const PALLET: &'static str = "Registrar"; - const EVENT: &'static str = "Deregistered"; + pub struct SetMaxUpwardQueueCount { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -29550,191 +26503,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Reserved { - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Reserved { - const PALLET: &'static str = "Registrar"; - const EVENT: &'static str = "Reserved"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Pending swap operations."] - pub fn pending_swap( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::Id, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Registrar", - "PendingSwap", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 121u8, 124u8, 4u8, 120u8, 173u8, 48u8, 227u8, 135u8, 72u8, 74u8, 238u8, - 230u8, 1u8, 175u8, 33u8, 241u8, 138u8, 82u8, 217u8, 129u8, 138u8, - 107u8, 59u8, 8u8, 205u8, 244u8, 192u8, 159u8, 171u8, 123u8, 149u8, - 174u8, - ], - ) - } - #[doc = " Pending swap operations."] - pub fn pending_swap_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::Id, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Registrar", - "PendingSwap", - Vec::new(), - [ - 121u8, 124u8, 4u8, 120u8, 173u8, 48u8, 227u8, 135u8, 72u8, 74u8, 238u8, - 230u8, 1u8, 175u8, 33u8, 241u8, 138u8, 82u8, 217u8, 129u8, 138u8, - 107u8, 59u8, 8u8, 205u8, 244u8, 192u8, 159u8, 171u8, 123u8, 149u8, - 174u8, - ], - ) - } - #[doc = " Amount held on deposit for each para and the original depositor."] - #[doc = ""] - #[doc = " The given account ID is responsible for registering the code and initial head data, but may only do"] - #[doc = " so if it isn't yet registered. (After that, it's up to governance to do so.)"] - pub fn paras( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::paras_registrar::ParaInfo< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Registrar", - "Paras", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 149u8, 3u8, 25u8, 145u8, 60u8, 126u8, 219u8, 71u8, 88u8, 241u8, 122u8, - 99u8, 134u8, 191u8, 60u8, 172u8, 230u8, 230u8, 110u8, 31u8, 43u8, 6u8, - 146u8, 161u8, 51u8, 21u8, 169u8, 220u8, 240u8, 218u8, 124u8, 56u8, - ], - ) - } - #[doc = " Amount held on deposit for each para and the original depositor."] - #[doc = ""] - #[doc = " The given account ID is responsible for registering the code and initial head data, but may only do"] - #[doc = " so if it isn't yet registered. (After that, it's up to governance to do so.)"] - pub fn paras_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::paras_registrar::ParaInfo< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Registrar", - "Paras", - Vec::new(), - [ - 149u8, 3u8, 25u8, 145u8, 60u8, 126u8, 219u8, 71u8, 88u8, 241u8, 122u8, - 99u8, 134u8, 191u8, 60u8, 172u8, 230u8, 230u8, 110u8, 31u8, 43u8, 6u8, - 146u8, 161u8, 51u8, 21u8, 169u8, 220u8, 240u8, 218u8, 124u8, 56u8, - ], - ) - } - #[doc = " The next free `ParaId`."] - pub fn next_free_para_id( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain::primitives::Id, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Registrar", - "NextFreeParaId", - vec![], - [ - 139u8, 76u8, 36u8, 150u8, 237u8, 36u8, 143u8, 242u8, 252u8, 29u8, - 236u8, 168u8, 97u8, 50u8, 175u8, 120u8, 83u8, 118u8, 205u8, 64u8, 95u8, - 65u8, 7u8, 230u8, 171u8, 86u8, 189u8, 205u8, 231u8, 211u8, 97u8, 29u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The deposit to be paid to run a parathread."] - #[doc = " This should include the cost for storing the genesis head and validation code."] - pub fn para_deposit(&self) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Registrar", - "ParaDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The deposit to be paid per byte stored on chain."] - pub fn data_deposit_per_byte( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Registrar", - "DataDepositPerByte", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } + pub struct SetMaxUpwardQueueSize { + pub new: ::core::primitive::u32, } - } - } - pub mod slots { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_common::slots::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -29744,12 +26517,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceLease { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub leaser: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - pub period_begin: ::core::primitive::u32, - pub period_count: ::core::primitive::u32, + pub struct SetMaxDownwardMessageSize { + pub new: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -29761,10 +26530,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClearAllLeases { - pub para: runtime_types::polkadot_parachain::primitives::Id, + pub struct SetUmpServiceTotalWeight { + pub new: runtime_types::sp_weights::weight_v2::Weight, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -29774,86 +26544,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TriggerOnboard { - pub para: runtime_types::polkadot_parachain::primitives::Id, - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Just a connect into the `lease_out` call, in case Root wants to force some lease to happen"] - #[doc = "independently of any other on-chain mechanism to use it."] - #[doc = ""] - #[doc = "The dispatch origin for this call must match `T::ForceOrigin`."] - pub fn force_lease( - &self, - para: runtime_types::polkadot_parachain::primitives::Id, - leaser: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - period_begin: ::core::primitive::u32, - period_count: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Slots", - "force_lease", - ForceLease { - para, - leaser, - amount, - period_begin, - period_count, - }, - [ - 196u8, 2u8, 63u8, 229u8, 18u8, 134u8, 48u8, 4u8, 165u8, 46u8, 173u8, - 0u8, 189u8, 35u8, 99u8, 84u8, 103u8, 124u8, 233u8, 246u8, 60u8, 172u8, - 181u8, 205u8, 154u8, 164u8, 36u8, 178u8, 60u8, 164u8, 166u8, 21u8, - ], - ) - } - #[doc = "Clear all leases for a Para Id, refunding any deposits back to the original owners."] - #[doc = ""] - #[doc = "The dispatch origin for this call must match `T::ForceOrigin`."] - pub fn clear_all_leases( - &self, - para: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Slots", - "clear_all_leases", - ClearAllLeases { para }, - [ - 16u8, 14u8, 185u8, 45u8, 149u8, 70u8, 177u8, 133u8, 130u8, 173u8, - 196u8, 244u8, 77u8, 63u8, 218u8, 64u8, 108u8, 83u8, 84u8, 184u8, 175u8, - 122u8, 36u8, 115u8, 146u8, 117u8, 132u8, 82u8, 2u8, 144u8, 62u8, 179u8, - ], - ) - } - #[doc = "Try to onboard a parachain that has a lease for the current lease period."] - #[doc = ""] - #[doc = "This function can be useful if there was some state issue with a para that should"] - #[doc = "have onboarded, but was unable to. As long as they have a lease period, we can"] - #[doc = "let them onboard from here."] - #[doc = ""] - #[doc = "Origin must be signed, but can be called by anyone."] - pub fn trigger_onboard( - &self, - para: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Slots", - "trigger_onboard", - TriggerOnboard { para }, - [ - 74u8, 158u8, 122u8, 37u8, 34u8, 62u8, 61u8, 218u8, 94u8, 222u8, 1u8, - 153u8, 131u8, 215u8, 157u8, 180u8, 98u8, 130u8, 151u8, 179u8, 22u8, - 120u8, 32u8, 207u8, 208u8, 46u8, 248u8, 43u8, 154u8, 118u8, 106u8, 2u8, - ], - ) - } + pub struct SetMaxUpwardMessageSize { + pub new: ::core::primitive::u32, } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::polkadot_runtime_common::slots::pallet::Event; - pub mod events { - use super::runtime_types; #[derive( :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, @@ -29865,15 +26558,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new `[lease_period]` is beginning."] - pub struct NewLeasePeriod { - pub lease_period: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for NewLeasePeriod { - const PALLET: &'static str = "Slots"; - const EVENT: &'static str = "NewLeasePeriod"; + pub struct SetMaxUpwardMessageNumPerCandidate { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -29883,157 +26572,25 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A para has won the right to a continuous set of lease periods as a parachain."] - #[doc = "First balance is any extra amount reserved on top of the para's existing deposit."] - #[doc = "Second balance is the total amount reserved."] - pub struct Leased { - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - pub leaser: ::subxt::utils::AccountId32, - pub period_begin: ::core::primitive::u32, - pub period_count: ::core::primitive::u32, - pub extra_reserved: ::core::primitive::u128, - pub total_amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Leased { - const PALLET: &'static str = "Slots"; - const EVENT: &'static str = "Leased"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Amounts held on deposit for each (possibly future) leased parachain."] - #[doc = ""] - #[doc = " The actual amount locked on its behalf by any account at any time is the maximum of the second values"] - #[doc = " of the items in this list whose first value is the account."] - #[doc = ""] - #[doc = " The first item in the list is the amount locked for the current Lease Period. Following"] - #[doc = " items are for the subsequent lease periods."] - #[doc = ""] - #[doc = " The default value (an empty list) implies that the parachain no longer exists (or never"] - #[doc = " existed) as far as this pallet is concerned."] - #[doc = ""] - #[doc = " If a parachain doesn't exist *yet* but is scheduled to exist in the future, then it"] - #[doc = " will be left-padded with one or more `None`s to denote the fact that nothing is held on"] - #[doc = " deposit for the non-existent chain currently, but is held at some point in the future."] - #[doc = ""] - #[doc = " It is illegal for a `None` value to trail in the list."] - pub fn leases( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - ::core::option::Option<( - ::subxt::utils::AccountId32, - ::core::primitive::u128, - )>, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Slots", - "Leases", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 7u8, 104u8, 17u8, 66u8, 157u8, 89u8, 238u8, 38u8, 233u8, 241u8, 110u8, - 67u8, 132u8, 101u8, 243u8, 62u8, 73u8, 7u8, 9u8, 172u8, 22u8, 51u8, - 118u8, 87u8, 3u8, 224u8, 120u8, 88u8, 139u8, 11u8, 96u8, 147u8, - ], - ) - } - #[doc = " Amounts held on deposit for each (possibly future) leased parachain."] - #[doc = ""] - #[doc = " The actual amount locked on its behalf by any account at any time is the maximum of the second values"] - #[doc = " of the items in this list whose first value is the account."] - #[doc = ""] - #[doc = " The first item in the list is the amount locked for the current Lease Period. Following"] - #[doc = " items are for the subsequent lease periods."] - #[doc = ""] - #[doc = " The default value (an empty list) implies that the parachain no longer exists (or never"] - #[doc = " existed) as far as this pallet is concerned."] - #[doc = ""] - #[doc = " If a parachain doesn't exist *yet* but is scheduled to exist in the future, then it"] - #[doc = " will be left-padded with one or more `None`s to denote the fact that nothing is held on"] - #[doc = " deposit for the non-existent chain currently, but is held at some point in the future."] - #[doc = ""] - #[doc = " It is illegal for a `None` value to trail in the list."] - pub fn leases_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - ::core::option::Option<( - ::subxt::utils::AccountId32, - ::core::primitive::u128, - )>, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Slots", - "Leases", - Vec::new(), - [ - 7u8, 104u8, 17u8, 66u8, 157u8, 89u8, 238u8, 38u8, 233u8, 241u8, 110u8, - 67u8, 132u8, 101u8, 243u8, 62u8, 73u8, 7u8, 9u8, 172u8, 22u8, 51u8, - 118u8, 87u8, 3u8, 224u8, 120u8, 88u8, 139u8, 11u8, 96u8, 147u8, - ], - ) - } + pub struct SetHrmpOpenRequestTtl { + pub new: ::core::primitive::u32, } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The number of blocks over which a single period lasts."] - pub fn lease_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Slots", - "LeasePeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The number of blocks to offset each lease period by."] - pub fn lease_offset(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Slots", - "LeaseOffset", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetHrmpSenderDeposit { + pub new: ::core::primitive::u128, } - } - } - pub mod auctions { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_common::auctions::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -30043,13 +26600,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NewAuction { - #[codec(compact)] - pub duration: ::core::primitive::u32, - #[codec(compact)] - pub lease_period_index: ::core::primitive::u32, + pub struct SetHrmpRecipientDeposit { + pub new: ::core::primitive::u128, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -30059,19 +26614,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Bid { - #[codec(compact)] - pub para: runtime_types::polkadot_parachain::primitives::Id, - #[codec(compact)] - pub auction_index: ::core::primitive::u32, - #[codec(compact)] - pub first_slot: ::core::primitive::u32, - #[codec(compact)] - pub last_slot: ::core::primitive::u32, - #[codec(compact)] - pub amount: ::core::primitive::u128, + pub struct SetHrmpChannelMaxCapacity { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -30081,117 +26628,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelAuction; - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Create a new auction."] - #[doc = ""] - #[doc = "This can only happen when there isn't already an auction in progress and may only be"] - #[doc = "called by the root origin. Accepts the `duration` of this auction and the"] - #[doc = "`lease_period_index` of the initial lease period of the four that are to be auctioned."] - pub fn new_auction( - &self, - duration: ::core::primitive::u32, - lease_period_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Auctions", - "new_auction", - NewAuction { - duration, - lease_period_index, - }, - [ - 171u8, 40u8, 200u8, 164u8, 213u8, 10u8, 145u8, 164u8, 212u8, 14u8, - 117u8, 215u8, 248u8, 59u8, 34u8, 79u8, 50u8, 176u8, 164u8, 143u8, 92u8, - 82u8, 207u8, 37u8, 103u8, 252u8, 255u8, 142u8, 239u8, 134u8, 114u8, - 151u8, - ], - ) - } - #[doc = "Make a new bid from an account (including a parachain account) for deploying a new"] - #[doc = "parachain."] - #[doc = ""] - #[doc = "Multiple simultaneous bids from the same bidder are allowed only as long as all active"] - #[doc = "bids overlap each other (i.e. are mutually exclusive). Bids cannot be redacted."] - #[doc = ""] - #[doc = "- `sub` is the sub-bidder ID, allowing for multiple competing bids to be made by (and"] - #[doc = "funded by) the same account."] - #[doc = "- `auction_index` is the index of the auction to bid on. Should just be the present"] - #[doc = "value of `AuctionCounter`."] - #[doc = "- `first_slot` is the first lease period index of the range to bid on. This is the"] - #[doc = "absolute lease period index value, not an auction-specific offset."] - #[doc = "- `last_slot` is the last lease period index of the range to bid on. This is the"] - #[doc = "absolute lease period index value, not an auction-specific offset."] - #[doc = "- `amount` is the amount to bid to be held as deposit for the parachain should the"] - #[doc = "bid win. This amount is held throughout the range."] - pub fn bid( - &self, - para: runtime_types::polkadot_parachain::primitives::Id, - auction_index: ::core::primitive::u32, - first_slot: ::core::primitive::u32, - last_slot: ::core::primitive::u32, - amount: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Auctions", - "bid", - Bid { - para, - auction_index, - first_slot, - last_slot, - amount, - }, - [ - 243u8, 233u8, 248u8, 221u8, 239u8, 59u8, 65u8, 63u8, 125u8, 129u8, - 202u8, 165u8, 30u8, 228u8, 32u8, 73u8, 225u8, 38u8, 128u8, 98u8, 102u8, - 46u8, 203u8, 32u8, 70u8, 74u8, 136u8, 163u8, 83u8, 211u8, 227u8, 139u8, - ], - ) - } - #[doc = "Cancel an in-progress auction."] - #[doc = ""] - #[doc = "Can only be called by Root origin."] - pub fn cancel_auction(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Auctions", - "cancel_auction", - CancelAuction {}, - [ - 182u8, 223u8, 178u8, 136u8, 1u8, 115u8, 229u8, 78u8, 166u8, 128u8, - 28u8, 106u8, 6u8, 248u8, 46u8, 55u8, 110u8, 120u8, 213u8, 11u8, 90u8, - 217u8, 42u8, 120u8, 47u8, 83u8, 126u8, 216u8, 236u8, 251u8, 255u8, - 50u8, - ], - ) - } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::polkadot_runtime_common::auctions::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An auction started. Provides its index and the block number where it will begin to"] - #[doc = "close and the first lease period of the quadruplet that is auctioned."] - pub struct AuctionStarted { - pub auction_index: ::core::primitive::u32, - pub lease_period: ::core::primitive::u32, - pub ending: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for AuctionStarted { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "AuctionStarted"; + pub struct SetHrmpChannelMaxTotalSize { + pub new: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: CompactAs, @@ -30204,55 +26642,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An auction ended. All funds become unreserved."] - pub struct AuctionClosed { - pub auction_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for AuctionClosed { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "AuctionClosed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Funds were reserved for a winning bid. First balance is the extra amount reserved."] - #[doc = "Second is the total."] - pub struct Reserved { - pub bidder: ::subxt::utils::AccountId32, - pub extra_reserved: ::core::primitive::u128, - pub total_amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Reserved { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "Reserved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Funds were unreserved since bidder is no longer active. `[bidder, amount]`"] - pub struct Unreserved { - pub bidder: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Unreserved { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "Unreserved"; + pub struct SetHrmpMaxParachainInboundChannels { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -30262,18 +26656,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Someone attempted to lease the same slot twice for a parachain. The amount is held in reserve"] - #[doc = "but no parachain slot has been leased."] - pub struct ReserveConfiscated { - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - pub leaser: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for ReserveConfiscated { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "ReserveConfiscated"; + pub struct SetHrmpMaxParathreadInboundChannels { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -30283,19 +26670,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new bid has been accepted as the current winner."] - pub struct BidAccepted { - pub bidder: ::subxt::utils::AccountId32, - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - pub amount: ::core::primitive::u128, - pub first_slot: ::core::primitive::u32, - pub last_slot: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for BidAccepted { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "BidAccepted"; + pub struct SetHrmpChannelMaxMessageSize { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -30305,250 +26684,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The winning offset was chosen for an auction. This will map into the `Winning` storage map."] - pub struct WinningOffset { - pub auction_index: ::core::primitive::u32, - pub block_number: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for WinningOffset { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "WinningOffset"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Number of auctions started so far."] - pub fn auction_counter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Auctions", - "AuctionCounter", - vec![], - [ - 67u8, 247u8, 96u8, 152u8, 0u8, 224u8, 230u8, 98u8, 194u8, 107u8, 3u8, - 203u8, 51u8, 201u8, 149u8, 22u8, 184u8, 80u8, 251u8, 239u8, 253u8, - 19u8, 58u8, 192u8, 65u8, 96u8, 189u8, 54u8, 175u8, 130u8, 143u8, 181u8, - ], - ) - } - #[doc = " Information relating to the current auction, if there is one."] - #[doc = ""] - #[doc = " The first item in the tuple is the lease period index that the first of the four"] - #[doc = " contiguous lease periods on auction is for. The second is the block number when the"] - #[doc = " auction will \"begin to end\", i.e. the first block of the Ending Period of the auction."] - pub fn auction_info( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Auctions", - "AuctionInfo", - vec![], - [ - 73u8, 216u8, 173u8, 230u8, 132u8, 78u8, 83u8, 62u8, 200u8, 69u8, 17u8, - 73u8, 57u8, 107u8, 160u8, 90u8, 147u8, 84u8, 29u8, 110u8, 144u8, 215u8, - 169u8, 110u8, 217u8, 77u8, 109u8, 204u8, 1u8, 164u8, 95u8, 83u8, - ], - ) - } - #[doc = " Amounts currently reserved in the accounts of the bidders currently winning"] - #[doc = " (sub-)ranges."] - pub fn reserved_amounts( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - _1: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Auctions", - "ReservedAmounts", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 120u8, 85u8, 180u8, 244u8, 154u8, 135u8, 87u8, 79u8, 75u8, 169u8, - 220u8, 117u8, 227u8, 85u8, 198u8, 214u8, 28u8, 126u8, 66u8, 188u8, - 137u8, 111u8, 110u8, 152u8, 18u8, 233u8, 76u8, 166u8, 55u8, 233u8, - 93u8, 62u8, - ], - ) - } - #[doc = " Amounts currently reserved in the accounts of the bidders currently winning"] - #[doc = " (sub-)ranges."] - pub fn reserved_amounts_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Auctions", - "ReservedAmounts", - Vec::new(), - [ - 120u8, 85u8, 180u8, 244u8, 154u8, 135u8, 87u8, 79u8, 75u8, 169u8, - 220u8, 117u8, 227u8, 85u8, 198u8, 214u8, 28u8, 126u8, 66u8, 188u8, - 137u8, 111u8, 110u8, 152u8, 18u8, 233u8, 76u8, 166u8, 55u8, 233u8, - 93u8, 62u8, - ], - ) - } - #[doc = " The winning bids for each of the 10 ranges at each sample in the final Ending Period of"] - #[doc = " the current auction. The map's key is the 0-based index into the Sample Size. The"] - #[doc = " first sample of the ending period is 0; the last is `Sample Size - 1`."] - pub fn winning( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - [::core::option::Option<( - ::subxt::utils::AccountId32, - runtime_types::polkadot_parachain::primitives::Id, - ::core::primitive::u128, - )>; 36usize], - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Auctions", - "Winning", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 63u8, 56u8, 143u8, 200u8, 12u8, 71u8, 187u8, 73u8, 215u8, 93u8, 222u8, - 102u8, 5u8, 113u8, 6u8, 170u8, 95u8, 228u8, 28u8, 58u8, 109u8, 62u8, - 3u8, 125u8, 211u8, 139u8, 194u8, 30u8, 151u8, 147u8, 47u8, 205u8, - ], - ) - } - #[doc = " The winning bids for each of the 10 ranges at each sample in the final Ending Period of"] - #[doc = " the current auction. The map's key is the 0-based index into the Sample Size. The"] - #[doc = " first sample of the ending period is 0; the last is `Sample Size - 1`."] - pub fn winning_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - [::core::option::Option<( - ::subxt::utils::AccountId32, - runtime_types::polkadot_parachain::primitives::Id, - ::core::primitive::u128, - )>; 36usize], - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Auctions", - "Winning", - Vec::new(), - [ - 63u8, 56u8, 143u8, 200u8, 12u8, 71u8, 187u8, 73u8, 215u8, 93u8, 222u8, - 102u8, 5u8, 113u8, 6u8, 170u8, 95u8, 228u8, 28u8, 58u8, 109u8, 62u8, - 3u8, 125u8, 211u8, 139u8, 194u8, 30u8, 151u8, 147u8, 47u8, 205u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The number of blocks over which an auction may be retroactively ended."] - pub fn ending_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Auctions", - "EndingPeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The length of each sample to take during the ending period."] - #[doc = ""] - #[doc = " `EndingPeriod` / `SampleLength` = Total # of Samples"] - pub fn sample_length(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Auctions", - "SampleLength", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - pub fn slot_range_count( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Auctions", - "SlotRangeCount", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - pub fn lease_periods_per_slot( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Auctions", - "LeasePeriodsPerSlot", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } + pub struct SetHrmpMaxParachainOutboundChannels { + pub new: ::core::primitive::u32, } - } - } - pub mod crowdloan { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_common::crowdloan::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -30558,20 +26698,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Create { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, - #[codec(compact)] - pub cap: ::core::primitive::u128, - #[codec(compact)] - pub first_period: ::core::primitive::u32, - #[codec(compact)] - pub last_period: ::core::primitive::u32, - #[codec(compact)] - pub end: ::core::primitive::u32, - pub verifier: ::core::option::Option, + pub struct SetHrmpMaxParathreadOutboundChannels { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -30581,12 +26712,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Contribute { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, - #[codec(compact)] - pub value: ::core::primitive::u128, - pub signature: ::core::option::Option, + pub struct SetHrmpMaxMessageNumPerCandidate { + pub new: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -30598,10 +26725,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Withdraw { - pub who: ::subxt::utils::AccountId32, - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, + pub struct SetUmpMaxIndividualWeight { + pub new: runtime_types::sp_weights::weight_v2::Weight, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -30613,11 +26738,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Refund { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, + pub struct SetPvfCheckingEnabled { + pub new: ::core::primitive::bool, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -30627,11 +26752,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Dissolve { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, + pub struct SetPvfVotingTtl { + pub new: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -30641,18 +26766,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Edit { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, - #[codec(compact)] - pub cap: ::core::primitive::u128, - #[codec(compact)] - pub first_period: ::core::primitive::u32, - #[codec(compact)] - pub last_period: ::core::primitive::u32, - #[codec(compact)] - pub end: ::core::primitive::u32, - pub verifier: ::core::option::Option, + pub struct SetMinimumValidationUpgradeDelay { + pub new: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -30664,9 +26779,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddMemo { - pub index: runtime_types::polkadot_parachain::primitives::Id, - pub memo: ::std::vec::Vec<::core::primitive::u8>, + pub struct SetBypassConsistencyCheck { + pub new: ::core::primitive::bool, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -30678,8 +26792,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Poke { - pub index: runtime_types::polkadot_parachain::primitives::Id, + pub struct SetAsyncBackingParams { + pub new: runtime_types::polkadot_primitives::vstaging::AsyncBackingParams, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -30691,1384 +26805,935 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ContributeAll { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, - pub signature: ::core::option::Option, + pub struct SetExecutorParams { + pub new: runtime_types::polkadot_primitives::v4::executor_params::ExecutorParams, } pub struct TransactionApi; impl TransactionApi { - #[doc = "Create a new crowdloaning campaign for a parachain slot with the given lease period range."] - #[doc = ""] - #[doc = "This applies a lock to your parachain configuration, ensuring that it cannot be changed"] - #[doc = "by the parachain manager."] - pub fn create( + #[doc = "Set the validation upgrade cooldown."] + pub fn set_validation_upgrade_cooldown( &self, - index: runtime_types::polkadot_parachain::primitives::Id, - cap: ::core::primitive::u128, - first_period: ::core::primitive::u32, - last_period: ::core::primitive::u32, - end: ::core::primitive::u32, - verifier: ::core::option::Option, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Crowdloan", - "create", - Create { - index, - cap, - first_period, - last_period, - end, - verifier, - }, + "Configuration", + "set_validation_upgrade_cooldown", + SetValidationUpgradeCooldown { new }, [ - 78u8, 52u8, 156u8, 23u8, 104u8, 251u8, 20u8, 233u8, 42u8, 231u8, 16u8, - 192u8, 164u8, 68u8, 98u8, 129u8, 88u8, 126u8, 123u8, 4u8, 210u8, 161u8, - 190u8, 90u8, 67u8, 235u8, 74u8, 184u8, 180u8, 197u8, 248u8, 238u8, + 109u8, 185u8, 0u8, 59u8, 177u8, 198u8, 76u8, 90u8, 108u8, 190u8, 56u8, + 126u8, 147u8, 110u8, 76u8, 111u8, 38u8, 200u8, 230u8, 144u8, 42u8, + 167u8, 175u8, 220u8, 102u8, 37u8, 60u8, 10u8, 118u8, 79u8, 146u8, + 203u8, ], ) } - #[doc = "Contribute to a crowd sale. This will transfer some balance over to fund a parachain"] - #[doc = "slot. It will be withdrawable when the crowdloan has ended and the funds are unused."] - pub fn contribute( + #[doc = "Set the validation upgrade delay."] + pub fn set_validation_upgrade_delay( &self, - index: runtime_types::polkadot_parachain::primitives::Id, - value: ::core::primitive::u128, - signature: ::core::option::Option, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Crowdloan", - "contribute", - Contribute { - index, - value, - signature, - }, + "Configuration", + "set_validation_upgrade_delay", + SetValidationUpgradeDelay { new }, [ - 159u8, 180u8, 248u8, 203u8, 128u8, 231u8, 28u8, 84u8, 14u8, 214u8, - 69u8, 217u8, 62u8, 201u8, 169u8, 160u8, 45u8, 160u8, 125u8, 255u8, - 95u8, 140u8, 58u8, 3u8, 224u8, 157u8, 199u8, 229u8, 72u8, 40u8, 218u8, - 55u8, + 18u8, 130u8, 158u8, 253u8, 160u8, 194u8, 220u8, 120u8, 9u8, 68u8, + 232u8, 176u8, 34u8, 81u8, 200u8, 236u8, 141u8, 139u8, 62u8, 110u8, + 76u8, 9u8, 218u8, 69u8, 55u8, 2u8, 233u8, 109u8, 83u8, 117u8, 141u8, + 253u8, ], ) } - #[doc = "Withdraw full balance of a specific contributor."] - #[doc = ""] - #[doc = "Origin must be signed, but can come from anyone."] - #[doc = ""] - #[doc = "The fund must be either in, or ready for, retirement. For a fund to be *in* retirement, then the retirement"] - #[doc = "flag must be set. For a fund to be ready for retirement, then:"] - #[doc = "- it must not already be in retirement;"] - #[doc = "- the amount of raised funds must be bigger than the _free_ balance of the account;"] - #[doc = "- and either:"] - #[doc = " - the block number must be at least `end`; or"] - #[doc = " - the current lease period must be greater than the fund's `last_period`."] - #[doc = ""] - #[doc = "In this case, the fund's retirement flag is set and its `end` is reset to the current block"] - #[doc = "number."] - #[doc = ""] - #[doc = "- `who`: The account whose contribution should be withdrawn."] - #[doc = "- `index`: The parachain to whose crowdloan the contribution was made."] - pub fn withdraw( + #[doc = "Set the acceptance period for an included candidate."] + pub fn set_code_retention_period( &self, - who: ::subxt::utils::AccountId32, - index: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Crowdloan", - "withdraw", - Withdraw { who, index }, + "Configuration", + "set_code_retention_period", + SetCodeRetentionPeriod { new }, [ - 147u8, 177u8, 116u8, 152u8, 9u8, 102u8, 4u8, 201u8, 204u8, 145u8, - 104u8, 226u8, 86u8, 211u8, 66u8, 109u8, 109u8, 139u8, 229u8, 97u8, - 215u8, 101u8, 255u8, 181u8, 121u8, 139u8, 165u8, 169u8, 112u8, 173u8, - 213u8, 121u8, + 221u8, 140u8, 253u8, 111u8, 64u8, 236u8, 93u8, 52u8, 214u8, 245u8, + 178u8, 30u8, 77u8, 166u8, 242u8, 252u8, 203u8, 106u8, 12u8, 195u8, + 27u8, 159u8, 96u8, 197u8, 145u8, 69u8, 241u8, 59u8, 74u8, 220u8, 62u8, + 205u8, ], ) } - #[doc = "Automatically refund contributors of an ended crowdloan."] - #[doc = "Due to weight restrictions, this function may need to be called multiple"] - #[doc = "times to fully refund all users. We will refund `RemoveKeysLimit` users at a time."] - #[doc = ""] - #[doc = "Origin must be signed, but can come from anyone."] - pub fn refund( + #[doc = "Set the max validation code size for incoming upgrades."] + pub fn set_max_code_size( &self, - index: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Crowdloan", - "refund", - Refund { index }, + "Configuration", + "set_max_code_size", + SetMaxCodeSize { new }, [ - 223u8, 64u8, 5u8, 135u8, 15u8, 234u8, 60u8, 114u8, 199u8, 216u8, 73u8, - 165u8, 198u8, 34u8, 140u8, 142u8, 214u8, 254u8, 203u8, 163u8, 224u8, - 120u8, 104u8, 54u8, 12u8, 126u8, 72u8, 147u8, 20u8, 180u8, 251u8, - 208u8, + 232u8, 106u8, 45u8, 195u8, 27u8, 162u8, 188u8, 213u8, 137u8, 13u8, + 123u8, 89u8, 215u8, 141u8, 231u8, 82u8, 205u8, 215u8, 73u8, 142u8, + 115u8, 109u8, 132u8, 118u8, 194u8, 211u8, 82u8, 20u8, 75u8, 55u8, + 218u8, 46u8, ], ) } - #[doc = "Remove a fund after the retirement period has ended and all funds have been returned."] - pub fn dissolve( + #[doc = "Set the max POV block size for incoming upgrades."] + pub fn set_max_pov_size( &self, - index: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Crowdloan", - "dissolve", - Dissolve { index }, + "Configuration", + "set_max_pov_size", + SetMaxPovSize { new }, [ - 100u8, 67u8, 105u8, 3u8, 213u8, 149u8, 201u8, 146u8, 241u8, 62u8, 31u8, - 108u8, 58u8, 30u8, 241u8, 141u8, 134u8, 115u8, 56u8, 131u8, 60u8, 75u8, - 143u8, 227u8, 11u8, 32u8, 31u8, 230u8, 165u8, 227u8, 170u8, 126u8, + 15u8, 176u8, 13u8, 19u8, 177u8, 160u8, 211u8, 238u8, 29u8, 194u8, + 187u8, 235u8, 244u8, 65u8, 158u8, 47u8, 102u8, 221u8, 95u8, 10u8, 21u8, + 33u8, 219u8, 234u8, 82u8, 122u8, 75u8, 53u8, 14u8, 126u8, 218u8, 23u8, ], ) } - #[doc = "Edit the configuration for an in-progress crowdloan."] - #[doc = ""] - #[doc = "Can only be called by Root origin."] - pub fn edit( + #[doc = "Set the max head data size for paras."] + pub fn set_max_head_data_size( &self, - index: runtime_types::polkadot_parachain::primitives::Id, - cap: ::core::primitive::u128, - first_period: ::core::primitive::u32, - last_period: ::core::primitive::u32, - end: ::core::primitive::u32, - verifier: ::core::option::Option, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Crowdloan", - "edit", - Edit { - index, - cap, - first_period, - last_period, - end, - verifier, - }, + "Configuration", + "set_max_head_data_size", + SetMaxHeadDataSize { new }, [ - 222u8, 124u8, 94u8, 221u8, 36u8, 183u8, 67u8, 114u8, 198u8, 107u8, - 154u8, 174u8, 142u8, 47u8, 3u8, 181u8, 72u8, 29u8, 2u8, 83u8, 81u8, - 47u8, 168u8, 142u8, 139u8, 63u8, 136u8, 191u8, 41u8, 252u8, 221u8, - 56u8, + 219u8, 128u8, 213u8, 65u8, 190u8, 224u8, 87u8, 80u8, 172u8, 112u8, + 160u8, 229u8, 52u8, 1u8, 189u8, 125u8, 177u8, 139u8, 103u8, 39u8, 21u8, + 125u8, 62u8, 177u8, 74u8, 25u8, 41u8, 11u8, 200u8, 79u8, 139u8, 171u8, ], ) } - #[doc = "Add an optional memo to an existing crowdloan contribution."] - #[doc = ""] - #[doc = "Origin must be Signed, and the user must have contributed to the crowdloan."] - pub fn add_memo( + #[doc = "Set the number of parathread execution cores."] + pub fn set_parathread_cores( &self, - index: runtime_types::polkadot_parachain::primitives::Id, - memo: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Crowdloan", - "add_memo", - AddMemo { index, memo }, + "Configuration", + "set_parathread_cores", + SetParathreadCores { new }, [ - 104u8, 199u8, 143u8, 251u8, 28u8, 49u8, 144u8, 186u8, 83u8, 108u8, - 26u8, 127u8, 22u8, 141u8, 48u8, 62u8, 194u8, 193u8, 97u8, 10u8, 84u8, - 89u8, 236u8, 191u8, 40u8, 8u8, 1u8, 250u8, 112u8, 165u8, 221u8, 112u8, + 155u8, 102u8, 168u8, 202u8, 236u8, 87u8, 16u8, 128u8, 141u8, 99u8, + 154u8, 162u8, 216u8, 198u8, 236u8, 233u8, 104u8, 230u8, 137u8, 132u8, + 41u8, 106u8, 167u8, 81u8, 195u8, 172u8, 107u8, 28u8, 138u8, 254u8, + 180u8, 61u8, ], ) } - #[doc = "Poke the fund into `NewRaise`"] - #[doc = ""] - #[doc = "Origin must be Signed, and the fund has non-zero raise."] - pub fn poke( + #[doc = "Set the number of retries for a particular parathread."] + pub fn set_parathread_retries( &self, - index: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Crowdloan", - "poke", - Poke { index }, + "Configuration", + "set_parathread_retries", + SetParathreadRetries { new }, [ - 118u8, 60u8, 131u8, 17u8, 27u8, 153u8, 57u8, 24u8, 191u8, 211u8, 101u8, - 123u8, 34u8, 145u8, 193u8, 113u8, 244u8, 162u8, 148u8, 143u8, 81u8, - 86u8, 136u8, 23u8, 48u8, 185u8, 52u8, 60u8, 216u8, 243u8, 63u8, 102u8, + 192u8, 81u8, 152u8, 41u8, 40u8, 3u8, 251u8, 205u8, 244u8, 133u8, 42u8, + 197u8, 21u8, 221u8, 80u8, 196u8, 222u8, 69u8, 153u8, 39u8, 161u8, 90u8, + 4u8, 38u8, 167u8, 131u8, 237u8, 42u8, 135u8, 37u8, 156u8, 108u8, ], ) } - #[doc = "Contribute your entire balance to a crowd sale. This will transfer the entire balance of a user over to fund a parachain"] - #[doc = "slot. It will be withdrawable when the crowdloan has ended and the funds are unused."] - pub fn contribute_all( + #[doc = "Set the parachain validator-group rotation frequency"] + pub fn set_group_rotation_frequency( &self, - index: runtime_types::polkadot_parachain::primitives::Id, - signature: ::core::option::Option, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Crowdloan", - "contribute_all", - ContributeAll { index, signature }, + "Configuration", + "set_group_rotation_frequency", + SetGroupRotationFrequency { new }, [ - 94u8, 61u8, 105u8, 107u8, 204u8, 18u8, 223u8, 242u8, 19u8, 162u8, - 205u8, 130u8, 203u8, 73u8, 42u8, 85u8, 208u8, 157u8, 115u8, 112u8, - 168u8, 10u8, 163u8, 80u8, 222u8, 71u8, 23u8, 194u8, 142u8, 4u8, 82u8, - 253u8, + 205u8, 222u8, 129u8, 36u8, 136u8, 186u8, 114u8, 70u8, 214u8, 22u8, + 112u8, 65u8, 56u8, 42u8, 103u8, 93u8, 108u8, 242u8, 188u8, 229u8, + 150u8, 19u8, 12u8, 222u8, 25u8, 254u8, 48u8, 218u8, 200u8, 208u8, + 132u8, 251u8, ], ) } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::polkadot_runtime_common::crowdloan::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Create a new crowdloaning campaign."] - pub struct Created { - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - } - impl ::subxt::events::StaticEvent for Created { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "Created"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contributed to a crowd sale."] - pub struct Contributed { - pub who: ::subxt::utils::AccountId32, - pub fund_index: runtime_types::polkadot_parachain::primitives::Id, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Contributed { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "Contributed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Withdrew full balance of a contributor."] - pub struct Withdrew { - pub who: ::subxt::utils::AccountId32, - pub fund_index: runtime_types::polkadot_parachain::primitives::Id, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Withdrew { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "Withdrew"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The loans in a fund have been partially dissolved, i.e. there are some left"] - #[doc = "over child keys that still need to be killed."] - pub struct PartiallyRefunded { - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - } - impl ::subxt::events::StaticEvent for PartiallyRefunded { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "PartiallyRefunded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "All loans in a fund have been refunded."] - pub struct AllRefunded { - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - } - impl ::subxt::events::StaticEvent for AllRefunded { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "AllRefunded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Fund is dissolved."] - pub struct Dissolved { - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - } - impl ::subxt::events::StaticEvent for Dissolved { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "Dissolved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The result of trying to submit a new bid to the Slots pallet."] - pub struct HandleBidResult { - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for HandleBidResult { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "HandleBidResult"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The configuration to a crowdloan has been edited."] - pub struct Edited { - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - } - impl ::subxt::events::StaticEvent for Edited { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "Edited"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A memo has been updated."] - pub struct MemoUpdated { - pub who: ::subxt::utils::AccountId32, - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - pub memo: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::events::StaticEvent for MemoUpdated { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "MemoUpdated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A parachain has been moved to `NewRaise`"] - pub struct AddedToNewRaise { - pub para_id: runtime_types::polkadot_parachain::primitives::Id, - } - impl ::subxt::events::StaticEvent for AddedToNewRaise { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "AddedToNewRaise"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Info on all of the funds."] - pub fn funds( + #[doc = "Set the availability period for parachains."] + pub fn set_chain_availability_period( &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::crowdloan::FundInfo< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Crowdloan", - "Funds", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_chain_availability_period", + SetChainAvailabilityPeriod { new }, [ - 231u8, 126u8, 89u8, 84u8, 167u8, 23u8, 211u8, 70u8, 203u8, 124u8, 20u8, - 162u8, 112u8, 38u8, 201u8, 207u8, 82u8, 202u8, 80u8, 228u8, 4u8, 41u8, - 95u8, 190u8, 193u8, 185u8, 178u8, 85u8, 179u8, 102u8, 53u8, 63u8, + 171u8, 21u8, 54u8, 241u8, 19u8, 100u8, 54u8, 143u8, 97u8, 191u8, 193u8, + 96u8, 7u8, 86u8, 255u8, 109u8, 255u8, 93u8, 113u8, 28u8, 182u8, 75u8, + 120u8, 208u8, 91u8, 125u8, 156u8, 38u8, 56u8, 230u8, 24u8, 139u8, ], ) } - #[doc = " Info on all of the funds."] - pub fn funds_root( + #[doc = "Set the availability period for parathreads."] + pub fn set_thread_availability_period( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::crowdloan::FundInfo< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Crowdloan", - "Funds", - Vec::new(), + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_thread_availability_period", + SetThreadAvailabilityPeriod { new }, [ - 231u8, 126u8, 89u8, 84u8, 167u8, 23u8, 211u8, 70u8, 203u8, 124u8, 20u8, - 162u8, 112u8, 38u8, 201u8, 207u8, 82u8, 202u8, 80u8, 228u8, 4u8, 41u8, - 95u8, 190u8, 193u8, 185u8, 178u8, 85u8, 179u8, 102u8, 53u8, 63u8, + 208u8, 27u8, 246u8, 33u8, 90u8, 200u8, 75u8, 177u8, 19u8, 107u8, 236u8, + 43u8, 159u8, 156u8, 184u8, 10u8, 146u8, 71u8, 212u8, 129u8, 44u8, 19u8, + 162u8, 172u8, 162u8, 46u8, 166u8, 10u8, 67u8, 112u8, 206u8, 50u8, ], ) } - #[doc = " The funds that have had additional contributions during the last block. This is used"] - #[doc = " in order to determine which funds should submit new or updated bids."] - pub fn new_raise( + #[doc = "Set the scheduling lookahead, in expected number of blocks at peak throughput."] + pub fn set_scheduling_lookahead( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Crowdloan", - "NewRaise", - vec![], + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_scheduling_lookahead", + SetSchedulingLookahead { new }, [ - 8u8, 180u8, 9u8, 197u8, 254u8, 198u8, 89u8, 112u8, 29u8, 153u8, 243u8, - 196u8, 92u8, 204u8, 135u8, 232u8, 93u8, 239u8, 147u8, 103u8, 130u8, - 28u8, 128u8, 124u8, 4u8, 236u8, 29u8, 248u8, 27u8, 165u8, 111u8, 147u8, + 220u8, 74u8, 0u8, 150u8, 45u8, 29u8, 56u8, 210u8, 66u8, 12u8, 119u8, + 176u8, 103u8, 24u8, 216u8, 55u8, 211u8, 120u8, 233u8, 204u8, 167u8, + 100u8, 199u8, 157u8, 186u8, 174u8, 40u8, 218u8, 19u8, 230u8, 253u8, + 7u8, ], ) } - #[doc = " The number of auctions that have entered into their ending period so far."] - pub fn endings_count( + #[doc = "Set the maximum number of validators to assign to any core."] + pub fn set_max_validators_per_core( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Crowdloan", - "EndingsCount", - vec![], + new: ::core::option::Option<::core::primitive::u32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_max_validators_per_core", + SetMaxValidatorsPerCore { new }, [ - 12u8, 159u8, 166u8, 75u8, 192u8, 33u8, 21u8, 244u8, 149u8, 200u8, 49u8, - 54u8, 191u8, 174u8, 202u8, 86u8, 76u8, 115u8, 189u8, 35u8, 192u8, - 175u8, 156u8, 188u8, 41u8, 23u8, 92u8, 36u8, 141u8, 235u8, 248u8, - 143u8, + 227u8, 113u8, 192u8, 116u8, 114u8, 171u8, 27u8, 22u8, 84u8, 117u8, + 146u8, 152u8, 94u8, 101u8, 14u8, 52u8, 228u8, 170u8, 163u8, 82u8, + 248u8, 130u8, 32u8, 103u8, 225u8, 151u8, 145u8, 36u8, 98u8, 158u8, 6u8, + 245u8, ], ) } - #[doc = " Tracker for the next available fund index"] - pub fn next_fund_index( + #[doc = "Set the maximum number of validators to use in parachain consensus."] + pub fn set_max_validators( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Crowdloan", - "NextFundIndex", - vec![], + new: ::core::option::Option<::core::primitive::u32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_max_validators", + SetMaxValidators { new }, [ - 1u8, 215u8, 164u8, 194u8, 231u8, 34u8, 207u8, 19u8, 149u8, 187u8, 3u8, - 176u8, 194u8, 240u8, 180u8, 169u8, 214u8, 194u8, 202u8, 240u8, 209u8, - 6u8, 244u8, 46u8, 54u8, 142u8, 61u8, 220u8, 240u8, 96u8, 10u8, 168u8, + 143u8, 212u8, 59u8, 147u8, 4u8, 55u8, 142u8, 209u8, 237u8, 76u8, 7u8, + 178u8, 41u8, 81u8, 4u8, 203u8, 184u8, 149u8, 32u8, 1u8, 106u8, 180u8, + 121u8, 20u8, 137u8, 169u8, 144u8, 77u8, 38u8, 53u8, 243u8, 127u8, ], ) } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " `PalletId` for the crowdloan pallet. An appropriate value could be `PalletId(*b\"py/cfund\")`"] - pub fn pallet_id( + #[doc = "Set the dispute period, in number of sessions to keep for disputes."] + pub fn set_dispute_period( &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "Crowdloan", - "PalletId", + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_dispute_period", + SetDisputePeriod { new }, [ - 139u8, 109u8, 228u8, 151u8, 252u8, 32u8, 130u8, 69u8, 112u8, 154u8, - 174u8, 45u8, 83u8, 245u8, 51u8, 132u8, 173u8, 5u8, 186u8, 24u8, 243u8, - 9u8, 12u8, 214u8, 80u8, 74u8, 69u8, 189u8, 30u8, 94u8, 22u8, 39u8, + 36u8, 191u8, 142u8, 240u8, 48u8, 101u8, 10u8, 197u8, 117u8, 125u8, + 156u8, 189u8, 130u8, 77u8, 242u8, 130u8, 205u8, 154u8, 152u8, 47u8, + 75u8, 56u8, 63u8, 61u8, 33u8, 163u8, 151u8, 97u8, 105u8, 99u8, 55u8, + 180u8, ], ) } - #[doc = " The minimum amount that may be contributed into a crowdloan. Should almost certainly be at"] - #[doc = " least `ExistentialDeposit`."] - pub fn min_contribution( + #[doc = "Set the dispute post conclusion acceptance period."] + pub fn set_dispute_post_conclusion_acceptance_period( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Crowdloan", - "MinContribution", + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload + { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_dispute_post_conclusion_acceptance_period", + SetDisputePostConclusionAcceptancePeriod { new }, [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 66u8, 56u8, 45u8, 87u8, 51u8, 49u8, 91u8, 95u8, 255u8, 185u8, 54u8, + 165u8, 85u8, 142u8, 238u8, 251u8, 174u8, 81u8, 3u8, 61u8, 92u8, 97u8, + 203u8, 20u8, 107u8, 50u8, 208u8, 250u8, 208u8, 159u8, 225u8, 175u8, ], ) } - #[doc = " Max number of storage keys to remove per extrinsic call."] - pub fn remove_keys_limit( + #[doc = "Set the no show slots, in number of number of consensus slots."] + #[doc = "Must be at least 1."] + pub fn set_no_show_slots( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Crowdloan", - "RemoveKeysLimit", + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_no_show_slots", + SetNoShowSlots { new }, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 94u8, 230u8, 89u8, 131u8, 188u8, 246u8, 251u8, 34u8, 249u8, 16u8, + 134u8, 63u8, 238u8, 115u8, 19u8, 97u8, 97u8, 218u8, 238u8, 115u8, + 126u8, 140u8, 236u8, 17u8, 177u8, 192u8, 210u8, 239u8, 126u8, 107u8, + 117u8, 207u8, ], ) } - } - } - } - pub mod xcm_pallet { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_xcm::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Send { - pub dest: ::std::boxed::Box, - pub message: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TeleportAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReserveTransferAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Execute { - pub message: ::std::boxed::Box, - pub max_weight: ::core::primitive::u64, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceXcmVersion { - pub location: - ::std::boxed::Box, - pub xcm_version: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceDefaultXcmVersion { - pub maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSubscribeVersionNotify { - pub location: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceUnsubscribeVersionNotify { - pub location: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct LimitedReserveTransferAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - pub weight_limit: runtime_types::xcm::v2::WeightLimit, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct LimitedTeleportAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - pub weight_limit: runtime_types::xcm::v2::WeightLimit, - } - pub struct TransactionApi; - impl TransactionApi { - pub fn send( + #[doc = "Set the total number of delay tranches."] + pub fn set_n_delay_tranches( &self, - dest: runtime_types::xcm::VersionedMultiLocation, - message: runtime_types::xcm::VersionedXcm, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "XcmPallet", - "send", - Send { - dest: ::std::boxed::Box::new(dest), - message: ::std::boxed::Box::new(message), - }, + "Configuration", + "set_n_delay_tranches", + SetNDelayTranches { new }, [ - 190u8, 88u8, 197u8, 248u8, 111u8, 198u8, 199u8, 206u8, 39u8, 121u8, - 23u8, 121u8, 93u8, 82u8, 22u8, 61u8, 96u8, 210u8, 142u8, 249u8, 195u8, - 78u8, 44u8, 8u8, 118u8, 120u8, 113u8, 168u8, 99u8, 94u8, 232u8, 4u8, + 195u8, 168u8, 178u8, 51u8, 20u8, 107u8, 227u8, 236u8, 57u8, 30u8, + 130u8, 93u8, 149u8, 2u8, 161u8, 66u8, 48u8, 37u8, 71u8, 108u8, 195u8, + 65u8, 153u8, 30u8, 181u8, 181u8, 158u8, 252u8, 120u8, 119u8, 36u8, + 146u8, ], ) } - #[doc = "Teleport some assets from the local chain to some destination chain."] - #[doc = ""] - #[doc = "Fee payment on the destination side is made from the asset in the `assets` vector of"] - #[doc = "index `fee_asset_item`. The weight limit for fees is not provided and thus is unlimited,"] - #[doc = "with all fees taken as needed from the asset."] - #[doc = ""] - #[doc = "- `origin`: Must be capable of withdrawing the `assets` and executing XCM."] - #[doc = "- `dest`: Destination context for the assets. Will typically be `X2(Parent, Parachain(..))` to send"] - #[doc = " from parachain to parachain, or `X1(Parachain(..))` to send from relay to parachain."] - #[doc = "- `beneficiary`: A beneficiary location for the assets in the context of `dest`. Will generally be"] - #[doc = " an `AccountId32` value."] - #[doc = "- `assets`: The assets to be withdrawn. The first item should be the currency used to to pay the fee on the"] - #[doc = " `dest` side. May not be empty."] - #[doc = "- `fee_asset_item`: The index into `assets` of the item which should be used to pay"] - #[doc = " fees."] - pub fn teleport_assets( + #[doc = "Set the zeroth delay tranche width."] + pub fn set_zeroth_delay_tranche_width( &self, - dest: runtime_types::xcm::VersionedMultiLocation, - beneficiary: runtime_types::xcm::VersionedMultiLocation, - assets: runtime_types::xcm::VersionedMultiAssets, - fee_asset_item: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "XcmPallet", - "teleport_assets", - TeleportAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - }, + "Configuration", + "set_zeroth_delay_tranche_width", + SetZerothDelayTrancheWidth { new }, [ - 255u8, 5u8, 68u8, 38u8, 44u8, 181u8, 75u8, 221u8, 239u8, 103u8, 88u8, - 47u8, 136u8, 90u8, 253u8, 55u8, 0u8, 122u8, 217u8, 126u8, 13u8, 77u8, - 209u8, 41u8, 7u8, 35u8, 235u8, 171u8, 150u8, 235u8, 202u8, 240u8, + 69u8, 56u8, 125u8, 24u8, 181u8, 62u8, 99u8, 92u8, 166u8, 107u8, 91u8, + 134u8, 230u8, 128u8, 214u8, 135u8, 245u8, 64u8, 62u8, 78u8, 96u8, + 231u8, 195u8, 29u8, 158u8, 113u8, 46u8, 96u8, 29u8, 0u8, 154u8, 80u8, ], ) } - #[doc = "Transfer some assets from the local chain to the sovereign account of a destination"] - #[doc = "chain and forward a notification XCM."] - #[doc = ""] - #[doc = "Fee payment on the destination side is made from the asset in the `assets` vector of"] - #[doc = "index `fee_asset_item`. The weight limit for fees is not provided and thus is unlimited,"] - #[doc = "with all fees taken as needed from the asset."] - #[doc = ""] - #[doc = "- `origin`: Must be capable of withdrawing the `assets` and executing XCM."] - #[doc = "- `dest`: Destination context for the assets. Will typically be `X2(Parent, Parachain(..))` to send"] - #[doc = " from parachain to parachain, or `X1(Parachain(..))` to send from relay to parachain."] - #[doc = "- `beneficiary`: A beneficiary location for the assets in the context of `dest`. Will generally be"] - #[doc = " an `AccountId32` value."] - #[doc = "- `assets`: The assets to be withdrawn. This should include the assets used to pay the fee on the"] - #[doc = " `dest` side."] - #[doc = "- `fee_asset_item`: The index into `assets` of the item which should be used to pay"] - #[doc = " fees."] - pub fn reserve_transfer_assets( + #[doc = "Set the number of validators needed to approve a block."] + pub fn set_needed_approvals( &self, - dest: runtime_types::xcm::VersionedMultiLocation, - beneficiary: runtime_types::xcm::VersionedMultiLocation, - assets: runtime_types::xcm::VersionedMultiAssets, - fee_asset_item: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "XcmPallet", - "reserve_transfer_assets", - ReserveTransferAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - }, + "Configuration", + "set_needed_approvals", + SetNeededApprovals { new }, [ - 177u8, 160u8, 188u8, 106u8, 153u8, 135u8, 121u8, 12u8, 83u8, 233u8, - 43u8, 161u8, 133u8, 26u8, 104u8, 79u8, 113u8, 8u8, 33u8, 128u8, 82u8, - 62u8, 30u8, 46u8, 203u8, 199u8, 175u8, 193u8, 55u8, 130u8, 206u8, 28u8, + 238u8, 55u8, 134u8, 30u8, 67u8, 153u8, 150u8, 5u8, 226u8, 227u8, 185u8, + 188u8, 66u8, 60u8, 147u8, 118u8, 46u8, 174u8, 104u8, 100u8, 26u8, + 162u8, 65u8, 58u8, 162u8, 52u8, 211u8, 66u8, 242u8, 177u8, 230u8, 98u8, ], ) } - #[doc = "Execute an XCM message from a local, signed, origin."] - #[doc = ""] - #[doc = "An event is deposited indicating whether `msg` could be executed completely or only"] - #[doc = "partially."] - #[doc = ""] - #[doc = "No more than `max_weight` will be used in its attempted execution. If this is less than the"] - #[doc = "maximum amount of weight that the message could take to be executed, then no execution"] - #[doc = "attempt will be made."] - #[doc = ""] - #[doc = "NOTE: A successful return to this does *not* imply that the `msg` was executed successfully"] - #[doc = "to completion; only that *some* of it was executed."] - pub fn execute( + #[doc = "Set the number of samples to do of the `RelayVRFModulo` approval assignment criterion."] + pub fn set_relay_vrf_modulo_samples( &self, - message: runtime_types::xcm::VersionedXcm, - max_weight: ::core::primitive::u64, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "XcmPallet", - "execute", - Execute { - message: ::std::boxed::Box::new(message), - max_weight, - }, + "Configuration", + "set_relay_vrf_modulo_samples", + SetRelayVrfModuloSamples { new }, [ - 191u8, 177u8, 39u8, 21u8, 1u8, 110u8, 39u8, 58u8, 94u8, 27u8, 44u8, - 18u8, 253u8, 135u8, 100u8, 205u8, 0u8, 231u8, 68u8, 247u8, 5u8, 140u8, - 131u8, 184u8, 251u8, 197u8, 100u8, 113u8, 253u8, 255u8, 120u8, 206u8, + 76u8, 101u8, 207u8, 184u8, 211u8, 8u8, 43u8, 4u8, 165u8, 147u8, 166u8, + 3u8, 189u8, 42u8, 125u8, 130u8, 21u8, 43u8, 189u8, 120u8, 239u8, 131u8, + 235u8, 35u8, 151u8, 15u8, 30u8, 81u8, 0u8, 2u8, 64u8, 21u8, ], ) } - #[doc = "Extoll that a particular destination can be communicated with through a particular"] - #[doc = "version of XCM."] - #[doc = ""] - #[doc = "- `origin`: Must be Root."] - #[doc = "- `location`: The destination that is being described."] - #[doc = "- `xcm_version`: The latest version of XCM that `location` supports."] - pub fn force_xcm_version( + #[doc = "Sets the maximum items that can present in a upward dispatch queue at once."] + pub fn set_max_upward_queue_count( &self, - location: runtime_types::xcm::v1::multilocation::MultiLocation, - xcm_version: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "XcmPallet", - "force_xcm_version", - ForceXcmVersion { - location: ::std::boxed::Box::new(location), - xcm_version, - }, + "Configuration", + "set_max_upward_queue_count", + SetMaxUpwardQueueCount { new }, [ - 231u8, 106u8, 60u8, 226u8, 31u8, 25u8, 20u8, 115u8, 107u8, 246u8, - 248u8, 11u8, 71u8, 183u8, 93u8, 3u8, 219u8, 21u8, 97u8, 188u8, 119u8, - 121u8, 239u8, 72u8, 200u8, 81u8, 6u8, 177u8, 111u8, 188u8, 168u8, 86u8, + 116u8, 186u8, 216u8, 17u8, 150u8, 187u8, 86u8, 154u8, 92u8, 122u8, + 178u8, 167u8, 215u8, 165u8, 55u8, 86u8, 229u8, 114u8, 10u8, 149u8, + 50u8, 183u8, 165u8, 32u8, 233u8, 105u8, 82u8, 177u8, 120u8, 25u8, 44u8, + 130u8, ], ) } - #[doc = "Set a safe XCM version (the version that XCM should be encoded with if the most recent"] - #[doc = "version a destination can accept is unknown)."] - #[doc = ""] - #[doc = "- `origin`: Must be Root."] - #[doc = "- `maybe_xcm_version`: The default XCM encoding version, or `None` to disable."] - pub fn force_default_xcm_version( + #[doc = "Sets the maximum total size of items that can present in a upward dispatch queue at once."] + pub fn set_max_upward_queue_size( &self, - maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "XcmPallet", - "force_default_xcm_version", - ForceDefaultXcmVersion { maybe_xcm_version }, + "Configuration", + "set_max_upward_queue_size", + SetMaxUpwardQueueSize { new }, [ - 38u8, 36u8, 59u8, 231u8, 18u8, 79u8, 76u8, 9u8, 200u8, 125u8, 214u8, - 166u8, 37u8, 99u8, 111u8, 161u8, 135u8, 2u8, 133u8, 157u8, 165u8, 18u8, - 152u8, 81u8, 209u8, 255u8, 137u8, 237u8, 28u8, 126u8, 224u8, 141u8, + 18u8, 60u8, 141u8, 57u8, 134u8, 96u8, 140u8, 85u8, 137u8, 9u8, 209u8, + 123u8, 10u8, 165u8, 33u8, 184u8, 34u8, 82u8, 59u8, 60u8, 30u8, 47u8, + 22u8, 163u8, 119u8, 200u8, 197u8, 192u8, 112u8, 243u8, 156u8, 12u8, ], ) } - #[doc = "Ask a location to notify us regarding their XCM version and any changes to it."] - #[doc = ""] - #[doc = "- `origin`: Must be Root."] - #[doc = "- `location`: The location to which we should subscribe for XCM version notifications."] - pub fn force_subscribe_version_notify( + #[doc = "Set the critical downward message size."] + pub fn set_max_downward_message_size( &self, - location: runtime_types::xcm::VersionedMultiLocation, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "XcmPallet", - "force_subscribe_version_notify", - ForceSubscribeVersionNotify { - location: ::std::boxed::Box::new(location), - }, + "Configuration", + "set_max_downward_message_size", + SetMaxDownwardMessageSize { new }, [ - 136u8, 216u8, 207u8, 51u8, 42u8, 153u8, 92u8, 70u8, 140u8, 169u8, - 172u8, 89u8, 69u8, 28u8, 200u8, 100u8, 209u8, 226u8, 194u8, 240u8, - 71u8, 38u8, 18u8, 6u8, 6u8, 83u8, 103u8, 254u8, 248u8, 241u8, 62u8, - 189u8, + 104u8, 25u8, 229u8, 184u8, 53u8, 246u8, 206u8, 180u8, 13u8, 156u8, + 14u8, 224u8, 215u8, 115u8, 104u8, 127u8, 167u8, 189u8, 239u8, 183u8, + 68u8, 124u8, 55u8, 211u8, 186u8, 115u8, 70u8, 195u8, 61u8, 151u8, 32u8, + 218u8, ], ) } - #[doc = "Require that a particular destination should no longer notify us regarding any XCM"] - #[doc = "version changes."] - #[doc = ""] - #[doc = "- `origin`: Must be Root."] - #[doc = "- `location`: The location to which we are currently subscribed for XCM version"] - #[doc = " notifications which we no longer desire."] - pub fn force_unsubscribe_version_notify( + #[doc = "Sets the soft limit for the phase of dispatching dispatchable upward messages."] + pub fn set_ump_service_total_weight( &self, - location: runtime_types::xcm::VersionedMultiLocation, - ) -> ::subxt::tx::Payload { + new: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "XcmPallet", - "force_unsubscribe_version_notify", - ForceUnsubscribeVersionNotify { - location: ::std::boxed::Box::new(location), - }, + "Configuration", + "set_ump_service_total_weight", + SetUmpServiceTotalWeight { new }, [ - 51u8, 72u8, 5u8, 227u8, 251u8, 243u8, 199u8, 9u8, 8u8, 213u8, 191u8, - 52u8, 21u8, 215u8, 170u8, 6u8, 53u8, 242u8, 225u8, 89u8, 150u8, 142u8, - 104u8, 249u8, 225u8, 209u8, 142u8, 234u8, 161u8, 100u8, 153u8, 120u8, + 178u8, 63u8, 233u8, 183u8, 160u8, 109u8, 10u8, 162u8, 150u8, 110u8, + 66u8, 166u8, 197u8, 207u8, 91u8, 208u8, 137u8, 106u8, 140u8, 184u8, + 35u8, 85u8, 138u8, 49u8, 32u8, 15u8, 150u8, 136u8, 50u8, 197u8, 21u8, + 99u8, ], ) } - #[doc = "Transfer some assets from the local chain to the sovereign account of a destination"] - #[doc = "chain and forward a notification XCM."] - #[doc = ""] - #[doc = "Fee payment on the destination side is made from the asset in the `assets` vector of"] - #[doc = "index `fee_asset_item`, up to enough to pay for `weight_limit` of weight. If more weight"] - #[doc = "is needed than `weight_limit`, then the operation will fail and the assets send may be"] - #[doc = "at risk."] - #[doc = ""] - #[doc = "- `origin`: Must be capable of withdrawing the `assets` and executing XCM."] - #[doc = "- `dest`: Destination context for the assets. Will typically be `X2(Parent, Parachain(..))` to send"] - #[doc = " from parachain to parachain, or `X1(Parachain(..))` to send from relay to parachain."] - #[doc = "- `beneficiary`: A beneficiary location for the assets in the context of `dest`. Will generally be"] - #[doc = " an `AccountId32` value."] - #[doc = "- `assets`: The assets to be withdrawn. This should include the assets used to pay the fee on the"] - #[doc = " `dest` side."] - #[doc = "- `fee_asset_item`: The index into `assets` of the item which should be used to pay"] - #[doc = " fees."] - #[doc = "- `weight_limit`: The remote-side weight limit, if any, for the XCM fee purchase."] - pub fn limited_reserve_transfer_assets( + #[doc = "Sets the maximum size of an upward message that can be sent by a candidate."] + pub fn set_max_upward_message_size( &self, - dest: runtime_types::xcm::VersionedMultiLocation, - beneficiary: runtime_types::xcm::VersionedMultiLocation, - assets: runtime_types::xcm::VersionedMultiAssets, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v2::WeightLimit, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "XcmPallet", - "limited_reserve_transfer_assets", - LimitedReserveTransferAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - weight_limit, - }, + "Configuration", + "set_max_upward_message_size", + SetMaxUpwardMessageSize { new }, [ - 191u8, 81u8, 68u8, 116u8, 196u8, 125u8, 226u8, 154u8, 144u8, 126u8, - 159u8, 149u8, 17u8, 124u8, 205u8, 60u8, 249u8, 106u8, 38u8, 251u8, - 136u8, 128u8, 81u8, 201u8, 164u8, 242u8, 216u8, 80u8, 21u8, 234u8, - 20u8, 70u8, + 213u8, 120u8, 21u8, 247u8, 101u8, 21u8, 164u8, 228u8, 33u8, 115u8, + 20u8, 138u8, 28u8, 174u8, 247u8, 39u8, 194u8, 113u8, 34u8, 73u8, 142u8, + 94u8, 116u8, 151u8, 113u8, 92u8, 151u8, 227u8, 116u8, 250u8, 101u8, + 179u8, ], ) } - #[doc = "Teleport some assets from the local chain to some destination chain."] - #[doc = ""] - #[doc = "Fee payment on the destination side is made from the asset in the `assets` vector of"] - #[doc = "index `fee_asset_item`, up to enough to pay for `weight_limit` of weight. If more weight"] - #[doc = "is needed than `weight_limit`, then the operation will fail and the assets send may be"] - #[doc = "at risk."] + #[doc = "Sets the maximum number of messages that a candidate can contain."] + pub fn set_max_upward_message_num_per_candidate( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_max_upward_message_num_per_candidate", + SetMaxUpwardMessageNumPerCandidate { new }, + [ + 54u8, 133u8, 226u8, 138u8, 184u8, 27u8, 130u8, 153u8, 130u8, 196u8, + 54u8, 79u8, 124u8, 10u8, 37u8, 139u8, 59u8, 190u8, 169u8, 87u8, 255u8, + 211u8, 38u8, 142u8, 37u8, 74u8, 144u8, 204u8, 75u8, 94u8, 154u8, 149u8, + ], + ) + } + #[doc = "Sets the number of sessions after which an HRMP open channel request expires."] + pub fn set_hrmp_open_request_ttl( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_hrmp_open_request_ttl", + SetHrmpOpenRequestTtl { new }, + [ + 192u8, 113u8, 113u8, 133u8, 197u8, 75u8, 88u8, 67u8, 130u8, 207u8, + 37u8, 192u8, 157u8, 159u8, 114u8, 75u8, 83u8, 180u8, 194u8, 180u8, + 96u8, 129u8, 7u8, 138u8, 110u8, 14u8, 229u8, 98u8, 71u8, 22u8, 229u8, + 247u8, + ], + ) + } + #[doc = "Sets the amount of funds that the sender should provide for opening an HRMP channel."] + pub fn set_hrmp_sender_deposit( + &self, + new: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_hrmp_sender_deposit", + SetHrmpSenderDeposit { new }, + [ + 49u8, 38u8, 173u8, 114u8, 66u8, 140u8, 15u8, 151u8, 193u8, 54u8, 128u8, + 108u8, 72u8, 71u8, 28u8, 65u8, 129u8, 199u8, 105u8, 61u8, 96u8, 119u8, + 16u8, 53u8, 115u8, 120u8, 152u8, 122u8, 182u8, 171u8, 233u8, 48u8, + ], + ) + } + #[doc = "Sets the amount of funds that the recipient should provide for accepting opening an HRMP"] + #[doc = "channel."] + pub fn set_hrmp_recipient_deposit( + &self, + new: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_hrmp_recipient_deposit", + SetHrmpRecipientDeposit { new }, + [ + 209u8, 212u8, 164u8, 56u8, 71u8, 215u8, 98u8, 250u8, 202u8, 150u8, + 228u8, 6u8, 166u8, 94u8, 171u8, 142u8, 10u8, 253u8, 89u8, 43u8, 6u8, + 173u8, 8u8, 235u8, 52u8, 18u8, 78u8, 129u8, 227u8, 61u8, 74u8, 83u8, + ], + ) + } + #[doc = "Sets the maximum number of messages allowed in an HRMP channel at once."] + pub fn set_hrmp_channel_max_capacity( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_hrmp_channel_max_capacity", + SetHrmpChannelMaxCapacity { new }, + [ + 148u8, 109u8, 67u8, 220u8, 1u8, 115u8, 70u8, 93u8, 138u8, 190u8, 60u8, + 220u8, 80u8, 137u8, 246u8, 230u8, 115u8, 162u8, 30u8, 197u8, 11u8, + 33u8, 211u8, 224u8, 49u8, 165u8, 149u8, 155u8, 197u8, 44u8, 6u8, 167u8, + ], + ) + } + #[doc = "Sets the maximum total size of messages in bytes allowed in an HRMP channel at once."] + pub fn set_hrmp_channel_max_total_size( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_hrmp_channel_max_total_size", + SetHrmpChannelMaxTotalSize { new }, + [ + 79u8, 40u8, 207u8, 173u8, 168u8, 143u8, 130u8, 240u8, 205u8, 34u8, + 61u8, 217u8, 215u8, 106u8, 61u8, 181u8, 8u8, 21u8, 105u8, 64u8, 183u8, + 235u8, 39u8, 133u8, 70u8, 77u8, 233u8, 201u8, 222u8, 8u8, 43u8, 159u8, + ], + ) + } + #[doc = "Sets the maximum number of inbound HRMP channels a parachain is allowed to accept."] + pub fn set_hrmp_max_parachain_inbound_channels( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_hrmp_max_parachain_inbound_channels", + SetHrmpMaxParachainInboundChannels { new }, + [ + 91u8, 215u8, 212u8, 131u8, 140u8, 185u8, 119u8, 184u8, 61u8, 121u8, + 120u8, 73u8, 202u8, 98u8, 124u8, 187u8, 171u8, 84u8, 136u8, 77u8, + 103u8, 169u8, 185u8, 8u8, 214u8, 214u8, 23u8, 195u8, 100u8, 72u8, 45u8, + 12u8, + ], + ) + } + #[doc = "Sets the maximum number of inbound HRMP channels a parathread is allowed to accept."] + pub fn set_hrmp_max_parathread_inbound_channels( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_hrmp_max_parathread_inbound_channels", + SetHrmpMaxParathreadInboundChannels { new }, + [ + 209u8, 66u8, 180u8, 20u8, 87u8, 242u8, 219u8, 71u8, 22u8, 145u8, 220u8, + 48u8, 44u8, 42u8, 77u8, 69u8, 255u8, 82u8, 27u8, 125u8, 231u8, 111u8, + 23u8, 32u8, 239u8, 28u8, 200u8, 255u8, 91u8, 207u8, 99u8, 107u8, + ], + ) + } + #[doc = "Sets the maximum size of a message that could ever be put into an HRMP channel."] + pub fn set_hrmp_channel_max_message_size( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_hrmp_channel_max_message_size", + SetHrmpChannelMaxMessageSize { new }, + [ + 17u8, 224u8, 230u8, 9u8, 114u8, 221u8, 138u8, 46u8, 234u8, 151u8, 27u8, + 34u8, 179u8, 67u8, 113u8, 228u8, 128u8, 212u8, 209u8, 125u8, 122u8, + 1u8, 79u8, 28u8, 10u8, 14u8, 83u8, 65u8, 253u8, 173u8, 116u8, 209u8, + ], + ) + } + #[doc = "Sets the maximum number of outbound HRMP channels a parachain is allowed to open."] + pub fn set_hrmp_max_parachain_outbound_channels( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_hrmp_max_parachain_outbound_channels", + SetHrmpMaxParachainOutboundChannels { new }, + [ + 26u8, 146u8, 150u8, 88u8, 236u8, 8u8, 63u8, 103u8, 71u8, 11u8, 20u8, + 210u8, 205u8, 106u8, 101u8, 112u8, 116u8, 73u8, 116u8, 136u8, 149u8, + 181u8, 207u8, 95u8, 151u8, 7u8, 98u8, 17u8, 224u8, 157u8, 117u8, 88u8, + ], + ) + } + #[doc = "Sets the maximum number of outbound HRMP channels a parathread is allowed to open."] + pub fn set_hrmp_max_parathread_outbound_channels( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_hrmp_max_parathread_outbound_channels", + SetHrmpMaxParathreadOutboundChannels { new }, + [ + 31u8, 72u8, 93u8, 21u8, 180u8, 156u8, 101u8, 24u8, 145u8, 220u8, 194u8, + 93u8, 176u8, 164u8, 53u8, 123u8, 36u8, 113u8, 152u8, 13u8, 222u8, 54u8, + 175u8, 170u8, 235u8, 68u8, 236u8, 130u8, 178u8, 56u8, 140u8, 31u8, + ], + ) + } + #[doc = "Sets the maximum number of outbound HRMP messages can be sent by a candidate."] + pub fn set_hrmp_max_message_num_per_candidate( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_hrmp_max_message_num_per_candidate", + SetHrmpMaxMessageNumPerCandidate { new }, + [ + 244u8, 94u8, 225u8, 194u8, 133u8, 116u8, 202u8, 238u8, 8u8, 57u8, + 122u8, 125u8, 6u8, 131u8, 84u8, 102u8, 180u8, 67u8, 250u8, 136u8, 30u8, + 29u8, 110u8, 105u8, 219u8, 166u8, 91u8, 140u8, 44u8, 192u8, 37u8, + 185u8, + ], + ) + } + #[doc = "Sets the maximum amount of weight any individual upward message may consume."] + pub fn set_ump_max_individual_weight( + &self, + new: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_ump_max_individual_weight", + SetUmpMaxIndividualWeight { new }, + [ + 66u8, 190u8, 15u8, 172u8, 67u8, 16u8, 117u8, 247u8, 176u8, 25u8, 163u8, + 130u8, 147u8, 224u8, 226u8, 101u8, 219u8, 173u8, 176u8, 49u8, 90u8, + 133u8, 12u8, 223u8, 220u8, 18u8, 83u8, 232u8, 137u8, 52u8, 206u8, 71u8, + ], + ) + } + #[doc = "Enable or disable PVF pre-checking. Consult the field documentation prior executing."] + pub fn set_pvf_checking_enabled( + &self, + new: ::core::primitive::bool, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_pvf_checking_enabled", + SetPvfCheckingEnabled { new }, + [ + 123u8, 76u8, 1u8, 112u8, 174u8, 245u8, 18u8, 67u8, 13u8, 29u8, 219u8, + 197u8, 201u8, 112u8, 230u8, 191u8, 37u8, 148u8, 73u8, 125u8, 54u8, + 236u8, 3u8, 80u8, 114u8, 155u8, 244u8, 132u8, 57u8, 63u8, 158u8, 248u8, + ], + ) + } + #[doc = "Set the number of session changes after which a PVF pre-checking voting is rejected."] + pub fn set_pvf_voting_ttl( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_pvf_voting_ttl", + SetPvfVotingTtl { new }, + [ + 17u8, 11u8, 98u8, 217u8, 208u8, 102u8, 238u8, 83u8, 118u8, 123u8, 20u8, + 18u8, 46u8, 212u8, 21u8, 164u8, 61u8, 104u8, 208u8, 204u8, 91u8, 210u8, + 40u8, 6u8, 201u8, 147u8, 46u8, 166u8, 219u8, 227u8, 121u8, 187u8, + ], + ) + } + #[doc = "Sets the minimum delay between announcing the upgrade block for a parachain until the"] + #[doc = "upgrade taking place."] #[doc = ""] - #[doc = "- `origin`: Must be capable of withdrawing the `assets` and executing XCM."] - #[doc = "- `dest`: Destination context for the assets. Will typically be `X2(Parent, Parachain(..))` to send"] - #[doc = " from parachain to parachain, or `X1(Parachain(..))` to send from relay to parachain."] - #[doc = "- `beneficiary`: A beneficiary location for the assets in the context of `dest`. Will generally be"] - #[doc = " an `AccountId32` value."] - #[doc = "- `assets`: The assets to be withdrawn. The first item should be the currency used to to pay the fee on the"] - #[doc = " `dest` side. May not be empty."] - #[doc = "- `fee_asset_item`: The index into `assets` of the item which should be used to pay"] - #[doc = " fees."] - #[doc = "- `weight_limit`: The remote-side weight limit, if any, for the XCM fee purchase."] - pub fn limited_teleport_assets( + #[doc = "See the field documentation for information and constraints for the new value."] + pub fn set_minimum_validation_upgrade_delay( &self, - dest: runtime_types::xcm::VersionedMultiLocation, - beneficiary: runtime_types::xcm::VersionedMultiLocation, - assets: runtime_types::xcm::VersionedMultiAssets, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v2::WeightLimit, - ) -> ::subxt::tx::Payload { + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "XcmPallet", - "limited_teleport_assets", - LimitedTeleportAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - weight_limit, - }, + "Configuration", + "set_minimum_validation_upgrade_delay", + SetMinimumValidationUpgradeDelay { new }, [ - 29u8, 31u8, 229u8, 83u8, 40u8, 60u8, 36u8, 185u8, 169u8, 74u8, 30u8, - 47u8, 118u8, 118u8, 22u8, 15u8, 246u8, 220u8, 169u8, 135u8, 72u8, - 154u8, 109u8, 192u8, 195u8, 58u8, 121u8, 240u8, 166u8, 243u8, 29u8, - 29u8, + 205u8, 188u8, 75u8, 136u8, 228u8, 26u8, 112u8, 27u8, 119u8, 37u8, + 252u8, 109u8, 23u8, 145u8, 21u8, 212u8, 7u8, 28u8, 242u8, 210u8, 182u8, + 111u8, 121u8, 109u8, 50u8, 130u8, 46u8, 127u8, 122u8, 40u8, 141u8, + 242u8, + ], + ) + } + #[doc = "Setting this to true will disable consistency checks for the configuration setters."] + #[doc = "Use with caution."] + pub fn set_bypass_consistency_check( + &self, + new: ::core::primitive::bool, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_bypass_consistency_check", + SetBypassConsistencyCheck { new }, + [ + 80u8, 66u8, 200u8, 98u8, 54u8, 207u8, 64u8, 99u8, 162u8, 121u8, 26u8, + 173u8, 113u8, 224u8, 240u8, 106u8, 69u8, 191u8, 177u8, 107u8, 34u8, + 74u8, 103u8, 128u8, 252u8, 160u8, 169u8, 246u8, 125u8, 127u8, 153u8, + 129u8, + ], + ) + } + #[doc = "Set the asynchronous backing parameters."] + pub fn set_async_backing_params( + &self, + new: runtime_types::polkadot_primitives::vstaging::AsyncBackingParams, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_async_backing_params", + SetAsyncBackingParams { new }, + [ + 124u8, 182u8, 66u8, 138u8, 209u8, 54u8, 42u8, 232u8, 110u8, 67u8, + 248u8, 16u8, 61u8, 38u8, 120u8, 242u8, 34u8, 240u8, 219u8, 169u8, + 145u8, 246u8, 194u8, 208u8, 225u8, 108u8, 135u8, 74u8, 194u8, 214u8, + 199u8, 139u8, + ], + ) + } + #[doc = "Set PVF executor parameters."] + pub fn set_executor_params( + &self, + new: runtime_types::polkadot_primitives::v4::executor_params::ExecutorParams, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Configuration", + "set_executor_params", + SetExecutorParams { new }, + [ + 193u8, 235u8, 143u8, 62u8, 34u8, 192u8, 162u8, 49u8, 224u8, 10u8, + 189u8, 132u8, 70u8, 114u8, 50u8, 155u8, 39u8, 238u8, 238u8, 161u8, + 181u8, 108u8, 187u8, 28u8, 48u8, 14u8, 209u8, 42u8, 196u8, 181u8, + 159u8, 124u8, ], ) } } } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_xcm::pallet::Event; - pub mod events { + pub mod storage { use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Execution of an XCM message was attempted."] - #[doc = ""] - #[doc = "\\[ outcome \\]"] - pub struct Attempted(pub runtime_types::xcm::v2::traits::Outcome); - impl ::subxt::events::StaticEvent for Attempted { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "Attempted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A XCM message was sent."] - #[doc = ""] - #[doc = "\\[ origin, destination, message \\]"] - pub struct Sent( - pub runtime_types::xcm::v1::multilocation::MultiLocation, - pub runtime_types::xcm::v1::multilocation::MultiLocation, - pub runtime_types::xcm::v2::Xcm, - ); - impl ::subxt::events::StaticEvent for Sent { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "Sent"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response received which does not match a registered query. This may be because a"] - #[doc = "matching query was never registered, it may be because it is a duplicate response, or"] - #[doc = "because the query timed out."] - #[doc = ""] - #[doc = "\\[ origin location, id \\]"] - pub struct UnexpectedResponse( - pub runtime_types::xcm::v1::multilocation::MultiLocation, - pub ::core::primitive::u64, - ); - impl ::subxt::events::StaticEvent for UnexpectedResponse { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "UnexpectedResponse"; + pub struct StorageApi; + impl StorageApi { + #[doc = " The active configuration for the current session."] + pub fn active_config( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::configuration::HostConfiguration< + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Configuration", + "ActiveConfig", + vec![], + [ + 254u8, 47u8, 159u8, 237u8, 202u8, 82u8, 132u8, 16u8, 100u8, 209u8, + 166u8, 154u8, 226u8, 156u8, 117u8, 11u8, 114u8, 37u8, 208u8, 255u8, + 96u8, 27u8, 192u8, 144u8, 56u8, 241u8, 49u8, 163u8, 15u8, 86u8, 229u8, + 166u8, + ], + ) + } + #[doc = " Pending configuration changes."] + #[doc = ""] + #[doc = " This is a list of configuration changes, each with a session index at which it should"] + #[doc = " be applied."] + #[doc = ""] + #[doc = " The list is sorted ascending by session index. Also, this list can only contain at most"] + #[doc = " 2 items: for the next session and for the `scheduled_session`."] pub fn pending_configs (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , :: std :: vec :: Vec < (:: core :: primitive :: u32 , runtime_types :: polkadot_runtime_parachains :: configuration :: HostConfiguration < :: core :: primitive :: u32 > ,) > , :: subxt :: storage :: address :: Yes , :: subxt :: storage :: address :: Yes , () >{ + ::subxt::storage::address::Address::new_static( + "Configuration", + "PendingConfigs", + vec![], + [ + 227u8, 119u8, 229u8, 201u8, 230u8, 27u8, 239u8, 171u8, 78u8, 212u8, + 218u8, 154u8, 195u8, 36u8, 129u8, 91u8, 53u8, 210u8, 185u8, 169u8, + 78u8, 146u8, 21u8, 67u8, 248u8, 117u8, 53u8, 130u8, 243u8, 186u8, + 144u8, 249u8, + ], + ) + } + #[doc = " If this is set, then the configuration setters will bypass the consistency checks. This"] + #[doc = " is meant to be used only as the last resort."] + pub fn bypass_consistency_check( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Configuration", + "BypassConsistencyCheck", + vec![], + [ + 42u8, 191u8, 122u8, 163u8, 112u8, 2u8, 148u8, 59u8, 79u8, 219u8, 184u8, + 172u8, 246u8, 136u8, 185u8, 251u8, 189u8, 226u8, 83u8, 129u8, 162u8, + 109u8, 148u8, 75u8, 120u8, 216u8, 44u8, 28u8, 221u8, 78u8, 177u8, 94u8, + ], + ) + } } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and is ready for taking with `take_response`. There is"] - #[doc = "no registered notification call."] - #[doc = ""] - #[doc = "\\[ id, response \\]"] - pub struct ResponseReady( - pub ::core::primitive::u64, - pub runtime_types::xcm::v2::Response, - ); - impl ::subxt::events::StaticEvent for ResponseReady { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "ResponseReady"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and query is removed. The registered notification has"] - #[doc = "been dispatched and executed successfully."] - #[doc = ""] - #[doc = "\\[ id, pallet index, call index \\]"] - pub struct Notified( - pub ::core::primitive::u64, - pub ::core::primitive::u8, - pub ::core::primitive::u8, - ); - impl ::subxt::events::StaticEvent for Notified { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "Notified"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and query is removed. The registered notification could"] - #[doc = "not be dispatched because the dispatch weight is greater than the maximum weight"] - #[doc = "originally budgeted by this runtime for the query result."] - #[doc = ""] - #[doc = "\\[ id, pallet index, call index, actual weight, max budgeted weight \\]"] - pub struct NotifyOverweight( - pub ::core::primitive::u64, - pub ::core::primitive::u8, - pub ::core::primitive::u8, - pub runtime_types::sp_weights::weight_v2::Weight, - pub runtime_types::sp_weights::weight_v2::Weight, - ); - impl ::subxt::events::StaticEvent for NotifyOverweight { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "NotifyOverweight"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and query is removed. There was a general error with"] - #[doc = "dispatching the notification call."] - #[doc = ""] - #[doc = "\\[ id, pallet index, call index \\]"] - pub struct NotifyDispatchError( - pub ::core::primitive::u64, - pub ::core::primitive::u8, - pub ::core::primitive::u8, - ); - impl ::subxt::events::StaticEvent for NotifyDispatchError { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "NotifyDispatchError"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and query is removed. The dispatch was unable to be"] - #[doc = "decoded into a `Call`; this might be due to dispatch function having a signature which"] - #[doc = "is not `(origin, QueryId, Response)`."] - #[doc = ""] - #[doc = "\\[ id, pallet index, call index \\]"] - pub struct NotifyDecodeFailed( - pub ::core::primitive::u64, - pub ::core::primitive::u8, - pub ::core::primitive::u8, - ); - impl ::subxt::events::StaticEvent for NotifyDecodeFailed { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "NotifyDecodeFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Expected query response has been received but the origin location of the response does"] - #[doc = "not match that expected. The query remains registered for a later, valid, response to"] - #[doc = "be received and acted upon."] - #[doc = ""] - #[doc = "\\[ origin location, id, expected location \\]"] - pub struct InvalidResponder( - pub runtime_types::xcm::v1::multilocation::MultiLocation, - pub ::core::primitive::u64, - pub ::core::option::Option, - ); - impl ::subxt::events::StaticEvent for InvalidResponder { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "InvalidResponder"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Expected query response has been received but the expected origin location placed in"] - #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] - #[doc = ""] - #[doc = "This is unexpected (since a location placed in storage in a previously executing"] - #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] - #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] - #[doc = "needed."] - #[doc = ""] - #[doc = "\\[ origin location, id \\]"] - pub struct InvalidResponderVersion( - pub runtime_types::xcm::v1::multilocation::MultiLocation, - pub ::core::primitive::u64, - ); - impl ::subxt::events::StaticEvent for InvalidResponderVersion { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "InvalidResponderVersion"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Received query response has been read and removed."] - #[doc = ""] - #[doc = "\\[ id \\]"] - pub struct ResponseTaken(pub ::core::primitive::u64); - impl ::subxt::events::StaticEvent for ResponseTaken { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "ResponseTaken"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some assets have been placed in an asset trap."] - #[doc = ""] - #[doc = "\\[ hash, origin, assets \\]"] - pub struct AssetsTrapped( - pub ::subxt::utils::H256, - pub runtime_types::xcm::v1::multilocation::MultiLocation, - pub runtime_types::xcm::VersionedMultiAssets, - ); - impl ::subxt::events::StaticEvent for AssetsTrapped { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "AssetsTrapped"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An XCM version change notification message has been attempted to be sent."] - #[doc = ""] - #[doc = "\\[ destination, result \\]"] - pub struct VersionChangeNotified( - pub runtime_types::xcm::v1::multilocation::MultiLocation, - pub ::core::primitive::u32, - ); - impl ::subxt::events::StaticEvent for VersionChangeNotified { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "VersionChangeNotified"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The supported version of a location has been changed. This might be through an"] - #[doc = "automatic notification or a manual intervention."] - #[doc = ""] - #[doc = "\\[ location, XCM version \\]"] - pub struct SupportedVersionChanged( - pub runtime_types::xcm::v1::multilocation::MultiLocation, - pub ::core::primitive::u32, - ); - impl ::subxt::events::StaticEvent for SupportedVersionChanged { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "SupportedVersionChanged"; + } + } + pub mod paras_shared { + use super::root_mod; + use super::runtime_types; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub struct TransactionApi; + impl TransactionApi {} + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The current session index."] + pub fn current_session_index( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParasShared", + "CurrentSessionIndex", + vec![], + [ + 83u8, 15u8, 20u8, 55u8, 103u8, 65u8, 76u8, 202u8, 69u8, 14u8, 221u8, + 93u8, 38u8, 163u8, 167u8, 83u8, 18u8, 245u8, 33u8, 175u8, 7u8, 97u8, + 67u8, 186u8, 96u8, 57u8, 147u8, 120u8, 107u8, 91u8, 147u8, 64u8, + ], + ) + } + #[doc = " All the validators actively participating in parachain consensus."] + #[doc = " Indices are into the broader validator set."] + pub fn active_validator_indices( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParasShared", + "ActiveValidatorIndices", + vec![], + [ + 123u8, 26u8, 202u8, 53u8, 219u8, 42u8, 54u8, 92u8, 144u8, 74u8, 228u8, + 234u8, 129u8, 216u8, 161u8, 98u8, 199u8, 12u8, 13u8, 231u8, 23u8, + 166u8, 185u8, 209u8, 191u8, 33u8, 231u8, 252u8, 232u8, 44u8, 213u8, + 221u8, + ], + ) + } + #[doc = " The parachain attestation keys of the validators actively participating in parachain consensus."] + #[doc = " This should be the same length as `ActiveValidatorIndices`."] + pub fn active_validator_keys( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParasShared", + "ActiveValidatorKeys", + vec![], + [ + 33u8, 14u8, 54u8, 86u8, 184u8, 171u8, 194u8, 35u8, 187u8, 252u8, 181u8, + 79u8, 229u8, 134u8, 50u8, 235u8, 162u8, 216u8, 108u8, 160u8, 175u8, + 172u8, 239u8, 114u8, 57u8, 238u8, 9u8, 54u8, 57u8, 196u8, 105u8, 15u8, + ], + ) + } } + } + } + pub mod para_inclusion { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::polkadot_runtime_parachains::inclusion::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub struct TransactionApi; + impl TransactionApi {} + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::polkadot_runtime_parachains::inclusion::pallet::Event; + pub mod events { + use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -32079,18 +27744,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A given location which had a version change subscription was dropped owing to an error"] - #[doc = "sending the notification to it."] - #[doc = ""] - #[doc = "\\[ location, query ID, error \\]"] - pub struct NotifyTargetSendFail( - pub runtime_types::xcm::v1::multilocation::MultiLocation, - pub ::core::primitive::u64, - pub runtime_types::xcm::v2::traits::Error, + #[doc = "A candidate was backed. `[candidate, head_data]`"] + pub struct CandidateBacked( + pub runtime_types::polkadot_primitives::v4::CandidateReceipt<::subxt::utils::H256>, + pub runtime_types::polkadot_parachain::primitives::HeadData, + pub runtime_types::polkadot_primitives::v4::CoreIndex, + pub runtime_types::polkadot_primitives::v4::GroupIndex, ); - impl ::subxt::events::StaticEvent for NotifyTargetSendFail { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "NotifyTargetSendFail"; + impl ::subxt::events::StaticEvent for CandidateBacked { + const PALLET: &'static str = "ParaInclusion"; + const EVENT: &'static str = "CandidateBacked"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -32102,17 +27765,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A given location which had a version change subscription was dropped owing to an error"] - #[doc = "migrating the location to our new XCM format."] - #[doc = ""] - #[doc = "\\[ location, query ID \\]"] - pub struct NotifyTargetMigrationFail( - pub runtime_types::xcm::VersionedMultiLocation, - pub ::core::primitive::u64, + #[doc = "A candidate was included. `[candidate, head_data]`"] + pub struct CandidateIncluded( + pub runtime_types::polkadot_primitives::v4::CandidateReceipt<::subxt::utils::H256>, + pub runtime_types::polkadot_parachain::primitives::HeadData, + pub runtime_types::polkadot_primitives::v4::CoreIndex, + pub runtime_types::polkadot_primitives::v4::GroupIndex, ); - impl ::subxt::events::StaticEvent for NotifyTargetMigrationFail { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "NotifyTargetMigrationFail"; + impl ::subxt::events::StaticEvent for CandidateIncluded { + const PALLET: &'static str = "ParaInclusion"; + const EVENT: &'static str = "CandidateIncluded"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -32124,374 +27786,423 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some assets have been claimed from an asset trap"] - #[doc = ""] - #[doc = "\\[ hash, origin, assets \\]"] - pub struct AssetsClaimed( - pub ::subxt::utils::H256, - pub runtime_types::xcm::v1::multilocation::MultiLocation, - pub runtime_types::xcm::VersionedMultiAssets, + #[doc = "A candidate timed out. `[candidate, head_data]`"] + pub struct CandidateTimedOut( + pub runtime_types::polkadot_primitives::v4::CandidateReceipt<::subxt::utils::H256>, + pub runtime_types::polkadot_parachain::primitives::HeadData, + pub runtime_types::polkadot_primitives::v4::CoreIndex, ); - impl ::subxt::events::StaticEvent for AssetsClaimed { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "AssetsClaimed"; + impl ::subxt::events::StaticEvent for CandidateTimedOut { + const PALLET: &'static str = "ParaInclusion"; + const EVENT: &'static str = "CandidateTimedOut"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " The latest available query index."] - pub fn query_counter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { + #[doc = " The latest bitfield for each validator, referred to by their index in the validator set."] pub fn availability_bitfields (& self , _0 : impl :: std :: borrow :: Borrow < runtime_types :: polkadot_primitives :: v4 :: ValidatorIndex > ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: inclusion :: AvailabilityBitfieldRecord < :: core :: primitive :: u32 > , :: subxt :: storage :: address :: Yes , () , :: subxt :: storage :: address :: Yes >{ ::subxt::storage::address::Address::new_static( - "XcmPallet", - "QueryCounter", - vec![], + "ParaInclusion", + "AvailabilityBitfields", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 137u8, 58u8, 184u8, 88u8, 247u8, 22u8, 151u8, 64u8, 50u8, 77u8, 49u8, - 10u8, 234u8, 84u8, 213u8, 156u8, 26u8, 200u8, 214u8, 225u8, 125u8, - 231u8, 42u8, 93u8, 159u8, 168u8, 86u8, 201u8, 116u8, 153u8, 41u8, - 127u8, + 149u8, 215u8, 123u8, 226u8, 73u8, 240u8, 102u8, 39u8, 243u8, 232u8, + 226u8, 116u8, 65u8, 180u8, 110u8, 4u8, 194u8, 50u8, 60u8, 193u8, 142u8, + 62u8, 20u8, 148u8, 106u8, 162u8, 96u8, 114u8, 215u8, 250u8, 111u8, + 225u8, ], ) } - #[doc = " The ongoing queries."] - pub fn queries( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u64>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::QueryStatus<::core::primitive::u32>, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { + #[doc = " The latest bitfield for each validator, referred to by their index in the validator set."] pub fn availability_bitfields_root (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: inclusion :: AvailabilityBitfieldRecord < :: core :: primitive :: u32 > , () , () , :: subxt :: storage :: address :: Yes >{ ::subxt::storage::address::Address::new_static( - "XcmPallet", - "Queries", + "ParaInclusion", + "AvailabilityBitfields", + Vec::new(), + [ + 149u8, 215u8, 123u8, 226u8, 73u8, 240u8, 102u8, 39u8, 243u8, 232u8, + 226u8, 116u8, 65u8, 180u8, 110u8, 4u8, 194u8, 50u8, 60u8, 193u8, 142u8, + 62u8, 20u8, 148u8, 106u8, 162u8, 96u8, 114u8, 215u8, 250u8, 111u8, + 225u8, + ], + ) + } + #[doc = " Candidates pending availability by `ParaId`."] pub fn pending_availability (& self , _0 : impl :: std :: borrow :: Borrow < runtime_types :: polkadot_parachain :: primitives :: Id > ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: inclusion :: CandidatePendingAvailability < :: subxt :: utils :: H256 , :: core :: primitive :: u32 > , :: subxt :: storage :: address :: Yes , () , :: subxt :: storage :: address :: Yes >{ + ::subxt::storage::address::Address::new_static( + "ParaInclusion", + "PendingAvailability", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 251u8, 97u8, 131u8, 135u8, 93u8, 68u8, 156u8, 25u8, 181u8, 231u8, - 124u8, 93u8, 170u8, 114u8, 250u8, 177u8, 172u8, 51u8, 59u8, 44u8, - 148u8, 189u8, 199u8, 62u8, 118u8, 89u8, 75u8, 29u8, 71u8, 49u8, 248u8, - 48u8, + 54u8, 166u8, 18u8, 56u8, 51u8, 241u8, 31u8, 165u8, 220u8, 138u8, 67u8, + 171u8, 23u8, 101u8, 109u8, 26u8, 211u8, 237u8, 81u8, 143u8, 192u8, + 214u8, 49u8, 42u8, 69u8, 30u8, 168u8, 113u8, 72u8, 12u8, 140u8, 242u8, ], ) } - #[doc = " The ongoing queries."] - pub fn queries_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::QueryStatus<::core::primitive::u32>, - (), - (), - ::subxt::storage::address::Yes, - > { + #[doc = " Candidates pending availability by `ParaId`."] pub fn pending_availability_root (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: inclusion :: CandidatePendingAvailability < :: subxt :: utils :: H256 , :: core :: primitive :: u32 > , () , () , :: subxt :: storage :: address :: Yes >{ ::subxt::storage::address::Address::new_static( - "XcmPallet", - "Queries", + "ParaInclusion", + "PendingAvailability", Vec::new(), [ - 251u8, 97u8, 131u8, 135u8, 93u8, 68u8, 156u8, 25u8, 181u8, 231u8, - 124u8, 93u8, 170u8, 114u8, 250u8, 177u8, 172u8, 51u8, 59u8, 44u8, - 148u8, 189u8, 199u8, 62u8, 118u8, 89u8, 75u8, 29u8, 71u8, 49u8, 248u8, - 48u8, + 54u8, 166u8, 18u8, 56u8, 51u8, 241u8, 31u8, 165u8, 220u8, 138u8, 67u8, + 171u8, 23u8, 101u8, 109u8, 26u8, 211u8, 237u8, 81u8, 143u8, 192u8, + 214u8, 49u8, 42u8, 69u8, 30u8, 168u8, 113u8, 72u8, 12u8, 140u8, 242u8, ], ) } - #[doc = " The existing asset traps."] - #[doc = ""] - #[doc = " Key is the blake2 256 hash of (origin, versioned `MultiAssets`) pair. Value is the number of"] - #[doc = " times this pair has been trapped (usually just 1 if it exists at all)."] - pub fn asset_traps( + #[doc = " The commitments of candidates pending availability, by `ParaId`."] + pub fn pending_availability_commitments( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + _0: impl ::std::borrow::Borrow, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, + runtime_types::polkadot_primitives::v4::CandidateCommitments< + ::core::primitive::u32, + >, ::subxt::storage::address::Yes, + (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "XcmPallet", - "AssetTraps", + "ParaInclusion", + "PendingAvailabilityCommitments", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 4u8, 185u8, 92u8, 4u8, 7u8, 71u8, 214u8, 1u8, 141u8, 59u8, 87u8, 55u8, - 149u8, 26u8, 125u8, 8u8, 88u8, 31u8, 240u8, 138u8, 133u8, 28u8, 37u8, - 131u8, 107u8, 218u8, 86u8, 152u8, 147u8, 44u8, 19u8, 239u8, + 128u8, 38u8, 30u8, 235u8, 157u8, 55u8, 36u8, 88u8, 188u8, 164u8, 61u8, + 62u8, 84u8, 83u8, 180u8, 208u8, 244u8, 240u8, 254u8, 183u8, 226u8, + 201u8, 27u8, 47u8, 212u8, 137u8, 251u8, 46u8, 13u8, 33u8, 13u8, 43u8, ], ) } - #[doc = " The existing asset traps."] - #[doc = ""] - #[doc = " Key is the blake2 256 hash of (origin, versioned `MultiAssets`) pair. Value is the number of"] - #[doc = " times this pair has been trapped (usually just 1 if it exists at all)."] - pub fn asset_traps_root( + #[doc = " The commitments of candidates pending availability, by `ParaId`."] + pub fn pending_availability_commitments_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + runtime_types::polkadot_primitives::v4::CandidateCommitments< + ::core::primitive::u32, + >, + (), (), - ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "XcmPallet", - "AssetTraps", + "ParaInclusion", + "PendingAvailabilityCommitments", Vec::new(), [ - 4u8, 185u8, 92u8, 4u8, 7u8, 71u8, 214u8, 1u8, 141u8, 59u8, 87u8, 55u8, - 149u8, 26u8, 125u8, 8u8, 88u8, 31u8, 240u8, 138u8, 133u8, 28u8, 37u8, - 131u8, 107u8, 218u8, 86u8, 152u8, 147u8, 44u8, 19u8, 239u8, + 128u8, 38u8, 30u8, 235u8, 157u8, 55u8, 36u8, 88u8, 188u8, 164u8, 61u8, + 62u8, 84u8, 83u8, 180u8, 208u8, 244u8, 240u8, 254u8, 183u8, 226u8, + 201u8, 27u8, 47u8, 212u8, 137u8, 251u8, 46u8, 13u8, 33u8, 13u8, 43u8, ], ) } - #[doc = " Default version to encode XCM when latest version of destination is unknown. If `None`,"] - #[doc = " then the destinations whose XCM version is unknown are considered unreachable."] - pub fn safe_xcm_version( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "SafeXcmVersion", - vec![], + } + } + } + pub mod para_inherent { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::polkadot_runtime_parachains::paras_inherent::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Enter { + pub data: runtime_types::polkadot_primitives::v4::InherentData< + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + >, + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Enter the paras inherent. This will process bitfields and backed candidates."] + pub fn enter( + &self, + data: runtime_types::polkadot_primitives::v4::InherentData< + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ParaInherent", + "enter", + Enter { data }, [ - 1u8, 223u8, 218u8, 204u8, 222u8, 129u8, 137u8, 237u8, 197u8, 142u8, - 233u8, 66u8, 229u8, 153u8, 138u8, 222u8, 113u8, 164u8, 135u8, 213u8, - 233u8, 34u8, 24u8, 23u8, 215u8, 59u8, 40u8, 188u8, 45u8, 244u8, 205u8, - 199u8, + 196u8, 247u8, 84u8, 213u8, 181u8, 15u8, 195u8, 125u8, 252u8, 46u8, + 165u8, 1u8, 23u8, 159u8, 187u8, 34u8, 8u8, 15u8, 44u8, 240u8, 136u8, + 148u8, 7u8, 82u8, 106u8, 255u8, 190u8, 127u8, 225u8, 230u8, 63u8, + 204u8, ], ) } - #[doc = " The Latest versions that we know various locations support."] - pub fn supported_version( + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Whether the paras inherent was included within this block."] + #[doc = ""] + #[doc = " The `Option<()>` is effectively a `bool`, but it never hits storage in the `None` variant"] + #[doc = " due to the guarantees of FRAME's storage APIs."] + #[doc = ""] + #[doc = " If this is `None` at the end of the block, we panic and render the block invalid."] + pub fn included( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, + (), + (), > { ::subxt::storage::address::Address::new_static( - "XcmPallet", - "SupportedVersion", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + "ParaInherent", + "Included", + vec![], [ - 112u8, 34u8, 251u8, 179u8, 217u8, 54u8, 125u8, 242u8, 190u8, 8u8, 44u8, - 14u8, 138u8, 76u8, 241u8, 95u8, 233u8, 96u8, 141u8, 26u8, 151u8, 196u8, - 219u8, 137u8, 165u8, 27u8, 87u8, 128u8, 19u8, 35u8, 222u8, 202u8, + 208u8, 213u8, 76u8, 64u8, 90u8, 141u8, 144u8, 52u8, 220u8, 35u8, 143u8, + 171u8, 45u8, 59u8, 9u8, 218u8, 29u8, 186u8, 139u8, 203u8, 205u8, 12u8, + 10u8, 2u8, 27u8, 167u8, 182u8, 244u8, 167u8, 220u8, 44u8, 16u8, ], ) } - #[doc = " The Latest versions that we know various locations support."] - pub fn supported_version_root( + #[doc = " Scraped on chain data for extracting resolved disputes as well as backing votes."] + pub fn on_chain_votes( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + runtime_types::polkadot_primitives::v4::ScrapedOnChainVotes< + ::subxt::utils::H256, + >, + ::subxt::storage::address::Yes, (), (), - ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "XcmPallet", - "SupportedVersion", - Vec::new(), + "ParaInherent", + "OnChainVotes", + vec![], [ - 112u8, 34u8, 251u8, 179u8, 217u8, 54u8, 125u8, 242u8, 190u8, 8u8, 44u8, - 14u8, 138u8, 76u8, 241u8, 95u8, 233u8, 96u8, 141u8, 26u8, 151u8, 196u8, - 219u8, 137u8, 165u8, 27u8, 87u8, 128u8, 19u8, 35u8, 222u8, 202u8, + 187u8, 34u8, 219u8, 197u8, 202u8, 214u8, 140u8, 152u8, 253u8, 65u8, + 206u8, 217u8, 36u8, 40u8, 107u8, 215u8, 135u8, 115u8, 35u8, 61u8, + 180u8, 131u8, 0u8, 184u8, 193u8, 76u8, 165u8, 63u8, 106u8, 222u8, + 126u8, 113u8, ], ) } - #[doc = " All locations that we have requested version notifications from."] - pub fn version_notifiers( + } + } + } + pub mod para_scheduler { + use super::root_mod; + use super::runtime_types; + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " All the validator groups. One for each core. Indices are into `ActiveValidators` - not the"] + #[doc = " broader set of Polkadot validators, but instead just the subset used for parachains during"] + #[doc = " this session."] + #[doc = ""] + #[doc = " Bound: The number of cores is the sum of the numbers of parachains and parathread multiplexers."] + #[doc = " Reasonably, 100-1000. The dominant factor is the number of validators: safe upper bound at 10k."] + pub fn validator_groups( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, + ::std::vec::Vec< + ::std::vec::Vec, + >, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "XcmPallet", - "VersionNotifiers", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + "ParaScheduler", + "ValidatorGroups", + vec![], [ - 233u8, 217u8, 119u8, 102u8, 41u8, 77u8, 198u8, 24u8, 161u8, 22u8, - 104u8, 149u8, 204u8, 128u8, 123u8, 166u8, 17u8, 36u8, 202u8, 92u8, - 190u8, 44u8, 73u8, 239u8, 88u8, 17u8, 92u8, 41u8, 236u8, 80u8, 154u8, - 10u8, + 175u8, 187u8, 69u8, 76u8, 211u8, 36u8, 162u8, 147u8, 83u8, 65u8, 83u8, + 44u8, 241u8, 112u8, 246u8, 14u8, 237u8, 255u8, 248u8, 58u8, 44u8, + 207u8, 159u8, 112u8, 31u8, 90u8, 15u8, 85u8, 4u8, 212u8, 215u8, 211u8, ], ) } - #[doc = " All locations that we have requested version notifications from."] - pub fn version_notifiers_root( + #[doc = " A queue of upcoming claims and which core they should be mapped onto."] + #[doc = ""] + #[doc = " The number of queued claims is bounded at the `scheduling_lookahead`"] + #[doc = " multiplied by the number of parathread multiplexer cores. Reasonably, 10 * 50 = 500."] + pub fn parathread_queue( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - (), - (), + runtime_types::polkadot_runtime_parachains::scheduler::ParathreadClaimQueue, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "XcmPallet", - "VersionNotifiers", - Vec::new(), + "ParaScheduler", + "ParathreadQueue", + vec![], [ - 233u8, 217u8, 119u8, 102u8, 41u8, 77u8, 198u8, 24u8, 161u8, 22u8, - 104u8, 149u8, 204u8, 128u8, 123u8, 166u8, 17u8, 36u8, 202u8, 92u8, - 190u8, 44u8, 73u8, 239u8, 88u8, 17u8, 92u8, 41u8, 236u8, 80u8, 154u8, - 10u8, + 79u8, 144u8, 191u8, 114u8, 235u8, 55u8, 133u8, 208u8, 73u8, 97u8, 73u8, + 148u8, 96u8, 185u8, 110u8, 95u8, 132u8, 54u8, 244u8, 86u8, 50u8, 218u8, + 121u8, 226u8, 153u8, 58u8, 232u8, 202u8, 132u8, 147u8, 168u8, 48u8, ], ) } - #[doc = " The target locations that are subscribed to our version changes, as well as the most recent"] - #[doc = " of our versions we informed them of."] - pub fn version_notify_targets( + #[doc = " One entry for each availability core. Entries are `None` if the core is not currently occupied. Can be"] + #[doc = " temporarily `Some` if scheduled but not occupied."] + #[doc = " The i'th parachain belongs to the i'th core, with the remaining cores all being"] + #[doc = " parathread-multiplexers."] + #[doc = ""] + #[doc = " Bounded by the maximum of either of these two values:"] + #[doc = " * The number of parachains and parathread multiplexers"] + #[doc = " * The number of validators divided by `configuration.max_validators_per_core`."] + pub fn availability_cores( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u64, - ::core::primitive::u64, - ::core::primitive::u32, - ), + ::std::vec::Vec< + ::core::option::Option< + runtime_types::polkadot_primitives::v4::CoreOccupied, + >, + >, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "XcmPallet", - "VersionNotifyTargets", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + "ParaScheduler", + "AvailabilityCores", + vec![], [ - 108u8, 104u8, 137u8, 191u8, 2u8, 2u8, 240u8, 174u8, 32u8, 174u8, 150u8, - 136u8, 33u8, 84u8, 30u8, 74u8, 95u8, 94u8, 20u8, 112u8, 101u8, 204u8, - 15u8, 47u8, 136u8, 56u8, 40u8, 66u8, 1u8, 42u8, 16u8, 247u8, + 103u8, 94u8, 52u8, 17u8, 118u8, 25u8, 254u8, 190u8, 74u8, 91u8, 64u8, + 205u8, 243u8, 113u8, 143u8, 166u8, 193u8, 110u8, 214u8, 151u8, 24u8, + 112u8, 69u8, 131u8, 235u8, 78u8, 240u8, 120u8, 240u8, 68u8, 56u8, + 215u8, ], ) } - #[doc = " The target locations that are subscribed to our version changes, as well as the most recent"] - #[doc = " of our versions we informed them of."] - pub fn version_notify_targets_root( + #[doc = " An index used to ensure that only one claim on a parathread exists in the queue or is"] + #[doc = " currently being handled by an occupied core."] + #[doc = ""] + #[doc = " Bounded by the number of parathread cores and scheduling lookahead. Reasonably, 10 * 50 = 500."] + pub fn parathread_claim_index( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u64, - ::core::primitive::u64, - ::core::primitive::u32, - ), - (), - (), + ::std::vec::Vec, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "XcmPallet", - "VersionNotifyTargets", - Vec::new(), + "ParaScheduler", + "ParathreadClaimIndex", + vec![], [ - 108u8, 104u8, 137u8, 191u8, 2u8, 2u8, 240u8, 174u8, 32u8, 174u8, 150u8, - 136u8, 33u8, 84u8, 30u8, 74u8, 95u8, 94u8, 20u8, 112u8, 101u8, 204u8, - 15u8, 47u8, 136u8, 56u8, 40u8, 66u8, 1u8, 42u8, 16u8, 247u8, + 64u8, 17u8, 173u8, 35u8, 14u8, 16u8, 149u8, 200u8, 118u8, 211u8, 130u8, + 15u8, 124u8, 112u8, 44u8, 220u8, 156u8, 132u8, 119u8, 148u8, 24u8, + 120u8, 252u8, 246u8, 204u8, 119u8, 206u8, 85u8, 44u8, 210u8, 135u8, + 83u8, ], ) } - #[doc = " Destinations whose latest XCM version we would like to know. Duplicates not allowed, and"] - #[doc = " the `u32` counter is the number of times that a send to the destination has been attempted,"] - #[doc = " which is used as a prioritization."] - pub fn version_discovery_queue( + #[doc = " The block number where the session start occurred. Used to track how many group rotations have occurred."] + #[doc = ""] + #[doc = " Note that in the context of parachains modules the session change is signaled during"] + #[doc = " the block and enacted at the end of the block (at the finalization stage, to be exact)."] + #[doc = " Thus for all intents and purposes the effect of the session change is observed at the"] + #[doc = " block following the session change, block number of which we save in this storage value."] + pub fn session_start_block( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec<( - runtime_types::xcm::VersionedMultiLocation, - ::core::primitive::u32, - )>, + ::core::primitive::u32, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "XcmPallet", - "VersionDiscoveryQueue", + "ParaScheduler", + "SessionStartBlock", vec![], [ - 30u8, 163u8, 210u8, 133u8, 30u8, 63u8, 36u8, 9u8, 162u8, 133u8, 99u8, - 170u8, 34u8, 205u8, 27u8, 41u8, 226u8, 141u8, 165u8, 151u8, 46u8, - 140u8, 150u8, 242u8, 178u8, 88u8, 164u8, 12u8, 129u8, 118u8, 25u8, - 79u8, + 122u8, 37u8, 150u8, 1u8, 185u8, 201u8, 168u8, 67u8, 55u8, 17u8, 101u8, + 18u8, 133u8, 212u8, 6u8, 73u8, 191u8, 204u8, 229u8, 22u8, 185u8, 120u8, + 24u8, 245u8, 121u8, 215u8, 124u8, 210u8, 49u8, 28u8, 26u8, 80u8, ], ) } - #[doc = " The current migration's stage, if any."] - pub fn current_migration( + #[doc = " Currently scheduled cores - free but up to be occupied."] + #[doc = ""] + #[doc = " Bounded by the number of cores: one for each parachain and parathread multiplexer."] + #[doc = ""] + #[doc = " The value contained here will not be valid after the end of a block. Runtime APIs should be used to determine scheduled cores/"] + #[doc = " for the upcoming block."] + pub fn scheduled( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::VersionMigrationStage, + ::std::vec::Vec< + runtime_types::polkadot_runtime_parachains::scheduler::CoreAssignment, + >, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), (), > { ::subxt::storage::address::Address::new_static( - "XcmPallet", - "CurrentMigration", + "ParaScheduler", + "Scheduled", vec![], [ - 137u8, 144u8, 168u8, 185u8, 158u8, 90u8, 127u8, 243u8, 227u8, 134u8, - 150u8, 73u8, 15u8, 99u8, 23u8, 47u8, 68u8, 18u8, 39u8, 16u8, 24u8, - 43u8, 161u8, 56u8, 66u8, 111u8, 16u8, 7u8, 252u8, 125u8, 100u8, 225u8, + 246u8, 105u8, 102u8, 107u8, 143u8, 92u8, 220u8, 69u8, 71u8, 102u8, + 212u8, 157u8, 56u8, 112u8, 42u8, 179u8, 183u8, 139u8, 128u8, 81u8, + 239u8, 84u8, 103u8, 126u8, 82u8, 247u8, 39u8, 39u8, 231u8, 218u8, + 131u8, 53u8, ], ) } } } } - pub mod runtime_types { + pub mod paras { + use super::root_mod; use super::runtime_types; - pub mod finality_grandpa { + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::polkadot_runtime_parachains::paras::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -32502,11 +28213,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Equivocation<_0, _1, _2> { - pub round_number: ::core::primitive::u64, - pub identity: _0, - pub first: (_1, _2), - pub second: (_1, _2), + pub struct ForceSetCurrentCode { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -32518,9 +28227,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Precommit<_0, _1> { - pub target_hash: _0, - pub target_number: _1, + pub struct ForceSetCurrentHead { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub new_head: runtime_types::polkadot_parachain::primitives::HeadData, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -32532,170 +28241,37 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Prevote<_0, _1> { - pub target_hash: _0, - pub target_number: _1, + pub struct ForceScheduleCodeUpgrade { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + pub relay_parent_number: ::core::primitive::u32, } - } - pub mod frame_support { - use super::runtime_types; - pub mod dispatch { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum DispatchClass { - #[codec(index = 0)] - Normal, - #[codec(index = 1)] - Operational, - #[codec(index = 2)] - Mandatory, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DispatchInfo { - pub weight: runtime_types::sp_weights::weight_v2::Weight, - pub class: runtime_types::frame_support::dispatch::DispatchClass, - pub pays_fee: runtime_types::frame_support::dispatch::Pays, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Pays { - #[codec(index = 0)] - Yes, - #[codec(index = 1)] - No, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PerDispatchClass<_0> { - pub normal: _0, - pub operational: _0, - pub mandatory: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum RawOrigin<_0> { - #[codec(index = 0)] - Root, - #[codec(index = 1)] - Signed(_0), - #[codec(index = 2)] - None, - } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceNoteNewHead { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub new_head: runtime_types::polkadot_parachain::primitives::HeadData, } - pub mod traits { - use super::runtime_types; - pub mod misc { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WrapperOpaque<_0>( - #[codec(compact)] pub ::core::primitive::u32, - pub _0, - ); - } - pub mod preimages { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Bounded<_0> { - #[codec(index = 0)] - Legacy { - hash: ::subxt::utils::H256, - }, - #[codec(index = 1)] - Inline( - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Lookup { - hash: ::subxt::utils::H256, - len: ::core::primitive::u32, - }, - __Ignore(::core::marker::PhantomData<_0>), - } - } - pub mod tokens { - use super::runtime_types; - pub mod misc { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum BalanceStatus { - #[codec(index = 0)] - Free, - #[codec(index = 1)] - Reserved, - } - } - } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceQueueAction { + pub para: runtime_types::polkadot_parachain::primitives::Id, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -32707,332 +28283,206 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PalletId(pub [::core::primitive::u8; 8usize]); - } - pub mod frame_system { - use super::runtime_types; - pub mod extensions { - use super::runtime_types; - pub mod check_genesis { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckGenesis; - } - pub mod check_mortality { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckMortality(pub runtime_types::sp_runtime::generic::era::Era); - } - pub mod check_non_zero_sender { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckNonZeroSender; - } - pub mod check_nonce { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckNonce(#[codec(compact)] pub ::core::primitive::u32); - } - pub mod check_spec_version { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckSpecVersion; - } - pub mod check_tx_version { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckTxVersion; + pub struct AddTrustedValidationCode { + pub validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PokeUnusedValidationCode { + pub validation_code_hash: + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct IncludePvfCheckStatement { + pub stmt: runtime_types::polkadot_primitives::v4::PvfCheckStatement, + pub signature: runtime_types::polkadot_primitives::v4::validator_app::Signature, + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Set the storage for the parachain validation code immediately."] + pub fn force_set_current_code( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Paras", + "force_set_current_code", + ForceSetCurrentCode { para, new_code }, + [ + 56u8, 59u8, 48u8, 185u8, 106u8, 99u8, 250u8, 32u8, 207u8, 2u8, 4u8, + 110u8, 165u8, 131u8, 22u8, 33u8, 248u8, 175u8, 186u8, 6u8, 118u8, 51u8, + 74u8, 239u8, 68u8, 122u8, 148u8, 242u8, 193u8, 131u8, 6u8, 135u8, + ], + ) } - pub mod check_weight { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckWeight; + #[doc = "Set the storage for the current parachain head data immediately."] + pub fn force_set_current_head( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + new_head: runtime_types::polkadot_parachain::primitives::HeadData, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Paras", + "force_set_current_head", + ForceSetCurrentHead { para, new_head }, + [ + 203u8, 70u8, 33u8, 168u8, 133u8, 64u8, 146u8, 137u8, 156u8, 104u8, + 183u8, 26u8, 74u8, 227u8, 154u8, 224u8, 75u8, 85u8, 143u8, 51u8, 60u8, + 194u8, 59u8, 94u8, 100u8, 84u8, 194u8, 100u8, 153u8, 9u8, 222u8, 63u8, + ], + ) } - } - pub mod limits { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BlockLength { - pub max: runtime_types::frame_support::dispatch::PerDispatchClass< - ::core::primitive::u32, - >, + #[doc = "Schedule an upgrade as if it was scheduled in the given relay parent block."] + pub fn force_schedule_code_upgrade( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + relay_parent_number: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Paras", + "force_schedule_code_upgrade", + ForceScheduleCodeUpgrade { + para, + new_code, + relay_parent_number, + }, + [ + 30u8, 210u8, 178u8, 31u8, 48u8, 144u8, 167u8, 117u8, 220u8, 36u8, + 175u8, 220u8, 145u8, 193u8, 20u8, 98u8, 149u8, 130u8, 66u8, 54u8, 20u8, + 204u8, 231u8, 116u8, 203u8, 179u8, 253u8, 106u8, 55u8, 58u8, 116u8, + 109u8, + ], + ) } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BlockWeights { - pub base_block: runtime_types::sp_weights::weight_v2::Weight, - pub max_block: runtime_types::sp_weights::weight_v2::Weight, - pub per_class: runtime_types::frame_support::dispatch::PerDispatchClass< - runtime_types::frame_system::limits::WeightsPerClass, - >, + #[doc = "Note a new block head for para within the context of the current block."] + pub fn force_note_new_head( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + new_head: runtime_types::polkadot_parachain::primitives::HeadData, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Paras", + "force_note_new_head", + ForceNoteNewHead { para, new_head }, + [ + 83u8, 93u8, 166u8, 142u8, 213u8, 1u8, 243u8, 73u8, 192u8, 164u8, 104u8, + 206u8, 99u8, 250u8, 31u8, 222u8, 231u8, 54u8, 12u8, 45u8, 92u8, 74u8, + 248u8, 50u8, 180u8, 86u8, 251u8, 172u8, 227u8, 88u8, 45u8, 127u8, + ], + ) } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WeightsPerClass { - pub base_extrinsic: runtime_types::sp_weights::weight_v2::Weight, - pub max_extrinsic: - ::core::option::Option, - pub max_total: - ::core::option::Option, - pub reserved: - ::core::option::Option, + #[doc = "Put a parachain directly into the next session's action queue."] + #[doc = "We can't queue it any sooner than this without going into the"] + #[doc = "initializer..."] + pub fn force_queue_action( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Paras", + "force_queue_action", + ForceQueueAction { para }, + [ + 195u8, 243u8, 79u8, 34u8, 111u8, 246u8, 109u8, 90u8, 251u8, 137u8, + 48u8, 23u8, 117u8, 29u8, 26u8, 200u8, 37u8, 64u8, 36u8, 254u8, 224u8, + 99u8, 165u8, 246u8, 8u8, 76u8, 250u8, 36u8, 141u8, 67u8, 185u8, 17u8, + ], + ) } - } - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub enum Call { - #[codec(index = 0)] - #[doc = "A dispatch that will fill the block weight up to the given ratio."] - fill_block { - ratio: runtime_types::sp_arithmetic::per_things::Perbill, - }, - #[codec(index = 1)] - #[doc = "Make some on-chain remark."] - #[doc = ""] - #[doc = "# "] - #[doc = "- `O(1)`"] - #[doc = "# "] - remark { - remark: ::std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 2)] - #[doc = "Set the number of pages in the WebAssembly environment's heap."] - set_heap_pages { pages: ::core::primitive::u64 }, - #[codec(index = 3)] - #[doc = "Set the new runtime code."] - #[doc = ""] - #[doc = "# "] - #[doc = "- `O(C + S)` where `C` length of `code` and `S` complexity of `can_set_code`"] - #[doc = "- 1 call to `can_set_code`: `O(S)` (calls `sp_io::misc::runtime_version` which is"] - #[doc = " expensive)."] - #[doc = "- 1 storage write (codec `O(C)`)."] - #[doc = "- 1 digest item."] - #[doc = "- 1 event."] - #[doc = "The weight of this function is dependent on the runtime, but generally this is very"] - #[doc = "expensive. We will treat this as a full block."] - #[doc = "# "] - set_code { - code: ::std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 4)] - #[doc = "Set the new runtime code without doing any checks of the given `code`."] - #[doc = ""] - #[doc = "# "] - #[doc = "- `O(C)` where `C` length of `code`"] - #[doc = "- 1 storage write (codec `O(C)`)."] - #[doc = "- 1 digest item."] - #[doc = "- 1 event."] - #[doc = "The weight of this function is dependent on the runtime. We will treat this as a full"] - #[doc = "block. # "] - set_code_without_checks { - code: ::std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 5)] - #[doc = "Set some items of storage."] - set_storage { - items: ::std::vec::Vec<( - ::std::vec::Vec<::core::primitive::u8>, - ::std::vec::Vec<::core::primitive::u8>, - )>, - }, - #[codec(index = 6)] - #[doc = "Kill some items from storage."] - kill_storage { - keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - }, - #[codec(index = 7)] - #[doc = "Kill all storage items with a key that starts with the given prefix."] - #[doc = ""] - #[doc = "**NOTE:** We rely on the Root origin to provide us the number of subkeys under"] - #[doc = "the prefix we are removing to accurately calculate the weight of this function."] - kill_prefix { - prefix: ::std::vec::Vec<::core::primitive::u8>, - subkeys: ::core::primitive::u32, - }, - #[codec(index = 8)] - #[doc = "Make some on-chain remark and emit event."] - remark_with_event { - remark: ::std::vec::Vec<::core::primitive::u8>, - }, + #[doc = "Adds the validation code to the storage."] + #[doc = ""] + #[doc = "The code will not be added if it is already present. Additionally, if PVF pre-checking"] + #[doc = "is running for that code, it will be instantly accepted."] + #[doc = ""] + #[doc = "Otherwise, the code will be added into the storage. Note that the code will be added"] + #[doc = "into storage with reference count 0. This is to account the fact that there are no users"] + #[doc = "for this code yet. The caller will have to make sure that this code eventually gets"] + #[doc = "used by some parachain or removed from the storage to avoid storage leaks. For the latter"] + #[doc = "prefer to use the `poke_unused_validation_code` dispatchable to raw storage manipulation."] + #[doc = ""] + #[doc = "This function is mainly meant to be used for upgrading parachains that do not follow"] + #[doc = "the go-ahead signal while the PVF pre-checking feature is enabled."] + pub fn add_trusted_validation_code( + &self, + validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Paras", + "add_trusted_validation_code", + AddTrustedValidationCode { validation_code }, + [ + 160u8, 199u8, 245u8, 178u8, 58u8, 65u8, 79u8, 199u8, 53u8, 60u8, 84u8, + 225u8, 2u8, 145u8, 154u8, 204u8, 165u8, 171u8, 173u8, 223u8, 59u8, + 196u8, 37u8, 12u8, 243u8, 158u8, 77u8, 184u8, 58u8, 64u8, 133u8, 71u8, + ], + ) } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Error for the System pallet"] - pub enum Error { - #[codec(index = 0)] - #[doc = "The name of specification does not match between the current runtime"] - #[doc = "and the new runtime."] - InvalidSpecName, - #[codec(index = 1)] - #[doc = "The specification version is not allowed to decrease between the current runtime"] - #[doc = "and the new runtime."] - SpecVersionNeedsToIncrease, - #[codec(index = 2)] - #[doc = "Failed to extract the runtime version from the new runtime."] - #[doc = ""] - #[doc = "Either calling `Core_version` or decoding `RuntimeVersion` failed."] - FailedToExtractRuntimeVersion, - #[codec(index = 3)] - #[doc = "Suicide called when the account has non-default composite data."] - NonDefaultComposite, - #[codec(index = 4)] - #[doc = "There is a non-zero reference count preventing the account from being purged."] - NonZeroRefCount, - #[codec(index = 5)] - #[doc = "The origin filter prevent the call to be dispatched."] - CallFiltered, + #[doc = "Remove the validation code from the storage iff the reference count is 0."] + #[doc = ""] + #[doc = "This is better than removing the storage directly, because it will not remove the code"] + #[doc = "that was suddenly got used by some parachain while this dispatchable was pending"] + #[doc = "dispatching."] + pub fn poke_unused_validation_code( + &self, + validation_code_hash : runtime_types :: polkadot_parachain :: primitives :: ValidationCodeHash, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Paras", + "poke_unused_validation_code", + PokeUnusedValidationCode { + validation_code_hash, + }, + [ + 98u8, 9u8, 24u8, 180u8, 8u8, 144u8, 36u8, 28u8, 111u8, 83u8, 162u8, + 160u8, 66u8, 119u8, 177u8, 117u8, 143u8, 233u8, 241u8, 128u8, 189u8, + 118u8, 241u8, 30u8, 74u8, 171u8, 193u8, 177u8, 233u8, 12u8, 254u8, + 146u8, + ], + ) } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Event for the System pallet."] - pub enum Event { - #[codec(index = 0)] - #[doc = "An extrinsic completed successfully."] - ExtrinsicSuccess { - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 1)] - #[doc = "An extrinsic failed."] - ExtrinsicFailed { - dispatch_error: runtime_types::sp_runtime::DispatchError, - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 2)] - #[doc = "`:code` was updated."] - CodeUpdated, - #[codec(index = 3)] - #[doc = "A new account was created."] - NewAccount { - account: ::subxt::utils::AccountId32, - }, - #[codec(index = 4)] - #[doc = "An account was reaped."] - KilledAccount { - account: ::subxt::utils::AccountId32, - }, - #[codec(index = 5)] - #[doc = "On on-chain remark happened."] - Remarked { - sender: ::subxt::utils::AccountId32, - hash: ::subxt::utils::H256, - }, + #[doc = "Includes a statement for a PVF pre-checking vote. Potentially, finalizes the vote and"] + #[doc = "enacts the results if that was the last vote before achieving the supermajority."] + pub fn include_pvf_check_statement( + &self, + stmt: runtime_types::polkadot_primitives::v4::PvfCheckStatement, + signature: runtime_types::polkadot_primitives::v4::validator_app::Signature, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Paras", + "include_pvf_check_statement", + IncludePvfCheckStatement { stmt, signature }, + [ + 22u8, 136u8, 241u8, 59u8, 36u8, 249u8, 239u8, 255u8, 169u8, 117u8, + 19u8, 58u8, 214u8, 16u8, 135u8, 65u8, 13u8, 250u8, 5u8, 41u8, 144u8, + 29u8, 207u8, 73u8, 215u8, 221u8, 1u8, 253u8, 123u8, 110u8, 6u8, 196u8, + ], + ) } } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::polkadot_runtime_parachains::paras::pallet::Event; + pub mod events { + use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -33043,12 +28493,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AccountInfo<_0, _1> { - pub nonce: _0, - pub consumers: _0, - pub providers: _0, - pub sufficients: _0, - pub data: _1, + #[doc = "Current code has been updated for a Para. `para_id`"] + pub struct CurrentCodeUpdated(pub runtime_types::polkadot_parachain::primitives::Id); + impl ::subxt::events::StaticEvent for CurrentCodeUpdated { + const PALLET: &'static str = "Paras"; + const EVENT: &'static str = "CurrentCodeUpdated"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -33060,10 +28509,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EventRecord<_0, _1> { - pub phase: runtime_types::frame_system::Phase, - pub event: _0, - pub topics: ::std::vec::Vec<_1>, + #[doc = "Current head has been updated for a Para. `para_id`"] + pub struct CurrentHeadUpdated(pub runtime_types::polkadot_parachain::primitives::Id); + impl ::subxt::events::StaticEvent for CurrentHeadUpdated { + const PALLET: &'static str = "Paras"; + const EVENT: &'static str = "CurrentHeadUpdated"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -33075,10 +28525,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct LastRuntimeUpgradeInfo { - #[codec(compact)] - pub spec_version: ::core::primitive::u32, - pub spec_name: ::std::string::String, + #[doc = "A code upgrade has been scheduled for a Para. `para_id`"] + pub struct CodeUpgradeScheduled(pub runtime_types::polkadot_parachain::primitives::Id); + impl ::subxt::events::StaticEvent for CodeUpgradeScheduled { + const PALLET: &'static str = "Paras"; + const EVENT: &'static str = "CodeUpgradeScheduled"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -33090,76 +28541,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Phase { - #[codec(index = 0)] - ApplyExtrinsic(::core::primitive::u32), - #[codec(index = 1)] - Finalization, - #[codec(index = 2)] - Initialization, - } - } - pub mod pallet_authorship { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub enum Call { - #[codec(index = 0)] - #[doc = "Provide a set of uncles."] - set_uncles { - new_uncles: ::std::vec::Vec< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - >, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub enum Error { - #[codec(index = 0)] - #[doc = "The uncle parent not in the chain."] - InvalidUncleParent, - #[codec(index = 1)] - #[doc = "Uncles already set in the block."] - UnclesAlreadySet, - #[codec(index = 2)] - #[doc = "Too many uncles."] - TooManyUncles, - #[codec(index = 3)] - #[doc = "The uncle is genesis."] - GenesisUncle, - #[codec(index = 4)] - #[doc = "The uncle is too high in chain."] - TooHighUncle, - #[codec(index = 5)] - #[doc = "The uncle is already included."] - UncleAlreadyIncluded, - #[codec(index = 6)] - #[doc = "The uncle isn't recent enough to be included."] - OldUncle, - } + #[doc = "A new head has been noted for a Para. `para_id`"] + pub struct NewHeadNoted(pub runtime_types::polkadot_parachain::primitives::Id); + impl ::subxt::events::StaticEvent for NewHeadNoted { + const PALLET: &'static str = "Paras"; + const EVENT: &'static str = "NewHeadNoted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -33171,480 +28557,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum UncleEntryItem<_0, _1, _2> { - #[codec(index = 0)] - InclusionHeight(_0), - #[codec(index = 1)] - Uncle(_1, ::core::option::Option<_2>), - } - } - pub mod pallet_babe { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub enum Call { - #[codec(index = 0)] - #[doc = "Report authority equivocation/misbehavior. This method will verify"] - #[doc = "the equivocation proof and validate the given key ownership proof"] - #[doc = "against the extracted offender. If both are valid, the offence will"] - #[doc = "be reported."] - report_equivocation { - equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - runtime_types::sp_consensus_babe::app::Public, - >, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - }, - #[codec(index = 1)] - #[doc = "Report authority equivocation/misbehavior. This method will verify"] - #[doc = "the equivocation proof and validate the given key ownership proof"] - #[doc = "against the extracted offender. If both are valid, the offence will"] - #[doc = "be reported."] - #[doc = "This extrinsic must be called unsigned and it is expected that only"] - #[doc = "block authors will call it (validated in `ValidateUnsigned`), as such"] - #[doc = "if the block author is defined it will be defined as the equivocation"] - #[doc = "reporter."] - report_equivocation_unsigned { - equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - runtime_types::sp_consensus_babe::app::Public, - >, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - }, - #[codec(index = 2)] - #[doc = "Plan an epoch config change. The epoch config change is recorded and will be enacted on"] - #[doc = "the next call to `enact_epoch_change`. The config will be activated one epoch after."] - #[doc = "Multiple calls to this method will replace any existing planned config change that had"] - #[doc = "not been enacted yet."] - plan_config_change { - config: runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub enum Error { - #[codec(index = 0)] - #[doc = "An equivocation proof provided as part of an equivocation report is invalid."] - InvalidEquivocationProof, - #[codec(index = 1)] - #[doc = "A key ownership proof provided as part of an equivocation report is invalid."] - InvalidKeyOwnershipProof, - #[codec(index = 2)] - #[doc = "A given equivocation report is valid but already previously reported."] - DuplicateOffenceReport, - #[codec(index = 3)] - #[doc = "Submitted configuration is invalid."] - InvalidConfiguration, - } - } - } - pub mod pallet_bags_list { - use super::runtime_types; - pub mod list { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Bag { - pub head: ::core::option::Option<::subxt::utils::AccountId32>, - pub tail: ::core::option::Option<::subxt::utils::AccountId32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum ListError { - #[codec(index = 0)] - Duplicate, - #[codec(index = 1)] - NotHeavier, - #[codec(index = 2)] - NotInSameBag, - #[codec(index = 3)] - NodeNotFound, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Node { - pub id: ::subxt::utils::AccountId32, - pub prev: ::core::option::Option<::subxt::utils::AccountId32>, - pub next: ::core::option::Option<::subxt::utils::AccountId32>, - pub bag_upper: ::core::primitive::u64, - pub score: ::core::primitive::u64, - } - } - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub enum Call { - #[codec(index = 0)] - #[doc = "Declare that some `dislocated` account has, through rewards or penalties, sufficiently"] - #[doc = "changed its score that it should properly fall into a different bag than its current"] - #[doc = "one."] - #[doc = ""] - #[doc = "Anyone can call this function about any potentially dislocated account."] - #[doc = ""] - #[doc = "Will always update the stored score of `dislocated` to the correct score, based on"] - #[doc = "`ScoreProvider`."] - #[doc = ""] - #[doc = "If `dislocated` does not exists, it returns an error."] - rebag { - dislocated: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 1)] - #[doc = "Move the caller's Id directly in front of `lighter`."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and can only be called by the Id of"] - #[doc = "the account going in front of `lighter`."] - #[doc = ""] - #[doc = "Only works if"] - #[doc = "- both nodes are within the same bag,"] - #[doc = "- and `origin` has a greater `Score` than `lighter`."] - put_in_front_of { - lighter: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub enum Error { - #[codec(index = 0)] - #[doc = "A error in the list interface implementation."] - List(runtime_types::pallet_bags_list::list::ListError), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub enum Event { - #[codec(index = 0)] - #[doc = "Moved an account from one bag to another."] - Rebagged { - who: ::subxt::utils::AccountId32, - from: ::core::primitive::u64, - to: ::core::primitive::u64, - }, - #[codec(index = 1)] - #[doc = "Updated the score of some account to the given amount."] - ScoreUpdated { - who: ::subxt::utils::AccountId32, - new_score: ::core::primitive::u64, - }, - } - } - } - pub mod pallet_balances { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub enum Call { - #[codec(index = 0)] - #[doc = "Transfer some liquid free balance to another account."] - #[doc = ""] - #[doc = "`transfer` will set the `FreeBalance` of the sender and receiver."] - #[doc = "If the sender's account is below the existential deposit as a result"] - #[doc = "of the transfer, the account will be reaped."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be `Signed` by the transactor."] - #[doc = ""] - #[doc = "# "] - #[doc = "- Dependent on arguments but not critical, given proper implementations for input config"] - #[doc = " types. See related functions below."] - #[doc = "- It contains a limited number of reads and writes internally and no complex"] - #[doc = " computation."] - #[doc = ""] - #[doc = "Related functions:"] - #[doc = ""] - #[doc = " - `ensure_can_withdraw` is always called internally but has a bounded complexity."] - #[doc = " - Transferring balances to accounts that did not exist before will cause"] - #[doc = " `T::OnNewAccount::on_new_account` to be called."] - #[doc = " - Removing enough funds from an account will trigger `T::DustRemoval::on_unbalanced`."] - #[doc = " - `transfer_keep_alive` works the same way as `transfer`, but has an additional check"] - #[doc = " that the transfer will not kill the origin account."] - #[doc = "---------------------------------"] - #[doc = "- Origin account is already in memory, so no DB operations for them."] - #[doc = "# "] - transfer { - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 1)] - #[doc = "Set the balances of a given account."] - #[doc = ""] - #[doc = "This will alter `FreeBalance` and `ReservedBalance` in storage. it will"] - #[doc = "also alter the total issuance of the system (`TotalIssuance`) appropriately."] - #[doc = "If the new free or reserved balance is below the existential deposit,"] - #[doc = "it will reset the account nonce (`frame_system::AccountNonce`)."] - #[doc = ""] - #[doc = "The dispatch origin for this call is `root`."] - set_balance { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - new_free: ::core::primitive::u128, - #[codec(compact)] - new_reserved: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "Exactly as `transfer`, except the origin must be root and the source account may be"] - #[doc = "specified."] - #[doc = "# "] - #[doc = "- Same as transfer, but additional read and write because the source account is not"] - #[doc = " assumed to be in the overlay."] - #[doc = "# "] - force_transfer { - source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "Same as the [`transfer`] call, but with a check that the transfer will not kill the"] - #[doc = "origin account."] - #[doc = ""] - #[doc = "99% of the time you want [`transfer`] instead."] - #[doc = ""] - #[doc = "[`transfer`]: struct.Pallet.html#method.transfer"] - transfer_keep_alive { - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 4)] - #[doc = "Transfer the entire transferable balance from the caller account."] - #[doc = ""] - #[doc = "NOTE: This function only attempts to transfer _transferable_ balances. This means that"] - #[doc = "any locked, reserved, or existential deposits (when `keep_alive` is `true`), will not be"] - #[doc = "transferred by this function. To ensure that this function results in a killed account,"] - #[doc = "you might need to prepare the account by removing any reference counters, storage"] - #[doc = "deposits, etc..."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be Signed."] - #[doc = ""] - #[doc = "- `dest`: The recipient of the transfer."] - #[doc = "- `keep_alive`: A boolean to determine if the `transfer_all` operation should send all"] - #[doc = " of the funds the account has, causing the sender account to be killed (false), or"] - #[doc = " transfer everything except at least the existential deposit, which will guarantee to"] - #[doc = " keep the sender account alive (true). # "] - #[doc = "- O(1). Just like transfer, but reading the user's transferable balance first."] - #[doc = " #"] - transfer_all { - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - keep_alive: ::core::primitive::bool, - }, - #[codec(index = 5)] - #[doc = "Unreserve some balance from a user by force."] - #[doc = ""] - #[doc = "Can only be called by ROOT."] - force_unreserve { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - amount: ::core::primitive::u128, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub enum Error { - #[codec(index = 0)] - #[doc = "Vesting balance too high to send value"] - VestingBalance, - #[codec(index = 1)] - #[doc = "Account liquidity restrictions prevent withdrawal"] - LiquidityRestrictions, - #[codec(index = 2)] - #[doc = "Balance too low to send value."] - InsufficientBalance, - #[codec(index = 3)] - #[doc = "Value too low to create account due to existential deposit"] - ExistentialDeposit, - #[codec(index = 4)] - #[doc = "Transfer/payment would kill account"] - KeepAlive, - #[codec(index = 5)] - #[doc = "A vesting schedule already exists for this account"] - ExistingVestingSchedule, - #[codec(index = 6)] - #[doc = "Beneficiary account must pre-exist"] - DeadAccount, - #[codec(index = 7)] - #[doc = "Number of named reserves exceed MaxReserves"] - TooManyReserves, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub enum Event { - #[codec(index = 0)] - #[doc = "An account was created with some free balance."] - Endowed { - account: ::subxt::utils::AccountId32, - free_balance: ::core::primitive::u128, - }, - #[codec(index = 1)] - #[doc = "An account was removed whose balance was non-zero but below ExistentialDeposit,"] - #[doc = "resulting in an outright loss."] - DustLost { - account: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "Transfer succeeded."] - Transfer { - from: ::subxt::utils::AccountId32, - to: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "A balance was set by root."] - BalanceSet { - who: ::subxt::utils::AccountId32, - free: ::core::primitive::u128, - reserved: ::core::primitive::u128, - }, - #[codec(index = 4)] - #[doc = "Some balance was reserved (moved from free to reserved)."] - Reserved { - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 5)] - #[doc = "Some balance was unreserved (moved from reserved to free)."] - Unreserved { - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - #[doc = "Some balance was moved from the reserve of the first account to the second account."] - #[doc = "Final argument indicates the destination balance type."] - ReserveRepatriated { - from: ::subxt::utils::AccountId32, - to: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - }, - #[codec(index = 7)] - #[doc = "Some amount was deposited (e.g. for transaction fees)."] - Deposit { - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 8)] - #[doc = "Some amount was withdrawn from the account (e.g. for transaction fees)."] - Withdraw { - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 9)] - #[doc = "Some amount was removed from the account (e.g. for misbehavior)."] - Slashed { - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - } + #[doc = "A para has been queued to execute pending actions. `para_id`"] + pub struct ActionQueued( + pub runtime_types::polkadot_parachain::primitives::Id, + pub ::core::primitive::u32, + ); + impl ::subxt::events::StaticEvent for ActionQueued { + const PALLET: &'static str = "Paras"; + const EVENT: &'static str = "ActionQueued"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -33656,11 +28576,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AccountData<_0> { - pub free: _0, - pub reserved: _0, - pub misc_frozen: _0, - pub fee_frozen: _0, + #[doc = "The given para either initiated or subscribed to a PVF check for the given validation"] + #[doc = "code. `code_hash` `para_id`"] + pub struct PvfCheckStarted( + pub runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + pub runtime_types::polkadot_parachain::primitives::Id, + ); + impl ::subxt::events::StaticEvent for PvfCheckStarted { + const PALLET: &'static str = "Paras"; + const EVENT: &'static str = "PvfCheckStarted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -33672,10 +28596,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BalanceLock<_0> { - pub id: [::core::primitive::u8; 8usize], - pub amount: _0, - pub reasons: runtime_types::pallet_balances::Reasons, + #[doc = "The given validation code was accepted by the PVF pre-checking vote."] + #[doc = "`code_hash` `para_id`"] + pub struct PvfCheckAccepted( + pub runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + pub runtime_types::polkadot_parachain::primitives::Id, + ); + impl ::subxt::events::StaticEvent for PvfCheckAccepted { + const PALLET: &'static str = "Paras"; + const EVENT: &'static str = "PvfCheckAccepted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -33687,43 +28616,8308 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Reasons { - #[codec(index = 0)] - Fee, - #[codec(index = 1)] - Misc, - #[codec(index = 2)] - All, + #[doc = "The given validation code was rejected by the PVF pre-checking vote."] + #[doc = "`code_hash` `para_id`"] + pub struct PvfCheckRejected( + pub runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + pub runtime_types::polkadot_parachain::primitives::Id, + ); + impl ::subxt::events::StaticEvent for PvfCheckRejected { + const PALLET: &'static str = "Paras"; + const EVENT: &'static str = "PvfCheckRejected"; } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " All currently active PVF pre-checking votes."] + #[doc = ""] + #[doc = " Invariant:"] + #[doc = " - There are no PVF pre-checking votes that exists in list but not in the set and vice versa."] + pub fn pvf_active_vote_map( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::paras::PvfCheckActiveVoteState< + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "PvfActiveVoteMap", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 84u8, 214u8, 221u8, 221u8, 244u8, 56u8, 135u8, 87u8, 252u8, 39u8, + 188u8, 13u8, 196u8, 25u8, 214u8, 186u8, 152u8, 181u8, 190u8, 39u8, + 235u8, 211u8, 236u8, 114u8, 67u8, 85u8, 138u8, 43u8, 248u8, 134u8, + 124u8, 73u8, + ], + ) + } + #[doc = " All currently active PVF pre-checking votes."] + #[doc = ""] + #[doc = " Invariant:"] + #[doc = " - There are no PVF pre-checking votes that exists in list but not in the set and vice versa."] + pub fn pvf_active_vote_map_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::paras::PvfCheckActiveVoteState< + ::core::primitive::u32, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "PvfActiveVoteMap", + Vec::new(), + [ + 84u8, 214u8, 221u8, 221u8, 244u8, 56u8, 135u8, 87u8, 252u8, 39u8, + 188u8, 13u8, 196u8, 25u8, 214u8, 186u8, 152u8, 181u8, 190u8, 39u8, + 235u8, 211u8, 236u8, 114u8, 67u8, 85u8, 138u8, 43u8, 248u8, 134u8, + 124u8, 73u8, + ], + ) + } + #[doc = " The list of all currently active PVF votes. Auxiliary to `PvfActiveVoteMap`."] + pub fn pvf_active_vote_list( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec< + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "PvfActiveVoteList", + vec![], + [ + 196u8, 23u8, 108u8, 162u8, 29u8, 33u8, 49u8, 219u8, 127u8, 26u8, 241u8, + 58u8, 102u8, 43u8, 156u8, 3u8, 87u8, 153u8, 195u8, 96u8, 68u8, 132u8, + 170u8, 162u8, 18u8, 156u8, 121u8, 63u8, 53u8, 91u8, 68u8, 69u8, + ], + ) + } + #[doc = " All parachains. Ordered ascending by `ParaId`. Parathreads are not included."] + #[doc = ""] + #[doc = " Consider using the [`ParachainsCache`] type of modifying."] + pub fn parachains( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "Parachains", + vec![], + [ + 85u8, 234u8, 218u8, 69u8, 20u8, 169u8, 235u8, 6u8, 69u8, 126u8, 28u8, + 18u8, 57u8, 93u8, 238u8, 7u8, 167u8, 221u8, 75u8, 35u8, 36u8, 4u8, + 46u8, 55u8, 234u8, 123u8, 122u8, 173u8, 13u8, 205u8, 58u8, 226u8, + ], + ) + } + #[doc = " The current lifecycle of a all known Para IDs."] + pub fn para_lifecycles( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::paras::ParaLifecycle, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "ParaLifecycles", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 221u8, 103u8, 112u8, 222u8, 86u8, 2u8, 172u8, 187u8, 174u8, 106u8, 4u8, + 253u8, 35u8, 73u8, 18u8, 78u8, 25u8, 31u8, 124u8, 110u8, 81u8, 62u8, + 215u8, 228u8, 183u8, 132u8, 138u8, 213u8, 186u8, 209u8, 191u8, 186u8, + ], + ) + } + #[doc = " The current lifecycle of a all known Para IDs."] + pub fn para_lifecycles_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::paras::ParaLifecycle, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "ParaLifecycles", + Vec::new(), + [ + 221u8, 103u8, 112u8, 222u8, 86u8, 2u8, 172u8, 187u8, 174u8, 106u8, 4u8, + 253u8, 35u8, 73u8, 18u8, 78u8, 25u8, 31u8, 124u8, 110u8, 81u8, 62u8, + 215u8, 228u8, 183u8, 132u8, 138u8, 213u8, 186u8, 209u8, 191u8, 186u8, + ], + ) + } + #[doc = " The head-data of every registered para."] + pub fn heads( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::HeadData, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "Heads", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 122u8, 38u8, 181u8, 121u8, 245u8, 100u8, 136u8, 233u8, 237u8, 248u8, + 127u8, 2u8, 147u8, 41u8, 202u8, 242u8, 238u8, 70u8, 55u8, 200u8, 15u8, + 106u8, 138u8, 108u8, 192u8, 61u8, 158u8, 134u8, 131u8, 142u8, 70u8, + 3u8, + ], + ) + } + #[doc = " The head-data of every registered para."] + pub fn heads_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::HeadData, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "Heads", + Vec::new(), + [ + 122u8, 38u8, 181u8, 121u8, 245u8, 100u8, 136u8, 233u8, 237u8, 248u8, + 127u8, 2u8, 147u8, 41u8, 202u8, 242u8, 238u8, 70u8, 55u8, 200u8, 15u8, + 106u8, 138u8, 108u8, 192u8, 61u8, 158u8, 134u8, 131u8, 142u8, 70u8, + 3u8, + ], + ) + } + #[doc = " The validation code hash of every live para."] + #[doc = ""] + #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] + pub fn current_code_hash( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "CurrentCodeHash", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 179u8, 145u8, 45u8, 44u8, 130u8, 240u8, 50u8, 128u8, 190u8, 133u8, + 66u8, 85u8, 47u8, 141u8, 56u8, 87u8, 131u8, 99u8, 170u8, 203u8, 8u8, + 51u8, 123u8, 73u8, 206u8, 30u8, 173u8, 35u8, 157u8, 195u8, 104u8, + 236u8, + ], + ) + } + #[doc = " The validation code hash of every live para."] + #[doc = ""] + #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] + pub fn current_code_hash_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "CurrentCodeHash", + Vec::new(), + [ + 179u8, 145u8, 45u8, 44u8, 130u8, 240u8, 50u8, 128u8, 190u8, 133u8, + 66u8, 85u8, 47u8, 141u8, 56u8, 87u8, 131u8, 99u8, 170u8, 203u8, 8u8, + 51u8, 123u8, 73u8, 206u8, 30u8, 173u8, 35u8, 157u8, 195u8, 104u8, + 236u8, + ], + ) + } + #[doc = " Actual past code hash, indicated by the para id as well as the block number at which it"] + #[doc = " became outdated."] + #[doc = ""] + #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] + pub fn past_code_hash( + &self, + _0: impl ::std::borrow::Borrow, + _1: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "PastCodeHash", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 241u8, 112u8, 128u8, 226u8, 163u8, 193u8, 77u8, 78u8, 177u8, 146u8, + 31u8, 143u8, 44u8, 140u8, 159u8, 134u8, 221u8, 129u8, 36u8, 224u8, + 46u8, 119u8, 245u8, 253u8, 55u8, 22u8, 137u8, 187u8, 71u8, 94u8, 88u8, + 124u8, + ], + ) + } + #[doc = " Actual past code hash, indicated by the para id as well as the block number at which it"] + #[doc = " became outdated."] + #[doc = ""] + #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] + pub fn past_code_hash_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "PastCodeHash", + Vec::new(), + [ + 241u8, 112u8, 128u8, 226u8, 163u8, 193u8, 77u8, 78u8, 177u8, 146u8, + 31u8, 143u8, 44u8, 140u8, 159u8, 134u8, 221u8, 129u8, 36u8, 224u8, + 46u8, 119u8, 245u8, 253u8, 55u8, 22u8, 137u8, 187u8, 71u8, 94u8, 88u8, + 124u8, + ], + ) + } + #[doc = " Past code of parachains. The parachains themselves may not be registered anymore,"] + #[doc = " but we also keep their code on-chain for the same amount of time as outdated code"] + #[doc = " to keep it available for approval checkers."] + pub fn past_code_meta( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::paras::ParaPastCodeMeta< + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "PastCodeMeta", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 251u8, 52u8, 126u8, 12u8, 21u8, 178u8, 151u8, 195u8, 153u8, 17u8, + 215u8, 242u8, 118u8, 192u8, 86u8, 72u8, 36u8, 97u8, 245u8, 134u8, + 155u8, 117u8, 85u8, 93u8, 225u8, 209u8, 63u8, 164u8, 168u8, 72u8, + 171u8, 228u8, + ], + ) + } + #[doc = " Past code of parachains. The parachains themselves may not be registered anymore,"] + #[doc = " but we also keep their code on-chain for the same amount of time as outdated code"] + #[doc = " to keep it available for approval checkers."] + pub fn past_code_meta_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::paras::ParaPastCodeMeta< + ::core::primitive::u32, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "PastCodeMeta", + Vec::new(), + [ + 251u8, 52u8, 126u8, 12u8, 21u8, 178u8, 151u8, 195u8, 153u8, 17u8, + 215u8, 242u8, 118u8, 192u8, 86u8, 72u8, 36u8, 97u8, 245u8, 134u8, + 155u8, 117u8, 85u8, 93u8, 225u8, 209u8, 63u8, 164u8, 168u8, 72u8, + 171u8, 228u8, + ], + ) + } + #[doc = " Which paras have past code that needs pruning and the relay-chain block at which the code was replaced."] + #[doc = " Note that this is the actual height of the included block, not the expected height at which the"] + #[doc = " code upgrade would be applied, although they may be equal."] + #[doc = " This is to ensure the entire acceptance period is covered, not an offset acceptance period starting"] + #[doc = " from the time at which the parachain perceives a code upgrade as having occurred."] + #[doc = " Multiple entries for a single para are permitted. Ordered ascending by block number."] + pub fn past_code_pruning( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<( + runtime_types::polkadot_parachain::primitives::Id, + ::core::primitive::u32, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "PastCodePruning", + vec![], + [ + 59u8, 26u8, 175u8, 129u8, 174u8, 27u8, 239u8, 77u8, 38u8, 130u8, 37u8, + 134u8, 62u8, 28u8, 218u8, 176u8, 16u8, 137u8, 175u8, 90u8, 248u8, 44u8, + 248u8, 172u8, 231u8, 6u8, 36u8, 190u8, 109u8, 237u8, 228u8, 135u8, + ], + ) + } + #[doc = " The block number at which the planned code change is expected for a para."] + #[doc = " The change will be applied after the first parablock for this ID included which executes"] + #[doc = " in the context of a relay chain block with a number >= `expected_at`."] + pub fn future_code_upgrades( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "FutureCodeUpgrades", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 40u8, 134u8, 185u8, 28u8, 48u8, 105u8, 152u8, 229u8, 166u8, 235u8, + 32u8, 173u8, 64u8, 63u8, 151u8, 157u8, 190u8, 214u8, 7u8, 8u8, 6u8, + 128u8, 21u8, 104u8, 175u8, 71u8, 130u8, 207u8, 158u8, 115u8, 172u8, + 149u8, + ], + ) + } + #[doc = " The block number at which the planned code change is expected for a para."] + #[doc = " The change will be applied after the first parablock for this ID included which executes"] + #[doc = " in the context of a relay chain block with a number >= `expected_at`."] + pub fn future_code_upgrades_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "FutureCodeUpgrades", + Vec::new(), + [ + 40u8, 134u8, 185u8, 28u8, 48u8, 105u8, 152u8, 229u8, 166u8, 235u8, + 32u8, 173u8, 64u8, 63u8, 151u8, 157u8, 190u8, 214u8, 7u8, 8u8, 6u8, + 128u8, 21u8, 104u8, 175u8, 71u8, 130u8, 207u8, 158u8, 115u8, 172u8, + 149u8, + ], + ) + } + #[doc = " The actual future code hash of a para."] + #[doc = ""] + #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] + pub fn future_code_hash( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "FutureCodeHash", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 252u8, 24u8, 95u8, 200u8, 207u8, 91u8, 66u8, 103u8, 54u8, 171u8, 191u8, + 187u8, 73u8, 170u8, 132u8, 59u8, 205u8, 125u8, 68u8, 194u8, 122u8, + 124u8, 190u8, 53u8, 241u8, 225u8, 131u8, 53u8, 44u8, 145u8, 244u8, + 216u8, + ], + ) + } + #[doc = " The actual future code hash of a para."] + #[doc = ""] + #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] + pub fn future_code_hash_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "FutureCodeHash", + Vec::new(), + [ + 252u8, 24u8, 95u8, 200u8, 207u8, 91u8, 66u8, 103u8, 54u8, 171u8, 191u8, + 187u8, 73u8, 170u8, 132u8, 59u8, 205u8, 125u8, 68u8, 194u8, 122u8, + 124u8, 190u8, 53u8, 241u8, 225u8, 131u8, 53u8, 44u8, 145u8, 244u8, + 216u8, + ], + ) + } + #[doc = " This is used by the relay-chain to communicate to a parachain a go-ahead with in the upgrade procedure."] + #[doc = ""] + #[doc = " This value is absent when there are no upgrades scheduled or during the time the relay chain"] + #[doc = " performs the checks. It is set at the first relay-chain block when the corresponding parachain"] + #[doc = " can switch its upgrade function. As soon as the parachain's block is included, the value"] + #[doc = " gets reset to `None`."] + #[doc = ""] + #[doc = " NOTE that this field is used by parachains via merkle storage proofs, therefore changing"] + #[doc = " the format will require migration of parachains."] + pub fn upgrade_go_ahead_signal( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_primitives::v4::UpgradeGoAhead, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "UpgradeGoAheadSignal", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 159u8, 47u8, 247u8, 154u8, 54u8, 20u8, 235u8, 49u8, 74u8, 41u8, 65u8, + 51u8, 52u8, 187u8, 242u8, 6u8, 84u8, 144u8, 200u8, 176u8, 222u8, 232u8, + 70u8, 50u8, 70u8, 97u8, 61u8, 249u8, 245u8, 120u8, 98u8, 183u8, + ], + ) + } + #[doc = " This is used by the relay-chain to communicate to a parachain a go-ahead with in the upgrade procedure."] + #[doc = ""] + #[doc = " This value is absent when there are no upgrades scheduled or during the time the relay chain"] + #[doc = " performs the checks. It is set at the first relay-chain block when the corresponding parachain"] + #[doc = " can switch its upgrade function. As soon as the parachain's block is included, the value"] + #[doc = " gets reset to `None`."] + #[doc = ""] + #[doc = " NOTE that this field is used by parachains via merkle storage proofs, therefore changing"] + #[doc = " the format will require migration of parachains."] + pub fn upgrade_go_ahead_signal_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_primitives::v4::UpgradeGoAhead, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "UpgradeGoAheadSignal", + Vec::new(), + [ + 159u8, 47u8, 247u8, 154u8, 54u8, 20u8, 235u8, 49u8, 74u8, 41u8, 65u8, + 51u8, 52u8, 187u8, 242u8, 6u8, 84u8, 144u8, 200u8, 176u8, 222u8, 232u8, + 70u8, 50u8, 70u8, 97u8, 61u8, 249u8, 245u8, 120u8, 98u8, 183u8, + ], + ) + } + #[doc = " This is used by the relay-chain to communicate that there are restrictions for performing"] + #[doc = " an upgrade for this parachain."] + #[doc = ""] + #[doc = " This may be a because the parachain waits for the upgrade cooldown to expire. Another"] + #[doc = " potential use case is when we want to perform some maintenance (such as storage migration)"] + #[doc = " we could restrict upgrades to make the process simpler."] + #[doc = ""] + #[doc = " NOTE that this field is used by parachains via merkle storage proofs, therefore changing"] + #[doc = " the format will require migration of parachains."] + pub fn upgrade_restriction_signal( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_primitives::v4::UpgradeRestriction, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "UpgradeRestrictionSignal", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 86u8, 190u8, 41u8, 79u8, 66u8, 68u8, 46u8, 87u8, 212u8, 176u8, 255u8, + 134u8, 104u8, 121u8, 44u8, 143u8, 248u8, 100u8, 35u8, 157u8, 91u8, + 165u8, 118u8, 38u8, 49u8, 171u8, 158u8, 163u8, 45u8, 92u8, 44u8, 11u8, + ], + ) + } + #[doc = " This is used by the relay-chain to communicate that there are restrictions for performing"] + #[doc = " an upgrade for this parachain."] + #[doc = ""] + #[doc = " This may be a because the parachain waits for the upgrade cooldown to expire. Another"] + #[doc = " potential use case is when we want to perform some maintenance (such as storage migration)"] + #[doc = " we could restrict upgrades to make the process simpler."] + #[doc = ""] + #[doc = " NOTE that this field is used by parachains via merkle storage proofs, therefore changing"] + #[doc = " the format will require migration of parachains."] + pub fn upgrade_restriction_signal_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_primitives::v4::UpgradeRestriction, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "UpgradeRestrictionSignal", + Vec::new(), + [ + 86u8, 190u8, 41u8, 79u8, 66u8, 68u8, 46u8, 87u8, 212u8, 176u8, 255u8, + 134u8, 104u8, 121u8, 44u8, 143u8, 248u8, 100u8, 35u8, 157u8, 91u8, + 165u8, 118u8, 38u8, 49u8, 171u8, 158u8, 163u8, 45u8, 92u8, 44u8, 11u8, + ], + ) + } + #[doc = " The list of parachains that are awaiting for their upgrade restriction to cooldown."] + #[doc = ""] + #[doc = " Ordered ascending by block number."] + pub fn upgrade_cooldowns( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<( + runtime_types::polkadot_parachain::primitives::Id, + ::core::primitive::u32, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "UpgradeCooldowns", + vec![], + [ + 205u8, 236u8, 140u8, 145u8, 241u8, 245u8, 60u8, 68u8, 23u8, 175u8, + 226u8, 174u8, 154u8, 107u8, 243u8, 197u8, 61u8, 218u8, 7u8, 24u8, + 109u8, 221u8, 178u8, 80u8, 242u8, 123u8, 33u8, 119u8, 5u8, 241u8, + 179u8, 13u8, + ], + ) + } + #[doc = " The list of upcoming code upgrades. Each item is a pair of which para performs a code"] + #[doc = " upgrade and at which relay-chain block it is expected at."] + #[doc = ""] + #[doc = " Ordered ascending by block number."] + pub fn upcoming_upgrades( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<( + runtime_types::polkadot_parachain::primitives::Id, + ::core::primitive::u32, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "UpcomingUpgrades", + vec![], + [ + 165u8, 112u8, 215u8, 149u8, 125u8, 175u8, 206u8, 195u8, 214u8, 173u8, + 0u8, 144u8, 46u8, 197u8, 55u8, 204u8, 144u8, 68u8, 158u8, 156u8, 145u8, + 230u8, 173u8, 101u8, 255u8, 108u8, 52u8, 199u8, 142u8, 37u8, 55u8, + 32u8, + ], + ) + } + #[doc = " The actions to perform during the start of a specific session index."] + pub fn actions_queue( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "ActionsQueue", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 209u8, 106u8, 198u8, 228u8, 148u8, 75u8, 246u8, 248u8, 12u8, 143u8, + 175u8, 56u8, 168u8, 243u8, 67u8, 166u8, 59u8, 92u8, 219u8, 184u8, 1u8, + 34u8, 241u8, 66u8, 245u8, 48u8, 174u8, 41u8, 123u8, 16u8, 178u8, 161u8, + ], + ) + } + #[doc = " The actions to perform during the start of a specific session index."] + pub fn actions_queue_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "ActionsQueue", + Vec::new(), + [ + 209u8, 106u8, 198u8, 228u8, 148u8, 75u8, 246u8, 248u8, 12u8, 143u8, + 175u8, 56u8, 168u8, 243u8, 67u8, 166u8, 59u8, 92u8, 219u8, 184u8, 1u8, + 34u8, 241u8, 66u8, 245u8, 48u8, 174u8, 41u8, 123u8, 16u8, 178u8, 161u8, + ], + ) + } + #[doc = " Upcoming paras instantiation arguments."] + #[doc = ""] + #[doc = " NOTE that after PVF pre-checking is enabled the para genesis arg will have it's code set"] + #[doc = " to empty. Instead, the code will be saved into the storage right away via `CodeByHash`."] + pub fn upcoming_paras_genesis( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::paras::ParaGenesisArgs, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "UpcomingParasGenesis", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 134u8, 111u8, 59u8, 49u8, 28u8, 111u8, 6u8, 57u8, 109u8, 75u8, 75u8, + 53u8, 91u8, 150u8, 86u8, 38u8, 223u8, 50u8, 107u8, 75u8, 200u8, 61u8, + 211u8, 7u8, 105u8, 251u8, 243u8, 18u8, 220u8, 195u8, 216u8, 167u8, + ], + ) + } + #[doc = " Upcoming paras instantiation arguments."] + #[doc = ""] + #[doc = " NOTE that after PVF pre-checking is enabled the para genesis arg will have it's code set"] + #[doc = " to empty. Instead, the code will be saved into the storage right away via `CodeByHash`."] + pub fn upcoming_paras_genesis_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::paras::ParaGenesisArgs, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "UpcomingParasGenesis", + Vec::new(), + [ + 134u8, 111u8, 59u8, 49u8, 28u8, 111u8, 6u8, 57u8, 109u8, 75u8, 75u8, + 53u8, 91u8, 150u8, 86u8, 38u8, 223u8, 50u8, 107u8, 75u8, 200u8, 61u8, + 211u8, 7u8, 105u8, 251u8, 243u8, 18u8, 220u8, 195u8, 216u8, 167u8, + ], + ) + } + #[doc = " The number of reference on the validation code in [`CodeByHash`] storage."] + pub fn code_by_hash_refs( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "CodeByHashRefs", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 24u8, 6u8, 23u8, 50u8, 105u8, 203u8, 126u8, 161u8, 0u8, 5u8, 121u8, + 165u8, 204u8, 106u8, 68u8, 91u8, 84u8, 126u8, 29u8, 239u8, 236u8, + 138u8, 32u8, 237u8, 241u8, 226u8, 190u8, 233u8, 160u8, 143u8, 88u8, + 168u8, + ], + ) + } + #[doc = " The number of reference on the validation code in [`CodeByHash`] storage."] + pub fn code_by_hash_refs_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "CodeByHashRefs", + Vec::new(), + [ + 24u8, 6u8, 23u8, 50u8, 105u8, 203u8, 126u8, 161u8, 0u8, 5u8, 121u8, + 165u8, 204u8, 106u8, 68u8, 91u8, 84u8, 126u8, 29u8, 239u8, 236u8, + 138u8, 32u8, 237u8, 241u8, 226u8, 190u8, 233u8, 160u8, 143u8, 88u8, + 168u8, + ], + ) + } + #[doc = " Validation code stored by its hash."] + #[doc = ""] + #[doc = " This storage is consistent with [`FutureCodeHash`], [`CurrentCodeHash`] and"] + #[doc = " [`PastCodeHash`]."] + pub fn code_by_hash( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::ValidationCode, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "CodeByHash", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 58u8, 104u8, 36u8, 34u8, 226u8, 210u8, 253u8, 90u8, 23u8, 3u8, 6u8, + 202u8, 9u8, 44u8, 107u8, 108u8, 41u8, 149u8, 255u8, 173u8, 119u8, + 206u8, 201u8, 180u8, 32u8, 193u8, 44u8, 232u8, 73u8, 15u8, 210u8, + 226u8, + ], + ) + } + #[doc = " Validation code stored by its hash."] + #[doc = ""] + #[doc = " This storage is consistent with [`FutureCodeHash`], [`CurrentCodeHash`] and"] + #[doc = " [`PastCodeHash`]."] + pub fn code_by_hash_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::ValidationCode, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Paras", + "CodeByHash", + Vec::new(), + [ + 58u8, 104u8, 36u8, 34u8, 226u8, 210u8, 253u8, 90u8, 23u8, 3u8, 6u8, + 202u8, 9u8, 44u8, 107u8, 108u8, 41u8, 149u8, 255u8, 173u8, 119u8, + 206u8, 201u8, 180u8, 32u8, 193u8, 44u8, 232u8, 73u8, 15u8, 210u8, + 226u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + pub fn unsigned_priority( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u64> { + ::subxt::constants::Address::new_static( + "Paras", + "UnsignedPriority", + [ + 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, + 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, + 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, + 246u8, + ], + ) + } + } + } + } + pub mod initializer { + use super::root_mod; + use super::runtime_types; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceApprove { + pub up_to: ::core::primitive::u32, + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Issue a signal to the consensus engine to forcibly act as though all parachain"] + #[doc = "blocks in all relay chain blocks up to and including the given number in the current"] + #[doc = "chain are valid and should be finalized."] + pub fn force_approve( + &self, + up_to: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Initializer", + "force_approve", + ForceApprove { up_to }, + [ + 28u8, 117u8, 86u8, 182u8, 19u8, 127u8, 43u8, 17u8, 153u8, 80u8, 193u8, + 53u8, 120u8, 41u8, 205u8, 23u8, 252u8, 148u8, 77u8, 227u8, 138u8, 35u8, + 182u8, 122u8, 112u8, 232u8, 246u8, 69u8, 173u8, 97u8, 42u8, 103u8, + ], + ) + } + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Whether the parachains modules have been initialized within this block."] + #[doc = ""] + #[doc = " Semantically a `bool`, but this guarantees it should never hit the trie,"] + #[doc = " as this is cleared in `on_finalize` and Frame optimizes `None` values to be empty values."] + #[doc = ""] + #[doc = " As a `bool`, `set(false)` and `remove()` both lead to the next `get()` being false, but one of"] + #[doc = " them writes to the trie and one does not. This confusion makes `Option<()>` more suitable for"] + #[doc = " the semantics of this variable."] + pub fn has_initialized( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + (), + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Initializer", + "HasInitialized", + vec![], + [ + 251u8, 135u8, 247u8, 61u8, 139u8, 102u8, 12u8, 122u8, 227u8, 123u8, + 11u8, 232u8, 120u8, 80u8, 81u8, 48u8, 216u8, 115u8, 159u8, 131u8, + 133u8, 105u8, 200u8, 122u8, 114u8, 6u8, 109u8, 4u8, 164u8, 204u8, + 214u8, 111u8, + ], + ) + } + #[doc = " Buffered session changes along with the block number at which they should be applied."] + #[doc = ""] + #[doc = " Typically this will be empty or one element long. Apart from that this item never hits"] + #[doc = " the storage."] + #[doc = ""] + #[doc = " However this is a `Vec` regardless to handle various edge cases that may occur at runtime"] + #[doc = " upgrade boundaries or if governance intervenes."] pub fn buffered_session_changes (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , :: std :: vec :: Vec < runtime_types :: polkadot_runtime_parachains :: initializer :: BufferedSessionChange > , :: subxt :: storage :: address :: Yes , :: subxt :: storage :: address :: Yes , () >{ + ::subxt::storage::address::Address::new_static( + "Initializer", + "BufferedSessionChanges", + vec![], + [ + 176u8, 60u8, 165u8, 138u8, 99u8, 140u8, 22u8, 169u8, 121u8, 65u8, + 203u8, 85u8, 39u8, 198u8, 91u8, 167u8, 118u8, 49u8, 129u8, 128u8, + 171u8, 232u8, 249u8, 39u8, 6u8, 101u8, 57u8, 193u8, 85u8, 143u8, 105u8, + 29u8, + ], + ) + } + } + } + } + pub mod dmp { + use super::root_mod; + use super::runtime_types; + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The downward messages addressed for a certain para."] + pub fn downward_message_queues( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec< + runtime_types::polkadot_core_primitives::InboundDownwardMessage< + ::core::primitive::u32, + >, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Dmp", + "DownwardMessageQueues", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 57u8, 115u8, 112u8, 195u8, 25u8, 43u8, 104u8, 199u8, 107u8, 238u8, + 93u8, 129u8, 141u8, 167u8, 167u8, 9u8, 85u8, 34u8, 53u8, 117u8, 148u8, + 246u8, 196u8, 46u8, 96u8, 114u8, 15u8, 88u8, 94u8, 40u8, 18u8, 31u8, + ], + ) + } + #[doc = " The downward messages addressed for a certain para."] + pub fn downward_message_queues_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec< + runtime_types::polkadot_core_primitives::InboundDownwardMessage< + ::core::primitive::u32, + >, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Dmp", + "DownwardMessageQueues", + Vec::new(), + [ + 57u8, 115u8, 112u8, 195u8, 25u8, 43u8, 104u8, 199u8, 107u8, 238u8, + 93u8, 129u8, 141u8, 167u8, 167u8, 9u8, 85u8, 34u8, 53u8, 117u8, 148u8, + 246u8, 196u8, 46u8, 96u8, 114u8, 15u8, 88u8, 94u8, 40u8, 18u8, 31u8, + ], + ) + } + #[doc = " A mapping that stores the downward message queue MQC head for each para."] + #[doc = ""] + #[doc = " Each link in this chain has a form:"] + #[doc = " `(prev_head, B, H(M))`, where"] + #[doc = " - `prev_head`: is the previous head hash or zero if none."] + #[doc = " - `B`: is the relay-chain block number in which a message was appended."] + #[doc = " - `H(M)`: is the hash of the message being appended."] + pub fn downward_message_queue_heads( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Dmp", + "DownwardMessageQueueHeads", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 137u8, 70u8, 108u8, 184u8, 177u8, 204u8, 17u8, 187u8, 250u8, 134u8, + 85u8, 18u8, 239u8, 185u8, 167u8, 224u8, 70u8, 18u8, 38u8, 245u8, 176u8, + 122u8, 254u8, 251u8, 204u8, 126u8, 34u8, 207u8, 163u8, 104u8, 103u8, + 38u8, + ], + ) + } + #[doc = " A mapping that stores the downward message queue MQC head for each para."] + #[doc = ""] + #[doc = " Each link in this chain has a form:"] + #[doc = " `(prev_head, B, H(M))`, where"] + #[doc = " - `prev_head`: is the previous head hash or zero if none."] + #[doc = " - `B`: is the relay-chain block number in which a message was appended."] + #[doc = " - `H(M)`: is the hash of the message being appended."] + pub fn downward_message_queue_heads_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Dmp", + "DownwardMessageQueueHeads", + Vec::new(), + [ + 137u8, 70u8, 108u8, 184u8, 177u8, 204u8, 17u8, 187u8, 250u8, 134u8, + 85u8, 18u8, 239u8, 185u8, 167u8, 224u8, 70u8, 18u8, 38u8, 245u8, 176u8, + 122u8, 254u8, 251u8, 204u8, 126u8, 34u8, 207u8, 163u8, 104u8, 103u8, + 38u8, + ], + ) + } + #[doc = " The number to multiply the base delivery fee by."] + pub fn delivery_fee_factor( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_arithmetic::fixed_point::FixedU128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Dmp", + "DeliveryFeeFactor", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 74u8, 221u8, 160u8, 244u8, 128u8, 163u8, 79u8, 26u8, 35u8, 182u8, + 211u8, 224u8, 181u8, 42u8, 98u8, 193u8, 128u8, 249u8, 40u8, 122u8, + 208u8, 19u8, 64u8, 8u8, 156u8, 165u8, 156u8, 59u8, 112u8, 197u8, 160u8, + 87u8, + ], + ) + } + #[doc = " The number to multiply the base delivery fee by."] + pub fn delivery_fee_factor_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_arithmetic::fixed_point::FixedU128, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Dmp", + "DeliveryFeeFactor", + Vec::new(), + [ + 74u8, 221u8, 160u8, 244u8, 128u8, 163u8, 79u8, 26u8, 35u8, 182u8, + 211u8, 224u8, 181u8, 42u8, 98u8, 193u8, 128u8, 249u8, 40u8, 122u8, + 208u8, 19u8, 64u8, 8u8, 156u8, 165u8, 156u8, 59u8, 112u8, 197u8, 160u8, + 87u8, + ], + ) + } + } + } + } + pub mod ump { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::polkadot_runtime_parachains::ump::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ServiceOverweight { + pub index: ::core::primitive::u64, + pub weight_limit: runtime_types::sp_weights::weight_v2::Weight, + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Service a single overweight upward message."] + #[doc = ""] + #[doc = "- `origin`: Must pass `ExecuteOverweightOrigin`."] + #[doc = "- `index`: The index of the overweight message to service."] + #[doc = "- `weight_limit`: The amount of weight that message execution may take."] + #[doc = ""] + #[doc = "Errors:"] + #[doc = "- `UnknownMessageIndex`: Message of `index` is unknown."] + #[doc = "- `WeightOverLimit`: Message execution may use greater than `weight_limit`."] + #[doc = ""] + #[doc = "Events:"] + #[doc = "- `OverweightServiced`: On success."] + pub fn service_overweight( + &self, + index: ::core::primitive::u64, + weight_limit: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Ump", + "service_overweight", + ServiceOverweight { + index, + weight_limit, + }, + [ + 121u8, 236u8, 235u8, 23u8, 210u8, 238u8, 238u8, 122u8, 15u8, 86u8, + 34u8, 119u8, 105u8, 100u8, 214u8, 236u8, 117u8, 39u8, 254u8, 235u8, + 189u8, 15u8, 72u8, 74u8, 225u8, 134u8, 148u8, 126u8, 31u8, 203u8, + 144u8, 106u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::polkadot_runtime_parachains::ump::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Upward message is invalid XCM."] + #[doc = "\\[ id \\]"] + pub struct InvalidFormat(pub [::core::primitive::u8; 32usize]); + impl ::subxt::events::StaticEvent for InvalidFormat { + const PALLET: &'static str = "Ump"; + const EVENT: &'static str = "InvalidFormat"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Upward message is unsupported version of XCM."] + #[doc = "\\[ id \\]"] + pub struct UnsupportedVersion(pub [::core::primitive::u8; 32usize]); + impl ::subxt::events::StaticEvent for UnsupportedVersion { + const PALLET: &'static str = "Ump"; + const EVENT: &'static str = "UnsupportedVersion"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Upward message executed with the given outcome."] + #[doc = "\\[ id, outcome \\]"] + pub struct ExecutedUpward( + pub [::core::primitive::u8; 32usize], + pub runtime_types::xcm::v3::traits::Outcome, + ); + impl ::subxt::events::StaticEvent for ExecutedUpward { + const PALLET: &'static str = "Ump"; + const EVENT: &'static str = "ExecutedUpward"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The weight limit for handling upward messages was reached."] + #[doc = "\\[ id, remaining, required \\]"] + pub struct WeightExhausted( + pub [::core::primitive::u8; 32usize], + pub runtime_types::sp_weights::weight_v2::Weight, + pub runtime_types::sp_weights::weight_v2::Weight, + ); + impl ::subxt::events::StaticEvent for WeightExhausted { + const PALLET: &'static str = "Ump"; + const EVENT: &'static str = "WeightExhausted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some upward messages have been received and will be processed."] + #[doc = "\\[ para, count, size \\]"] + pub struct UpwardMessagesReceived( + pub runtime_types::polkadot_parachain::primitives::Id, + pub ::core::primitive::u32, + pub ::core::primitive::u32, + ); + impl ::subxt::events::StaticEvent for UpwardMessagesReceived { + const PALLET: &'static str = "Ump"; + const EVENT: &'static str = "UpwardMessagesReceived"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The weight budget was exceeded for an individual upward message."] + #[doc = ""] + #[doc = "This message can be later dispatched manually using `service_overweight` dispatchable"] + #[doc = "using the assigned `overweight_index`."] + #[doc = ""] + #[doc = "\\[ para, id, overweight_index, required \\]"] + pub struct OverweightEnqueued( + pub runtime_types::polkadot_parachain::primitives::Id, + pub [::core::primitive::u8; 32usize], + pub ::core::primitive::u64, + pub runtime_types::sp_weights::weight_v2::Weight, + ); + impl ::subxt::events::StaticEvent for OverweightEnqueued { + const PALLET: &'static str = "Ump"; + const EVENT: &'static str = "OverweightEnqueued"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Upward message from the overweight queue was executed with the given actual weight"] + #[doc = "used."] + #[doc = ""] + #[doc = "\\[ overweight_index, used \\]"] + pub struct OverweightServiced( + pub ::core::primitive::u64, + pub runtime_types::sp_weights::weight_v2::Weight, + ); + impl ::subxt::events::StaticEvent for OverweightServiced { + const PALLET: &'static str = "Ump"; + const EVENT: &'static str = "OverweightServiced"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The messages waiting to be handled by the relay-chain originating from a certain parachain."] + #[doc = ""] + #[doc = " Note that some upward messages might have been already processed by the inclusion logic. E.g."] + #[doc = " channel management messages."] + #[doc = ""] + #[doc = " The messages are processed in FIFO order."] + pub fn relay_dispatch_queues( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Ump", + "RelayDispatchQueues", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 237u8, 72u8, 167u8, 6u8, 67u8, 106u8, 186u8, 191u8, 160u8, 9u8, 62u8, + 102u8, 229u8, 164u8, 100u8, 24u8, 202u8, 109u8, 90u8, 24u8, 192u8, + 233u8, 26u8, 239u8, 23u8, 127u8, 77u8, 191u8, 144u8, 14u8, 3u8, 141u8, + ], + ) + } + #[doc = " The messages waiting to be handled by the relay-chain originating from a certain parachain."] + #[doc = ""] + #[doc = " Note that some upward messages might have been already processed by the inclusion logic. E.g."] + #[doc = " channel management messages."] + #[doc = ""] + #[doc = " The messages are processed in FIFO order."] + pub fn relay_dispatch_queues_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Ump", + "RelayDispatchQueues", + Vec::new(), + [ + 237u8, 72u8, 167u8, 6u8, 67u8, 106u8, 186u8, 191u8, 160u8, 9u8, 62u8, + 102u8, 229u8, 164u8, 100u8, 24u8, 202u8, 109u8, 90u8, 24u8, 192u8, + 233u8, 26u8, 239u8, 23u8, 127u8, 77u8, 191u8, 144u8, 14u8, 3u8, 141u8, + ], + ) + } + #[doc = " Size of the dispatch queues. Caches sizes of the queues in `RelayDispatchQueue`."] + #[doc = ""] + #[doc = " First item in the tuple is the count of messages and second"] + #[doc = " is the total length (in bytes) of the message payloads."] + #[doc = ""] + #[doc = " Note that this is an auxiliary mapping: it's possible to tell the byte size and the number of"] + #[doc = " messages only looking at `RelayDispatchQueues`. This mapping is separate to avoid the cost of"] + #[doc = " loading the whole message queue if only the total size and count are required."] + #[doc = ""] + #[doc = " Invariant:"] + #[doc = " - The set of keys should exactly match the set of keys of `RelayDispatchQueues`."] + pub fn relay_dispatch_queue_size( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + (::core::primitive::u32, ::core::primitive::u32), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Ump", + "RelayDispatchQueueSize", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 243u8, 120u8, 70u8, 2u8, 208u8, 105u8, 180u8, 25u8, 86u8, 219u8, 151u8, + 227u8, 233u8, 53u8, 151u8, 29u8, 231u8, 40u8, 84u8, 163u8, 71u8, 254u8, + 19u8, 47u8, 174u8, 63u8, 200u8, 173u8, 86u8, 199u8, 207u8, 138u8, + ], + ) + } + #[doc = " Size of the dispatch queues. Caches sizes of the queues in `RelayDispatchQueue`."] + #[doc = ""] + #[doc = " First item in the tuple is the count of messages and second"] + #[doc = " is the total length (in bytes) of the message payloads."] + #[doc = ""] + #[doc = " Note that this is an auxiliary mapping: it's possible to tell the byte size and the number of"] + #[doc = " messages only looking at `RelayDispatchQueues`. This mapping is separate to avoid the cost of"] + #[doc = " loading the whole message queue if only the total size and count are required."] + #[doc = ""] + #[doc = " Invariant:"] + #[doc = " - The set of keys should exactly match the set of keys of `RelayDispatchQueues`."] + pub fn relay_dispatch_queue_size_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + (::core::primitive::u32, ::core::primitive::u32), + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Ump", + "RelayDispatchQueueSize", + Vec::new(), + [ + 243u8, 120u8, 70u8, 2u8, 208u8, 105u8, 180u8, 25u8, 86u8, 219u8, 151u8, + 227u8, 233u8, 53u8, 151u8, 29u8, 231u8, 40u8, 84u8, 163u8, 71u8, 254u8, + 19u8, 47u8, 174u8, 63u8, 200u8, 173u8, 86u8, 199u8, 207u8, 138u8, + ], + ) + } + #[doc = " The ordered list of `ParaId`s that have a `RelayDispatchQueue` entry."] + #[doc = ""] + #[doc = " Invariant:"] + #[doc = " - The set of items from this vector should be exactly the set of the keys in"] + #[doc = " `RelayDispatchQueues` and `RelayDispatchQueueSize`."] + pub fn needs_dispatch( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Ump", + "NeedsDispatch", + vec![], + [ + 176u8, 94u8, 152u8, 112u8, 46u8, 124u8, 89u8, 29u8, 92u8, 104u8, 192u8, + 58u8, 59u8, 186u8, 81u8, 150u8, 157u8, 61u8, 235u8, 182u8, 222u8, + 127u8, 109u8, 11u8, 104u8, 175u8, 141u8, 219u8, 15u8, 152u8, 255u8, + 40u8, + ], + ) + } + #[doc = " This is the para that gets will get dispatched first during the next upward dispatchable queue"] + #[doc = " execution round."] + #[doc = ""] + #[doc = " Invariant:"] + #[doc = " - If `Some(para)`, then `para` must be present in `NeedsDispatch`."] + pub fn next_dispatch_round_start_with( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::Id, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Ump", + "NextDispatchRoundStartWith", + vec![], + [ + 157u8, 221u8, 6u8, 175u8, 61u8, 99u8, 250u8, 30u8, 177u8, 53u8, 37u8, + 191u8, 138u8, 65u8, 251u8, 216u8, 37u8, 84u8, 246u8, 76u8, 8u8, 29u8, + 18u8, 253u8, 143u8, 75u8, 129u8, 141u8, 48u8, 178u8, 135u8, 197u8, + ], + ) + } + #[doc = " The messages that exceeded max individual message weight budget."] + #[doc = ""] + #[doc = " These messages stay there until manually dispatched."] + pub fn overweight( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u64>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ( + runtime_types::polkadot_parachain::primitives::Id, + ::std::vec::Vec<::core::primitive::u8>, + ), + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Ump", + "Overweight", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 49u8, 4u8, 221u8, 218u8, 249u8, 183u8, 49u8, 198u8, 48u8, 42u8, 110u8, + 67u8, 47u8, 50u8, 181u8, 141u8, 184u8, 47u8, 114u8, 3u8, 232u8, 132u8, + 32u8, 201u8, 13u8, 213u8, 175u8, 236u8, 111u8, 87u8, 146u8, 212u8, + ], + ) + } + #[doc = " The messages that exceeded max individual message weight budget."] + #[doc = ""] + #[doc = " These messages stay there until manually dispatched."] + pub fn overweight_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ( + runtime_types::polkadot_parachain::primitives::Id, + ::std::vec::Vec<::core::primitive::u8>, + ), + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Ump", + "Overweight", + Vec::new(), + [ + 49u8, 4u8, 221u8, 218u8, 249u8, 183u8, 49u8, 198u8, 48u8, 42u8, 110u8, + 67u8, 47u8, 50u8, 181u8, 141u8, 184u8, 47u8, 114u8, 3u8, 232u8, 132u8, + 32u8, 201u8, 13u8, 213u8, 175u8, 236u8, 111u8, 87u8, 146u8, 212u8, + ], + ) + } + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_overweight( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Ump", + "CounterForOverweight", + vec![], + [ + 148u8, 226u8, 248u8, 107u8, 165u8, 97u8, 218u8, 160u8, 127u8, 48u8, + 185u8, 251u8, 35u8, 137u8, 119u8, 251u8, 151u8, 167u8, 189u8, 66u8, + 80u8, 74u8, 134u8, 129u8, 222u8, 180u8, 51u8, 182u8, 50u8, 110u8, 10u8, + 43u8, + ], + ) + } + #[doc = " The number of overweight messages ever recorded in `Overweight` (and thus the lowest free"] + #[doc = " index)."] + pub fn overweight_count( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u64, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Ump", + "OverweightCount", + vec![], + [ + 102u8, 180u8, 196u8, 148u8, 115u8, 62u8, 46u8, 238u8, 97u8, 116u8, + 117u8, 42u8, 14u8, 5u8, 72u8, 237u8, 230u8, 46u8, 150u8, 126u8, 89u8, + 64u8, 233u8, 166u8, 180u8, 137u8, 52u8, 233u8, 252u8, 255u8, 36u8, + 20u8, + ], + ) + } + } + } + } + pub mod hrmp { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::polkadot_runtime_parachains::hrmp::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct HrmpInitOpenChannel { + pub recipient: runtime_types::polkadot_parachain::primitives::Id, + pub proposed_max_capacity: ::core::primitive::u32, + pub proposed_max_message_size: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct HrmpAcceptOpenChannel { + pub sender: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct HrmpCloseChannel { + pub channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceCleanHrmp { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub inbound: ::core::primitive::u32, + pub outbound: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceProcessHrmpOpen { + pub channels: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceProcessHrmpClose { + pub channels: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct HrmpCancelOpenRequest { + pub channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, + pub open_requests: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceOpenHrmpChannel { + pub sender: runtime_types::polkadot_parachain::primitives::Id, + pub recipient: runtime_types::polkadot_parachain::primitives::Id, + pub max_capacity: ::core::primitive::u32, + pub max_message_size: ::core::primitive::u32, + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Initiate opening a channel from a parachain to a given recipient with given channel"] + #[doc = "parameters."] + #[doc = ""] + #[doc = "- `proposed_max_capacity` - specifies how many messages can be in the channel at once."] + #[doc = "- `proposed_max_message_size` - specifies the maximum size of the messages."] + #[doc = ""] + #[doc = "These numbers are a subject to the relay-chain configuration limits."] + #[doc = ""] + #[doc = "The channel can be opened only after the recipient confirms it and only on a session"] + #[doc = "change."] + pub fn hrmp_init_open_channel( + &self, + recipient: runtime_types::polkadot_parachain::primitives::Id, + proposed_max_capacity: ::core::primitive::u32, + proposed_max_message_size: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Hrmp", + "hrmp_init_open_channel", + HrmpInitOpenChannel { + recipient, + proposed_max_capacity, + proposed_max_message_size, + }, + [ + 170u8, 72u8, 58u8, 42u8, 38u8, 11u8, 110u8, 229u8, 239u8, 136u8, 99u8, + 230u8, 223u8, 225u8, 126u8, 61u8, 234u8, 185u8, 101u8, 156u8, 40u8, + 102u8, 253u8, 123u8, 77u8, 204u8, 217u8, 86u8, 162u8, 66u8, 25u8, + 214u8, + ], + ) + } + #[doc = "Accept a pending open channel request from the given sender."] + #[doc = ""] + #[doc = "The channel will be opened only on the next session boundary."] + pub fn hrmp_accept_open_channel( + &self, + sender: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Hrmp", + "hrmp_accept_open_channel", + HrmpAcceptOpenChannel { sender }, + [ + 75u8, 111u8, 52u8, 164u8, 204u8, 100u8, 204u8, 111u8, 127u8, 84u8, + 60u8, 136u8, 95u8, 255u8, 48u8, 157u8, 189u8, 76u8, 33u8, 177u8, 223u8, + 27u8, 74u8, 221u8, 139u8, 1u8, 12u8, 128u8, 242u8, 7u8, 3u8, 53u8, + ], + ) + } + #[doc = "Initiate unilateral closing of a channel. The origin must be either the sender or the"] + #[doc = "recipient in the channel being closed."] + #[doc = ""] + #[doc = "The closure can only happen on a session change."] + pub fn hrmp_close_channel( + &self, + channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Hrmp", + "hrmp_close_channel", + HrmpCloseChannel { channel_id }, + [ + 11u8, 202u8, 76u8, 107u8, 213u8, 21u8, 191u8, 190u8, 40u8, 229u8, 60u8, + 115u8, 232u8, 136u8, 41u8, 114u8, 21u8, 19u8, 238u8, 236u8, 202u8, + 56u8, 212u8, 232u8, 34u8, 84u8, 27u8, 70u8, 176u8, 252u8, 218u8, 52u8, + ], + ) + } + #[doc = "This extrinsic triggers the cleanup of all the HRMP storage items that"] + #[doc = "a para may have. Normally this happens once per session, but this allows"] + #[doc = "you to trigger the cleanup immediately for a specific parachain."] + #[doc = ""] + #[doc = "Origin must be Root."] + #[doc = ""] + #[doc = "Number of inbound and outbound channels for `para` must be provided as witness data of weighing."] + pub fn force_clean_hrmp( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + inbound: ::core::primitive::u32, + outbound: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Hrmp", + "force_clean_hrmp", + ForceCleanHrmp { + para, + inbound, + outbound, + }, + [ + 171u8, 109u8, 147u8, 49u8, 163u8, 107u8, 36u8, 169u8, 117u8, 193u8, + 231u8, 114u8, 207u8, 38u8, 240u8, 195u8, 155u8, 222u8, 244u8, 142u8, + 93u8, 79u8, 111u8, 43u8, 5u8, 33u8, 190u8, 30u8, 200u8, 225u8, 173u8, + 64u8, + ], + ) + } + #[doc = "Force process HRMP open channel requests."] + #[doc = ""] + #[doc = "If there are pending HRMP open channel requests, you can use this"] + #[doc = "function process all of those requests immediately."] + #[doc = ""] + #[doc = "Total number of opening channels must be provided as witness data of weighing."] + pub fn force_process_hrmp_open( + &self, + channels: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Hrmp", + "force_process_hrmp_open", + ForceProcessHrmpOpen { channels }, + [ + 231u8, 80u8, 233u8, 15u8, 131u8, 167u8, 223u8, 28u8, 182u8, 185u8, + 213u8, 24u8, 154u8, 160u8, 68u8, 94u8, 160u8, 59u8, 78u8, 85u8, 85u8, + 149u8, 130u8, 131u8, 9u8, 162u8, 169u8, 119u8, 165u8, 44u8, 150u8, + 50u8, + ], + ) + } + #[doc = "Force process HRMP close channel requests."] + #[doc = ""] + #[doc = "If there are pending HRMP close channel requests, you can use this"] + #[doc = "function process all of those requests immediately."] + #[doc = ""] + #[doc = "Total number of closing channels must be provided as witness data of weighing."] + pub fn force_process_hrmp_close( + &self, + channels: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Hrmp", + "force_process_hrmp_close", + ForceProcessHrmpClose { channels }, + [ + 248u8, 138u8, 30u8, 151u8, 53u8, 16u8, 44u8, 116u8, 51u8, 194u8, 173u8, + 252u8, 143u8, 53u8, 184u8, 129u8, 80u8, 80u8, 25u8, 118u8, 47u8, 183u8, + 249u8, 130u8, 8u8, 221u8, 56u8, 106u8, 182u8, 114u8, 186u8, 161u8, + ], + ) + } + #[doc = "This cancels a pending open channel request. It can be canceled by either of the sender"] + #[doc = "or the recipient for that request. The origin must be either of those."] + #[doc = ""] + #[doc = "The cancellation happens immediately. It is not possible to cancel the request if it is"] + #[doc = "already accepted."] + #[doc = ""] + #[doc = "Total number of open requests (i.e. `HrmpOpenChannelRequestsList`) must be provided as"] + #[doc = "witness data."] + pub fn hrmp_cancel_open_request( + &self, + channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, + open_requests: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Hrmp", + "hrmp_cancel_open_request", + HrmpCancelOpenRequest { + channel_id, + open_requests, + }, + [ + 136u8, 217u8, 56u8, 138u8, 227u8, 37u8, 120u8, 83u8, 116u8, 228u8, + 42u8, 111u8, 206u8, 210u8, 177u8, 235u8, 225u8, 98u8, 172u8, 184u8, + 87u8, 65u8, 77u8, 129u8, 7u8, 0u8, 232u8, 139u8, 134u8, 1u8, 59u8, + 19u8, + ], + ) + } + #[doc = "Open a channel from a `sender` to a `recipient` `ParaId` using the Root origin. Although"] + #[doc = "opened by Root, the `max_capacity` and `max_message_size` are still subject to the Relay"] + #[doc = "Chain's configured limits."] + #[doc = ""] + #[doc = "Expected use is when one of the `ParaId`s involved in the channel is governed by the"] + #[doc = "Relay Chain, e.g. a common good parachain."] + pub fn force_open_hrmp_channel( + &self, + sender: runtime_types::polkadot_parachain::primitives::Id, + recipient: runtime_types::polkadot_parachain::primitives::Id, + max_capacity: ::core::primitive::u32, + max_message_size: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Hrmp", + "force_open_hrmp_channel", + ForceOpenHrmpChannel { + sender, + recipient, + max_capacity, + max_message_size, + }, + [ + 145u8, 23u8, 215u8, 75u8, 94u8, 119u8, 205u8, 222u8, 186u8, 149u8, + 11u8, 172u8, 211u8, 158u8, 247u8, 21u8, 125u8, 144u8, 91u8, 157u8, + 94u8, 143u8, 188u8, 20u8, 98u8, 136u8, 165u8, 70u8, 155u8, 14u8, 92u8, + 58u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::polkadot_runtime_parachains::hrmp::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Open HRMP channel requested."] + #[doc = "`[sender, recipient, proposed_max_capacity, proposed_max_message_size]`"] + pub struct OpenChannelRequested( + pub runtime_types::polkadot_parachain::primitives::Id, + pub runtime_types::polkadot_parachain::primitives::Id, + pub ::core::primitive::u32, + pub ::core::primitive::u32, + ); + impl ::subxt::events::StaticEvent for OpenChannelRequested { + const PALLET: &'static str = "Hrmp"; + const EVENT: &'static str = "OpenChannelRequested"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An HRMP channel request sent by the receiver was canceled by either party."] + #[doc = "`[by_parachain, channel_id]`"] + pub struct OpenChannelCanceled( + pub runtime_types::polkadot_parachain::primitives::Id, + pub runtime_types::polkadot_parachain::primitives::HrmpChannelId, + ); + impl ::subxt::events::StaticEvent for OpenChannelCanceled { + const PALLET: &'static str = "Hrmp"; + const EVENT: &'static str = "OpenChannelCanceled"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Open HRMP channel accepted. `[sender, recipient]`"] + pub struct OpenChannelAccepted( + pub runtime_types::polkadot_parachain::primitives::Id, + pub runtime_types::polkadot_parachain::primitives::Id, + ); + impl ::subxt::events::StaticEvent for OpenChannelAccepted { + const PALLET: &'static str = "Hrmp"; + const EVENT: &'static str = "OpenChannelAccepted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "HRMP channel closed. `[by_parachain, channel_id]`"] + pub struct ChannelClosed( + pub runtime_types::polkadot_parachain::primitives::Id, + pub runtime_types::polkadot_parachain::primitives::HrmpChannelId, + ); + impl ::subxt::events::StaticEvent for ChannelClosed { + const PALLET: &'static str = "Hrmp"; + const EVENT: &'static str = "ChannelClosed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An HRMP channel was opened via Root origin."] + #[doc = "`[sender, recipient, proposed_max_capacity, proposed_max_message_size]`"] + pub struct HrmpChannelForceOpened( + pub runtime_types::polkadot_parachain::primitives::Id, + pub runtime_types::polkadot_parachain::primitives::Id, + pub ::core::primitive::u32, + pub ::core::primitive::u32, + ); + impl ::subxt::events::StaticEvent for HrmpChannelForceOpened { + const PALLET: &'static str = "Hrmp"; + const EVENT: &'static str = "HrmpChannelForceOpened"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The set of pending HRMP open channel requests."] + #[doc = ""] + #[doc = " The set is accompanied by a list for iteration."] + #[doc = ""] + #[doc = " Invariant:"] + #[doc = " - There are no channels that exists in list but not in the set and vice versa."] + pub fn hrmp_open_channel_requests( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_parachain::primitives::HrmpChannelId, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::hrmp::HrmpOpenChannelRequest, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpOpenChannelRequests", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 226u8, 115u8, 207u8, 13u8, 5u8, 81u8, 64u8, 161u8, 246u8, 4u8, 17u8, + 207u8, 210u8, 109u8, 91u8, 54u8, 28u8, 53u8, 35u8, 74u8, 62u8, 91u8, + 196u8, 236u8, 18u8, 70u8, 13u8, 86u8, 235u8, 74u8, 181u8, 169u8, + ], + ) + } + #[doc = " The set of pending HRMP open channel requests."] + #[doc = ""] + #[doc = " The set is accompanied by a list for iteration."] + #[doc = ""] + #[doc = " Invariant:"] + #[doc = " - There are no channels that exists in list but not in the set and vice versa."] + pub fn hrmp_open_channel_requests_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::hrmp::HrmpOpenChannelRequest, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpOpenChannelRequests", + Vec::new(), + [ + 226u8, 115u8, 207u8, 13u8, 5u8, 81u8, 64u8, 161u8, 246u8, 4u8, 17u8, + 207u8, 210u8, 109u8, 91u8, 54u8, 28u8, 53u8, 35u8, 74u8, 62u8, 91u8, + 196u8, 236u8, 18u8, 70u8, 13u8, 86u8, 235u8, 74u8, 181u8, 169u8, + ], + ) + } + pub fn hrmp_open_channel_requests_list( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpOpenChannelRequestsList", + vec![], + [ + 187u8, 157u8, 7u8, 183u8, 88u8, 215u8, 128u8, 174u8, 244u8, 130u8, + 137u8, 13u8, 110u8, 126u8, 181u8, 165u8, 142u8, 69u8, 75u8, 37u8, 37u8, + 149u8, 46u8, 100u8, 140u8, 69u8, 234u8, 171u8, 103u8, 136u8, 223u8, + 193u8, + ], + ) + } + #[doc = " This mapping tracks how many open channel requests are initiated by a given sender para."] + #[doc = " Invariant: `HrmpOpenChannelRequests` should contain the same number of items that has"] + #[doc = " `(X, _)` as the number of `HrmpOpenChannelRequestCount` for `X`."] + pub fn hrmp_open_channel_request_count( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpOpenChannelRequestCount", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 156u8, 87u8, 232u8, 34u8, 30u8, 237u8, 159u8, 78u8, 212u8, 138u8, + 140u8, 206u8, 191u8, 117u8, 209u8, 218u8, 251u8, 146u8, 217u8, 56u8, + 93u8, 15u8, 131u8, 64u8, 126u8, 253u8, 126u8, 1u8, 12u8, 242u8, 176u8, + 217u8, + ], + ) + } + #[doc = " This mapping tracks how many open channel requests are initiated by a given sender para."] + #[doc = " Invariant: `HrmpOpenChannelRequests` should contain the same number of items that has"] + #[doc = " `(X, _)` as the number of `HrmpOpenChannelRequestCount` for `X`."] + pub fn hrmp_open_channel_request_count_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpOpenChannelRequestCount", + Vec::new(), + [ + 156u8, 87u8, 232u8, 34u8, 30u8, 237u8, 159u8, 78u8, 212u8, 138u8, + 140u8, 206u8, 191u8, 117u8, 209u8, 218u8, 251u8, 146u8, 217u8, 56u8, + 93u8, 15u8, 131u8, 64u8, 126u8, 253u8, 126u8, 1u8, 12u8, 242u8, 176u8, + 217u8, + ], + ) + } + #[doc = " This mapping tracks how many open channel requests were accepted by a given recipient para."] + #[doc = " Invariant: `HrmpOpenChannelRequests` should contain the same number of items `(_, X)` with"] + #[doc = " `confirmed` set to true, as the number of `HrmpAcceptedChannelRequestCount` for `X`."] + pub fn hrmp_accepted_channel_request_count( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpAcceptedChannelRequestCount", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 93u8, 183u8, 17u8, 253u8, 119u8, 213u8, 106u8, 205u8, 17u8, 10u8, + 230u8, 242u8, 5u8, 223u8, 49u8, 235u8, 41u8, 221u8, 80u8, 51u8, 153u8, + 62u8, 191u8, 3u8, 120u8, 224u8, 46u8, 164u8, 161u8, 6u8, 15u8, 15u8, + ], + ) + } + #[doc = " This mapping tracks how many open channel requests were accepted by a given recipient para."] + #[doc = " Invariant: `HrmpOpenChannelRequests` should contain the same number of items `(_, X)` with"] + #[doc = " `confirmed` set to true, as the number of `HrmpAcceptedChannelRequestCount` for `X`."] + pub fn hrmp_accepted_channel_request_count_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpAcceptedChannelRequestCount", + Vec::new(), + [ + 93u8, 183u8, 17u8, 253u8, 119u8, 213u8, 106u8, 205u8, 17u8, 10u8, + 230u8, 242u8, 5u8, 223u8, 49u8, 235u8, 41u8, 221u8, 80u8, 51u8, 153u8, + 62u8, 191u8, 3u8, 120u8, 224u8, 46u8, 164u8, 161u8, 6u8, 15u8, 15u8, + ], + ) + } + #[doc = " A set of pending HRMP close channel requests that are going to be closed during the session"] + #[doc = " change. Used for checking if a given channel is registered for closure."] + #[doc = ""] + #[doc = " The set is accompanied by a list for iteration."] + #[doc = ""] + #[doc = " Invariant:"] + #[doc = " - There are no channels that exists in list but not in the set and vice versa."] + pub fn hrmp_close_channel_requests( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_parachain::primitives::HrmpChannelId, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + (), + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpCloseChannelRequests", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 125u8, 131u8, 1u8, 231u8, 19u8, 207u8, 229u8, 72u8, 150u8, 100u8, + 165u8, 215u8, 241u8, 165u8, 91u8, 35u8, 230u8, 148u8, 127u8, 249u8, + 128u8, 221u8, 167u8, 172u8, 67u8, 30u8, 177u8, 176u8, 134u8, 223u8, + 39u8, 87u8, + ], + ) + } + #[doc = " A set of pending HRMP close channel requests that are going to be closed during the session"] + #[doc = " change. Used for checking if a given channel is registered for closure."] + #[doc = ""] + #[doc = " The set is accompanied by a list for iteration."] + #[doc = ""] + #[doc = " Invariant:"] + #[doc = " - There are no channels that exists in list but not in the set and vice versa."] + pub fn hrmp_close_channel_requests_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + (), + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpCloseChannelRequests", + Vec::new(), + [ + 125u8, 131u8, 1u8, 231u8, 19u8, 207u8, 229u8, 72u8, 150u8, 100u8, + 165u8, 215u8, 241u8, 165u8, 91u8, 35u8, 230u8, 148u8, 127u8, 249u8, + 128u8, 221u8, 167u8, 172u8, 67u8, 30u8, 177u8, 176u8, 134u8, 223u8, + 39u8, 87u8, + ], + ) + } + pub fn hrmp_close_channel_requests_list( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpCloseChannelRequestsList", + vec![], + [ + 192u8, 165u8, 71u8, 70u8, 211u8, 233u8, 155u8, 146u8, 160u8, 58u8, + 103u8, 64u8, 123u8, 232u8, 157u8, 71u8, 199u8, 223u8, 158u8, 5u8, + 164u8, 93u8, 231u8, 153u8, 1u8, 63u8, 155u8, 4u8, 138u8, 89u8, 178u8, + 116u8, + ], + ) + } + #[doc = " The HRMP watermark associated with each para."] + #[doc = " Invariant:"] + #[doc = " - each para `P` used here as a key should satisfy `Paras::is_valid_para(P)` within a session."] + pub fn hrmp_watermarks( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpWatermarks", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 231u8, 195u8, 117u8, 35u8, 235u8, 18u8, 80u8, 28u8, 212u8, 37u8, 253u8, + 204u8, 71u8, 217u8, 12u8, 35u8, 219u8, 250u8, 45u8, 83u8, 102u8, 236u8, + 186u8, 149u8, 54u8, 31u8, 83u8, 19u8, 129u8, 51u8, 103u8, 155u8, + ], + ) + } + #[doc = " The HRMP watermark associated with each para."] + #[doc = " Invariant:"] + #[doc = " - each para `P` used here as a key should satisfy `Paras::is_valid_para(P)` within a session."] + pub fn hrmp_watermarks_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpWatermarks", + Vec::new(), + [ + 231u8, 195u8, 117u8, 35u8, 235u8, 18u8, 80u8, 28u8, 212u8, 37u8, 253u8, + 204u8, 71u8, 217u8, 12u8, 35u8, 219u8, 250u8, 45u8, 83u8, 102u8, 236u8, + 186u8, 149u8, 54u8, 31u8, 83u8, 19u8, 129u8, 51u8, 103u8, 155u8, + ], + ) + } + #[doc = " HRMP channel data associated with each para."] + #[doc = " Invariant:"] + #[doc = " - each participant in the channel should satisfy `Paras::is_valid_para(P)` within a session."] + pub fn hrmp_channels( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_parachain::primitives::HrmpChannelId, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::hrmp::HrmpChannel, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpChannels", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 224u8, 252u8, 187u8, 122u8, 179u8, 193u8, 227u8, 250u8, 255u8, 216u8, + 107u8, 26u8, 224u8, 16u8, 178u8, 111u8, 77u8, 237u8, 177u8, 148u8, + 22u8, 17u8, 213u8, 99u8, 194u8, 140u8, 217u8, 211u8, 151u8, 51u8, 66u8, + 169u8, + ], + ) + } + #[doc = " HRMP channel data associated with each para."] + #[doc = " Invariant:"] + #[doc = " - each participant in the channel should satisfy `Paras::is_valid_para(P)` within a session."] + pub fn hrmp_channels_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::hrmp::HrmpChannel, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpChannels", + Vec::new(), + [ + 224u8, 252u8, 187u8, 122u8, 179u8, 193u8, 227u8, 250u8, 255u8, 216u8, + 107u8, 26u8, 224u8, 16u8, 178u8, 111u8, 77u8, 237u8, 177u8, 148u8, + 22u8, 17u8, 213u8, 99u8, 194u8, 140u8, 217u8, 211u8, 151u8, 51u8, 66u8, + 169u8, + ], + ) + } + #[doc = " Ingress/egress indexes allow to find all the senders and receivers given the opposite side."] + #[doc = " I.e."] + #[doc = ""] + #[doc = " (a) ingress index allows to find all the senders for a given recipient."] + #[doc = " (b) egress index allows to find all the recipients for a given sender."] + #[doc = ""] + #[doc = " Invariants:"] + #[doc = " - for each ingress index entry for `P` each item `I` in the index should present in"] + #[doc = " `HrmpChannels` as `(I, P)`."] + #[doc = " - for each egress index entry for `P` each item `E` in the index should present in"] + #[doc = " `HrmpChannels` as `(P, E)`."] + #[doc = " - there should be no other dangling channels in `HrmpChannels`."] + #[doc = " - the vectors are sorted."] + pub fn hrmp_ingress_channels_index( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpIngressChannelsIndex", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 58u8, 193u8, 212u8, 225u8, 48u8, 195u8, 119u8, 15u8, 61u8, 166u8, + 249u8, 1u8, 118u8, 67u8, 253u8, 40u8, 58u8, 220u8, 124u8, 152u8, 4u8, + 16u8, 155u8, 151u8, 195u8, 15u8, 205u8, 175u8, 234u8, 0u8, 101u8, 99u8, + ], + ) + } + #[doc = " Ingress/egress indexes allow to find all the senders and receivers given the opposite side."] + #[doc = " I.e."] + #[doc = ""] + #[doc = " (a) ingress index allows to find all the senders for a given recipient."] + #[doc = " (b) egress index allows to find all the recipients for a given sender."] + #[doc = ""] + #[doc = " Invariants:"] + #[doc = " - for each ingress index entry for `P` each item `I` in the index should present in"] + #[doc = " `HrmpChannels` as `(I, P)`."] + #[doc = " - for each egress index entry for `P` each item `E` in the index should present in"] + #[doc = " `HrmpChannels` as `(P, E)`."] + #[doc = " - there should be no other dangling channels in `HrmpChannels`."] + #[doc = " - the vectors are sorted."] + pub fn hrmp_ingress_channels_index_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpIngressChannelsIndex", + Vec::new(), + [ + 58u8, 193u8, 212u8, 225u8, 48u8, 195u8, 119u8, 15u8, 61u8, 166u8, + 249u8, 1u8, 118u8, 67u8, 253u8, 40u8, 58u8, 220u8, 124u8, 152u8, 4u8, + 16u8, 155u8, 151u8, 195u8, 15u8, 205u8, 175u8, 234u8, 0u8, 101u8, 99u8, + ], + ) + } + pub fn hrmp_egress_channels_index( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpEgressChannelsIndex", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 9u8, 242u8, 41u8, 234u8, 85u8, 193u8, 232u8, 245u8, 254u8, 26u8, 240u8, + 113u8, 184u8, 151u8, 150u8, 44u8, 43u8, 98u8, 84u8, 209u8, 145u8, + 175u8, 128u8, 68u8, 183u8, 112u8, 171u8, 236u8, 211u8, 32u8, 177u8, + 88u8, + ], + ) + } + pub fn hrmp_egress_channels_index_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpEgressChannelsIndex", + Vec::new(), + [ + 9u8, 242u8, 41u8, 234u8, 85u8, 193u8, 232u8, 245u8, 254u8, 26u8, 240u8, + 113u8, 184u8, 151u8, 150u8, 44u8, 43u8, 98u8, 84u8, 209u8, 145u8, + 175u8, 128u8, 68u8, 183u8, 112u8, 171u8, 236u8, 211u8, 32u8, 177u8, + 88u8, + ], + ) + } + #[doc = " Storage for the messages for each channel."] + #[doc = " Invariant: cannot be non-empty if the corresponding channel in `HrmpChannels` is `None`."] + pub fn hrmp_channel_contents( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_parachain::primitives::HrmpChannelId, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec< + runtime_types::polkadot_core_primitives::InboundHrmpMessage< + ::core::primitive::u32, + >, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpChannelContents", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 114u8, 86u8, 172u8, 88u8, 118u8, 243u8, 133u8, 147u8, 108u8, 60u8, + 128u8, 235u8, 45u8, 80u8, 225u8, 130u8, 89u8, 50u8, 40u8, 118u8, 63u8, + 3u8, 83u8, 222u8, 75u8, 167u8, 148u8, 150u8, 193u8, 90u8, 196u8, 225u8, + ], + ) + } + #[doc = " Storage for the messages for each channel."] + #[doc = " Invariant: cannot be non-empty if the corresponding channel in `HrmpChannels` is `None`."] + pub fn hrmp_channel_contents_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec< + runtime_types::polkadot_core_primitives::InboundHrmpMessage< + ::core::primitive::u32, + >, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpChannelContents", + Vec::new(), + [ + 114u8, 86u8, 172u8, 88u8, 118u8, 243u8, 133u8, 147u8, 108u8, 60u8, + 128u8, 235u8, 45u8, 80u8, 225u8, 130u8, 89u8, 50u8, 40u8, 118u8, 63u8, + 3u8, 83u8, 222u8, 75u8, 167u8, 148u8, 150u8, 193u8, 90u8, 196u8, 225u8, + ], + ) + } + #[doc = " Maintains a mapping that can be used to answer the question: What paras sent a message at"] + #[doc = " the given block number for a given receiver. Invariants:"] + #[doc = " - The inner `Vec` is never empty."] + #[doc = " - The inner `Vec` cannot store two same `ParaId`."] + #[doc = " - The outer vector is sorted ascending by block number and cannot store two items with the"] + #[doc = " same block number."] + pub fn hrmp_channel_digests( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<( + ::core::primitive::u32, + ::std::vec::Vec, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpChannelDigests", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 205u8, 18u8, 60u8, 54u8, 123u8, 40u8, 160u8, 149u8, 174u8, 45u8, 135u8, + 213u8, 83u8, 44u8, 97u8, 243u8, 47u8, 200u8, 156u8, 131u8, 15u8, 63u8, + 170u8, 206u8, 101u8, 17u8, 244u8, 132u8, 73u8, 133u8, 79u8, 104u8, + ], + ) + } + #[doc = " Maintains a mapping that can be used to answer the question: What paras sent a message at"] + #[doc = " the given block number for a given receiver. Invariants:"] + #[doc = " - The inner `Vec` is never empty."] + #[doc = " - The inner `Vec` cannot store two same `ParaId`."] + #[doc = " - The outer vector is sorted ascending by block number and cannot store two items with the"] + #[doc = " same block number."] + pub fn hrmp_channel_digests_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<( + ::core::primitive::u32, + ::std::vec::Vec, + )>, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Hrmp", + "HrmpChannelDigests", + Vec::new(), + [ + 205u8, 18u8, 60u8, 54u8, 123u8, 40u8, 160u8, 149u8, 174u8, 45u8, 135u8, + 213u8, 83u8, 44u8, 97u8, 243u8, 47u8, 200u8, 156u8, 131u8, 15u8, 63u8, + 170u8, 206u8, 101u8, 17u8, 244u8, 132u8, 73u8, 133u8, 79u8, 104u8, + ], + ) + } + } + } + } + pub mod para_session_info { + use super::root_mod; + use super::runtime_types; + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Assignment keys for the current session."] + #[doc = " Note that this API is private due to it being prone to 'off-by-one' at session boundaries."] + #[doc = " When in doubt, use `Sessions` API instead."] + pub fn assignment_keys_unsafe( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParaSessionInfo", + "AssignmentKeysUnsafe", + vec![], + [ + 80u8, 24u8, 61u8, 132u8, 118u8, 225u8, 207u8, 75u8, 35u8, 240u8, 209u8, + 255u8, 19u8, 240u8, 114u8, 174u8, 86u8, 65u8, 65u8, 52u8, 135u8, 232u8, + 59u8, 208u8, 3u8, 107u8, 114u8, 241u8, 14u8, 98u8, 40u8, 226u8, + ], + ) + } + #[doc = " The earliest session for which previous session info is stored."] + pub fn earliest_stored_session( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParaSessionInfo", + "EarliestStoredSession", + vec![], + [ + 25u8, 143u8, 246u8, 184u8, 35u8, 166u8, 140u8, 147u8, 171u8, 5u8, + 164u8, 159u8, 228u8, 21u8, 248u8, 236u8, 48u8, 210u8, 133u8, 140u8, + 171u8, 3u8, 85u8, 250u8, 160u8, 102u8, 95u8, 46u8, 33u8, 81u8, 102u8, + 241u8, + ], + ) + } + #[doc = " Session information in a rolling window."] + #[doc = " Should have an entry in range `EarliestStoredSession..=CurrentSessionIndex`."] + #[doc = " Does not have any entries before the session index in the first session change notification."] + pub fn sessions( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_primitives::v4::SessionInfo, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParaSessionInfo", + "Sessions", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 186u8, 220u8, 61u8, 52u8, 195u8, 40u8, 214u8, 113u8, 92u8, 109u8, + 221u8, 201u8, 122u8, 213u8, 124u8, 35u8, 244u8, 55u8, 244u8, 168u8, + 23u8, 0u8, 240u8, 109u8, 143u8, 90u8, 40u8, 87u8, 127u8, 64u8, 100u8, + 75u8, + ], + ) + } + #[doc = " Session information in a rolling window."] + #[doc = " Should have an entry in range `EarliestStoredSession..=CurrentSessionIndex`."] + #[doc = " Does not have any entries before the session index in the first session change notification."] + pub fn sessions_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_primitives::v4::SessionInfo, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParaSessionInfo", + "Sessions", + Vec::new(), + [ + 186u8, 220u8, 61u8, 52u8, 195u8, 40u8, 214u8, 113u8, 92u8, 109u8, + 221u8, 201u8, 122u8, 213u8, 124u8, 35u8, 244u8, 55u8, 244u8, 168u8, + 23u8, 0u8, 240u8, 109u8, 143u8, 90u8, 40u8, 87u8, 127u8, 64u8, 100u8, + 75u8, + ], + ) + } + #[doc = " The validator account keys of the validators actively participating in parachain consensus."] + pub fn account_keys( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::subxt::utils::AccountId32>, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParaSessionInfo", + "AccountKeys", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 48u8, 179u8, 139u8, 15u8, 144u8, 71u8, 92u8, 160u8, 254u8, 237u8, 98u8, + 60u8, 254u8, 208u8, 201u8, 32u8, 79u8, 55u8, 3u8, 33u8, 188u8, 134u8, + 18u8, 151u8, 132u8, 40u8, 192u8, 215u8, 94u8, 124u8, 148u8, 142u8, + ], + ) + } + #[doc = " The validator account keys of the validators actively participating in parachain consensus."] + pub fn account_keys_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::subxt::utils::AccountId32>, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParaSessionInfo", + "AccountKeys", + Vec::new(), + [ + 48u8, 179u8, 139u8, 15u8, 144u8, 71u8, 92u8, 160u8, 254u8, 237u8, 98u8, + 60u8, 254u8, 208u8, 201u8, 32u8, 79u8, 55u8, 3u8, 33u8, 188u8, 134u8, + 18u8, 151u8, 132u8, 40u8, 192u8, 215u8, 94u8, 124u8, 148u8, 142u8, + ], + ) + } + #[doc = " Executor parameter set for a given session index"] + pub fn session_executor_params( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_primitives::v4::executor_params::ExecutorParams, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParaSessionInfo", + "SessionExecutorParams", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 182u8, 246u8, 210u8, 246u8, 208u8, 93u8, 19u8, 9u8, 132u8, 75u8, 158u8, + 40u8, 146u8, 8u8, 143u8, 37u8, 148u8, 19u8, 89u8, 70u8, 151u8, 143u8, + 143u8, 62u8, 127u8, 208u8, 74u8, 177u8, 82u8, 55u8, 226u8, 43u8, + ], + ) + } + #[doc = " Executor parameter set for a given session index"] + pub fn session_executor_params_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_primitives::v4::executor_params::ExecutorParams, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParaSessionInfo", + "SessionExecutorParams", + Vec::new(), + [ + 182u8, 246u8, 210u8, 246u8, 208u8, 93u8, 19u8, 9u8, 132u8, 75u8, 158u8, + 40u8, 146u8, 8u8, 143u8, 37u8, 148u8, 19u8, 89u8, 70u8, 151u8, 143u8, + 143u8, 62u8, 127u8, 208u8, 74u8, 177u8, 82u8, 55u8, 226u8, 43u8, + ], + ) + } + } + } + } + pub mod paras_disputes { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::polkadot_runtime_parachains::disputes::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceUnfreeze; + pub struct TransactionApi; + impl TransactionApi { + pub fn force_unfreeze(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ParasDisputes", + "force_unfreeze", + ForceUnfreeze {}, + [ + 212u8, 211u8, 58u8, 159u8, 23u8, 220u8, 64u8, 175u8, 65u8, 50u8, 192u8, + 122u8, 113u8, 189u8, 74u8, 191u8, 48u8, 93u8, 251u8, 50u8, 237u8, + 240u8, 91u8, 139u8, 193u8, 114u8, 131u8, 125u8, 124u8, 236u8, 191u8, + 190u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::polkadot_runtime_parachains::disputes::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A dispute has been initiated. \\[candidate hash, dispute location\\]"] + pub struct DisputeInitiated( + pub runtime_types::polkadot_core_primitives::CandidateHash, + pub runtime_types::polkadot_runtime_parachains::disputes::DisputeLocation, + ); + impl ::subxt::events::StaticEvent for DisputeInitiated { + const PALLET: &'static str = "ParasDisputes"; + const EVENT: &'static str = "DisputeInitiated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A dispute has concluded for or against a candidate."] + #[doc = "`\\[para id, candidate hash, dispute result\\]`"] + pub struct DisputeConcluded( + pub runtime_types::polkadot_core_primitives::CandidateHash, + pub runtime_types::polkadot_runtime_parachains::disputes::DisputeResult, + ); + impl ::subxt::events::StaticEvent for DisputeConcluded { + const PALLET: &'static str = "ParasDisputes"; + const EVENT: &'static str = "DisputeConcluded"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A dispute has concluded with supermajority against a candidate."] + #[doc = "Block authors should no longer build on top of this head and should"] + #[doc = "instead revert the block at the given height. This should be the"] + #[doc = "number of the child of the last known valid block in the chain."] + pub struct Revert(pub ::core::primitive::u32); + impl ::subxt::events::StaticEvent for Revert { + const PALLET: &'static str = "ParasDisputes"; + const EVENT: &'static str = "Revert"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The last pruned session, if any. All data stored by this module"] + #[doc = " references sessions."] + pub fn last_pruned_session( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ParasDisputes", + "LastPrunedSession", + vec![], + [ + 125u8, 138u8, 99u8, 242u8, 9u8, 246u8, 215u8, 246u8, 141u8, 6u8, 129u8, + 87u8, 27u8, 58u8, 53u8, 121u8, 61u8, 119u8, 35u8, 104u8, 33u8, 43u8, + 179u8, 82u8, 244u8, 121u8, 174u8, 135u8, 87u8, 119u8, 236u8, 105u8, + ], + ) + } + #[doc = " All ongoing or concluded disputes for the last several sessions."] + pub fn disputes( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow< + runtime_types::polkadot_core_primitives::CandidateHash, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_primitives::v4::DisputeState<::core::primitive::u32>, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParasDisputes", + "Disputes", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 192u8, 238u8, 255u8, 67u8, 169u8, 86u8, 99u8, 243u8, 228u8, 88u8, + 142u8, 138u8, 183u8, 117u8, 82u8, 22u8, 163u8, 30u8, 175u8, 247u8, + 50u8, 204u8, 12u8, 171u8, 57u8, 189u8, 151u8, 191u8, 196u8, 89u8, 94u8, + 165u8, + ], + ) + } + #[doc = " All ongoing or concluded disputes for the last several sessions."] + pub fn disputes_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_primitives::v4::DisputeState<::core::primitive::u32>, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParasDisputes", + "Disputes", + Vec::new(), + [ + 192u8, 238u8, 255u8, 67u8, 169u8, 86u8, 99u8, 243u8, 228u8, 88u8, + 142u8, 138u8, 183u8, 117u8, 82u8, 22u8, 163u8, 30u8, 175u8, 247u8, + 50u8, 204u8, 12u8, 171u8, 57u8, 189u8, 151u8, 191u8, 196u8, 89u8, 94u8, + 165u8, + ], + ) + } + #[doc = " Backing votes stored for each dispute."] + #[doc = " This storage is used for slashing."] + pub fn backers_on_disputes( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow< + runtime_types::polkadot_core_primitives::CandidateHash, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParasDisputes", + "BackersOnDisputes", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 78u8, 51u8, 233u8, 125u8, 212u8, 66u8, 171u8, 4u8, 46u8, 64u8, 92u8, + 237u8, 177u8, 72u8, 36u8, 163u8, 64u8, 238u8, 47u8, 61u8, 34u8, 249u8, + 178u8, 133u8, 129u8, 52u8, 103u8, 14u8, 91u8, 184u8, 192u8, 237u8, + ], + ) + } + #[doc = " Backing votes stored for each dispute."] + #[doc = " This storage is used for slashing."] + pub fn backers_on_disputes_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParasDisputes", + "BackersOnDisputes", + Vec::new(), + [ + 78u8, 51u8, 233u8, 125u8, 212u8, 66u8, 171u8, 4u8, 46u8, 64u8, 92u8, + 237u8, 177u8, 72u8, 36u8, 163u8, 64u8, 238u8, 47u8, 61u8, 34u8, 249u8, + 178u8, 133u8, 129u8, 52u8, 103u8, 14u8, 91u8, 184u8, 192u8, 237u8, + ], + ) + } + #[doc = " All included blocks on the chain, as well as the block number in this chain that"] + #[doc = " should be reverted back to if the candidate is disputed and determined to be invalid."] + pub fn included( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow< + runtime_types::polkadot_core_primitives::CandidateHash, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParasDisputes", + "Included", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 129u8, 50u8, 76u8, 60u8, 82u8, 106u8, 248u8, 164u8, 152u8, 80u8, 58u8, + 185u8, 211u8, 225u8, 122u8, 100u8, 234u8, 241u8, 123u8, 205u8, 4u8, + 8u8, 193u8, 116u8, 167u8, 158u8, 252u8, 223u8, 204u8, 226u8, 74u8, + 195u8, + ], + ) + } + #[doc = " All included blocks on the chain, as well as the block number in this chain that"] + #[doc = " should be reverted back to if the candidate is disputed and determined to be invalid."] + pub fn included_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParasDisputes", + "Included", + Vec::new(), + [ + 129u8, 50u8, 76u8, 60u8, 82u8, 106u8, 248u8, 164u8, 152u8, 80u8, 58u8, + 185u8, 211u8, 225u8, 122u8, 100u8, 234u8, 241u8, 123u8, 205u8, 4u8, + 8u8, 193u8, 116u8, 167u8, 158u8, 252u8, 223u8, 204u8, 226u8, 74u8, + 195u8, + ], + ) + } + #[doc = " Whether the chain is frozen. Starts as `None`. When this is `Some`,"] + #[doc = " the chain will not accept any new parachain blocks for backing or inclusion,"] + #[doc = " and its value indicates the last valid block number in the chain."] + #[doc = " It can only be set back to `None` by governance intervention."] + pub fn frozen( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::option::Option<::core::primitive::u32>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParasDisputes", + "Frozen", + vec![], + [ + 133u8, 100u8, 86u8, 220u8, 180u8, 189u8, 65u8, 131u8, 64u8, 56u8, + 219u8, 47u8, 130u8, 167u8, 210u8, 125u8, 49u8, 7u8, 153u8, 254u8, 20u8, + 53u8, 218u8, 177u8, 122u8, 148u8, 16u8, 198u8, 251u8, 50u8, 194u8, + 128u8, + ], + ) + } + } + } + } + pub mod paras_slashing { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = + runtime_types::polkadot_runtime_parachains::disputes::slashing::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReportDisputeLostUnsigned { + pub dispute_proof: ::std::boxed::Box< + runtime_types::polkadot_runtime_parachains::disputes::slashing::DisputeProof, + >, + pub key_owner_proof: runtime_types::sp_session::MembershipProof, + } + pub struct TransactionApi; + impl TransactionApi { + pub fn report_dispute_lost_unsigned( + &self, + dispute_proof : runtime_types :: polkadot_runtime_parachains :: disputes :: slashing :: DisputeProof, + key_owner_proof: runtime_types::sp_session::MembershipProof, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ParasSlashing", + "report_dispute_lost_unsigned", + ReportDisputeLostUnsigned { + dispute_proof: ::std::boxed::Box::new(dispute_proof), + key_owner_proof, + }, + [ + 56u8, 94u8, 136u8, 125u8, 219u8, 155u8, 79u8, 241u8, 109u8, 125u8, + 106u8, 175u8, 5u8, 189u8, 34u8, 232u8, 132u8, 113u8, 157u8, 184u8, + 10u8, 34u8, 135u8, 184u8, 36u8, 224u8, 234u8, 141u8, 35u8, 69u8, 254u8, + 125u8, + ], + ) + } + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Validators pending dispute slashes."] + pub fn unapplied_slashes( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow< + runtime_types::polkadot_core_primitives::CandidateHash, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::disputes::slashing::PendingSlashes, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParasSlashing", + "UnappliedSlashes", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 54u8, 95u8, 76u8, 24u8, 68u8, 137u8, 201u8, 120u8, 51u8, 146u8, 12u8, + 14u8, 39u8, 109u8, 69u8, 148u8, 117u8, 193u8, 139u8, 82u8, 23u8, 77u8, + 0u8, 16u8, 64u8, 125u8, 181u8, 249u8, 23u8, 156u8, 70u8, 90u8, + ], + ) + } + #[doc = " Validators pending dispute slashes."] + pub fn unapplied_slashes_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_parachains::disputes::slashing::PendingSlashes, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParasSlashing", + "UnappliedSlashes", + Vec::new(), + [ + 54u8, 95u8, 76u8, 24u8, 68u8, 137u8, 201u8, 120u8, 51u8, 146u8, 12u8, + 14u8, 39u8, 109u8, 69u8, 148u8, 117u8, 193u8, 139u8, 82u8, 23u8, 77u8, + 0u8, 16u8, 64u8, 125u8, 181u8, 249u8, 23u8, 156u8, 70u8, 90u8, + ], + ) + } + #[doc = " `ValidatorSetCount` per session."] + pub fn validator_set_counts( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParasSlashing", + "ValidatorSetCounts", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 121u8, 241u8, 222u8, 61u8, 186u8, 55u8, 206u8, 246u8, 31u8, 128u8, + 103u8, 53u8, 6u8, 73u8, 13u8, 120u8, 63u8, 56u8, 167u8, 75u8, 113u8, + 102u8, 221u8, 129u8, 151u8, 186u8, 225u8, 169u8, 128u8, 192u8, 107u8, + 214u8, + ], + ) + } + #[doc = " `ValidatorSetCount` per session."] + pub fn validator_set_counts_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ParasSlashing", + "ValidatorSetCounts", + Vec::new(), + [ + 121u8, 241u8, 222u8, 61u8, 186u8, 55u8, 206u8, 246u8, 31u8, 128u8, + 103u8, 53u8, 6u8, 73u8, 13u8, 120u8, 63u8, 56u8, 167u8, 75u8, 113u8, + 102u8, 221u8, 129u8, 151u8, 186u8, 225u8, 169u8, 128u8, 192u8, 107u8, + 214u8, + ], + ) + } + } + } + } + pub mod registrar { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::polkadot_runtime_common::paras_registrar::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Register { + pub id: runtime_types::polkadot_parachain::primitives::Id, + pub genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, + pub validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceRegister { + pub who: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, + pub id: runtime_types::polkadot_parachain::primitives::Id, + pub genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, + pub validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Deregister { + pub id: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Swap { + pub id: runtime_types::polkadot_parachain::primitives::Id, + pub other: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveLock { + pub para: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Reserve; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddLock { + pub para: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ScheduleCodeUpgrade { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetCurrentHead { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub new_head: runtime_types::polkadot_parachain::primitives::HeadData, + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Register head data and validation code for a reserved Para Id."] + #[doc = ""] + #[doc = "## Arguments"] + #[doc = "- `origin`: Must be called by a `Signed` origin."] + #[doc = "- `id`: The para ID. Must be owned/managed by the `origin` signing account."] + #[doc = "- `genesis_head`: The genesis head data of the parachain/thread."] + #[doc = "- `validation_code`: The initial validation code of the parachain/thread."] + #[doc = ""] + #[doc = "## Deposits/Fees"] + #[doc = "The origin signed account must reserve a corresponding deposit for the registration. Anything already"] + #[doc = "reserved previously for this para ID is accounted for."] + #[doc = ""] + #[doc = "## Events"] + #[doc = "The `Registered` event is emitted in case of success."] + pub fn register( + &self, + id: runtime_types::polkadot_parachain::primitives::Id, + genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, + validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Registrar", + "register", + Register { + id, + genesis_head, + validation_code, + }, + [ + 154u8, 84u8, 201u8, 125u8, 72u8, 69u8, 188u8, 42u8, 225u8, 14u8, 136u8, + 48u8, 78u8, 86u8, 99u8, 238u8, 252u8, 255u8, 226u8, 219u8, 214u8, 17u8, + 19u8, 9u8, 12u8, 13u8, 174u8, 243u8, 37u8, 134u8, 76u8, 23u8, + ], + ) + } + #[doc = "Force the registration of a Para Id on the relay chain."] + #[doc = ""] + #[doc = "This function must be called by a Root origin."] + #[doc = ""] + #[doc = "The deposit taken can be specified for this registration. Any `ParaId`"] + #[doc = "can be registered, including sub-1000 IDs which are System Parachains."] + pub fn force_register( + &self, + who: ::subxt::utils::AccountId32, + deposit: ::core::primitive::u128, + id: runtime_types::polkadot_parachain::primitives::Id, + genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, + validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Registrar", + "force_register", + ForceRegister { + who, + deposit, + id, + genesis_head, + validation_code, + }, + [ + 59u8, 24u8, 236u8, 163u8, 53u8, 49u8, 92u8, 199u8, 38u8, 76u8, 101u8, + 73u8, 166u8, 105u8, 145u8, 55u8, 89u8, 30u8, 30u8, 137u8, 151u8, 219u8, + 116u8, 226u8, 168u8, 220u8, 222u8, 6u8, 105u8, 91u8, 254u8, 216u8, + ], + ) + } + #[doc = "Deregister a Para Id, freeing all data and returning any deposit."] + #[doc = ""] + #[doc = "The caller must be Root, the `para` owner, or the `para` itself. The para must be a parathread."] + pub fn deregister( + &self, + id: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Registrar", + "deregister", + Deregister { id }, + [ + 137u8, 9u8, 146u8, 11u8, 126u8, 125u8, 186u8, 222u8, 246u8, 199u8, + 94u8, 229u8, 147u8, 245u8, 213u8, 51u8, 203u8, 181u8, 78u8, 87u8, 18u8, + 255u8, 79u8, 107u8, 234u8, 2u8, 21u8, 212u8, 1u8, 73u8, 173u8, 253u8, + ], + ) + } + #[doc = "Swap a parachain with another parachain or parathread."] + #[doc = ""] + #[doc = "The origin must be Root, the `para` owner, or the `para` itself."] + #[doc = ""] + #[doc = "The swap will happen only if there is already an opposite swap pending. If there is not,"] + #[doc = "the swap will be stored in the pending swaps map, ready for a later confirmatory swap."] + #[doc = ""] + #[doc = "The `ParaId`s remain mapped to the same head data and code so external code can rely on"] + #[doc = "`ParaId` to be a long-term identifier of a notional \"parachain\". However, their"] + #[doc = "scheduling info (i.e. whether they're a parathread or parachain), auction information"] + #[doc = "and the auction deposit are switched."] + pub fn swap( + &self, + id: runtime_types::polkadot_parachain::primitives::Id, + other: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Registrar", + "swap", + Swap { id, other }, + [ + 238u8, 154u8, 249u8, 250u8, 57u8, 242u8, 47u8, 17u8, 50u8, 70u8, 124u8, + 189u8, 193u8, 137u8, 107u8, 138u8, 216u8, 137u8, 160u8, 103u8, 192u8, + 133u8, 7u8, 130u8, 41u8, 39u8, 47u8, 139u8, 202u8, 7u8, 84u8, 214u8, + ], + ) + } + #[doc = "Remove a manager lock from a para. This will allow the manager of a"] + #[doc = "previously locked para to deregister or swap a para without using governance."] + #[doc = ""] + #[doc = "Can only be called by the Root origin or the parachain."] + pub fn remove_lock( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Registrar", + "remove_lock", + RemoveLock { para }, + [ + 93u8, 50u8, 223u8, 180u8, 185u8, 3u8, 225u8, 27u8, 233u8, 205u8, 101u8, + 86u8, 122u8, 19u8, 147u8, 8u8, 202u8, 151u8, 80u8, 24u8, 196u8, 2u8, + 88u8, 250u8, 184u8, 96u8, 158u8, 70u8, 181u8, 201u8, 200u8, 213u8, + ], + ) + } + #[doc = "Reserve a Para Id on the relay chain."] + #[doc = ""] + #[doc = "This function will reserve a new Para Id to be owned/managed by the origin account."] + #[doc = "The origin account is able to register head data and validation code using `register` to create"] + #[doc = "a parathread. Using the Slots pallet, a parathread can then be upgraded to get a parachain slot."] + #[doc = ""] + #[doc = "## Arguments"] + #[doc = "- `origin`: Must be called by a `Signed` origin. Becomes the manager/owner of the new para ID."] + #[doc = ""] + #[doc = "## Deposits/Fees"] + #[doc = "The origin must reserve a deposit of `ParaDeposit` for the registration."] + #[doc = ""] + #[doc = "## Events"] + #[doc = "The `Reserved` event is emitted in case of success, which provides the ID reserved for use."] + pub fn reserve(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Registrar", + "reserve", + Reserve {}, + [ + 22u8, 210u8, 13u8, 54u8, 253u8, 13u8, 89u8, 174u8, 232u8, 119u8, 148u8, + 206u8, 130u8, 133u8, 199u8, 127u8, 201u8, 205u8, 8u8, 213u8, 108u8, + 93u8, 135u8, 88u8, 238u8, 171u8, 31u8, 193u8, 23u8, 113u8, 106u8, + 135u8, + ], + ) + } + #[doc = "Add a manager lock from a para. This will prevent the manager of a"] + #[doc = "para to deregister or swap a para."] + #[doc = ""] + #[doc = "Can be called by Root, the parachain, or the parachain manager if the parachain is unlocked."] + pub fn add_lock( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Registrar", + "add_lock", + AddLock { para }, + [ + 99u8, 199u8, 192u8, 92u8, 180u8, 52u8, 86u8, 165u8, 249u8, 60u8, 72u8, + 79u8, 233u8, 5u8, 83u8, 194u8, 48u8, 83u8, 249u8, 218u8, 141u8, 234u8, + 232u8, 59u8, 9u8, 150u8, 147u8, 173u8, 91u8, 154u8, 81u8, 17u8, + ], + ) + } + #[doc = "Schedule a parachain upgrade."] + #[doc = ""] + #[doc = "Can be called by Root, the parachain, or the parachain manager if the parachain is unlocked."] + pub fn schedule_code_upgrade( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Registrar", + "schedule_code_upgrade", + ScheduleCodeUpgrade { para, new_code }, + [ + 67u8, 11u8, 148u8, 83u8, 36u8, 106u8, 97u8, 77u8, 79u8, 114u8, 249u8, + 218u8, 207u8, 89u8, 209u8, 120u8, 45u8, 101u8, 69u8, 21u8, 61u8, 158u8, + 90u8, 83u8, 29u8, 143u8, 55u8, 9u8, 178u8, 75u8, 183u8, 25u8, + ], + ) + } + #[doc = "Set the parachain's current head."] + #[doc = ""] + #[doc = "Can be called by Root, the parachain, or the parachain manager if the parachain is unlocked."] + pub fn set_current_head( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + new_head: runtime_types::polkadot_parachain::primitives::HeadData, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Registrar", + "set_current_head", + SetCurrentHead { para, new_head }, + [ + 103u8, 240u8, 206u8, 26u8, 120u8, 189u8, 94u8, 221u8, 174u8, 225u8, + 210u8, 176u8, 217u8, 18u8, 94u8, 216u8, 77u8, 205u8, 86u8, 196u8, + 121u8, 4u8, 230u8, 147u8, 19u8, 224u8, 38u8, 254u8, 199u8, 254u8, + 245u8, 110u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::polkadot_runtime_common::paras_registrar::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Registered { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub manager: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for Registered { + const PALLET: &'static str = "Registrar"; + const EVENT: &'static str = "Registered"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Deregistered { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + } + impl ::subxt::events::StaticEvent for Deregistered { + const PALLET: &'static str = "Registrar"; + const EVENT: &'static str = "Deregistered"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Reserved { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub who: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for Reserved { + const PALLET: &'static str = "Registrar"; + const EVENT: &'static str = "Reserved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Swapped { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub other_id: runtime_types::polkadot_parachain::primitives::Id, + } + impl ::subxt::events::StaticEvent for Swapped { + const PALLET: &'static str = "Registrar"; + const EVENT: &'static str = "Swapped"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Pending swap operations."] + pub fn pending_swap( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::Id, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Registrar", + "PendingSwap", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 121u8, 124u8, 4u8, 120u8, 173u8, 48u8, 227u8, 135u8, 72u8, 74u8, 238u8, + 230u8, 1u8, 175u8, 33u8, 241u8, 138u8, 82u8, 217u8, 129u8, 138u8, + 107u8, 59u8, 8u8, 205u8, 244u8, 192u8, 159u8, 171u8, 123u8, 149u8, + 174u8, + ], + ) + } + #[doc = " Pending swap operations."] + pub fn pending_swap_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::Id, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Registrar", + "PendingSwap", + Vec::new(), + [ + 121u8, 124u8, 4u8, 120u8, 173u8, 48u8, 227u8, 135u8, 72u8, 74u8, 238u8, + 230u8, 1u8, 175u8, 33u8, 241u8, 138u8, 82u8, 217u8, 129u8, 138u8, + 107u8, 59u8, 8u8, 205u8, 244u8, 192u8, 159u8, 171u8, 123u8, 149u8, + 174u8, + ], + ) + } + #[doc = " Amount held on deposit for each para and the original depositor."] + #[doc = ""] + #[doc = " The given account ID is responsible for registering the code and initial head data, but may only do"] + #[doc = " so if it isn't yet registered. (After that, it's up to governance to do so.)"] + pub fn paras( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_common::paras_registrar::ParaInfo< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Registrar", + "Paras", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 149u8, 3u8, 25u8, 145u8, 60u8, 126u8, 219u8, 71u8, 88u8, 241u8, 122u8, + 99u8, 134u8, 191u8, 60u8, 172u8, 230u8, 230u8, 110u8, 31u8, 43u8, 6u8, + 146u8, 161u8, 51u8, 21u8, 169u8, 220u8, 240u8, 218u8, 124u8, 56u8, + ], + ) + } + #[doc = " Amount held on deposit for each para and the original depositor."] + #[doc = ""] + #[doc = " The given account ID is responsible for registering the code and initial head data, but may only do"] + #[doc = " so if it isn't yet registered. (After that, it's up to governance to do so.)"] + pub fn paras_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_common::paras_registrar::ParaInfo< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Registrar", + "Paras", + Vec::new(), + [ + 149u8, 3u8, 25u8, 145u8, 60u8, 126u8, 219u8, 71u8, 88u8, 241u8, 122u8, + 99u8, 134u8, 191u8, 60u8, 172u8, 230u8, 230u8, 110u8, 31u8, 43u8, 6u8, + 146u8, 161u8, 51u8, 21u8, 169u8, 220u8, 240u8, 218u8, 124u8, 56u8, + ], + ) + } + #[doc = " The next free `ParaId`."] + pub fn next_free_para_id( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain::primitives::Id, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Registrar", + "NextFreeParaId", + vec![], + [ + 139u8, 76u8, 36u8, 150u8, 237u8, 36u8, 143u8, 242u8, 252u8, 29u8, + 236u8, 168u8, 97u8, 50u8, 175u8, 120u8, 83u8, 118u8, 205u8, 64u8, 95u8, + 65u8, 7u8, 230u8, 171u8, 86u8, 189u8, 205u8, 231u8, 211u8, 97u8, 29u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The deposit to be paid to run a parathread."] + #[doc = " This should include the cost for storing the genesis head and validation code."] + pub fn para_deposit(&self) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Registrar", + "ParaDeposit", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The deposit to be paid per byte stored on chain."] + pub fn data_deposit_per_byte( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Registrar", + "DataDepositPerByte", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + } + } + } + pub mod slots { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::polkadot_runtime_common::slots::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceLease { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub leaser: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + pub period_begin: ::core::primitive::u32, + pub period_count: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClearAllLeases { + pub para: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TriggerOnboard { + pub para: runtime_types::polkadot_parachain::primitives::Id, + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Just a connect into the `lease_out` call, in case Root wants to force some lease to happen"] + #[doc = "independently of any other on-chain mechanism to use it."] + #[doc = ""] + #[doc = "The dispatch origin for this call must match `T::ForceOrigin`."] + pub fn force_lease( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + leaser: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + period_begin: ::core::primitive::u32, + period_count: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Slots", + "force_lease", + ForceLease { + para, + leaser, + amount, + period_begin, + period_count, + }, + [ + 196u8, 2u8, 63u8, 229u8, 18u8, 134u8, 48u8, 4u8, 165u8, 46u8, 173u8, + 0u8, 189u8, 35u8, 99u8, 84u8, 103u8, 124u8, 233u8, 246u8, 60u8, 172u8, + 181u8, 205u8, 154u8, 164u8, 36u8, 178u8, 60u8, 164u8, 166u8, 21u8, + ], + ) + } + #[doc = "Clear all leases for a Para Id, refunding any deposits back to the original owners."] + #[doc = ""] + #[doc = "The dispatch origin for this call must match `T::ForceOrigin`."] + pub fn clear_all_leases( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Slots", + "clear_all_leases", + ClearAllLeases { para }, + [ + 16u8, 14u8, 185u8, 45u8, 149u8, 70u8, 177u8, 133u8, 130u8, 173u8, + 196u8, 244u8, 77u8, 63u8, 218u8, 64u8, 108u8, 83u8, 84u8, 184u8, 175u8, + 122u8, 36u8, 115u8, 146u8, 117u8, 132u8, 82u8, 2u8, 144u8, 62u8, 179u8, + ], + ) + } + #[doc = "Try to onboard a parachain that has a lease for the current lease period."] + #[doc = ""] + #[doc = "This function can be useful if there was some state issue with a para that should"] + #[doc = "have onboarded, but was unable to. As long as they have a lease period, we can"] + #[doc = "let them onboard from here."] + #[doc = ""] + #[doc = "Origin must be signed, but can be called by anyone."] + pub fn trigger_onboard( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Slots", + "trigger_onboard", + TriggerOnboard { para }, + [ + 74u8, 158u8, 122u8, 37u8, 34u8, 62u8, 61u8, 218u8, 94u8, 222u8, 1u8, + 153u8, 131u8, 215u8, 157u8, 180u8, 98u8, 130u8, 151u8, 179u8, 22u8, + 120u8, 32u8, 207u8, 208u8, 46u8, 248u8, 43u8, 154u8, 118u8, 106u8, 2u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::polkadot_runtime_common::slots::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new `[lease_period]` is beginning."] + pub struct NewLeasePeriod { + pub lease_period: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for NewLeasePeriod { + const PALLET: &'static str = "Slots"; + const EVENT: &'static str = "NewLeasePeriod"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A para has won the right to a continuous set of lease periods as a parachain."] + #[doc = "First balance is any extra amount reserved on top of the para's existing deposit."] + #[doc = "Second balance is the total amount reserved."] + pub struct Leased { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub leaser: ::subxt::utils::AccountId32, + pub period_begin: ::core::primitive::u32, + pub period_count: ::core::primitive::u32, + pub extra_reserved: ::core::primitive::u128, + pub total_amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Leased { + const PALLET: &'static str = "Slots"; + const EVENT: &'static str = "Leased"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Amounts held on deposit for each (possibly future) leased parachain."] + #[doc = ""] + #[doc = " The actual amount locked on its behalf by any account at any time is the maximum of the second values"] + #[doc = " of the items in this list whose first value is the account."] + #[doc = ""] + #[doc = " The first item in the list is the amount locked for the current Lease Period. Following"] + #[doc = " items are for the subsequent lease periods."] + #[doc = ""] + #[doc = " The default value (an empty list) implies that the parachain no longer exists (or never"] + #[doc = " existed) as far as this pallet is concerned."] + #[doc = ""] + #[doc = " If a parachain doesn't exist *yet* but is scheduled to exist in the future, then it"] + #[doc = " will be left-padded with one or more `None`s to denote the fact that nothing is held on"] + #[doc = " deposit for the non-existent chain currently, but is held at some point in the future."] + #[doc = ""] + #[doc = " It is illegal for a `None` value to trail in the list."] + pub fn leases( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec< + ::core::option::Option<( + ::subxt::utils::AccountId32, + ::core::primitive::u128, + )>, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Slots", + "Leases", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 7u8, 104u8, 17u8, 66u8, 157u8, 89u8, 238u8, 38u8, 233u8, 241u8, 110u8, + 67u8, 132u8, 101u8, 243u8, 62u8, 73u8, 7u8, 9u8, 172u8, 22u8, 51u8, + 118u8, 87u8, 3u8, 224u8, 120u8, 88u8, 139u8, 11u8, 96u8, 147u8, + ], + ) + } + #[doc = " Amounts held on deposit for each (possibly future) leased parachain."] + #[doc = ""] + #[doc = " The actual amount locked on its behalf by any account at any time is the maximum of the second values"] + #[doc = " of the items in this list whose first value is the account."] + #[doc = ""] + #[doc = " The first item in the list is the amount locked for the current Lease Period. Following"] + #[doc = " items are for the subsequent lease periods."] + #[doc = ""] + #[doc = " The default value (an empty list) implies that the parachain no longer exists (or never"] + #[doc = " existed) as far as this pallet is concerned."] + #[doc = ""] + #[doc = " If a parachain doesn't exist *yet* but is scheduled to exist in the future, then it"] + #[doc = " will be left-padded with one or more `None`s to denote the fact that nothing is held on"] + #[doc = " deposit for the non-existent chain currently, but is held at some point in the future."] + #[doc = ""] + #[doc = " It is illegal for a `None` value to trail in the list."] + pub fn leases_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec< + ::core::option::Option<( + ::subxt::utils::AccountId32, + ::core::primitive::u128, + )>, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Slots", + "Leases", + Vec::new(), + [ + 7u8, 104u8, 17u8, 66u8, 157u8, 89u8, 238u8, 38u8, 233u8, 241u8, 110u8, + 67u8, 132u8, 101u8, 243u8, 62u8, 73u8, 7u8, 9u8, 172u8, 22u8, 51u8, + 118u8, 87u8, 3u8, 224u8, 120u8, 88u8, 139u8, 11u8, 96u8, 147u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The number of blocks over which a single period lasts."] + pub fn lease_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Slots", + "LeasePeriod", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The number of blocks to offset each lease period by."] + pub fn lease_offset(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Slots", + "LeaseOffset", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod auctions { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::polkadot_runtime_common::auctions::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct NewAuction { + #[codec(compact)] + pub duration: ::core::primitive::u32, + #[codec(compact)] + pub lease_period_index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Bid { + #[codec(compact)] + pub para: runtime_types::polkadot_parachain::primitives::Id, + #[codec(compact)] + pub auction_index: ::core::primitive::u32, + #[codec(compact)] + pub first_slot: ::core::primitive::u32, + #[codec(compact)] + pub last_slot: ::core::primitive::u32, + #[codec(compact)] + pub amount: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelAuction; + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Create a new auction."] + #[doc = ""] + #[doc = "This can only happen when there isn't already an auction in progress and may only be"] + #[doc = "called by the root origin. Accepts the `duration` of this auction and the"] + #[doc = "`lease_period_index` of the initial lease period of the four that are to be auctioned."] + pub fn new_auction( + &self, + duration: ::core::primitive::u32, + lease_period_index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Auctions", + "new_auction", + NewAuction { + duration, + lease_period_index, + }, + [ + 171u8, 40u8, 200u8, 164u8, 213u8, 10u8, 145u8, 164u8, 212u8, 14u8, + 117u8, 215u8, 248u8, 59u8, 34u8, 79u8, 50u8, 176u8, 164u8, 143u8, 92u8, + 82u8, 207u8, 37u8, 103u8, 252u8, 255u8, 142u8, 239u8, 134u8, 114u8, + 151u8, + ], + ) + } + #[doc = "Make a new bid from an account (including a parachain account) for deploying a new"] + #[doc = "parachain."] + #[doc = ""] + #[doc = "Multiple simultaneous bids from the same bidder are allowed only as long as all active"] + #[doc = "bids overlap each other (i.e. are mutually exclusive). Bids cannot be redacted."] + #[doc = ""] + #[doc = "- `sub` is the sub-bidder ID, allowing for multiple competing bids to be made by (and"] + #[doc = "funded by) the same account."] + #[doc = "- `auction_index` is the index of the auction to bid on. Should just be the present"] + #[doc = "value of `AuctionCounter`."] + #[doc = "- `first_slot` is the first lease period index of the range to bid on. This is the"] + #[doc = "absolute lease period index value, not an auction-specific offset."] + #[doc = "- `last_slot` is the last lease period index of the range to bid on. This is the"] + #[doc = "absolute lease period index value, not an auction-specific offset."] + #[doc = "- `amount` is the amount to bid to be held as deposit for the parachain should the"] + #[doc = "bid win. This amount is held throughout the range."] + pub fn bid( + &self, + para: runtime_types::polkadot_parachain::primitives::Id, + auction_index: ::core::primitive::u32, + first_slot: ::core::primitive::u32, + last_slot: ::core::primitive::u32, + amount: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Auctions", + "bid", + Bid { + para, + auction_index, + first_slot, + last_slot, + amount, + }, + [ + 243u8, 233u8, 248u8, 221u8, 239u8, 59u8, 65u8, 63u8, 125u8, 129u8, + 202u8, 165u8, 30u8, 228u8, 32u8, 73u8, 225u8, 38u8, 128u8, 98u8, 102u8, + 46u8, 203u8, 32u8, 70u8, 74u8, 136u8, 163u8, 83u8, 211u8, 227u8, 139u8, + ], + ) + } + #[doc = "Cancel an in-progress auction."] + #[doc = ""] + #[doc = "Can only be called by Root origin."] + pub fn cancel_auction(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Auctions", + "cancel_auction", + CancelAuction {}, + [ + 182u8, 223u8, 178u8, 136u8, 1u8, 115u8, 229u8, 78u8, 166u8, 128u8, + 28u8, 106u8, 6u8, 248u8, 46u8, 55u8, 110u8, 120u8, 213u8, 11u8, 90u8, + 217u8, 42u8, 120u8, 47u8, 83u8, 126u8, 216u8, 236u8, 251u8, 255u8, + 50u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::polkadot_runtime_common::auctions::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An auction started. Provides its index and the block number where it will begin to"] + #[doc = "close and the first lease period of the quadruplet that is auctioned."] + pub struct AuctionStarted { + pub auction_index: ::core::primitive::u32, + pub lease_period: ::core::primitive::u32, + pub ending: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for AuctionStarted { + const PALLET: &'static str = "Auctions"; + const EVENT: &'static str = "AuctionStarted"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An auction ended. All funds become unreserved."] + pub struct AuctionClosed { + pub auction_index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for AuctionClosed { + const PALLET: &'static str = "Auctions"; + const EVENT: &'static str = "AuctionClosed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Funds were reserved for a winning bid. First balance is the extra amount reserved."] + #[doc = "Second is the total."] + pub struct Reserved { + pub bidder: ::subxt::utils::AccountId32, + pub extra_reserved: ::core::primitive::u128, + pub total_amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Reserved { + const PALLET: &'static str = "Auctions"; + const EVENT: &'static str = "Reserved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Funds were unreserved since bidder is no longer active. `[bidder, amount]`"] + pub struct Unreserved { + pub bidder: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Unreserved { + const PALLET: &'static str = "Auctions"; + const EVENT: &'static str = "Unreserved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Someone attempted to lease the same slot twice for a parachain. The amount is held in reserve"] + #[doc = "but no parachain slot has been leased."] + pub struct ReserveConfiscated { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub leaser: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for ReserveConfiscated { + const PALLET: &'static str = "Auctions"; + const EVENT: &'static str = "ReserveConfiscated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new bid has been accepted as the current winner."] + pub struct BidAccepted { + pub bidder: ::subxt::utils::AccountId32, + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub amount: ::core::primitive::u128, + pub first_slot: ::core::primitive::u32, + pub last_slot: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for BidAccepted { + const PALLET: &'static str = "Auctions"; + const EVENT: &'static str = "BidAccepted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The winning offset was chosen for an auction. This will map into the `Winning` storage map."] + pub struct WinningOffset { + pub auction_index: ::core::primitive::u32, + pub block_number: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for WinningOffset { + const PALLET: &'static str = "Auctions"; + const EVENT: &'static str = "WinningOffset"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Number of auctions started so far."] + pub fn auction_counter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Auctions", + "AuctionCounter", + vec![], + [ + 67u8, 247u8, 96u8, 152u8, 0u8, 224u8, 230u8, 98u8, 194u8, 107u8, 3u8, + 203u8, 51u8, 201u8, 149u8, 22u8, 184u8, 80u8, 251u8, 239u8, 253u8, + 19u8, 58u8, 192u8, 65u8, 96u8, 189u8, 54u8, 175u8, 130u8, 143u8, 181u8, + ], + ) + } + #[doc = " Information relating to the current auction, if there is one."] + #[doc = ""] + #[doc = " The first item in the tuple is the lease period index that the first of the four"] + #[doc = " contiguous lease periods on auction is for. The second is the block number when the"] + #[doc = " auction will \"begin to end\", i.e. the first block of the Ending Period of the auction."] + pub fn auction_info( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + (::core::primitive::u32, ::core::primitive::u32), + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Auctions", + "AuctionInfo", + vec![], + [ + 73u8, 216u8, 173u8, 230u8, 132u8, 78u8, 83u8, 62u8, 200u8, 69u8, 17u8, + 73u8, 57u8, 107u8, 160u8, 90u8, 147u8, 84u8, 29u8, 110u8, 144u8, 215u8, + 169u8, 110u8, 217u8, 77u8, 109u8, 204u8, 1u8, 164u8, 95u8, 83u8, + ], + ) + } + #[doc = " Amounts currently reserved in the accounts of the bidders currently winning"] + #[doc = " (sub-)ranges."] + pub fn reserved_amounts( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _1: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Auctions", + "ReservedAmounts", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 120u8, 85u8, 180u8, 244u8, 154u8, 135u8, 87u8, 79u8, 75u8, 169u8, + 220u8, 117u8, 227u8, 85u8, 198u8, 214u8, 28u8, 126u8, 66u8, 188u8, + 137u8, 111u8, 110u8, 152u8, 18u8, 233u8, 76u8, 166u8, 55u8, 233u8, + 93u8, 62u8, + ], + ) + } + #[doc = " Amounts currently reserved in the accounts of the bidders currently winning"] + #[doc = " (sub-)ranges."] + pub fn reserved_amounts_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Auctions", + "ReservedAmounts", + Vec::new(), + [ + 120u8, 85u8, 180u8, 244u8, 154u8, 135u8, 87u8, 79u8, 75u8, 169u8, + 220u8, 117u8, 227u8, 85u8, 198u8, 214u8, 28u8, 126u8, 66u8, 188u8, + 137u8, 111u8, 110u8, 152u8, 18u8, 233u8, 76u8, 166u8, 55u8, 233u8, + 93u8, 62u8, + ], + ) + } + #[doc = " The winning bids for each of the 10 ranges at each sample in the final Ending Period of"] + #[doc = " the current auction. The map's key is the 0-based index into the Sample Size. The"] + #[doc = " first sample of the ending period is 0; the last is `Sample Size - 1`."] + pub fn winning( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + [::core::option::Option<( + ::subxt::utils::AccountId32, + runtime_types::polkadot_parachain::primitives::Id, + ::core::primitive::u128, + )>; 36usize], + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Auctions", + "Winning", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 63u8, 56u8, 143u8, 200u8, 12u8, 71u8, 187u8, 73u8, 215u8, 93u8, 222u8, + 102u8, 5u8, 113u8, 6u8, 170u8, 95u8, 228u8, 28u8, 58u8, 109u8, 62u8, + 3u8, 125u8, 211u8, 139u8, 194u8, 30u8, 151u8, 147u8, 47u8, 205u8, + ], + ) + } + #[doc = " The winning bids for each of the 10 ranges at each sample in the final Ending Period of"] + #[doc = " the current auction. The map's key is the 0-based index into the Sample Size. The"] + #[doc = " first sample of the ending period is 0; the last is `Sample Size - 1`."] + pub fn winning_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + [::core::option::Option<( + ::subxt::utils::AccountId32, + runtime_types::polkadot_parachain::primitives::Id, + ::core::primitive::u128, + )>; 36usize], + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Auctions", + "Winning", + Vec::new(), + [ + 63u8, 56u8, 143u8, 200u8, 12u8, 71u8, 187u8, 73u8, 215u8, 93u8, 222u8, + 102u8, 5u8, 113u8, 6u8, 170u8, 95u8, 228u8, 28u8, 58u8, 109u8, 62u8, + 3u8, 125u8, 211u8, 139u8, 194u8, 30u8, 151u8, 147u8, 47u8, 205u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The number of blocks over which an auction may be retroactively ended."] + pub fn ending_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Auctions", + "EndingPeriod", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The length of each sample to take during the ending period."] + #[doc = ""] + #[doc = " `EndingPeriod` / `SampleLength` = Total # of Samples"] + pub fn sample_length(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Auctions", + "SampleLength", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + pub fn slot_range_count( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Auctions", + "SlotRangeCount", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + pub fn lease_periods_per_slot( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Auctions", + "LeasePeriodsPerSlot", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod crowdloan { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::polkadot_runtime_common::crowdloan::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Create { + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + #[codec(compact)] + pub cap: ::core::primitive::u128, + #[codec(compact)] + pub first_period: ::core::primitive::u32, + #[codec(compact)] + pub last_period: ::core::primitive::u32, + #[codec(compact)] + pub end: ::core::primitive::u32, + pub verifier: ::core::option::Option, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Contribute { + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + #[codec(compact)] + pub value: ::core::primitive::u128, + pub signature: ::core::option::Option, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Withdraw { + pub who: ::subxt::utils::AccountId32, + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Refund { + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Dissolve { + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Edit { + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + #[codec(compact)] + pub cap: ::core::primitive::u128, + #[codec(compact)] + pub first_period: ::core::primitive::u32, + #[codec(compact)] + pub last_period: ::core::primitive::u32, + #[codec(compact)] + pub end: ::core::primitive::u32, + pub verifier: ::core::option::Option, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddMemo { + pub index: runtime_types::polkadot_parachain::primitives::Id, + pub memo: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Poke { + pub index: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ContributeAll { + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + pub signature: ::core::option::Option, + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Create a new crowdloaning campaign for a parachain slot with the given lease period range."] + #[doc = ""] + #[doc = "This applies a lock to your parachain configuration, ensuring that it cannot be changed"] + #[doc = "by the parachain manager."] + pub fn create( + &self, + index: runtime_types::polkadot_parachain::primitives::Id, + cap: ::core::primitive::u128, + first_period: ::core::primitive::u32, + last_period: ::core::primitive::u32, + end: ::core::primitive::u32, + verifier: ::core::option::Option, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Crowdloan", + "create", + Create { + index, + cap, + first_period, + last_period, + end, + verifier, + }, + [ + 78u8, 52u8, 156u8, 23u8, 104u8, 251u8, 20u8, 233u8, 42u8, 231u8, 16u8, + 192u8, 164u8, 68u8, 98u8, 129u8, 88u8, 126u8, 123u8, 4u8, 210u8, 161u8, + 190u8, 90u8, 67u8, 235u8, 74u8, 184u8, 180u8, 197u8, 248u8, 238u8, + ], + ) + } + #[doc = "Contribute to a crowd sale. This will transfer some balance over to fund a parachain"] + #[doc = "slot. It will be withdrawable when the crowdloan has ended and the funds are unused."] + pub fn contribute( + &self, + index: runtime_types::polkadot_parachain::primitives::Id, + value: ::core::primitive::u128, + signature: ::core::option::Option, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Crowdloan", + "contribute", + Contribute { + index, + value, + signature, + }, + [ + 159u8, 180u8, 248u8, 203u8, 128u8, 231u8, 28u8, 84u8, 14u8, 214u8, + 69u8, 217u8, 62u8, 201u8, 169u8, 160u8, 45u8, 160u8, 125u8, 255u8, + 95u8, 140u8, 58u8, 3u8, 224u8, 157u8, 199u8, 229u8, 72u8, 40u8, 218u8, + 55u8, + ], + ) + } + #[doc = "Withdraw full balance of a specific contributor."] + #[doc = ""] + #[doc = "Origin must be signed, but can come from anyone."] + #[doc = ""] + #[doc = "The fund must be either in, or ready for, retirement. For a fund to be *in* retirement, then the retirement"] + #[doc = "flag must be set. For a fund to be ready for retirement, then:"] + #[doc = "- it must not already be in retirement;"] + #[doc = "- the amount of raised funds must be bigger than the _free_ balance of the account;"] + #[doc = "- and either:"] + #[doc = " - the block number must be at least `end`; or"] + #[doc = " - the current lease period must be greater than the fund's `last_period`."] + #[doc = ""] + #[doc = "In this case, the fund's retirement flag is set and its `end` is reset to the current block"] + #[doc = "number."] + #[doc = ""] + #[doc = "- `who`: The account whose contribution should be withdrawn."] + #[doc = "- `index`: The parachain to whose crowdloan the contribution was made."] + pub fn withdraw( + &self, + who: ::subxt::utils::AccountId32, + index: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Crowdloan", + "withdraw", + Withdraw { who, index }, + [ + 147u8, 177u8, 116u8, 152u8, 9u8, 102u8, 4u8, 201u8, 204u8, 145u8, + 104u8, 226u8, 86u8, 211u8, 66u8, 109u8, 109u8, 139u8, 229u8, 97u8, + 215u8, 101u8, 255u8, 181u8, 121u8, 139u8, 165u8, 169u8, 112u8, 173u8, + 213u8, 121u8, + ], + ) + } + #[doc = "Automatically refund contributors of an ended crowdloan."] + #[doc = "Due to weight restrictions, this function may need to be called multiple"] + #[doc = "times to fully refund all users. We will refund `RemoveKeysLimit` users at a time."] + #[doc = ""] + #[doc = "Origin must be signed, but can come from anyone."] + pub fn refund( + &self, + index: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Crowdloan", + "refund", + Refund { index }, + [ + 223u8, 64u8, 5u8, 135u8, 15u8, 234u8, 60u8, 114u8, 199u8, 216u8, 73u8, + 165u8, 198u8, 34u8, 140u8, 142u8, 214u8, 254u8, 203u8, 163u8, 224u8, + 120u8, 104u8, 54u8, 12u8, 126u8, 72u8, 147u8, 20u8, 180u8, 251u8, + 208u8, + ], + ) + } + #[doc = "Remove a fund after the retirement period has ended and all funds have been returned."] + pub fn dissolve( + &self, + index: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Crowdloan", + "dissolve", + Dissolve { index }, + [ + 100u8, 67u8, 105u8, 3u8, 213u8, 149u8, 201u8, 146u8, 241u8, 62u8, 31u8, + 108u8, 58u8, 30u8, 241u8, 141u8, 134u8, 115u8, 56u8, 131u8, 60u8, 75u8, + 143u8, 227u8, 11u8, 32u8, 31u8, 230u8, 165u8, 227u8, 170u8, 126u8, + ], + ) + } + #[doc = "Edit the configuration for an in-progress crowdloan."] + #[doc = ""] + #[doc = "Can only be called by Root origin."] + pub fn edit( + &self, + index: runtime_types::polkadot_parachain::primitives::Id, + cap: ::core::primitive::u128, + first_period: ::core::primitive::u32, + last_period: ::core::primitive::u32, + end: ::core::primitive::u32, + verifier: ::core::option::Option, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Crowdloan", + "edit", + Edit { + index, + cap, + first_period, + last_period, + end, + verifier, + }, + [ + 222u8, 124u8, 94u8, 221u8, 36u8, 183u8, 67u8, 114u8, 198u8, 107u8, + 154u8, 174u8, 142u8, 47u8, 3u8, 181u8, 72u8, 29u8, 2u8, 83u8, 81u8, + 47u8, 168u8, 142u8, 139u8, 63u8, 136u8, 191u8, 41u8, 252u8, 221u8, + 56u8, + ], + ) + } + #[doc = "Add an optional memo to an existing crowdloan contribution."] + #[doc = ""] + #[doc = "Origin must be Signed, and the user must have contributed to the crowdloan."] + pub fn add_memo( + &self, + index: runtime_types::polkadot_parachain::primitives::Id, + memo: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Crowdloan", + "add_memo", + AddMemo { index, memo }, + [ + 104u8, 199u8, 143u8, 251u8, 28u8, 49u8, 144u8, 186u8, 83u8, 108u8, + 26u8, 127u8, 22u8, 141u8, 48u8, 62u8, 194u8, 193u8, 97u8, 10u8, 84u8, + 89u8, 236u8, 191u8, 40u8, 8u8, 1u8, 250u8, 112u8, 165u8, 221u8, 112u8, + ], + ) + } + #[doc = "Poke the fund into `NewRaise`"] + #[doc = ""] + #[doc = "Origin must be Signed, and the fund has non-zero raise."] + pub fn poke( + &self, + index: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Crowdloan", + "poke", + Poke { index }, + [ + 118u8, 60u8, 131u8, 17u8, 27u8, 153u8, 57u8, 24u8, 191u8, 211u8, 101u8, + 123u8, 34u8, 145u8, 193u8, 113u8, 244u8, 162u8, 148u8, 143u8, 81u8, + 86u8, 136u8, 23u8, 48u8, 185u8, 52u8, 60u8, 216u8, 243u8, 63u8, 102u8, + ], + ) + } + #[doc = "Contribute your entire balance to a crowd sale. This will transfer the entire balance of a user over to fund a parachain"] + #[doc = "slot. It will be withdrawable when the crowdloan has ended and the funds are unused."] + pub fn contribute_all( + &self, + index: runtime_types::polkadot_parachain::primitives::Id, + signature: ::core::option::Option, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Crowdloan", + "contribute_all", + ContributeAll { index, signature }, + [ + 94u8, 61u8, 105u8, 107u8, 204u8, 18u8, 223u8, 242u8, 19u8, 162u8, + 205u8, 130u8, 203u8, 73u8, 42u8, 85u8, 208u8, 157u8, 115u8, 112u8, + 168u8, 10u8, 163u8, 80u8, 222u8, 71u8, 23u8, 194u8, 142u8, 4u8, 82u8, + 253u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::polkadot_runtime_common::crowdloan::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Create a new crowdloaning campaign."] + pub struct Created { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + } + impl ::subxt::events::StaticEvent for Created { + const PALLET: &'static str = "Crowdloan"; + const EVENT: &'static str = "Created"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contributed to a crowd sale."] + pub struct Contributed { + pub who: ::subxt::utils::AccountId32, + pub fund_index: runtime_types::polkadot_parachain::primitives::Id, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Contributed { + const PALLET: &'static str = "Crowdloan"; + const EVENT: &'static str = "Contributed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Withdrew full balance of a contributor."] + pub struct Withdrew { + pub who: ::subxt::utils::AccountId32, + pub fund_index: runtime_types::polkadot_parachain::primitives::Id, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Withdrew { + const PALLET: &'static str = "Crowdloan"; + const EVENT: &'static str = "Withdrew"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The loans in a fund have been partially dissolved, i.e. there are some left"] + #[doc = "over child keys that still need to be killed."] + pub struct PartiallyRefunded { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + } + impl ::subxt::events::StaticEvent for PartiallyRefunded { + const PALLET: &'static str = "Crowdloan"; + const EVENT: &'static str = "PartiallyRefunded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "All loans in a fund have been refunded."] + pub struct AllRefunded { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + } + impl ::subxt::events::StaticEvent for AllRefunded { + const PALLET: &'static str = "Crowdloan"; + const EVENT: &'static str = "AllRefunded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Fund is dissolved."] + pub struct Dissolved { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + } + impl ::subxt::events::StaticEvent for Dissolved { + const PALLET: &'static str = "Crowdloan"; + const EVENT: &'static str = "Dissolved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The result of trying to submit a new bid to the Slots pallet."] + pub struct HandleBidResult { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + } + impl ::subxt::events::StaticEvent for HandleBidResult { + const PALLET: &'static str = "Crowdloan"; + const EVENT: &'static str = "HandleBidResult"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The configuration to a crowdloan has been edited."] + pub struct Edited { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + } + impl ::subxt::events::StaticEvent for Edited { + const PALLET: &'static str = "Crowdloan"; + const EVENT: &'static str = "Edited"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A memo has been updated."] + pub struct MemoUpdated { + pub who: ::subxt::utils::AccountId32, + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub memo: ::std::vec::Vec<::core::primitive::u8>, + } + impl ::subxt::events::StaticEvent for MemoUpdated { + const PALLET: &'static str = "Crowdloan"; + const EVENT: &'static str = "MemoUpdated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A parachain has been moved to `NewRaise`"] + pub struct AddedToNewRaise { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + } + impl ::subxt::events::StaticEvent for AddedToNewRaise { + const PALLET: &'static str = "Crowdloan"; + const EVENT: &'static str = "AddedToNewRaise"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Info on all of the funds."] + pub fn funds( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_common::crowdloan::FundInfo< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Crowdloan", + "Funds", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 231u8, 126u8, 89u8, 84u8, 167u8, 23u8, 211u8, 70u8, 203u8, 124u8, 20u8, + 162u8, 112u8, 38u8, 201u8, 207u8, 82u8, 202u8, 80u8, 228u8, 4u8, 41u8, + 95u8, 190u8, 193u8, 185u8, 178u8, 85u8, 179u8, 102u8, 53u8, 63u8, + ], + ) + } + #[doc = " Info on all of the funds."] + pub fn funds_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_common::crowdloan::FundInfo< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + ::core::primitive::u32, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Crowdloan", + "Funds", + Vec::new(), + [ + 231u8, 126u8, 89u8, 84u8, 167u8, 23u8, 211u8, 70u8, 203u8, 124u8, 20u8, + 162u8, 112u8, 38u8, 201u8, 207u8, 82u8, 202u8, 80u8, 228u8, 4u8, 41u8, + 95u8, 190u8, 193u8, 185u8, 178u8, 85u8, 179u8, 102u8, 53u8, 63u8, + ], + ) + } + #[doc = " The funds that have had additional contributions during the last block. This is used"] + #[doc = " in order to determine which funds should submit new or updated bids."] + pub fn new_raise( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Crowdloan", + "NewRaise", + vec![], + [ + 8u8, 180u8, 9u8, 197u8, 254u8, 198u8, 89u8, 112u8, 29u8, 153u8, 243u8, + 196u8, 92u8, 204u8, 135u8, 232u8, 93u8, 239u8, 147u8, 103u8, 130u8, + 28u8, 128u8, 124u8, 4u8, 236u8, 29u8, 248u8, 27u8, 165u8, 111u8, 147u8, + ], + ) + } + #[doc = " The number of auctions that have entered into their ending period so far."] + pub fn endings_count( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Crowdloan", + "EndingsCount", + vec![], + [ + 12u8, 159u8, 166u8, 75u8, 192u8, 33u8, 21u8, 244u8, 149u8, 200u8, 49u8, + 54u8, 191u8, 174u8, 202u8, 86u8, 76u8, 115u8, 189u8, 35u8, 192u8, + 175u8, 156u8, 188u8, 41u8, 23u8, 92u8, 36u8, 141u8, 235u8, 248u8, + 143u8, + ], + ) + } + #[doc = " Tracker for the next available fund index"] + pub fn next_fund_index( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Crowdloan", + "NextFundIndex", + vec![], + [ + 1u8, 215u8, 164u8, 194u8, 231u8, 34u8, 207u8, 19u8, 149u8, 187u8, 3u8, + 176u8, 194u8, 240u8, 180u8, 169u8, 214u8, 194u8, 202u8, 240u8, 209u8, + 6u8, 244u8, 46u8, 54u8, 142u8, 61u8, 220u8, 240u8, 96u8, 10u8, 168u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " `PalletId` for the crowdloan pallet. An appropriate value could be `PalletId(*b\"py/cfund\")`"] + pub fn pallet_id( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "Crowdloan", + "PalletId", + [ + 139u8, 109u8, 228u8, 151u8, 252u8, 32u8, 130u8, 69u8, 112u8, 154u8, + 174u8, 45u8, 83u8, 245u8, 51u8, 132u8, 173u8, 5u8, 186u8, 24u8, 243u8, + 9u8, 12u8, 214u8, 80u8, 74u8, 69u8, 189u8, 30u8, 94u8, 22u8, 39u8, + ], + ) + } + #[doc = " The minimum amount that may be contributed into a crowdloan. Should almost certainly be at"] + #[doc = " least `ExistentialDeposit`."] + pub fn min_contribution( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Crowdloan", + "MinContribution", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " Max number of storage keys to remove per extrinsic call."] + pub fn remove_keys_limit( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Crowdloan", + "RemoveKeysLimit", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod xcm_pallet { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_xcm::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Send { + pub dest: ::std::boxed::Box, + pub message: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TeleportAssets { + pub dest: ::std::boxed::Box, + pub beneficiary: ::std::boxed::Box, + pub assets: ::std::boxed::Box, + pub fee_asset_item: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReserveTransferAssets { + pub dest: ::std::boxed::Box, + pub beneficiary: ::std::boxed::Box, + pub assets: ::std::boxed::Box, + pub fee_asset_item: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Execute { + pub message: ::std::boxed::Box, + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceXcmVersion { + pub location: + ::std::boxed::Box, + pub xcm_version: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceDefaultXcmVersion { + pub maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceSubscribeVersionNotify { + pub location: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceUnsubscribeVersionNotify { + pub location: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct LimitedReserveTransferAssets { + pub dest: ::std::boxed::Box, + pub beneficiary: ::std::boxed::Box, + pub assets: ::std::boxed::Box, + pub fee_asset_item: ::core::primitive::u32, + pub weight_limit: runtime_types::xcm::v3::WeightLimit, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct LimitedTeleportAssets { + pub dest: ::std::boxed::Box, + pub beneficiary: ::std::boxed::Box, + pub assets: ::std::boxed::Box, + pub fee_asset_item: ::core::primitive::u32, + pub weight_limit: runtime_types::xcm::v3::WeightLimit, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceSuspension { + pub suspended: ::core::primitive::bool, + } + pub struct TransactionApi; + impl TransactionApi { + pub fn send( + &self, + dest: runtime_types::xcm::VersionedMultiLocation, + message: runtime_types::xcm::VersionedXcm, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmPallet", + "send", + Send { + dest: ::std::boxed::Box::new(dest), + message: ::std::boxed::Box::new(message), + }, + [ + 246u8, 35u8, 227u8, 112u8, 223u8, 7u8, 44u8, 186u8, 60u8, 225u8, 153u8, + 249u8, 104u8, 51u8, 123u8, 227u8, 143u8, 65u8, 232u8, 209u8, 178u8, + 104u8, 70u8, 56u8, 230u8, 14u8, 75u8, 83u8, 250u8, 160u8, 9u8, 39u8, + ], + ) + } + #[doc = "Teleport some assets from the local chain to some destination chain."] + #[doc = ""] + #[doc = "Fee payment on the destination side is made from the asset in the `assets` vector of"] + #[doc = "index `fee_asset_item`. The weight limit for fees is not provided and thus is unlimited,"] + #[doc = "with all fees taken as needed from the asset."] + #[doc = ""] + #[doc = "- `origin`: Must be capable of withdrawing the `assets` and executing XCM."] + #[doc = "- `dest`: Destination context for the assets. Will typically be `X2(Parent, Parachain(..))` to send"] + #[doc = " from parachain to parachain, or `X1(Parachain(..))` to send from relay to parachain."] + #[doc = "- `beneficiary`: A beneficiary location for the assets in the context of `dest`. Will generally be"] + #[doc = " an `AccountId32` value."] + #[doc = "- `assets`: The assets to be withdrawn. The first item should be the currency used to to pay the fee on the"] + #[doc = " `dest` side. May not be empty."] + #[doc = "- `fee_asset_item`: The index into `assets` of the item which should be used to pay"] + #[doc = " fees."] + pub fn teleport_assets( + &self, + dest: runtime_types::xcm::VersionedMultiLocation, + beneficiary: runtime_types::xcm::VersionedMultiLocation, + assets: runtime_types::xcm::VersionedMultiAssets, + fee_asset_item: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmPallet", + "teleport_assets", + TeleportAssets { + dest: ::std::boxed::Box::new(dest), + beneficiary: ::std::boxed::Box::new(beneficiary), + assets: ::std::boxed::Box::new(assets), + fee_asset_item, + }, + [ + 187u8, 42u8, 2u8, 96u8, 105u8, 125u8, 74u8, 53u8, 2u8, 21u8, 31u8, + 160u8, 201u8, 197u8, 157u8, 190u8, 40u8, 145u8, 5u8, 99u8, 194u8, 41u8, + 114u8, 60u8, 165u8, 186u8, 15u8, 226u8, 85u8, 113u8, 159u8, 136u8, + ], + ) + } + #[doc = "Transfer some assets from the local chain to the sovereign account of a destination"] + #[doc = "chain and forward a notification XCM."] + #[doc = ""] + #[doc = "Fee payment on the destination side is made from the asset in the `assets` vector of"] + #[doc = "index `fee_asset_item`. The weight limit for fees is not provided and thus is unlimited,"] + #[doc = "with all fees taken as needed from the asset."] + #[doc = ""] + #[doc = "- `origin`: Must be capable of withdrawing the `assets` and executing XCM."] + #[doc = "- `dest`: Destination context for the assets. Will typically be `X2(Parent, Parachain(..))` to send"] + #[doc = " from parachain to parachain, or `X1(Parachain(..))` to send from relay to parachain."] + #[doc = "- `beneficiary`: A beneficiary location for the assets in the context of `dest`. Will generally be"] + #[doc = " an `AccountId32` value."] + #[doc = "- `assets`: The assets to be withdrawn. This should include the assets used to pay the fee on the"] + #[doc = " `dest` side."] + #[doc = "- `fee_asset_item`: The index into `assets` of the item which should be used to pay"] + #[doc = " fees."] + pub fn reserve_transfer_assets( + &self, + dest: runtime_types::xcm::VersionedMultiLocation, + beneficiary: runtime_types::xcm::VersionedMultiLocation, + assets: runtime_types::xcm::VersionedMultiAssets, + fee_asset_item: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmPallet", + "reserve_transfer_assets", + ReserveTransferAssets { + dest: ::std::boxed::Box::new(dest), + beneficiary: ::std::boxed::Box::new(beneficiary), + assets: ::std::boxed::Box::new(assets), + fee_asset_item, + }, + [ + 249u8, 177u8, 76u8, 204u8, 186u8, 165u8, 16u8, 186u8, 129u8, 239u8, + 65u8, 252u8, 9u8, 132u8, 32u8, 164u8, 117u8, 177u8, 40u8, 21u8, 196u8, + 246u8, 147u8, 2u8, 95u8, 110u8, 68u8, 162u8, 148u8, 9u8, 59u8, 170u8, + ], + ) + } + #[doc = "Execute an XCM message from a local, signed, origin."] + #[doc = ""] + #[doc = "An event is deposited indicating whether `msg` could be executed completely or only"] + #[doc = "partially."] + #[doc = ""] + #[doc = "No more than `max_weight` will be used in its attempted execution. If this is less than the"] + #[doc = "maximum amount of weight that the message could take to be executed, then no execution"] + #[doc = "attempt will be made."] + #[doc = ""] + #[doc = "NOTE: A successful return to this does *not* imply that the `msg` was executed successfully"] + #[doc = "to completion; only that *some* of it was executed."] + pub fn execute( + &self, + message: runtime_types::xcm::VersionedXcm, + max_weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmPallet", + "execute", + Execute { + message: ::std::boxed::Box::new(message), + max_weight, + }, + [ + 102u8, 41u8, 146u8, 29u8, 241u8, 205u8, 95u8, 153u8, 228u8, 141u8, + 11u8, 228u8, 13u8, 44u8, 75u8, 204u8, 174u8, 35u8, 155u8, 104u8, 204u8, + 82u8, 239u8, 98u8, 249u8, 187u8, 193u8, 1u8, 122u8, 88u8, 162u8, 200u8, + ], + ) + } + #[doc = "Extoll that a particular destination can be communicated with through a particular"] + #[doc = "version of XCM."] + #[doc = ""] + #[doc = "- `origin`: Must be an origin specified by AdminOrigin."] + #[doc = "- `location`: The destination that is being described."] + #[doc = "- `xcm_version`: The latest version of XCM that `location` supports."] + pub fn force_xcm_version( + &self, + location: runtime_types::xcm::v3::multilocation::MultiLocation, + xcm_version: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmPallet", + "force_xcm_version", + ForceXcmVersion { + location: ::std::boxed::Box::new(location), + xcm_version, + }, + [ + 68u8, 48u8, 95u8, 61u8, 152u8, 95u8, 213u8, 126u8, 209u8, 176u8, 230u8, + 160u8, 164u8, 42u8, 128u8, 62u8, 175u8, 3u8, 161u8, 170u8, 20u8, 31u8, + 216u8, 122u8, 31u8, 77u8, 64u8, 182u8, 121u8, 41u8, 23u8, 80u8, + ], + ) + } + #[doc = "Set a safe XCM version (the version that XCM should be encoded with if the most recent"] + #[doc = "version a destination can accept is unknown)."] + #[doc = ""] + #[doc = "- `origin`: Must be an origin specified by AdminOrigin."] + #[doc = "- `maybe_xcm_version`: The default XCM encoding version, or `None` to disable."] + pub fn force_default_xcm_version( + &self, + maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmPallet", + "force_default_xcm_version", + ForceDefaultXcmVersion { maybe_xcm_version }, + [ + 38u8, 36u8, 59u8, 231u8, 18u8, 79u8, 76u8, 9u8, 200u8, 125u8, 214u8, + 166u8, 37u8, 99u8, 111u8, 161u8, 135u8, 2u8, 133u8, 157u8, 165u8, 18u8, + 152u8, 81u8, 209u8, 255u8, 137u8, 237u8, 28u8, 126u8, 224u8, 141u8, + ], + ) + } + #[doc = "Ask a location to notify us regarding their XCM version and any changes to it."] + #[doc = ""] + #[doc = "- `origin`: Must be an origin specified by AdminOrigin."] + #[doc = "- `location`: The location to which we should subscribe for XCM version notifications."] + pub fn force_subscribe_version_notify( + &self, + location: runtime_types::xcm::VersionedMultiLocation, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmPallet", + "force_subscribe_version_notify", + ForceSubscribeVersionNotify { + location: ::std::boxed::Box::new(location), + }, + [ + 236u8, 37u8, 153u8, 26u8, 174u8, 187u8, 154u8, 38u8, 179u8, 223u8, + 130u8, 32u8, 128u8, 30u8, 148u8, 229u8, 7u8, 185u8, 174u8, 9u8, 96u8, + 215u8, 189u8, 178u8, 148u8, 141u8, 249u8, 118u8, 7u8, 238u8, 1u8, 49u8, + ], + ) + } + #[doc = "Require that a particular destination should no longer notify us regarding any XCM"] + #[doc = "version changes."] + #[doc = ""] + #[doc = "- `origin`: Must be an origin specified by AdminOrigin."] + #[doc = "- `location`: The location to which we are currently subscribed for XCM version"] + #[doc = " notifications which we no longer desire."] + pub fn force_unsubscribe_version_notify( + &self, + location: runtime_types::xcm::VersionedMultiLocation, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmPallet", + "force_unsubscribe_version_notify", + ForceUnsubscribeVersionNotify { + location: ::std::boxed::Box::new(location), + }, + [ + 154u8, 169u8, 145u8, 211u8, 185u8, 71u8, 9u8, 63u8, 3u8, 158u8, 187u8, + 173u8, 115u8, 166u8, 100u8, 66u8, 12u8, 40u8, 198u8, 40u8, 213u8, + 104u8, 95u8, 183u8, 215u8, 53u8, 94u8, 158u8, 106u8, 56u8, 149u8, 52u8, + ], + ) + } + #[doc = "Transfer some assets from the local chain to the sovereign account of a destination"] + #[doc = "chain and forward a notification XCM."] + #[doc = ""] + #[doc = "Fee payment on the destination side is made from the asset in the `assets` vector of"] + #[doc = "index `fee_asset_item`, up to enough to pay for `weight_limit` of weight. If more weight"] + #[doc = "is needed than `weight_limit`, then the operation will fail and the assets send may be"] + #[doc = "at risk."] + #[doc = ""] + #[doc = "- `origin`: Must be capable of withdrawing the `assets` and executing XCM."] + #[doc = "- `dest`: Destination context for the assets. Will typically be `X2(Parent, Parachain(..))` to send"] + #[doc = " from parachain to parachain, or `X1(Parachain(..))` to send from relay to parachain."] + #[doc = "- `beneficiary`: A beneficiary location for the assets in the context of `dest`. Will generally be"] + #[doc = " an `AccountId32` value."] + #[doc = "- `assets`: The assets to be withdrawn. This should include the assets used to pay the fee on the"] + #[doc = " `dest` side."] + #[doc = "- `fee_asset_item`: The index into `assets` of the item which should be used to pay"] + #[doc = " fees."] + #[doc = "- `weight_limit`: The remote-side weight limit, if any, for the XCM fee purchase."] + pub fn limited_reserve_transfer_assets( + &self, + dest: runtime_types::xcm::VersionedMultiLocation, + beneficiary: runtime_types::xcm::VersionedMultiLocation, + assets: runtime_types::xcm::VersionedMultiAssets, + fee_asset_item: ::core::primitive::u32, + weight_limit: runtime_types::xcm::v3::WeightLimit, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmPallet", + "limited_reserve_transfer_assets", + LimitedReserveTransferAssets { + dest: ::std::boxed::Box::new(dest), + beneficiary: ::std::boxed::Box::new(beneficiary), + assets: ::std::boxed::Box::new(assets), + fee_asset_item, + weight_limit, + }, + [ + 131u8, 191u8, 89u8, 27u8, 236u8, 142u8, 130u8, 129u8, 245u8, 95u8, + 159u8, 96u8, 252u8, 80u8, 28u8, 40u8, 128u8, 55u8, 41u8, 123u8, 22u8, + 18u8, 0u8, 236u8, 77u8, 68u8, 135u8, 181u8, 40u8, 47u8, 92u8, 240u8, + ], + ) + } + #[doc = "Teleport some assets from the local chain to some destination chain."] + #[doc = ""] + #[doc = "Fee payment on the destination side is made from the asset in the `assets` vector of"] + #[doc = "index `fee_asset_item`, up to enough to pay for `weight_limit` of weight. If more weight"] + #[doc = "is needed than `weight_limit`, then the operation will fail and the assets send may be"] + #[doc = "at risk."] + #[doc = ""] + #[doc = "- `origin`: Must be capable of withdrawing the `assets` and executing XCM."] + #[doc = "- `dest`: Destination context for the assets. Will typically be `X2(Parent, Parachain(..))` to send"] + #[doc = " from parachain to parachain, or `X1(Parachain(..))` to send from relay to parachain."] + #[doc = "- `beneficiary`: A beneficiary location for the assets in the context of `dest`. Will generally be"] + #[doc = " an `AccountId32` value."] + #[doc = "- `assets`: The assets to be withdrawn. The first item should be the currency used to to pay the fee on the"] + #[doc = " `dest` side. May not be empty."] + #[doc = "- `fee_asset_item`: The index into `assets` of the item which should be used to pay"] + #[doc = " fees."] + #[doc = "- `weight_limit`: The remote-side weight limit, if any, for the XCM fee purchase."] + pub fn limited_teleport_assets( + &self, + dest: runtime_types::xcm::VersionedMultiLocation, + beneficiary: runtime_types::xcm::VersionedMultiLocation, + assets: runtime_types::xcm::VersionedMultiAssets, + fee_asset_item: ::core::primitive::u32, + weight_limit: runtime_types::xcm::v3::WeightLimit, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmPallet", + "limited_teleport_assets", + LimitedTeleportAssets { + dest: ::std::boxed::Box::new(dest), + beneficiary: ::std::boxed::Box::new(beneficiary), + assets: ::std::boxed::Box::new(assets), + fee_asset_item, + weight_limit, + }, + [ + 234u8, 19u8, 104u8, 174u8, 98u8, 159u8, 205u8, 110u8, 240u8, 78u8, + 186u8, 138u8, 236u8, 116u8, 104u8, 215u8, 57u8, 178u8, 166u8, 208u8, + 197u8, 113u8, 101u8, 56u8, 23u8, 56u8, 84u8, 14u8, 173u8, 70u8, 211u8, + 201u8, + ], + ) + } + #[doc = "Set or unset the global suspension state of the XCM executor."] + #[doc = ""] + #[doc = "- `origin`: Must be an origin specified by AdminOrigin."] + #[doc = "- `suspended`: `true` to suspend, `false` to resume."] + pub fn force_suspension( + &self, + suspended: ::core::primitive::bool, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmPallet", + "force_suspension", + ForceSuspension { suspended }, + [ + 147u8, 1u8, 117u8, 148u8, 8u8, 14u8, 53u8, 167u8, 85u8, 184u8, 25u8, + 183u8, 52u8, 197u8, 12u8, 135u8, 45u8, 88u8, 13u8, 27u8, 218u8, 31u8, + 80u8, 27u8, 183u8, 36u8, 0u8, 243u8, 235u8, 85u8, 75u8, 81u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_xcm::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Execution of an XCM message was attempted."] + #[doc = ""] + #[doc = "\\[ outcome \\]"] + pub struct Attempted(pub runtime_types::xcm::v3::traits::Outcome); + impl ::subxt::events::StaticEvent for Attempted { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "Attempted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A XCM message was sent."] + #[doc = ""] + #[doc = "\\[ origin, destination, message \\]"] + pub struct Sent( + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub runtime_types::xcm::v3::Xcm, + ); + impl ::subxt::events::StaticEvent for Sent { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "Sent"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Query response received which does not match a registered query. This may be because a"] + #[doc = "matching query was never registered, it may be because it is a duplicate response, or"] + #[doc = "because the query timed out."] + #[doc = ""] + #[doc = "\\[ origin location, id \\]"] + pub struct UnexpectedResponse( + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub ::core::primitive::u64, + ); + impl ::subxt::events::StaticEvent for UnexpectedResponse { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "UnexpectedResponse"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Query response has been received and is ready for taking with `take_response`. There is"] + #[doc = "no registered notification call."] + #[doc = ""] + #[doc = "\\[ id, response \\]"] + pub struct ResponseReady( + pub ::core::primitive::u64, + pub runtime_types::xcm::v3::Response, + ); + impl ::subxt::events::StaticEvent for ResponseReady { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "ResponseReady"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Query response has been received and query is removed. The registered notification has"] + #[doc = "been dispatched and executed successfully."] + #[doc = ""] + #[doc = "\\[ id, pallet index, call index \\]"] + pub struct Notified( + pub ::core::primitive::u64, + pub ::core::primitive::u8, + pub ::core::primitive::u8, + ); + impl ::subxt::events::StaticEvent for Notified { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "Notified"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Query response has been received and query is removed. The registered notification could"] + #[doc = "not be dispatched because the dispatch weight is greater than the maximum weight"] + #[doc = "originally budgeted by this runtime for the query result."] + #[doc = ""] + #[doc = "\\[ id, pallet index, call index, actual weight, max budgeted weight \\]"] + pub struct NotifyOverweight( + pub ::core::primitive::u64, + pub ::core::primitive::u8, + pub ::core::primitive::u8, + pub runtime_types::sp_weights::weight_v2::Weight, + pub runtime_types::sp_weights::weight_v2::Weight, + ); + impl ::subxt::events::StaticEvent for NotifyOverweight { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "NotifyOverweight"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Query response has been received and query is removed. There was a general error with"] + #[doc = "dispatching the notification call."] + #[doc = ""] + #[doc = "\\[ id, pallet index, call index \\]"] + pub struct NotifyDispatchError( + pub ::core::primitive::u64, + pub ::core::primitive::u8, + pub ::core::primitive::u8, + ); + impl ::subxt::events::StaticEvent for NotifyDispatchError { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "NotifyDispatchError"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Query response has been received and query is removed. The dispatch was unable to be"] + #[doc = "decoded into a `Call`; this might be due to dispatch function having a signature which"] + #[doc = "is not `(origin, QueryId, Response)`."] + #[doc = ""] + #[doc = "\\[ id, pallet index, call index \\]"] + pub struct NotifyDecodeFailed( + pub ::core::primitive::u64, + pub ::core::primitive::u8, + pub ::core::primitive::u8, + ); + impl ::subxt::events::StaticEvent for NotifyDecodeFailed { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "NotifyDecodeFailed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Expected query response has been received but the origin location of the response does"] + #[doc = "not match that expected. The query remains registered for a later, valid, response to"] + #[doc = "be received and acted upon."] + #[doc = ""] + #[doc = "\\[ origin location, id, expected location \\]"] + pub struct InvalidResponder( + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub ::core::primitive::u64, + pub ::core::option::Option, + ); + impl ::subxt::events::StaticEvent for InvalidResponder { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "InvalidResponder"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Expected query response has been received but the expected origin location placed in"] + #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] + #[doc = ""] + #[doc = "This is unexpected (since a location placed in storage in a previously executing"] + #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] + #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] + #[doc = "needed."] + #[doc = ""] + #[doc = "\\[ origin location, id \\]"] + pub struct InvalidResponderVersion( + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub ::core::primitive::u64, + ); + impl ::subxt::events::StaticEvent for InvalidResponderVersion { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "InvalidResponderVersion"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Received query response has been read and removed."] + #[doc = ""] + #[doc = "\\[ id \\]"] + pub struct ResponseTaken(pub ::core::primitive::u64); + impl ::subxt::events::StaticEvent for ResponseTaken { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "ResponseTaken"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some assets have been placed in an asset trap."] + #[doc = ""] + #[doc = "\\[ hash, origin, assets \\]"] + pub struct AssetsTrapped( + pub ::subxt::utils::H256, + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub runtime_types::xcm::VersionedMultiAssets, + ); + impl ::subxt::events::StaticEvent for AssetsTrapped { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "AssetsTrapped"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An XCM version change notification message has been attempted to be sent."] + #[doc = ""] + #[doc = "The cost of sending it (borne by the chain) is included."] + #[doc = ""] + #[doc = "\\[ destination, result, cost \\]"] + pub struct VersionChangeNotified( + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub ::core::primitive::u32, + pub runtime_types::xcm::v3::multiasset::MultiAssets, + ); + impl ::subxt::events::StaticEvent for VersionChangeNotified { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "VersionChangeNotified"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The supported version of a location has been changed. This might be through an"] + #[doc = "automatic notification or a manual intervention."] + #[doc = ""] + #[doc = "\\[ location, XCM version \\]"] + pub struct SupportedVersionChanged( + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub ::core::primitive::u32, + ); + impl ::subxt::events::StaticEvent for SupportedVersionChanged { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "SupportedVersionChanged"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A given location which had a version change subscription was dropped owing to an error"] + #[doc = "sending the notification to it."] + #[doc = ""] + #[doc = "\\[ location, query ID, error \\]"] + pub struct NotifyTargetSendFail( + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub ::core::primitive::u64, + pub runtime_types::xcm::v3::traits::Error, + ); + impl ::subxt::events::StaticEvent for NotifyTargetSendFail { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "NotifyTargetSendFail"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A given location which had a version change subscription was dropped owing to an error"] + #[doc = "migrating the location to our new XCM format."] + #[doc = ""] + #[doc = "\\[ location, query ID \\]"] + pub struct NotifyTargetMigrationFail( + pub runtime_types::xcm::VersionedMultiLocation, + pub ::core::primitive::u64, + ); + impl ::subxt::events::StaticEvent for NotifyTargetMigrationFail { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "NotifyTargetMigrationFail"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Expected query response has been received but the expected querier location placed in"] + #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] + #[doc = ""] + #[doc = "This is unexpected (since a location placed in storage in a previously executing"] + #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] + #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] + #[doc = "needed."] + #[doc = ""] + #[doc = "\\[ origin location, id \\]"] + pub struct InvalidQuerierVersion( + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub ::core::primitive::u64, + ); + impl ::subxt::events::StaticEvent for InvalidQuerierVersion { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "InvalidQuerierVersion"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Expected query response has been received but the querier location of the response does"] + #[doc = "not match the expected. The query remains registered for a later, valid, response to"] + #[doc = "be received and acted upon."] + #[doc = ""] + #[doc = "\\[ origin location, id, expected querier, maybe actual querier \\]"] + pub struct InvalidQuerier( + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub ::core::primitive::u64, + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub ::core::option::Option, + ); + impl ::subxt::events::StaticEvent for InvalidQuerier { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "InvalidQuerier"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A remote has requested XCM version change notification from us and we have honored it."] + #[doc = "A version information message is sent to them and its cost is included."] + #[doc = ""] + #[doc = "\\[ destination location, cost \\]"] + pub struct VersionNotifyStarted( + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub runtime_types::xcm::v3::multiasset::MultiAssets, + ); + impl ::subxt::events::StaticEvent for VersionNotifyStarted { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "VersionNotifyStarted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "We have requested that a remote chain sends us XCM version change notifications."] + #[doc = ""] + #[doc = "\\[ destination location, cost \\]"] + pub struct VersionNotifyRequested( + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub runtime_types::xcm::v3::multiasset::MultiAssets, + ); + impl ::subxt::events::StaticEvent for VersionNotifyRequested { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "VersionNotifyRequested"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "We have requested that a remote chain stops sending us XCM version change notifications."] + #[doc = ""] + #[doc = "\\[ destination location, cost \\]"] + pub struct VersionNotifyUnrequested( + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub runtime_types::xcm::v3::multiasset::MultiAssets, + ); + impl ::subxt::events::StaticEvent for VersionNotifyUnrequested { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "VersionNotifyUnrequested"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Fees were paid from a location for an operation (often for using `SendXcm`)."] + #[doc = ""] + #[doc = "\\[ paying location, fees \\]"] + pub struct FeesPaid( + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub runtime_types::xcm::v3::multiasset::MultiAssets, + ); + impl ::subxt::events::StaticEvent for FeesPaid { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "FeesPaid"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some assets have been claimed from an asset trap"] + #[doc = ""] + #[doc = "\\[ hash, origin, assets \\]"] + pub struct AssetsClaimed( + pub ::subxt::utils::H256, + pub runtime_types::xcm::v3::multilocation::MultiLocation, + pub runtime_types::xcm::VersionedMultiAssets, + ); + impl ::subxt::events::StaticEvent for AssetsClaimed { + const PALLET: &'static str = "XcmPallet"; + const EVENT: &'static str = "AssetsClaimed"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The latest available query index."] + pub fn query_counter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u64, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "QueryCounter", + vec![], + [ + 137u8, 58u8, 184u8, 88u8, 247u8, 22u8, 151u8, 64u8, 50u8, 77u8, 49u8, + 10u8, 234u8, 84u8, 213u8, 156u8, 26u8, 200u8, 214u8, 225u8, 125u8, + 231u8, 42u8, 93u8, 159u8, 168u8, 86u8, 201u8, 116u8, 153u8, 41u8, + 127u8, + ], + ) + } + #[doc = " The ongoing queries."] + pub fn queries( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u64>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_xcm::pallet::QueryStatus<::core::primitive::u32>, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "Queries", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 72u8, 239u8, 157u8, 117u8, 200u8, 28u8, 80u8, 70u8, 205u8, 253u8, + 147u8, 30u8, 130u8, 72u8, 154u8, 95u8, 183u8, 162u8, 165u8, 203u8, + 128u8, 98u8, 216u8, 172u8, 98u8, 220u8, 16u8, 236u8, 216u8, 68u8, 33u8, + 184u8, + ], + ) + } + #[doc = " The ongoing queries."] + pub fn queries_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_xcm::pallet::QueryStatus<::core::primitive::u32>, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "Queries", + Vec::new(), + [ + 72u8, 239u8, 157u8, 117u8, 200u8, 28u8, 80u8, 70u8, 205u8, 253u8, + 147u8, 30u8, 130u8, 72u8, 154u8, 95u8, 183u8, 162u8, 165u8, 203u8, + 128u8, 98u8, 216u8, 172u8, 98u8, 220u8, 16u8, 236u8, 216u8, 68u8, 33u8, + 184u8, + ], + ) + } + #[doc = " The existing asset traps."] + #[doc = ""] + #[doc = " Key is the blake2 256 hash of (origin, versioned `MultiAssets`) pair. Value is the number of"] + #[doc = " times this pair has been trapped (usually just 1 if it exists at all)."] + pub fn asset_traps( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "AssetTraps", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 4u8, 185u8, 92u8, 4u8, 7u8, 71u8, 214u8, 1u8, 141u8, 59u8, 87u8, 55u8, + 149u8, 26u8, 125u8, 8u8, 88u8, 31u8, 240u8, 138u8, 133u8, 28u8, 37u8, + 131u8, 107u8, 218u8, 86u8, 152u8, 147u8, 44u8, 19u8, 239u8, + ], + ) + } + #[doc = " The existing asset traps."] + #[doc = ""] + #[doc = " Key is the blake2 256 hash of (origin, versioned `MultiAssets`) pair. Value is the number of"] + #[doc = " times this pair has been trapped (usually just 1 if it exists at all)."] + pub fn asset_traps_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "AssetTraps", + Vec::new(), + [ + 4u8, 185u8, 92u8, 4u8, 7u8, 71u8, 214u8, 1u8, 141u8, 59u8, 87u8, 55u8, + 149u8, 26u8, 125u8, 8u8, 88u8, 31u8, 240u8, 138u8, 133u8, 28u8, 37u8, + 131u8, 107u8, 218u8, 86u8, 152u8, 147u8, 44u8, 19u8, 239u8, + ], + ) + } + #[doc = " Default version to encode XCM when latest version of destination is unknown. If `None`,"] + #[doc = " then the destinations whose XCM version is unknown are considered unreachable."] + pub fn safe_xcm_version( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "SafeXcmVersion", + vec![], + [ + 1u8, 223u8, 218u8, 204u8, 222u8, 129u8, 137u8, 237u8, 197u8, 142u8, + 233u8, 66u8, 229u8, 153u8, 138u8, 222u8, 113u8, 164u8, 135u8, 213u8, + 233u8, 34u8, 24u8, 23u8, 215u8, 59u8, 40u8, 188u8, 45u8, 244u8, 205u8, + 199u8, + ], + ) + } + #[doc = " The Latest versions that we know various locations support."] + pub fn supported_version( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "SupportedVersion", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 16u8, 172u8, 183u8, 14u8, 63u8, 199u8, 42u8, 204u8, 218u8, 197u8, + 129u8, 40u8, 32u8, 213u8, 50u8, 170u8, 231u8, 123u8, 188u8, 83u8, + 250u8, 148u8, 133u8, 78u8, 249u8, 33u8, 122u8, 55u8, 22u8, 179u8, 98u8, + 113u8, + ], + ) + } + #[doc = " The Latest versions that we know various locations support."] + pub fn supported_version_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "SupportedVersion", + Vec::new(), + [ + 16u8, 172u8, 183u8, 14u8, 63u8, 199u8, 42u8, 204u8, 218u8, 197u8, + 129u8, 40u8, 32u8, 213u8, 50u8, 170u8, 231u8, 123u8, 188u8, 83u8, + 250u8, 148u8, 133u8, 78u8, 249u8, 33u8, 122u8, 55u8, 22u8, 179u8, 98u8, + 113u8, + ], + ) + } + #[doc = " All locations that we have requested version notifications from."] + pub fn version_notifiers( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u64, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "VersionNotifiers", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 137u8, 87u8, 59u8, 219u8, 207u8, 188u8, 145u8, 38u8, 197u8, 219u8, + 197u8, 179u8, 102u8, 25u8, 184u8, 83u8, 31u8, 63u8, 251u8, 21u8, 211u8, + 124u8, 23u8, 40u8, 4u8, 43u8, 113u8, 158u8, 233u8, 192u8, 38u8, 177u8, + ], + ) + } + #[doc = " All locations that we have requested version notifications from."] + pub fn version_notifiers_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u64, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "VersionNotifiers", + Vec::new(), + [ + 137u8, 87u8, 59u8, 219u8, 207u8, 188u8, 145u8, 38u8, 197u8, 219u8, + 197u8, 179u8, 102u8, 25u8, 184u8, 83u8, 31u8, 63u8, 251u8, 21u8, 211u8, + 124u8, 23u8, 40u8, 4u8, 43u8, 113u8, 158u8, 233u8, 192u8, 38u8, 177u8, + ], + ) + } + #[doc = " The target locations that are subscribed to our version changes, as well as the most recent"] + #[doc = " of our versions we informed them of."] + pub fn version_notify_targets( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ( + ::core::primitive::u64, + runtime_types::sp_weights::weight_v2::Weight, + ::core::primitive::u32, + ), + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "VersionNotifyTargets", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 138u8, 26u8, 26u8, 108u8, 21u8, 255u8, 143u8, 241u8, 15u8, 163u8, 22u8, + 155u8, 221u8, 63u8, 58u8, 104u8, 4u8, 186u8, 66u8, 178u8, 67u8, 178u8, + 220u8, 78u8, 1u8, 77u8, 45u8, 214u8, 98u8, 240u8, 120u8, 254u8, + ], + ) + } + #[doc = " The target locations that are subscribed to our version changes, as well as the most recent"] + #[doc = " of our versions we informed them of."] + pub fn version_notify_targets_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ( + ::core::primitive::u64, + runtime_types::sp_weights::weight_v2::Weight, + ::core::primitive::u32, + ), + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "VersionNotifyTargets", + Vec::new(), + [ + 138u8, 26u8, 26u8, 108u8, 21u8, 255u8, 143u8, 241u8, 15u8, 163u8, 22u8, + 155u8, 221u8, 63u8, 58u8, 104u8, 4u8, 186u8, 66u8, 178u8, 67u8, 178u8, + 220u8, 78u8, 1u8, 77u8, 45u8, 214u8, 98u8, 240u8, 120u8, 254u8, + ], + ) + } + #[doc = " Destinations whose latest XCM version we would like to know. Duplicates not allowed, and"] + #[doc = " the `u32` counter is the number of times that a send to the destination has been attempted,"] + #[doc = " which is used as a prioritization."] + pub fn version_discovery_queue( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + runtime_types::xcm::VersionedMultiLocation, + ::core::primitive::u32, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "VersionDiscoveryQueue", + vec![], + [ + 134u8, 60u8, 255u8, 145u8, 139u8, 29u8, 38u8, 47u8, 209u8, 218u8, + 127u8, 123u8, 2u8, 196u8, 52u8, 99u8, 143u8, 112u8, 0u8, 133u8, 99u8, + 218u8, 187u8, 171u8, 175u8, 153u8, 149u8, 1u8, 57u8, 45u8, 118u8, 79u8, + ], + ) + } + #[doc = " The current migration's stage, if any."] + pub fn current_migration( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_xcm::pallet::VersionMigrationStage, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "CurrentMigration", + vec![], + [ + 137u8, 144u8, 168u8, 185u8, 158u8, 90u8, 127u8, 243u8, 227u8, 134u8, + 150u8, 73u8, 15u8, 99u8, 23u8, 47u8, 68u8, 18u8, 39u8, 16u8, 24u8, + 43u8, 161u8, 56u8, 66u8, 111u8, 16u8, 7u8, 252u8, 125u8, 100u8, 225u8, + ], + ) + } + #[doc = " Fungible assets which we know are locked on a remote chain."] + pub fn remote_locked_fungibles( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _2: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "RemoteLockedFungibles", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_2.borrow()), + ], + [ + 26u8, 71u8, 1u8, 2u8, 214u8, 3u8, 65u8, 62u8, 133u8, 85u8, 151u8, + 180u8, 225u8, 180u8, 40u8, 49u8, 133u8, 107u8, 190u8, 102u8, 1u8, + 111u8, 144u8, 240u8, 0u8, 209u8, 198u8, 76u8, 143u8, 121u8, 2u8, 118u8, + ], + ) + } + #[doc = " Fungible assets which we know are locked on a remote chain."] + pub fn remote_locked_fungibles_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "RemoteLockedFungibles", + Vec::new(), + [ + 26u8, 71u8, 1u8, 2u8, 214u8, 3u8, 65u8, 62u8, 133u8, 85u8, 151u8, + 180u8, 225u8, 180u8, 40u8, 49u8, 133u8, 107u8, 190u8, 102u8, 1u8, + 111u8, 144u8, 240u8, 0u8, 209u8, 198u8, 76u8, 143u8, 121u8, 2u8, 118u8, + ], + ) + } + #[doc = " Fungible assets which we know are locked on this chain."] + pub fn locked_fungibles( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u128, + runtime_types::xcm::VersionedMultiLocation, + )>, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "LockedFungibles", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 158u8, 103u8, 153u8, 216u8, 19u8, 122u8, 251u8, 183u8, 15u8, 143u8, + 161u8, 105u8, 168u8, 100u8, 76u8, 220u8, 56u8, 129u8, 185u8, 251u8, + 220u8, 166u8, 3u8, 100u8, 48u8, 147u8, 123u8, 94u8, 226u8, 112u8, 59u8, + 171u8, + ], + ) + } + #[doc = " Fungible assets which we know are locked on this chain."] + pub fn locked_fungibles_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u128, + runtime_types::xcm::VersionedMultiLocation, + )>, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "LockedFungibles", + Vec::new(), + [ + 158u8, 103u8, 153u8, 216u8, 19u8, 122u8, 251u8, 183u8, 15u8, 143u8, + 161u8, 105u8, 168u8, 100u8, 76u8, 220u8, 56u8, 129u8, 185u8, 251u8, + 220u8, 166u8, 3u8, 100u8, 48u8, 147u8, 123u8, 94u8, 226u8, 112u8, 59u8, + 171u8, + ], + ) + } + #[doc = " Global suspension state of the XCM executor."] + pub fn xcm_execution_suspended( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "XcmPallet", + "XcmExecutionSuspended", + vec![], + [ + 182u8, 20u8, 35u8, 10u8, 65u8, 208u8, 52u8, 141u8, 158u8, 23u8, 46u8, + 221u8, 172u8, 110u8, 39u8, 121u8, 106u8, 104u8, 19u8, 64u8, 90u8, + 137u8, 173u8, 31u8, 112u8, 219u8, 64u8, 238u8, 125u8, 242u8, 24u8, + 107u8, + ], + ) + } + } + } + } + pub mod runtime_types { + use super::runtime_types; + pub mod bounded_collections { + use super::runtime_types; + pub mod bounded_btree_map { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BoundedBTreeMap<_0, _1>(pub ::subxt::utils::KeyedVec<_0, _1>); + } + pub mod bounded_vec { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BoundedVec<_0>(pub ::std::vec::Vec<_0>); + } + pub mod weak_bounded_vec { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct WeakBoundedVec<_0>(pub ::std::vec::Vec<_0>); + } + } + pub mod finality_grandpa { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Equivocation<_0, _1, _2> { + pub round_number: ::core::primitive::u64, + pub identity: _0, + pub first: (_1, _2), + pub second: (_1, _2), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Precommit<_0, _1> { + pub target_hash: _0, + pub target_number: _1, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Prevote<_0, _1> { + pub target_hash: _0, + pub target_number: _1, + } + } + pub mod frame_support { + use super::runtime_types; + pub mod dispatch { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum DispatchClass { + #[codec(index = 0)] + Normal, + #[codec(index = 1)] + Operational, + #[codec(index = 2)] + Mandatory, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DispatchInfo { + pub weight: runtime_types::sp_weights::weight_v2::Weight, + pub class: runtime_types::frame_support::dispatch::DispatchClass, + pub pays_fee: runtime_types::frame_support::dispatch::Pays, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Pays { + #[codec(index = 0)] + Yes, + #[codec(index = 1)] + No, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PerDispatchClass<_0> { + pub normal: _0, + pub operational: _0, + pub mandatory: _0, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PostDispatchInfo { + pub actual_weight: + ::core::option::Option, + pub pays_fee: runtime_types::frame_support::dispatch::Pays, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum RawOrigin<_0> { + #[codec(index = 0)] + Root, + #[codec(index = 1)] + Signed(_0), + #[codec(index = 2)] + None, + } + } + pub mod traits { + use super::runtime_types; + pub mod misc { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct WrapperOpaque<_0>( + #[codec(compact)] pub ::core::primitive::u32, + pub _0, + ); + } + pub mod preimages { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Bounded<_0> { + #[codec(index = 0)] + Legacy { + hash: ::subxt::utils::H256, + }, + #[codec(index = 1)] + Inline( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 2)] + Lookup { + hash: ::subxt::utils::H256, + len: ::core::primitive::u32, + }, + __Ignore(::core::marker::PhantomData<_0>), + } + } + pub mod schedule { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum DispatchTime<_0> { + #[codec(index = 0)] + At(_0), + #[codec(index = 1)] + After(_0), + } + } + pub mod tokens { + use super::runtime_types; + pub mod misc { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum BalanceStatus { + #[codec(index = 0)] + Free, + #[codec(index = 1)] + Reserved, + } + } + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Releases { + pub struct PalletId(pub [::core::primitive::u8; 8usize]); + } + pub mod frame_system { + use super::runtime_types; + pub mod extensions { + use super::runtime_types; + pub mod check_genesis { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckGenesis; + } + pub mod check_mortality { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckMortality(pub runtime_types::sp_runtime::generic::era::Era); + } + pub mod check_non_zero_sender { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckNonZeroSender; + } + pub mod check_nonce { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckNonce(#[codec(compact)] pub ::core::primitive::u32); + } + pub mod check_spec_version { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckSpecVersion; + } + pub mod check_tx_version { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckTxVersion; + } + pub mod check_weight { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckWeight; + } + } + pub mod limits { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BlockLength { + pub max: runtime_types::frame_support::dispatch::PerDispatchClass< + ::core::primitive::u32, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BlockWeights { + pub base_block: runtime_types::sp_weights::weight_v2::Weight, + pub max_block: runtime_types::sp_weights::weight_v2::Weight, + pub per_class: runtime_types::frame_support::dispatch::PerDispatchClass< + runtime_types::frame_system::limits::WeightsPerClass, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct WeightsPerClass { + pub base_extrinsic: runtime_types::sp_weights::weight_v2::Weight, + pub max_extrinsic: + ::core::option::Option, + pub max_total: + ::core::option::Option, + pub reserved: + ::core::option::Option, + } + } + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub enum Call { + #[codec(index = 0)] + #[doc = "Make some on-chain remark."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(1)`"] + remark { + remark: ::std::vec::Vec<::core::primitive::u8>, + }, + #[codec(index = 1)] + #[doc = "Set the number of pages in the WebAssembly environment's heap."] + set_heap_pages { pages: ::core::primitive::u64 }, + #[codec(index = 2)] + #[doc = "Set the new runtime code."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(C + S)` where `C` length of `code` and `S` complexity of `can_set_code`"] + set_code { + code: ::std::vec::Vec<::core::primitive::u8>, + }, + #[codec(index = 3)] + #[doc = "Set the new runtime code without doing any checks of the given `code`."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(C)` where `C` length of `code`"] + set_code_without_checks { + code: ::std::vec::Vec<::core::primitive::u8>, + }, + #[codec(index = 4)] + #[doc = "Set some items of storage."] + set_storage { + items: ::std::vec::Vec<( + ::std::vec::Vec<::core::primitive::u8>, + ::std::vec::Vec<::core::primitive::u8>, + )>, + }, + #[codec(index = 5)] + #[doc = "Kill some items from storage."] + kill_storage { + keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + }, + #[codec(index = 6)] + #[doc = "Kill all storage items with a key that starts with the given prefix."] + #[doc = ""] + #[doc = "**NOTE:** We rely on the Root origin to provide us the number of subkeys under"] + #[doc = "the prefix we are removing to accurately calculate the weight of this function."] + kill_prefix { + prefix: ::std::vec::Vec<::core::primitive::u8>, + subkeys: ::core::primitive::u32, + }, + #[codec(index = 7)] + #[doc = "Make some on-chain remark and emit event."] + remark_with_event { + remark: ::std::vec::Vec<::core::primitive::u8>, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Error for the System pallet"] + pub enum Error { + #[codec(index = 0)] + #[doc = "The name of specification does not match between the current runtime"] + #[doc = "and the new runtime."] + InvalidSpecName, + #[codec(index = 1)] + #[doc = "The specification version is not allowed to decrease between the current runtime"] + #[doc = "and the new runtime."] + SpecVersionNeedsToIncrease, + #[codec(index = 2)] + #[doc = "Failed to extract the runtime version from the new runtime."] + #[doc = ""] + #[doc = "Either calling `Core_version` or decoding `RuntimeVersion` failed."] + FailedToExtractRuntimeVersion, + #[codec(index = 3)] + #[doc = "Suicide called when the account has non-default composite data."] + NonDefaultComposite, + #[codec(index = 4)] + #[doc = "There is a non-zero reference count preventing the account from being purged."] + NonZeroRefCount, + #[codec(index = 5)] + #[doc = "The origin filter prevent the call to be dispatched."] + CallFiltered, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Event for the System pallet."] + pub enum Event { + #[codec(index = 0)] + #[doc = "An extrinsic completed successfully."] + ExtrinsicSuccess { + dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, + }, + #[codec(index = 1)] + #[doc = "An extrinsic failed."] + ExtrinsicFailed { + dispatch_error: runtime_types::sp_runtime::DispatchError, + dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, + }, + #[codec(index = 2)] + #[doc = "`:code` was updated."] + CodeUpdated, + #[codec(index = 3)] + #[doc = "A new account was created."] + NewAccount { + account: ::subxt::utils::AccountId32, + }, + #[codec(index = 4)] + #[doc = "An account was reaped."] + KilledAccount { + account: ::subxt::utils::AccountId32, + }, + #[codec(index = 5)] + #[doc = "On on-chain remark happened."] + Remarked { + sender: ::subxt::utils::AccountId32, + hash: ::subxt::utils::H256, + }, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AccountInfo<_0, _1> { + pub nonce: _0, + pub consumers: _0, + pub providers: _0, + pub sufficients: _0, + pub data: _1, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct EventRecord<_0, _1> { + pub phase: runtime_types::frame_system::Phase, + pub event: _0, + pub topics: ::std::vec::Vec<_1>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct LastRuntimeUpgradeInfo { + #[codec(compact)] + pub spec_version: ::core::primitive::u32, + pub spec_name: ::std::string::String, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Phase { #[codec(index = 0)] - V1_0_0, + ApplyExtrinsic(::core::primitive::u32), #[codec(index = 1)] - V2_0_0, + Finalization, + #[codec(index = 2)] + Initialization, + } + } + pub mod pallet_babe { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub enum Call { + #[codec(index = 0)] + #[doc = "Report authority equivocation/misbehavior. This method will verify"] + #[doc = "the equivocation proof and validate the given key ownership proof"] + #[doc = "against the extracted offender. If both are valid, the offence will"] + #[doc = "be reported."] + report_equivocation { + equivocation_proof: ::std::boxed::Box< + runtime_types::sp_consensus_slots::EquivocationProof< + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + runtime_types::sp_consensus_babe::app::Public, + >, + >, + key_owner_proof: runtime_types::sp_session::MembershipProof, + }, + #[codec(index = 1)] + #[doc = "Report authority equivocation/misbehavior. This method will verify"] + #[doc = "the equivocation proof and validate the given key ownership proof"] + #[doc = "against the extracted offender. If both are valid, the offence will"] + #[doc = "be reported."] + #[doc = "This extrinsic must be called unsigned and it is expected that only"] + #[doc = "block authors will call it (validated in `ValidateUnsigned`), as such"] + #[doc = "if the block author is defined it will be defined as the equivocation"] + #[doc = "reporter."] + report_equivocation_unsigned { + equivocation_proof: ::std::boxed::Box< + runtime_types::sp_consensus_slots::EquivocationProof< + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + runtime_types::sp_consensus_babe::app::Public, + >, + >, + key_owner_proof: runtime_types::sp_session::MembershipProof, + }, + #[codec(index = 2)] + #[doc = "Plan an epoch config change. The epoch config change is recorded and will be enacted on"] + #[doc = "the next call to `enact_epoch_change`. The config will be activated one epoch after."] + #[doc = "Multiple calls to this method will replace any existing planned config change that had"] + #[doc = "not been enacted yet."] + plan_config_change { + config: runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub enum Error { + #[codec(index = 0)] + #[doc = "An equivocation proof provided as part of an equivocation report is invalid."] + InvalidEquivocationProof, + #[codec(index = 1)] + #[doc = "A key ownership proof provided as part of an equivocation report is invalid."] + InvalidKeyOwnershipProof, + #[codec(index = 2)] + #[doc = "A given equivocation report is valid but already previously reported."] + DuplicateOffenceReport, + #[codec(index = 3)] + #[doc = "Submitted configuration is invalid."] + InvalidConfiguration, + } } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReserveData<_0, _1> { - pub id: _0, - pub amount: _1, + } + pub mod pallet_bags_list { + use super::runtime_types; + pub mod list { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Bag { + pub head: ::core::option::Option<::subxt::utils::AccountId32>, + pub tail: ::core::option::Option<::subxt::utils::AccountId32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum ListError { + #[codec(index = 0)] + Duplicate, + #[codec(index = 1)] + NotHeavier, + #[codec(index = 2)] + NotInSameBag, + #[codec(index = 3)] + NodeNotFound, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Node { + pub id: ::subxt::utils::AccountId32, + pub prev: ::core::option::Option<::subxt::utils::AccountId32>, + pub next: ::core::option::Option<::subxt::utils::AccountId32>, + pub bag_upper: ::core::primitive::u64, + pub score: ::core::primitive::u64, + } + } + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub enum Call { + #[codec(index = 0)] + #[doc = "Declare that some `dislocated` account has, through rewards or penalties, sufficiently"] + #[doc = "changed its score that it should properly fall into a different bag than its current"] + #[doc = "one."] + #[doc = ""] + #[doc = "Anyone can call this function about any potentially dislocated account."] + #[doc = ""] + #[doc = "Will always update the stored score of `dislocated` to the correct score, based on"] + #[doc = "`ScoreProvider`."] + #[doc = ""] + #[doc = "If `dislocated` does not exists, it returns an error."] + rebag { + dislocated: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + }, + #[codec(index = 1)] + #[doc = "Move the caller's Id directly in front of `lighter`."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and can only be called by the Id of"] + #[doc = "the account going in front of `lighter`."] + #[doc = ""] + #[doc = "Only works if"] + #[doc = "- both nodes are within the same bag,"] + #[doc = "- and `origin` has a greater `Score` than `lighter`."] + put_in_front_of { + lighter: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub enum Error { + #[codec(index = 0)] + #[doc = "A error in the list interface implementation."] + List(runtime_types::pallet_bags_list::list::ListError), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub enum Event { + #[codec(index = 0)] + #[doc = "Moved an account from one bag to another."] + Rebagged { + who: ::subxt::utils::AccountId32, + from: ::core::primitive::u64, + to: ::core::primitive::u64, + }, + #[codec(index = 1)] + #[doc = "Updated the score of some account to the given amount."] + ScoreUpdated { + who: ::subxt::utils::AccountId32, + new_score: ::core::primitive::u64, + }, + } + } + } + pub mod pallet_balances { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub enum Call { + #[codec(index = 0)] + #[doc = "Transfer some liquid free balance to another account."] + #[doc = ""] + #[doc = "`transfer_allow_death` will set the `FreeBalance` of the sender and receiver."] + #[doc = "If the sender's account is below the existential deposit as a result"] + #[doc = "of the transfer, the account will be reaped."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be `Signed` by the transactor."] + transfer_allow_death { + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + value: ::core::primitive::u128, + }, + #[codec(index = 1)] + #[doc = "Set the regular balance of a given account; it also takes a reserved balance but this"] + #[doc = "must be the same as the account's current reserved balance."] + #[doc = ""] + #[doc = "The dispatch origin for this call is `root`."] + #[doc = ""] + #[doc = "WARNING: This call is DEPRECATED! Use `force_set_balance` instead."] + set_balance_deprecated { + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + new_free: ::core::primitive::u128, + #[codec(compact)] + old_reserved: ::core::primitive::u128, + }, + #[codec(index = 2)] + #[doc = "Exactly as `transfer_allow_death`, except the origin must be root and the source account"] + #[doc = "may be specified."] + force_transfer { + source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + value: ::core::primitive::u128, + }, + #[codec(index = 3)] + #[doc = "Same as the [`transfer_allow_death`] call, but with a check that the transfer will not"] + #[doc = "kill the origin account."] + #[doc = ""] + #[doc = "99% of the time you want [`transfer_allow_death`] instead."] + #[doc = ""] + #[doc = "[`transfer_allow_death`]: struct.Pallet.html#method.transfer"] + transfer_keep_alive { + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + value: ::core::primitive::u128, + }, + #[codec(index = 4)] + #[doc = "Transfer the entire transferable balance from the caller account."] + #[doc = ""] + #[doc = "NOTE: This function only attempts to transfer _transferable_ balances. This means that"] + #[doc = "any locked, reserved, or existential deposits (when `keep_alive` is `true`), will not be"] + #[doc = "transferred by this function. To ensure that this function results in a killed account,"] + #[doc = "you might need to prepare the account by removing any reference counters, storage"] + #[doc = "deposits, etc..."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be Signed."] + #[doc = ""] + #[doc = "- `dest`: The recipient of the transfer."] + #[doc = "- `keep_alive`: A boolean to determine if the `transfer_all` operation should send all"] + #[doc = " of the funds the account has, causing the sender account to be killed (false), or"] + #[doc = " transfer everything except at least the existential deposit, which will guarantee to"] + #[doc = " keep the sender account alive (true)."] + transfer_all { + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + keep_alive: ::core::primitive::bool, + }, + #[codec(index = 5)] + #[doc = "Unreserve some balance from a user by force."] + #[doc = ""] + #[doc = "Can only be called by ROOT."] + force_unreserve { + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + amount: ::core::primitive::u128, + }, + #[codec(index = 6)] + #[doc = "Upgrade a specified account."] + #[doc = ""] + #[doc = "- `origin`: Must be `Signed`."] + #[doc = "- `who`: The account to be upgraded."] + #[doc = ""] + #[doc = "This will waive the transaction fee if at least all but 10% of the accounts needed to"] + #[doc = "be upgraded. (We let some not have to be upgraded just in order to allow for the"] + #[doc = "possibililty of churn)."] + upgrade_accounts { + who: ::std::vec::Vec<::subxt::utils::AccountId32>, + }, + #[codec(index = 7)] + #[doc = "Alias for `transfer_allow_death`, provided only for name-wise compatibility."] + #[doc = ""] + #[doc = "WARNING: DEPRECATED! Will be released in approximately 3 months."] + transfer { + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + value: ::core::primitive::u128, + }, + #[codec(index = 8)] + #[doc = "Set the regular balance of a given account."] + #[doc = ""] + #[doc = "The dispatch origin for this call is `root`."] + force_set_balance { + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + new_free: ::core::primitive::u128, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub enum Error { + #[codec(index = 0)] + #[doc = "Vesting balance too high to send value."] + VestingBalance, + #[codec(index = 1)] + #[doc = "Account liquidity restrictions prevent withdrawal."] + LiquidityRestrictions, + #[codec(index = 2)] + #[doc = "Balance too low to send value."] + InsufficientBalance, + #[codec(index = 3)] + #[doc = "Value too low to create account due to existential deposit."] + ExistentialDeposit, + #[codec(index = 4)] + #[doc = "Transfer/payment would kill account."] + Expendability, + #[codec(index = 5)] + #[doc = "A vesting schedule already exists for this account."] + ExistingVestingSchedule, + #[codec(index = 6)] + #[doc = "Beneficiary account must pre-exist."] + DeadAccount, + #[codec(index = 7)] + #[doc = "Number of named reserves exceed `MaxReserves`."] + TooManyReserves, + #[codec(index = 8)] + #[doc = "Number of holds exceed `MaxHolds`."] + TooManyHolds, + #[codec(index = 9)] + #[doc = "Number of freezes exceed `MaxFreezes`."] + TooManyFreezes, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub enum Event { + #[codec(index = 0)] + #[doc = "An account was created with some free balance."] + Endowed { + account: ::subxt::utils::AccountId32, + free_balance: ::core::primitive::u128, + }, + #[codec(index = 1)] + #[doc = "An account was removed whose balance was non-zero but below ExistentialDeposit,"] + #[doc = "resulting in an outright loss."] + DustLost { + account: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 2)] + #[doc = "Transfer succeeded."] + Transfer { + from: ::subxt::utils::AccountId32, + to: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 3)] + #[doc = "A balance was set by root."] + BalanceSet { + who: ::subxt::utils::AccountId32, + free: ::core::primitive::u128, + }, + #[codec(index = 4)] + #[doc = "Some balance was reserved (moved from free to reserved)."] + Reserved { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 5)] + #[doc = "Some balance was unreserved (moved from reserved to free)."] + Unreserved { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 6)] + #[doc = "Some balance was moved from the reserve of the first account to the second account."] + #[doc = "Final argument indicates the destination balance type."] + ReserveRepatriated { + from: ::subxt::utils::AccountId32, + to: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + destination_status: + runtime_types::frame_support::traits::tokens::misc::BalanceStatus, + }, + #[codec(index = 7)] + #[doc = "Some amount was deposited (e.g. for transaction fees)."] + Deposit { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 8)] + #[doc = "Some amount was withdrawn from the account (e.g. for transaction fees)."] + Withdraw { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 9)] + #[doc = "Some amount was removed from the account (e.g. for misbehavior)."] + Slashed { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 10)] + #[doc = "Some amount was minted into an account."] + Minted { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 11)] + #[doc = "Some amount was burned from an account."] + Burned { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 12)] + #[doc = "Some amount was suspended from an account (it can be restored later)."] + Suspended { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 13)] + #[doc = "Some amount was restored into an account."] + Restored { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 14)] + #[doc = "An account was upgraded."] + Upgraded { who: ::subxt::utils::AccountId32 }, + #[codec(index = 15)] + #[doc = "Total issuance was increased by `amount`, creating a credit to be balanced."] + Issued { amount: ::core::primitive::u128 }, + #[codec(index = 16)] + #[doc = "Total issuance was decreased by `amount`, creating a debt to be balanced."] + Rescinded { amount: ::core::primitive::u128 }, + #[codec(index = 17)] + #[doc = "Some balance was locked."] + Locked { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 18)] + #[doc = "Some balance was unlocked."] + Unlocked { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 19)] + #[doc = "Some balance was frozen."] + Frozen { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 20)] + #[doc = "Some balance was thawed."] + Thawed { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AccountData<_0> { + pub free: _0, + pub reserved: _0, + pub frozen: _0, + pub flags: runtime_types::pallet_balances::types::ExtraFlags, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BalanceLock<_0> { + pub id: [::core::primitive::u8; 8usize], + pub amount: _0, + pub reasons: runtime_types::pallet_balances::types::Reasons, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ExtraFlags(pub ::core::primitive::u128); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct IdAmount<_0, _1> { + pub id: _0, + pub amount: _1, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Reasons { + #[codec(index = 0)] + Fee, + #[codec(index = 1)] + Misc, + #[codec(index = 2)] + All, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReserveData<_0, _1> { + pub id: _0, + pub amount: _1, + } } } pub mod pallet_bounties { @@ -33764,11 +36958,10 @@ pub mod api { #[doc = "Approve a bounty proposal. At a later time, the bounty will be funded and become active"] #[doc = "and the original deposit will be returned."] #[doc = ""] - #[doc = "May only be called from `T::ApproveOrigin`."] + #[doc = "May only be called from `T::SpendOrigin`."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- O(1)."] - #[doc = "# "] approve_bounty { #[codec(compact)] bounty_id: ::core::primitive::u32, @@ -33776,11 +36969,10 @@ pub mod api { #[codec(index = 2)] #[doc = "Assign a curator to a funded bounty."] #[doc = ""] - #[doc = "May only be called from `T::ApproveOrigin`."] + #[doc = "May only be called from `T::SpendOrigin`."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- O(1)."] - #[doc = "# "] propose_curator { #[codec(compact)] bounty_id: ::core::primitive::u32, @@ -33804,9 +36996,8 @@ pub mod api { #[doc = "anyone in the community to call out that a curator is not doing their due diligence, and"] #[doc = "we should pick a new curator. In this case the curator should also be slashed."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- O(1)."] - #[doc = "# "] unassign_curator { #[codec(compact)] bounty_id: ::core::primitive::u32, @@ -33817,9 +37008,8 @@ pub mod api { #[doc = ""] #[doc = "May only be called from the curator."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- O(1)."] - #[doc = "# "] accept_curator { #[codec(compact)] bounty_id: ::core::primitive::u32, @@ -33833,9 +37023,8 @@ pub mod api { #[doc = "- `bounty_id`: Bounty ID to award."] #[doc = "- `beneficiary`: The beneficiary account whom will receive the payout."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- O(1)."] - #[doc = "# "] award_bounty { #[codec(compact)] bounty_id: ::core::primitive::u32, @@ -33848,9 +37037,8 @@ pub mod api { #[doc = ""] #[doc = "- `bounty_id`: Bounty ID to claim."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- O(1)."] - #[doc = "# "] claim_bounty { #[codec(compact)] bounty_id: ::core::primitive::u32, @@ -33863,9 +37051,8 @@ pub mod api { #[doc = ""] #[doc = "- `bounty_id`: Bounty ID to cancel."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- O(1)."] - #[doc = "# "] close_bounty { #[codec(compact)] bounty_id: ::core::primitive::u32, @@ -33878,9 +37065,8 @@ pub mod api { #[doc = "- `bounty_id`: Bounty ID to extend."] #[doc = "- `remark`: additional information."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- O(1)."] - #[doc = "# "] extend_bounty_expiry { #[codec(compact)] bounty_id: ::core::primitive::u32, @@ -34368,7 +37554,7 @@ pub mod api { #[doc = "- `old_count`: The upper bound for the previous number of members in storage. Used for"] #[doc = " weight estimation."] #[doc = ""] - #[doc = "Requires root origin."] + #[doc = "The dispatch of this call must be `SetMembersOrigin`."] #[doc = ""] #[doc = "NOTE: Does not enforce the expected `MaxMembers` limit on the amount of members, but"] #[doc = " the weight estimations rely on it to estimate dispatchable weight."] @@ -34380,19 +37566,11 @@ pub mod api { #[doc = "Any call to `set_members` must be careful that the member set doesn't get out of sync"] #[doc = "with other logic managing the member set."] #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] + #[doc = "## Complexity:"] #[doc = "- `O(MP + N)` where:"] #[doc = " - `M` old-members-count (code- and governance-bounded)"] #[doc = " - `N` new-members-count (code- and governance-bounded)"] #[doc = " - `P` proposals-count (code-bounded)"] - #[doc = "- DB:"] - #[doc = " - 1 storage mutation (codec `O(M)` read, `O(N)` write) for reading and writing the"] - #[doc = " members"] - #[doc = " - 1 storage read (codec `O(P)`) for reading the proposals"] - #[doc = " - `P` storage mutations (codec `O(M)`) for updating the votes for each proposal"] - #[doc = " - 1 storage write (codec `O(1)`) for deleting the old `prime` and setting the new one"] - #[doc = "# "] set_members { new_members: ::std::vec::Vec<::subxt::utils::AccountId32>, prime: ::core::option::Option<::subxt::utils::AccountId32>, @@ -34403,13 +37581,11 @@ pub mod api { #[doc = ""] #[doc = "Origin must be a member of the collective."] #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] - #[doc = "- `O(M + P)` where `M` members-count (code-bounded) and `P` complexity of dispatching"] - #[doc = " `proposal`"] - #[doc = "- DB: 1 read (codec `O(M)`) + DB access of `proposal`"] - #[doc = "- 1 event"] - #[doc = "# "] + #[doc = "## Complexity:"] + #[doc = "- `O(B + M + P)` where:"] + #[doc = "- `B` is `proposal` size in bytes (length-fee-bounded)"] + #[doc = "- `M` members-count (code-bounded)"] + #[doc = "- `P` complexity of dispatching `proposal`"] execute { proposal: ::std::boxed::Box, #[codec(compact)] @@ -34423,26 +37599,13 @@ pub mod api { #[doc = "`threshold` determines whether `proposal` is executed directly (`threshold < 2`)"] #[doc = "or put up for voting."] #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] + #[doc = "## Complexity"] #[doc = "- `O(B + M + P1)` or `O(B + M + P2)` where:"] #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] #[doc = " - `M` is members-count (code- and governance-bounded)"] #[doc = " - branching is influenced by `threshold` where:"] #[doc = " - `P1` is proposal execution complexity (`threshold < 2`)"] #[doc = " - `P2` is proposals-count (code-bounded) (`threshold >= 2`)"] - #[doc = "- DB:"] - #[doc = " - 1 storage read `is_member` (codec `O(M)`)"] - #[doc = " - 1 storage read `ProposalOf::contains_key` (codec `O(1)`)"] - #[doc = " - DB accesses influenced by `threshold`:"] - #[doc = " - EITHER storage accesses done by `proposal` (`threshold < 2`)"] - #[doc = " - OR proposal insertion (`threshold <= 2`)"] - #[doc = " - 1 storage mutation `Proposals` (codec `O(P2)`)"] - #[doc = " - 1 storage mutation `ProposalCount` (codec `O(1)`)"] - #[doc = " - 1 storage write `ProposalOf` (codec `O(B)`)"] - #[doc = " - 1 storage write `Voting` (codec `O(M)`)"] - #[doc = " - 1 event"] - #[doc = "# "] propose { #[codec(compact)] threshold: ::core::primitive::u32, @@ -34458,62 +37621,14 @@ pub mod api { #[doc = "Transaction fees will be waived if the member is voting on any particular proposal"] #[doc = "for the first time and the call is successful. Subsequent vote changes will charge a"] #[doc = "fee."] - #[doc = "# "] - #[doc = "## Weight"] + #[doc = "## Complexity"] #[doc = "- `O(M)` where `M` is members-count (code- and governance-bounded)"] - #[doc = "- DB:"] - #[doc = " - 1 storage read `Members` (codec `O(M)`)"] - #[doc = " - 1 storage mutation `Voting` (codec `O(M)`)"] - #[doc = "- 1 event"] - #[doc = "# "] vote { proposal: ::subxt::utils::H256, #[codec(compact)] index: ::core::primitive::u32, approve: ::core::primitive::bool, }, - #[codec(index = 4)] - #[doc = "Close a vote that is either approved, disapproved or whose voting period has ended."] - #[doc = ""] - #[doc = "May be called by any signed account in order to finish voting and close the proposal."] - #[doc = ""] - #[doc = "If called before the end of the voting period it will only close the vote if it is"] - #[doc = "has enough votes to be approved or disapproved."] - #[doc = ""] - #[doc = "If called after the end of the voting period abstentions are counted as rejections"] - #[doc = "unless there is a prime member set and the prime member cast an approval."] - #[doc = ""] - #[doc = "If the close operation completes successfully with disapproval, the transaction fee will"] - #[doc = "be waived. Otherwise execution of the approved operation will be charged to the caller."] - #[doc = ""] - #[doc = "+ `proposal_weight_bound`: The maximum amount of weight consumed by executing the closed"] - #[doc = "proposal."] - #[doc = "+ `length_bound`: The upper bound for the length of the proposal in storage. Checked via"] - #[doc = "`storage::read` so it is `size_of::() == 4` larger than the pure length."] - #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] - #[doc = "- `O(B + M + P1 + P2)` where:"] - #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] - #[doc = " - `M` is members-count (code- and governance-bounded)"] - #[doc = " - `P1` is the complexity of `proposal` preimage."] - #[doc = " - `P2` is proposal-count (code-bounded)"] - #[doc = "- DB:"] - #[doc = " - 2 storage reads (`Members`: codec `O(M)`, `Prime`: codec `O(1)`)"] - #[doc = " - 3 mutations (`Voting`: codec `O(M)`, `ProposalOf`: codec `O(B)`, `Proposals`: codec"] - #[doc = " `O(P2)`)"] - #[doc = " - any mutations done while executing `proposal` (`P1`)"] - #[doc = "- up to 3 events"] - #[doc = "# "] - close_old_weight { - proposal_hash: ::subxt::utils::H256, - #[codec(compact)] - index: ::core::primitive::u32, - #[codec(compact)] - proposal_weight_bound: runtime_types::sp_weights::OldWeight, - #[codec(compact)] - length_bound: ::core::primitive::u32, - }, #[codec(index = 5)] #[doc = "Disapprove a proposal, close, and remove it from the system, regardless of its current"] #[doc = "state."] @@ -34523,12 +37638,8 @@ pub mod api { #[doc = "Parameters:"] #[doc = "* `proposal_hash`: The hash of the proposal that should be disapproved."] #[doc = ""] - #[doc = "# "] - #[doc = "Complexity: O(P) where P is the number of max proposals"] - #[doc = "DB Weight:"] - #[doc = "* Reads: Proposals"] - #[doc = "* Writes: Voting, Proposals, ProposalOf"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "O(P) where P is the number of max proposals"] disapprove_proposal { proposal_hash: ::subxt::utils::H256 }, #[codec(index = 6)] #[doc = "Close a vote that is either approved, disapproved or whose voting period has ended."] @@ -34549,20 +37660,12 @@ pub mod api { #[doc = "+ `length_bound`: The upper bound for the length of the proposal in storage. Checked via"] #[doc = "`storage::read` so it is `size_of::() == 4` larger than the pure length."] #[doc = ""] - #[doc = "# "] - #[doc = "## Weight"] + #[doc = "## Complexity"] #[doc = "- `O(B + M + P1 + P2)` where:"] #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] #[doc = " - `M` is members-count (code- and governance-bounded)"] #[doc = " - `P1` is the complexity of `proposal` preimage."] #[doc = " - `P2` is proposal-count (code-bounded)"] - #[doc = "- DB:"] - #[doc = " - 2 storage reads (`Members`: codec `O(M)`, `Prime`: codec `O(1)`)"] - #[doc = " - 3 mutations (`Voting`: codec `O(M)`, `ProposalOf`: codec `O(B)`, `Proposals`: codec"] - #[doc = " `O(P2)`)"] - #[doc = " - any mutations done while executing `proposal` (`P1`)"] - #[doc = "- up to 3 events"] - #[doc = "# "] close { proposal_hash: ::subxt::utils::H256, #[codec(compact)] @@ -34711,6 +37814,393 @@ pub mod api { pub end: _1, } } + pub mod pallet_conviction_voting { + use super::runtime_types; + pub mod conviction { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Conviction { + #[codec(index = 0)] + None, + #[codec(index = 1)] + Locked1x, + #[codec(index = 2)] + Locked2x, + #[codec(index = 3)] + Locked3x, + #[codec(index = 4)] + Locked4x, + #[codec(index = 5)] + Locked5x, + #[codec(index = 6)] + Locked6x, + } + } + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub enum Call { + #[codec(index = 0)] + #[doc = "Vote in a poll. If `vote.is_aye()`, the vote is to enact the proposal;"] + #[doc = "otherwise it is a vote to keep the status quo."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be _Signed_."] + #[doc = ""] + #[doc = "- `poll_index`: The index of the poll to vote for."] + #[doc = "- `vote`: The vote configuration."] + #[doc = ""] + #[doc = "Weight: `O(R)` where R is the number of polls the voter has voted on."] + vote { + #[codec(compact)] + poll_index: ::core::primitive::u32, + vote: runtime_types::pallet_conviction_voting::vote::AccountVote< + ::core::primitive::u128, + >, + }, + #[codec(index = 1)] + #[doc = "Delegate the voting power (with some given conviction) of the sending account for a"] + #[doc = "particular class of polls."] + #[doc = ""] + #[doc = "The balance delegated is locked for as long as it's delegated, and thereafter for the"] + #[doc = "time appropriate for the conviction's lock period."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be _Signed_, and the signing account must either:"] + #[doc = " - be delegating already; or"] + #[doc = " - have no voting activity (if there is, then it will need to be removed/consolidated"] + #[doc = " through `reap_vote` or `unvote`)."] + #[doc = ""] + #[doc = "- `to`: The account whose voting the `target` account's voting power will follow."] + #[doc = "- `class`: The class of polls to delegate. To delegate multiple classes, multiple calls"] + #[doc = " to this function are required."] + #[doc = "- `conviction`: The conviction that will be attached to the delegated votes. When the"] + #[doc = " account is undelegated, the funds will be locked for the corresponding period."] + #[doc = "- `balance`: The amount of the account's balance to be used in delegating. This must not"] + #[doc = " be more than the account's current balance."] + #[doc = ""] + #[doc = "Emits `Delegated`."] + #[doc = ""] + #[doc = "Weight: `O(R)` where R is the number of polls the voter delegating to has"] + #[doc = " voted on. Weight is initially charged as if maximum votes, but is refunded later."] + delegate { + class: ::core::primitive::u16, + to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + conviction: runtime_types::pallet_conviction_voting::conviction::Conviction, + balance: ::core::primitive::u128, + }, + #[codec(index = 2)] + #[doc = "Undelegate the voting power of the sending account for a particular class of polls."] + #[doc = ""] + #[doc = "Tokens may be unlocked following once an amount of time consistent with the lock period"] + #[doc = "of the conviction with which the delegation was issued has passed."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be _Signed_ and the signing account must be"] + #[doc = "currently delegating."] + #[doc = ""] + #[doc = "- `class`: The class of polls to remove the delegation from."] + #[doc = ""] + #[doc = "Emits `Undelegated`."] + #[doc = ""] + #[doc = "Weight: `O(R)` where R is the number of polls the voter delegating to has"] + #[doc = " voted on. Weight is initially charged as if maximum votes, but is refunded later."] + undelegate { class: ::core::primitive::u16 }, + #[codec(index = 3)] + #[doc = "Remove the lock caused by prior voting/delegating which has expired within a particular"] + #[doc = "class."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be _Signed_."] + #[doc = ""] + #[doc = "- `class`: The class of polls to unlock."] + #[doc = "- `target`: The account to remove the lock on."] + #[doc = ""] + #[doc = "Weight: `O(R)` with R number of vote of target."] + unlock { + class: ::core::primitive::u16, + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + }, + #[codec(index = 4)] + #[doc = "Remove a vote for a poll."] + #[doc = ""] + #[doc = "If:"] + #[doc = "- the poll was cancelled, or"] + #[doc = "- the poll is ongoing, or"] + #[doc = "- the poll has ended such that"] + #[doc = " - the vote of the account was in opposition to the result; or"] + #[doc = " - there was no conviction to the account's vote; or"] + #[doc = " - the account made a split vote"] + #[doc = "...then the vote is removed cleanly and a following call to `unlock` may result in more"] + #[doc = "funds being available."] + #[doc = ""] + #[doc = "If, however, the poll has ended and:"] + #[doc = "- it finished corresponding to the vote of the account, and"] + #[doc = "- the account made a standard vote with conviction, and"] + #[doc = "- the lock period of the conviction is not over"] + #[doc = "...then the lock will be aggregated into the overall account's lock, which may involve"] + #[doc = "*overlocking* (where the two locks are combined into a single lock that is the maximum"] + #[doc = "of both the amount locked and the time is it locked for)."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be _Signed_, and the signer must have a vote"] + #[doc = "registered for poll `index`."] + #[doc = ""] + #[doc = "- `index`: The index of poll of the vote to be removed."] + #[doc = "- `class`: Optional parameter, if given it indicates the class of the poll. For polls"] + #[doc = " which have finished or are cancelled, this must be `Some`."] + #[doc = ""] + #[doc = "Weight: `O(R + log R)` where R is the number of polls that `target` has voted on."] + #[doc = " Weight is calculated for the maximum number of vote."] + remove_vote { + class: ::core::option::Option<::core::primitive::u16>, + index: ::core::primitive::u32, + }, + #[codec(index = 5)] + #[doc = "Remove a vote for a poll."] + #[doc = ""] + #[doc = "If the `target` is equal to the signer, then this function is exactly equivalent to"] + #[doc = "`remove_vote`. If not equal to the signer, then the vote must have expired,"] + #[doc = "either because the poll was cancelled, because the voter lost the poll or"] + #[doc = "because the conviction period is over."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be _Signed_."] + #[doc = ""] + #[doc = "- `target`: The account of the vote to be removed; this account must have voted for poll"] + #[doc = " `index`."] + #[doc = "- `index`: The index of poll of the vote to be removed."] + #[doc = "- `class`: The class of the poll."] + #[doc = ""] + #[doc = "Weight: `O(R + log R)` where R is the number of polls that `target` has voted on."] + #[doc = " Weight is calculated for the maximum number of vote."] + remove_other_vote { + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + class: ::core::primitive::u16, + index: ::core::primitive::u32, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub enum Error { + #[codec(index = 0)] + #[doc = "Poll is not ongoing."] + NotOngoing, + #[codec(index = 1)] + #[doc = "The given account did not vote on the poll."] + NotVoter, + #[codec(index = 2)] + #[doc = "The actor has no permission to conduct the action."] + NoPermission, + #[codec(index = 3)] + #[doc = "The actor has no permission to conduct the action right now but will do in the future."] + NoPermissionYet, + #[codec(index = 4)] + #[doc = "The account is already delegating."] + AlreadyDelegating, + #[codec(index = 5)] + #[doc = "The account currently has votes attached to it and the operation cannot succeed until"] + #[doc = "these are removed, either through `unvote` or `reap_vote`."] + AlreadyVoting, + #[codec(index = 6)] + #[doc = "Too high a balance was provided that the account cannot afford."] + InsufficientFunds, + #[codec(index = 7)] + #[doc = "The account is not currently delegating."] + NotDelegating, + #[codec(index = 8)] + #[doc = "Delegation to oneself makes no sense."] + Nonsense, + #[codec(index = 9)] + #[doc = "Maximum number of votes reached."] + MaxVotesReached, + #[codec(index = 10)] + #[doc = "The class must be supplied since it is not easily determinable from the state."] + ClassNeeded, + #[codec(index = 11)] + #[doc = "The class ID supplied is invalid."] + BadClass, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub enum Event { + #[codec(index = 0)] + #[doc = "An account has delegated their vote to another account. \\[who, target\\]"] + Delegated(::subxt::utils::AccountId32, ::subxt::utils::AccountId32), + #[codec(index = 1)] + #[doc = "An \\[account\\] has cancelled a previous delegation operation."] + Undelegated(::subxt::utils::AccountId32), + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Delegations<_0> { + pub votes: _0, + pub capital: _0, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Tally<_0> { + pub ayes: _0, + pub nays: _0, + pub support: _0, + } + } + pub mod vote { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum AccountVote<_0> { + #[codec(index = 0)] + Standard { + vote: runtime_types::pallet_conviction_voting::vote::Vote, + balance: _0, + }, + #[codec(index = 1)] + Split { aye: _0, nay: _0 }, + #[codec(index = 2)] + SplitAbstain { aye: _0, nay: _0, abstain: _0 }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Casting<_0, _1, _2> { + pub votes: runtime_types::bounded_collections::bounded_vec::BoundedVec<( + _1, + runtime_types::pallet_conviction_voting::vote::AccountVote<_0>, + )>, + pub delegations: + runtime_types::pallet_conviction_voting::types::Delegations<_0>, + pub prior: runtime_types::pallet_conviction_voting::vote::PriorLock<_1, _0>, + #[codec(skip)] + pub __subxt_unused_type_params: ::core::marker::PhantomData<_2>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Delegating<_0, _1, _2> { + pub balance: _0, + pub target: _1, + pub conviction: runtime_types::pallet_conviction_voting::conviction::Conviction, + pub delegations: + runtime_types::pallet_conviction_voting::types::Delegations<_0>, + pub prior: runtime_types::pallet_conviction_voting::vote::PriorLock<_2, _0>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PriorLock<_0, _1>(pub _0, pub _1); + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Vote(pub ::core::primitive::u8); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Voting<_0, _1, _2, _3> { + #[codec(index = 0)] + Casting(runtime_types::pallet_conviction_voting::vote::Casting<_0, _2, _2>), + #[codec(index = 1)] + Delegating( + runtime_types::pallet_conviction_voting::vote::Delegating<_0, _1, _2>, + ), + __Ignore(::core::marker::PhantomData<_3>), + } + } + } pub mod pallet_democracy { use super::runtime_types; pub mod conviction { @@ -35039,6 +38529,26 @@ pub mod api { #[codec(compact)] prop_index: ::core::primitive::u32, }, + #[codec(index = 18)] + #[doc = "Set or clear a metadata of a proposal or a referendum."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `origin`: Must correspond to the `MetadataOwner`."] + #[doc = " - `ExternalOrigin` for an external proposal with the `SuperMajorityApprove`"] + #[doc = " threshold."] + #[doc = " - `ExternalDefaultOrigin` for an external proposal with the `SuperMajorityAgainst`"] + #[doc = " threshold."] + #[doc = " - `ExternalMajorityOrigin` for an external proposal with the `SimpleMajority`"] + #[doc = " threshold."] + #[doc = " - `Signed` by a creator for a public proposal."] + #[doc = " - `Signed` to clear a metadata for a finished referendum."] + #[doc = " - `Root` to set a metadata for an ongoing referendum."] + #[doc = "- `owner`: an identifier of a metadata owner."] + #[doc = "- `maybe_hash`: The hash of an on-chain stored preimage. `None` to clear a metadata."] + set_metadata { + owner: runtime_types::pallet_democracy::types::MetadataOwner, + maybe_hash: ::core::option::Option<::subxt::utils::H256>, + }, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -35122,6 +38632,9 @@ pub mod api { #[codec(index = 22)] #[doc = "Voting period too low"] VotingPeriodLow, + #[codec(index = 23)] + #[doc = "The preimage does not exist."] + PreimageNotExist, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -35204,6 +38717,25 @@ pub mod api { #[codec(index = 13)] #[doc = "A proposal got canceled."] ProposalCanceled { prop_index: ::core::primitive::u32 }, + #[codec(index = 14)] + #[doc = "Metadata for a proposal or a referendum has been set."] + MetadataSet { + owner: runtime_types::pallet_democracy::types::MetadataOwner, + hash: ::subxt::utils::H256, + }, + #[codec(index = 15)] + #[doc = "Metadata for a proposal or a referendum has been cleared."] + MetadataCleared { + owner: runtime_types::pallet_democracy::types::MetadataOwner, + hash: ::subxt::utils::H256, + }, + #[codec(index = 16)] + #[doc = "Metadata has been transferred to new owner."] + MetadataTransferred { + prev_owner: runtime_types::pallet_democracy::types::MetadataOwner, + owner: runtime_types::pallet_democracy::types::MetadataOwner, + hash: ::subxt::utils::H256, + }, } } pub mod types { @@ -35232,6 +38764,24 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum MetadataOwner { + #[codec(index = 0)] + External, + #[codec(index = 1)] + Proposal(::core::primitive::u32), + #[codec(index = 2)] + Referendum(::core::primitive::u32), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum ReferendumInfo<_0, _1, _2> { #[codec(index = 0)] Ongoing(runtime_types::pallet_democracy::types::ReferendumStatus<_0, _1, _2>), @@ -35331,7 +38881,7 @@ pub mod api { pub enum Voting<_0, _1, _2> { #[codec(index = 0)] Direct { - votes: runtime_types::sp_core::bounded::bounded_vec::BoundedVec<( + votes: runtime_types::bounded_collections::bounded_vec::BoundedVec<( _2, runtime_types::pallet_democracy::vote::AccountVote<_0>, )>, @@ -35457,13 +39007,15 @@ pub mod api { #[codec(index = 0)] #[doc = "A solution was stored with the given compute."] #[doc = ""] - #[doc = "If the solution is signed, this means that it hasn't yet been processed. If the"] - #[doc = "solution is unsigned, this means that it has also been processed."] - #[doc = ""] - #[doc = "The `bool` is `true` when a previous solution was ejected to make room for this one."] + #[doc = "The `origin` indicates the origin of the solution. If `origin` is `Some(AccountId)`,"] + #[doc = "the stored solution was submited in the signed phase by a miner with the `AccountId`."] + #[doc = "Otherwise, the solution was stored either during the unsigned phase or by"] + #[doc = "`T::ForceOrigin`. The `bool` is `true` when a previous solution was ejected to make"] + #[doc = "room for this one."] SolutionStored { compute: runtime_types::pallet_election_provider_multi_phase::ElectionCompute, + origin: ::core::option::Option<::subxt::utils::AccountId32>, prev_ejected: ::core::primitive::bool, }, #[codec(index = 1)] @@ -35491,11 +39043,16 @@ pub mod api { value: ::core::primitive::u128, }, #[codec(index = 5)] - #[doc = "The signed phase of the given round has started."] - SignedPhaseStarted { round: ::core::primitive::u32 }, - #[codec(index = 6)] - #[doc = "The unsigned phase of the given round has started."] - UnsignedPhaseStarted { round: ::core::primitive::u32 }, + #[doc = "There was a phase transition in a given round."] + PhaseTransitioned { + from: runtime_types::pallet_election_provider_multi_phase::Phase< + ::core::primitive::u32, + >, + to: runtime_types::pallet_election_provider_multi_phase::Phase< + ::core::primitive::u32, + >, + round: ::core::primitive::u32, + }, } } pub mod signed { @@ -35586,7 +39143,7 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReadySolution { - pub supports: runtime_types::sp_core::bounded::bounded_vec::BoundedVec<( + pub supports: runtime_types::bounded_collections::bounded_vec::BoundedVec<( ::subxt::utils::AccountId32, runtime_types::sp_npos_elections::Support<::subxt::utils::AccountId32>, )>, @@ -35603,15 +39160,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RoundSnapshot { - pub voters: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - ::core::primitive::u64, - runtime_types::sp_core::bounded::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - )>, - pub targets: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub struct RoundSnapshot<_0, _1> { + pub voters: ::std::vec::Vec<_1>, + pub targets: ::std::vec::Vec<_0>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -35666,10 +39217,6 @@ pub mod api { #[doc = ""] #[doc = "It is the responsibility of the caller to **NOT** place all of their balance into the"] #[doc = "lock and keep some for further operations."] - #[doc = ""] - #[doc = "# "] - #[doc = "We assume the maximum weight among all 3 cases: vote_equal, vote_more and vote_less."] - #[doc = "# "] vote { votes: ::std::vec::Vec<::subxt::utils::AccountId32>, #[codec(compact)] @@ -35695,9 +39242,9 @@ pub mod api { #[doc = "Even if a candidate ends up being a member, they must call [`Call::renounce_candidacy`]"] #[doc = "to get their deposit back. Losing the spot in an election will always lead to a slash."] #[doc = ""] - #[doc = "# "] #[doc = "The number of current candidates must be provided as witness data."] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "O(C + log(C)) where C is candidate_count."] submit_candidacy { #[codec(compact)] candidate_count: ::core::primitive::u32, @@ -35717,10 +39264,12 @@ pub mod api { #[doc = " next round."] #[doc = ""] #[doc = "The dispatch origin of this call must be signed, and have one of the above roles."] - #[doc = ""] - #[doc = "# "] #[doc = "The type of renouncing must be provided as witness data."] - #[doc = "# "] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = " - Renouncing::Candidate(count): O(count + log(count))"] + #[doc = " - Renouncing::Member: O(1)"] + #[doc = " - Renouncing::RunnerUp: O(1)"] renounce_candidacy { renouncing: runtime_types::pallet_elections_phragmen::Renouncing, }, @@ -35739,10 +39288,8 @@ pub mod api { #[doc = ""] #[doc = "Note that this does not affect the designated block number of the next election."] #[doc = ""] - #[doc = "# "] - #[doc = "If we have a replacement, we use a small weight. Else, since this is a root call and"] - #[doc = "will go into phragmen, we assume full block for now."] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- Check details of remove_and_replace_member() and do_phragmen()."] remove_member { who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, slash_bond: ::core::primitive::bool, @@ -35756,9 +39303,8 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin of this call must be root."] #[doc = ""] - #[doc = "# "] - #[doc = "The total number of voters and those that are defunct must be provided as witness data."] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- Check is_defunct_voter() details."] clean_defunct_voters { num_voters: ::core::primitive::u32, num_defunct: ::core::primitive::u32, @@ -35982,7 +39528,7 @@ pub mod api { #[doc = ""] #[doc = "Dispatch origin must be signed by the [`Config::ControlOrigin`]."] control { - unchecked_eras_to_check: ::core::primitive::u32, + eras_to_check: ::core::primitive::u32, }, } #[derive( @@ -36044,23 +39590,19 @@ pub mod api { amount: ::core::primitive::u128, }, #[codec(index = 2)] - #[doc = "Some internal error happened while migrating stash. They are removed as head as a"] - #[doc = "consequence."] - Errored { stash: ::subxt::utils::AccountId32 }, - #[codec(index = 3)] #[doc = "An internal error happened. Operations will be paused now."] InternalError, - #[codec(index = 4)] + #[codec(index = 3)] #[doc = "A batch was partially checked for the given eras, but the process did not finish."] BatchChecked { eras: ::std::vec::Vec<::core::primitive::u32>, }, - #[codec(index = 5)] - #[doc = "A batch was terminated."] + #[codec(index = 4)] + #[doc = "A batch of a given size was terminated."] #[doc = ""] #[doc = "This is always follows by a number of `Unstaked` or `Slashed` events, marking the end"] #[doc = "of the batch. A new batch will be created upon next block."] - BatchFinished, + BatchFinished { size: ::core::primitive::u32 }, } } pub mod types { @@ -36076,11 +39618,11 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct UnstakeRequest { - pub stashes: runtime_types::sp_core::bounded::bounded_vec::BoundedVec<( + pub stashes: runtime_types::bounded_collections::bounded_vec::BoundedVec<( ::subxt::utils::AccountId32, ::core::primitive::u128, )>, - pub checked: runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + pub checked: runtime_types::bounded_collections::bounded_vec::BoundedVec< ::core::primitive::u32, >, } @@ -36109,7 +39651,7 @@ pub mod api { #[doc = "will be reported."] report_equivocation { equivocation_proof: ::std::boxed::Box< - runtime_types::sp_finality_grandpa::EquivocationProof< + runtime_types::sp_consensus_grandpa::EquivocationProof< ::subxt::utils::H256, ::core::primitive::u32, >, @@ -36128,7 +39670,7 @@ pub mod api { #[doc = "reporter."] report_equivocation_unsigned { equivocation_proof: ::std::boxed::Box< - runtime_types::sp_finality_grandpa::EquivocationProof< + runtime_types::sp_consensus_grandpa::EquivocationProof< ::subxt::utils::H256, ::core::primitive::u32, >, @@ -36205,7 +39747,7 @@ pub mod api { #[doc = "New authority set has been applied."] NewAuthorities { authority_set: ::std::vec::Vec<( - runtime_types::sp_finality_grandpa::app::Public, + runtime_types::sp_consensus_grandpa::app::Public, ::core::primitive::u64, )>, }, @@ -36231,8 +39773,8 @@ pub mod api { pub scheduled_at: _0, pub delay: _0, pub next_authorities: - runtime_types::sp_core::bounded::weak_bounded_vec::WeakBoundedVec<( - runtime_types::sp_finality_grandpa::app::Public, + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec<( + runtime_types::sp_consensus_grandpa::app::Public, ::core::primitive::u64, )>, pub forced: ::core::option::Option<_0>, @@ -36283,11 +39825,8 @@ pub mod api { #[doc = ""] #[doc = "Emits `RegistrarAdded` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(R)` where `R` registrar-count (governance-bounded and code-bounded)."] - #[doc = "- One storage mutation (codec `O(R)`)."] - #[doc = "- One event."] - #[doc = "# "] add_registrar { account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, }, @@ -36303,14 +39842,10 @@ pub mod api { #[doc = ""] #[doc = "Emits `IdentitySet` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(X + X' + R)`"] #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)"] #[doc = " - where `R` judgements-count (registrar-count-bounded)"] - #[doc = "- One balance reserve operation."] - #[doc = "- One storage mutation (codec-read `O(X' + R)`, codec-write `O(X + R)`)."] - #[doc = "- One event."] - #[doc = "# "] set_identity { info: ::std::boxed::Box, @@ -36326,17 +39861,10 @@ pub mod api { #[doc = ""] #[doc = "- `subs`: The identity's (new) sub-accounts."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(P + S)`"] #[doc = " - where `P` old-subs-count (hard- and deposit-bounded)."] #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] - #[doc = "- At most one balance operations."] - #[doc = "- DB:"] - #[doc = " - `P + S` storage mutations (codec complexity `O(1)`)"] - #[doc = " - One storage read (codec complexity `O(P)`)."] - #[doc = " - One storage write (codec complexity `O(S)`)."] - #[doc = " - One storage-exists (`IdentityOf::contains_key`)."] - #[doc = "# "] set_subs { subs: ::std::vec::Vec<( ::subxt::utils::AccountId32, @@ -36353,15 +39881,11 @@ pub mod api { #[doc = ""] #[doc = "Emits `IdentityCleared` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(R + S + X)`"] #[doc = " - where `R` registrar-count (governance-bounded)."] #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] - #[doc = "- One balance-unreserve operation."] - #[doc = "- `2` storage reads and `S + 2` storage deletions."] - #[doc = "- One event."] - #[doc = "# "] clear_identity, #[codec(index = 4)] #[doc = "Request a judgement from a registrar."] @@ -36381,12 +39905,10 @@ pub mod api { #[doc = ""] #[doc = "Emits `JudgementRequested` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(R + X)`."] - #[doc = "- One balance-reserve operation."] - #[doc = "- Storage: 1 read `O(R)`, 1 mutate `O(X + R)`."] - #[doc = "- One event."] - #[doc = "# "] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] request_judgement { #[codec(compact)] reg_index: ::core::primitive::u32, @@ -36405,12 +39927,10 @@ pub mod api { #[doc = ""] #[doc = "Emits `JudgementUnrequested` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(R + X)`."] - #[doc = "- One balance-reserve operation."] - #[doc = "- One storage mutation `O(R + X)`."] - #[doc = "- One event"] - #[doc = "# "] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] cancel_request { reg_index: ::core::primitive::u32 }, #[codec(index = 6)] #[doc = "Set the fee required for a judgement to be requested from a registrar."] @@ -36421,11 +39941,9 @@ pub mod api { #[doc = "- `index`: the index of the registrar whose fee is to be set."] #[doc = "- `fee`: the new fee."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(R)`."] - #[doc = "- One storage mutation `O(R)`."] - #[doc = "- Benchmark: 7.315 + R * 0.329 µs (min squares analysis)"] - #[doc = "# "] + #[doc = " - where `R` registrar-count (governance-bounded)."] set_fee { #[codec(compact)] index: ::core::primitive::u32, @@ -36441,11 +39959,9 @@ pub mod api { #[doc = "- `index`: the index of the registrar whose fee is to be set."] #[doc = "- `new`: the new account ID."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(R)`."] - #[doc = "- One storage mutation `O(R)`."] - #[doc = "- Benchmark: 8.823 + R * 0.32 µs (min squares analysis)"] - #[doc = "# "] + #[doc = " - where `R` registrar-count (governance-bounded)."] set_account_id { #[codec(compact)] index: ::core::primitive::u32, @@ -36460,11 +39976,9 @@ pub mod api { #[doc = "- `index`: the index of the registrar whose fee is to be set."] #[doc = "- `fields`: the fields that the registrar concerns themselves with."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(R)`."] - #[doc = "- One storage mutation `O(R)`."] - #[doc = "- Benchmark: 7.464 + R * 0.325 µs (min squares analysis)"] - #[doc = "# "] + #[doc = " - where `R` registrar-count (governance-bounded)."] set_fields { #[codec(compact)] index: ::core::primitive::u32, @@ -36486,13 +40000,10 @@ pub mod api { #[doc = ""] #[doc = "Emits `JudgementGiven` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(R + X)`."] - #[doc = "- One balance-transfer operation."] - #[doc = "- Up to one account-lookup operation."] - #[doc = "- Storage: 1 read `O(R)`, 1 mutate `O(R + X)`."] - #[doc = "- One event."] - #[doc = "# "] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] provide_judgement { #[codec(compact)] reg_index: ::core::primitive::u32, @@ -36516,12 +40027,11 @@ pub mod api { #[doc = ""] #[doc = "Emits `IdentityKilled` if successful."] #[doc = ""] - #[doc = "# "] - #[doc = "- `O(R + S + X)`."] - #[doc = "- One balance-reserve operation."] - #[doc = "- `S + 2` storage mutations."] - #[doc = "- One event."] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- `O(R + S + X)`"] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] kill_identity { target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, }, @@ -36855,7 +40365,7 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct IdentityInfo { - pub additional: runtime_types::sp_core::bounded::bounded_vec::BoundedVec<( + pub additional: runtime_types::bounded_collections::bounded_vec::BoundedVec<( runtime_types::pallet_identity::types::Data, runtime_types::pallet_identity::types::Data, )>, @@ -36922,7 +40432,7 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Registration<_0> { - pub judgements: runtime_types::sp_core::bounded::bounded_vec::BoundedVec<( + pub judgements: runtime_types::bounded_collections::bounded_vec::BoundedVec<( ::core::primitive::u32, runtime_types::pallet_identity::types::Judgement<_0>, )>, @@ -36948,15 +40458,11 @@ pub mod api { #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub enum Call { #[codec(index = 0)] - #[doc = "# "] - #[doc = "- Complexity: `O(K + E)` where K is length of `Keys` (heartbeat.validators_len) and E is"] - #[doc = " length of `heartbeat.network_state.external_address`"] + #[doc = "## Complexity:"] + #[doc = "- `O(K + E)` where K is length of `Keys` (heartbeat.validators_len) and E is length of"] + #[doc = " `heartbeat.network_state.external_address`"] #[doc = " - `O(K)`: decoding of length `K`"] #[doc = " - `O(E)`: decoding/encoding of length `E`"] - #[doc = "- DbReads: pallet_session `Validators`, pallet_session `CurrentIndex`, `Keys`,"] - #[doc = " `ReceivedHeartbeats`"] - #[doc = "- DbWrites: `ReceivedHeartbeats`"] - #[doc = "# "] heartbeat { heartbeat: runtime_types::pallet_im_online::Heartbeat<::core::primitive::u32>, @@ -37054,12 +40560,12 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BoundedOpaqueNetworkState { - pub peer_id: runtime_types::sp_core::bounded::weak_bounded_vec::WeakBoundedVec< + pub peer_id: runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< ::core::primitive::u8, >, pub external_addresses: - runtime_types::sp_core::bounded::weak_bounded_vec::WeakBoundedVec< - runtime_types::sp_core::bounded::weak_bounded_vec::WeakBoundedVec< + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< ::core::primitive::u8, >, >, @@ -37109,14 +40615,8 @@ pub mod api { #[doc = ""] #[doc = "Emits `IndexAssigned` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- One storage mutation (codec `O(1)`)."] - #[doc = "- One reserve operation."] - #[doc = "- One event."] - #[doc = "-------------------"] - #[doc = "- DB Weight: 1 Read/Write (Accounts)"] - #[doc = "# "] claim { index: ::core::primitive::u32 }, #[codec(index = 1)] #[doc = "Assign an index already owned by the sender to another account. The balance reservation"] @@ -37129,16 +40629,8 @@ pub mod api { #[doc = ""] #[doc = "Emits `IndexAssigned` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- One storage mutation (codec `O(1)`)."] - #[doc = "- One transfer operation."] - #[doc = "- One event."] - #[doc = "-------------------"] - #[doc = "- DB Weight:"] - #[doc = " - Reads: Indices Accounts, System Account (recipient)"] - #[doc = " - Writes: Indices Accounts, System Account (recipient)"] - #[doc = "# "] transfer { new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, index: ::core::primitive::u32, @@ -37154,14 +40646,8 @@ pub mod api { #[doc = ""] #[doc = "Emits `IndexFreed` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- One storage mutation (codec `O(1)`)."] - #[doc = "- One reserve operation."] - #[doc = "- One event."] - #[doc = "-------------------"] - #[doc = "- DB Weight: 1 Read/Write (Accounts)"] - #[doc = "# "] free { index: ::core::primitive::u32 }, #[codec(index = 3)] #[doc = "Force an index to an account. This doesn't require a deposit. If the index is already"] @@ -37175,16 +40661,8 @@ pub mod api { #[doc = ""] #[doc = "Emits `IndexAssigned` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- One storage mutation (codec `O(1)`)."] - #[doc = "- Up to one reserve operation."] - #[doc = "- One event."] - #[doc = "-------------------"] - #[doc = "- DB Weight:"] - #[doc = " - Reads: Indices Accounts, System Account (original owner)"] - #[doc = " - Writes: Indices Accounts, System Account (original owner)"] - #[doc = "# "] force_transfer { new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, index: ::core::primitive::u32, @@ -37201,14 +40679,8 @@ pub mod api { #[doc = ""] #[doc = "Emits `IndexFrozen` if successful."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- One storage mutation (codec `O(1)`)."] - #[doc = "- Up to one slash operation."] - #[doc = "- One event."] - #[doc = "-------------------"] - #[doc = "- DB Weight: 1 Read/Write (Accounts)"] - #[doc = "# "] freeze { index: ::core::primitive::u32 }, } #[derive( @@ -37421,12 +40893,8 @@ pub mod api { #[doc = ""] #[doc = "Result is equivalent to the dispatched result."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "O(Z + C) where Z is the length of the call and C its execution weight."] - #[doc = "-------------------------------"] - #[doc = "- DB Weight: None"] - #[doc = "- Plus Call Weight"] - #[doc = "# "] as_multi_threshold_1 { other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, call: ::std::boxed::Box, @@ -37458,7 +40926,7 @@ pub mod api { #[doc = "on success, result is `Ok` and the result from the interior call, if it was executed,"] #[doc = "may be found in the deposited `MultisigExecuted` event."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(S + Z + Call)`."] #[doc = "- Up to one balance-reserve or unreserve operation."] #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] @@ -37471,12 +40939,6 @@ pub mod api { #[doc = "- The weight of the `call`."] #[doc = "- Storage: inserts one item, value size bounded by `MaxSignatories`, with a deposit"] #[doc = " taken for its lifetime of `DepositBase + threshold * DepositFactor`."] - #[doc = "-------------------------------"] - #[doc = "- DB Weight:"] - #[doc = " - Reads: Multisig Storage, [Caller Account]"] - #[doc = " - Writes: Multisig Storage, [Caller Account]"] - #[doc = "- Plus Call Weight"] - #[doc = "# "] as_multi { threshold: ::core::primitive::u16, other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, @@ -37506,7 +40968,7 @@ pub mod api { #[doc = ""] #[doc = "NOTE: If this is the final approval, you will want to use `as_multi` instead."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(S)`."] #[doc = "- Up to one balance-reserve or unreserve operation."] #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] @@ -37517,11 +40979,6 @@ pub mod api { #[doc = "- One event."] #[doc = "- Storage: inserts one item, value size bounded by `MaxSignatories`, with a deposit"] #[doc = " taken for its lifetime of `DepositBase + threshold * DepositFactor`."] - #[doc = "----------------------------------"] - #[doc = "- DB Weight:"] - #[doc = " - Read: Multisig Storage, [Caller Account]"] - #[doc = " - Write: Multisig Storage, [Caller Account]"] - #[doc = "# "] approve_as_multi { threshold: ::core::primitive::u16, other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, @@ -37544,7 +41001,7 @@ pub mod api { #[doc = "transaction for this dispatch."] #[doc = "- `call_hash`: The hash of the call to be executed."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(S)`."] #[doc = "- Up to one balance-reserve or unreserve operation."] #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] @@ -37553,11 +41010,6 @@ pub mod api { #[doc = "- One event."] #[doc = "- I/O: 1 read `O(S)`, one remove."] #[doc = "- Storage: removes one item."] - #[doc = "----------------------------------"] - #[doc = "- DB Weight:"] - #[doc = " - Read: Multisig Storage, [Caller Account], Refund Account"] - #[doc = " - Write: Multisig Storage, [Caller Account], Refund Account"] - #[doc = "# "] cancel_as_multi { threshold: ::core::primitive::u16, other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, @@ -37685,7 +41137,7 @@ pub mod api { pub when: runtime_types::pallet_multisig::Timepoint<_0>, pub deposit: _1, pub depositor: _2, - pub approvals: runtime_types::sp_core::bounded::bounded_vec::BoundedVec<_2>, + pub approvals: runtime_types::bounded_collections::bounded_vec::BoundedVec<_2>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -37741,6 +41193,7 @@ pub mod api { #[doc = "accumulated rewards, see [`BondExtra`]."] #[doc = ""] #[doc = "Bonding extra funds implies an automatic payout of all pending rewards as well."] + #[doc = "See `bond_extra_other` to bond pending rewards of `other` members."] bond_extra { extra: runtime_types::pallet_nomination_pools::BondExtra< ::core::primitive::u128, @@ -37748,11 +41201,13 @@ pub mod api { }, #[codec(index = 2)] #[doc = "A bonded member can use this to claim their payout based on the rewards that the pool"] - #[doc = "has accumulated since their last claimed payout (OR since joining if this is there first"] + #[doc = "has accumulated since their last claimed payout (OR since joining if this is their first"] #[doc = "time claiming rewards). The payout will be transferred to the member's account."] #[doc = ""] #[doc = "The member will earn rewards pro rata based on the members stake vs the sum of the"] #[doc = "members in the pools stake. Rewards do not \"expire\"."] + #[doc = ""] + #[doc = "See `claim_payout_other` to caim rewards on bahalf of some `other` pool member."] claim_payout, #[codec(index = 3)] #[doc = "Unbond up to `unbonding_points` of the `member_account`'s funds from the pool. It"] @@ -37764,8 +41219,8 @@ pub mod api { #[doc = ""] #[doc = "# Conditions for a permissionless dispatch."] #[doc = ""] - #[doc = "* The pool is blocked and the caller is either the root or state-toggler. This is"] - #[doc = " refereed to as a kick."] + #[doc = "* The pool is blocked and the caller is either the root or bouncer. This is refereed to"] + #[doc = " as a kick."] #[doc = "* The pool is destroying and the member is not the depositor."] #[doc = "* The pool is destroying, the member is the depositor and no other members are in the"] #[doc = " pool."] @@ -37780,9 +41235,12 @@ pub mod api { #[doc = "# Note"] #[doc = ""] #[doc = "If there are too many unlocking chunks to unbond with the pool account,"] - #[doc = "[`Call::pool_withdraw_unbonded`] can be called to try and minimize unlocking chunks. If"] - #[doc = "there are too many unlocking chunks, the result of this call will likely be the"] - #[doc = "`NoMoreChunks` error from the staking system."] + #[doc = "[`Call::pool_withdraw_unbonded`] can be called to try and minimize unlocking chunks."] + #[doc = "The [`StakingInterface::unbond`] will implicitly call [`Call::pool_withdraw_unbonded`]"] + #[doc = "to try to free chunks if necessary (ie. if unbound was called and no unlocking chunks"] + #[doc = "are available). However, it may not be possible to release the current unlocking chunks,"] + #[doc = "in which case, the result of this call will likely be the `NoMoreChunks` error from the"] + #[doc = "staking system."] unbond { member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -37811,7 +41269,7 @@ pub mod api { #[doc = ""] #[doc = "* The pool is in destroy mode and the target is not the depositor."] #[doc = "* The target is the depositor and they are the only member in the sub pools."] - #[doc = "* The pool is blocked and the caller is either the root or state-toggler."] + #[doc = "* The pool is blocked and the caller is either the root or bouncer."] #[doc = ""] #[doc = "# Conditions for permissioned dispatch"] #[doc = ""] @@ -37837,7 +41295,7 @@ pub mod api { #[doc = " creating multiple pools in the same extrinsic."] #[doc = "* `root` - The account to set as [`PoolRoles::root`]."] #[doc = "* `nominator` - The account to set as the [`PoolRoles::nominator`]."] - #[doc = "* `state_toggler` - The account to set as the [`PoolRoles::state_toggler`]."] + #[doc = "* `bouncer` - The account to set as the [`PoolRoles::bouncer`]."] #[doc = ""] #[doc = "# Note"] #[doc = ""] @@ -37848,8 +41306,7 @@ pub mod api { amount: ::core::primitive::u128, root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - state_toggler: - ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, }, #[codec(index = 7)] #[doc = "Create a new delegation pool with a previously used pool id"] @@ -37863,8 +41320,7 @@ pub mod api { amount: ::core::primitive::u128, root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - state_toggler: - ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, pool_id: ::core::primitive::u32, }, #[codec(index = 8)] @@ -37887,7 +41343,7 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin of this call must be either:"] #[doc = ""] - #[doc = "1. signed by the state toggler, or the root role of the pool,"] + #[doc = "1. signed by the bouncer, or the root role of the pool,"] #[doc = "2. if the pool conditions to be open are NOT met (as described by `ok_to_be_open`), and"] #[doc = " then the state of the pool can be permissionlessly changed to `Destroying`."] set_state { @@ -37897,8 +41353,8 @@ pub mod api { #[codec(index = 10)] #[doc = "Set a new metadata for the pool."] #[doc = ""] - #[doc = "The dispatch origin of this call must be signed by the state toggler, or the root role"] - #[doc = "of the pool."] + #[doc = "The dispatch origin of this call must be signed by the bouncer, or the root role of the"] + #[doc = "pool."] set_metadata { pool_id: ::core::primitive::u32, metadata: ::std::vec::Vec<::core::primitive::u8>, @@ -37914,6 +41370,7 @@ pub mod api { #[doc = "* `max_pools` - Set [`MaxPools`]."] #[doc = "* `max_members` - Set [`MaxPoolMembers`]."] #[doc = "* `max_members_per_pool` - Set [`MaxPoolMembersPerPool`]."] + #[doc = "* `global_max_commission` - Set [`GlobalMaxCommission`]."] set_configs { min_join_bond: runtime_types::pallet_nomination_pools::ConfigOp< ::core::primitive::u128, @@ -37930,6 +41387,9 @@ pub mod api { max_members_per_pool: runtime_types::pallet_nomination_pools::ConfigOp< ::core::primitive::u32, >, + global_max_commission: runtime_types::pallet_nomination_pools::ConfigOp< + runtime_types::sp_arithmetic::per_things::Perbill, + >, }, #[codec(index = 12)] #[doc = "Update the roles of the pool."] @@ -37947,7 +41407,7 @@ pub mod api { new_nominator: runtime_types::pallet_nomination_pools::ConfigOp< ::subxt::utils::AccountId32, >, - new_state_toggler: runtime_types::pallet_nomination_pools::ConfigOp< + new_bouncer: runtime_types::pallet_nomination_pools::ConfigOp< ::subxt::utils::AccountId32, >, }, @@ -37960,6 +41420,85 @@ pub mod api { #[doc = "This directly forward the call to the staking pallet, on behalf of the pool bonded"] #[doc = "account."] chill { pool_id: ::core::primitive::u32 }, + #[codec(index = 14)] + #[doc = "`origin` bonds funds from `extra` for some pool member `member` into their respective"] + #[doc = "pools."] + #[doc = ""] + #[doc = "`origin` can bond extra funds from free balance or pending rewards when `origin =="] + #[doc = "other`."] + #[doc = ""] + #[doc = "In the case of `origin != other`, `origin` can only bond extra pending rewards of"] + #[doc = "`other` members assuming set_claim_permission for the given member is"] + #[doc = "`PermissionlessAll` or `PermissionlessCompound`."] + bond_extra_other { + member: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + extra: runtime_types::pallet_nomination_pools::BondExtra< + ::core::primitive::u128, + >, + }, + #[codec(index = 15)] + #[doc = "Allows a pool member to set a claim permission to allow or disallow permissionless"] + #[doc = "bonding and withdrawing."] + #[doc = ""] + #[doc = "By default, this is `Permissioned`, which implies only the pool member themselves can"] + #[doc = "claim their pending rewards. If a pool member wishes so, they can set this to"] + #[doc = "`PermissionlessAll` to allow any account to claim their rewards and bond extra to the"] + #[doc = "pool."] + #[doc = ""] + #[doc = "# Arguments"] + #[doc = ""] + #[doc = "* `origin` - Member of a pool."] + #[doc = "* `actor` - Account to claim reward. // improve this"] + set_claim_permission { + permission: runtime_types::pallet_nomination_pools::ClaimPermission, + }, + #[codec(index = 16)] + #[doc = "`origin` can claim payouts on some pool member `other`'s behalf."] + #[doc = ""] + #[doc = "Pool member `other` must have a `PermissionlessAll` or `PermissionlessWithdraw` in order"] + #[doc = "for this call to be successful."] + claim_payout_other { other: ::subxt::utils::AccountId32 }, + #[codec(index = 17)] + #[doc = "Set the commission of a pool."] + #[doc = "Both a commission percentage and a commission payee must be provided in the `current`"] + #[doc = "tuple. Where a `current` of `None` is provided, any current commission will be removed."] + #[doc = ""] + #[doc = "- If a `None` is supplied to `new_commission`, existing commission will be removed."] + set_commission { + pool_id: ::core::primitive::u32, + new_commission: ::core::option::Option<( + runtime_types::sp_arithmetic::per_things::Perbill, + ::subxt::utils::AccountId32, + )>, + }, + #[codec(index = 18)] + #[doc = "Set the maximum commission of a pool."] + #[doc = ""] + #[doc = "- Initial max can be set to any `Perbill`, and only smaller values thereafter."] + #[doc = "- Current commission will be lowered in the event it is higher than a new max"] + #[doc = " commission."] + set_commission_max { + pool_id: ::core::primitive::u32, + max_commission: runtime_types::sp_arithmetic::per_things::Perbill, + }, + #[codec(index = 19)] + #[doc = "Set the commission change rate for a pool."] + #[doc = ""] + #[doc = "Initial change rate is not bounded, whereas subsequent updates can only be more"] + #[doc = "restrictive than the current."] + set_commission_change_rate { + pool_id: ::core::primitive::u32, + change_rate: runtime_types::pallet_nomination_pools::CommissionChangeRate< + ::core::primitive::u32, + >, + }, + #[codec(index = 20)] + #[doc = "Claim pending commission."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be signed by the `root` role of the pool. Pending"] + #[doc = "commission is paid out and added to total claimed commission`. Total pending commission"] + #[doc = "is reset to zero. the current."] + claim_commission { pool_id: ::core::primitive::u32 }, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -38067,11 +41606,32 @@ pub mod api { #[doc = "Partial unbonding now allowed permissionlessly."] PartialUnbondNotAllowedPermissionlessly, #[codec(index = 21)] + #[doc = "The pool's max commission cannot be set higher than the existing value."] + MaxCommissionRestricted, + #[codec(index = 22)] + #[doc = "The supplied commission exceeds the max allowed commission."] + CommissionExceedsMaximum, + #[codec(index = 23)] + #[doc = "Not enough blocks have surpassed since the last commission update."] + CommissionChangeThrottled, + #[codec(index = 24)] + #[doc = "The submitted changes to commission change rate are not allowed."] + CommissionChangeRateNotAllowed, + #[codec(index = 25)] + #[doc = "There is no pending commission to claim."] + NoPendingCommission, + #[codec(index = 26)] + #[doc = "No commission current has been set."] + NoCommissionCurrentSet, + #[codec(index = 27)] #[doc = "Pool id currently in use."] PoolIdInUse, - #[codec(index = 22)] + #[codec(index = 28)] #[doc = "Pool id provided is not correct/usable."] InvalidPoolId, + #[codec(index = 29)] + #[doc = "Bonding extra is restricted to the exact pending reward amount."] + BondExtraRestricted, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -38160,7 +41720,7 @@ pub mod api { #[doc = "can never change."] RolesUpdated { root: ::core::option::Option<::subxt::utils::AccountId32>, - state_toggler: ::core::option::Option<::subxt::utils::AccountId32>, + bouncer: ::core::option::Option<::subxt::utils::AccountId32>, nominator: ::core::option::Option<::subxt::utils::AccountId32>, }, #[codec(index = 9)] @@ -38176,6 +41736,35 @@ pub mod api { era: ::core::primitive::u32, balance: ::core::primitive::u128, }, + #[codec(index = 11)] + #[doc = "A pool's commission setting has been changed."] + PoolCommissionUpdated { + pool_id: ::core::primitive::u32, + current: ::core::option::Option<( + runtime_types::sp_arithmetic::per_things::Perbill, + ::subxt::utils::AccountId32, + )>, + }, + #[codec(index = 12)] + #[doc = "A pool's maximum commission setting has been changed."] + PoolMaxCommissionUpdated { + pool_id: ::core::primitive::u32, + max_commission: runtime_types::sp_arithmetic::per_things::Perbill, + }, + #[codec(index = 13)] + #[doc = "A pool's commission `change_rate` has been changed."] + PoolCommissionChangeRateUpdated { + pool_id: ::core::primitive::u32, + change_rate: runtime_types::pallet_nomination_pools::CommissionChangeRate< + ::core::primitive::u32, + >, + }, + #[codec(index = 14)] + #[doc = "Pool commission has been claimed."] + PoolCommissionClaimed { + pool_id: ::core::primitive::u32, + commission: ::core::primitive::u128, + }, } } #[derive( @@ -38205,11 +41794,69 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BondedPoolInner { - pub points: ::core::primitive::u128, - pub state: runtime_types::pallet_nomination_pools::PoolState, + pub commission: runtime_types::pallet_nomination_pools::Commission, pub member_counter: ::core::primitive::u32, + pub points: ::core::primitive::u128, pub roles: runtime_types::pallet_nomination_pools::PoolRoles<::subxt::utils::AccountId32>, + pub state: runtime_types::pallet_nomination_pools::PoolState, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum ClaimPermission { + #[codec(index = 0)] + Permissioned, + #[codec(index = 1)] + PermissionlessCompound, + #[codec(index = 2)] + PermissionlessWithdraw, + #[codec(index = 3)] + PermissionlessAll, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Commission { + pub current: ::core::option::Option<( + runtime_types::sp_arithmetic::per_things::Perbill, + ::subxt::utils::AccountId32, + )>, + pub max: ::core::option::Option, + pub change_rate: ::core::option::Option< + runtime_types::pallet_nomination_pools::CommissionChangeRate< + ::core::primitive::u32, + >, + >, + pub throttle_from: ::core::option::Option<::core::primitive::u32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CommissionChangeRate<_0> { + pub max_increase: runtime_types::sp_arithmetic::per_things::Perbill, + pub min_delay: _0, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -38245,7 +41892,7 @@ pub mod api { pub last_recorded_reward_counter: runtime_types::sp_arithmetic::fixed_point::FixedU128, pub unbonding_eras: - runtime_types::sp_core::bounded::bounded_btree_map::BoundedBTreeMap< + runtime_types::bounded_collections::bounded_btree_map::BoundedBTreeMap< ::core::primitive::u32, ::core::primitive::u128, >, @@ -38264,7 +41911,7 @@ pub mod api { pub depositor: _0, pub root: ::core::option::Option<_0>, pub nominator: ::core::option::Option<_0>, - pub state_toggler: ::core::option::Option<_0>, + pub bouncer: ::core::option::Option<_0>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -38299,6 +41946,8 @@ pub mod api { runtime_types::sp_arithmetic::fixed_point::FixedU128, pub last_recorded_total_payouts: ::core::primitive::u128, pub total_rewards_claimed: ::core::primitive::u128, + pub total_commission_pending: ::core::primitive::u128, + pub total_commission_claimed: ::core::primitive::u128, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -38312,10 +41961,11 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SubPools { pub no_era: runtime_types::pallet_nomination_pools::UnbondPool, - pub with_era: runtime_types::sp_core::bounded::bounded_btree_map::BoundedBTreeMap< - ::core::primitive::u32, - runtime_types::pallet_nomination_pools::UnbondPool, - >, + pub with_era: + runtime_types::bounded_collections::bounded_btree_map::BoundedBTreeMap< + ::core::primitive::u32, + runtime_types::pallet_nomination_pools::UnbondPool, + >, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -38501,8 +42151,6 @@ pub mod api { #[doc = "Dispatch the given `call` from an account that the sender is authorised for through"] #[doc = "`add_proxy`."] #[doc = ""] - #[doc = "Removes any corresponding announcement(s)."] - #[doc = ""] #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] #[doc = "Parameters:"] @@ -38791,6 +42439,468 @@ pub mod api { pub delay: _2, } } + pub mod pallet_referenda { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub enum Call { + #[codec(index = 0)] + #[doc = "Propose a referendum on a privileged action."] + #[doc = ""] + #[doc = "- `origin`: must be `SubmitOrigin` and the account must have `SubmissionDeposit` funds"] + #[doc = " available."] + #[doc = "- `proposal_origin`: The origin from which the proposal should be executed."] + #[doc = "- `proposal`: The proposal."] + #[doc = "- `enactment_moment`: The moment that the proposal should be enacted."] + #[doc = ""] + #[doc = "Emits `Submitted`."] + submit { + proposal_origin: + ::std::boxed::Box, + proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + enactment_moment: + runtime_types::frame_support::traits::schedule::DispatchTime< + ::core::primitive::u32, + >, + }, + #[codec(index = 1)] + #[doc = "Post the Decision Deposit for a referendum."] + #[doc = ""] + #[doc = "- `origin`: must be `Signed` and the account must have funds available for the"] + #[doc = " referendum's track's Decision Deposit."] + #[doc = "- `index`: The index of the submitted referendum whose Decision Deposit is yet to be"] + #[doc = " posted."] + #[doc = ""] + #[doc = "Emits `DecisionDepositPlaced`."] + place_decision_deposit { index: ::core::primitive::u32 }, + #[codec(index = 2)] + #[doc = "Refund the Decision Deposit for a closed referendum back to the depositor."] + #[doc = ""] + #[doc = "- `origin`: must be `Signed` or `Root`."] + #[doc = "- `index`: The index of a closed referendum whose Decision Deposit has not yet been"] + #[doc = " refunded."] + #[doc = ""] + #[doc = "Emits `DecisionDepositRefunded`."] + refund_decision_deposit { index: ::core::primitive::u32 }, + #[codec(index = 3)] + #[doc = "Cancel an ongoing referendum."] + #[doc = ""] + #[doc = "- `origin`: must be the `CancelOrigin`."] + #[doc = "- `index`: The index of the referendum to be cancelled."] + #[doc = ""] + #[doc = "Emits `Cancelled`."] + cancel { index: ::core::primitive::u32 }, + #[codec(index = 4)] + #[doc = "Cancel an ongoing referendum and slash the deposits."] + #[doc = ""] + #[doc = "- `origin`: must be the `KillOrigin`."] + #[doc = "- `index`: The index of the referendum to be cancelled."] + #[doc = ""] + #[doc = "Emits `Killed` and `DepositSlashed`."] + kill { index: ::core::primitive::u32 }, + #[codec(index = 5)] + #[doc = "Advance a referendum onto its next logical state. Only used internally."] + #[doc = ""] + #[doc = "- `origin`: must be `Root`."] + #[doc = "- `index`: the referendum to be advanced."] + nudge_referendum { index: ::core::primitive::u32 }, + #[codec(index = 6)] + #[doc = "Advance a track onto its next logical state. Only used internally."] + #[doc = ""] + #[doc = "- `origin`: must be `Root`."] + #[doc = "- `track`: the track to be advanced."] + #[doc = ""] + #[doc = "Action item for when there is now one fewer referendum in the deciding phase and the"] + #[doc = "`DecidingCount` is not yet updated. This means that we should either:"] + #[doc = "- begin deciding another referendum (and leave `DecidingCount` alone); or"] + #[doc = "- decrement `DecidingCount`."] + one_fewer_deciding { track: ::core::primitive::u16 }, + #[codec(index = 7)] + #[doc = "Refund the Submission Deposit for a closed referendum back to the depositor."] + #[doc = ""] + #[doc = "- `origin`: must be `Signed` or `Root`."] + #[doc = "- `index`: The index of a closed referendum whose Submission Deposit has not yet been"] + #[doc = " refunded."] + #[doc = ""] + #[doc = "Emits `SubmissionDepositRefunded`."] + refund_submission_deposit { index: ::core::primitive::u32 }, + #[codec(index = 8)] + #[doc = "Set or clear metadata of a referendum."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `origin`: Must be `Signed` by a creator of a referendum or by anyone to clear a"] + #[doc = " metadata of a finished referendum."] + #[doc = "- `index`: The index of a referendum to set or clear metadata for."] + #[doc = "- `maybe_hash`: The hash of an on-chain stored preimage. `None` to clear a metadata."] + set_metadata { + index: ::core::primitive::u32, + maybe_hash: ::core::option::Option<::subxt::utils::H256>, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub enum Error { + #[codec(index = 0)] + #[doc = "Referendum is not ongoing."] + NotOngoing, + #[codec(index = 1)] + #[doc = "Referendum's decision deposit is already paid."] + HasDeposit, + #[codec(index = 2)] + #[doc = "The track identifier given was invalid."] + BadTrack, + #[codec(index = 3)] + #[doc = "There are already a full complement of referenda in progress for this track."] + Full, + #[codec(index = 4)] + #[doc = "The queue of the track is empty."] + QueueEmpty, + #[codec(index = 5)] + #[doc = "The referendum index provided is invalid in this context."] + BadReferendum, + #[codec(index = 6)] + #[doc = "There was nothing to do in the advancement."] + NothingToDo, + #[codec(index = 7)] + #[doc = "No track exists for the proposal origin."] + NoTrack, + #[codec(index = 8)] + #[doc = "Any deposit cannot be refunded until after the decision is over."] + Unfinished, + #[codec(index = 9)] + #[doc = "The deposit refunder is not the depositor."] + NoPermission, + #[codec(index = 10)] + #[doc = "The deposit cannot be refunded since none was made."] + NoDeposit, + #[codec(index = 11)] + #[doc = "The referendum status is invalid for this operation."] + BadStatus, + #[codec(index = 12)] + #[doc = "The preimage does not exist."] + PreimageNotExist, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub enum Event { + #[codec(index = 0)] + #[doc = "A referendum has been submitted."] + Submitted { + index: ::core::primitive::u32, + track: ::core::primitive::u16, + proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + }, + #[codec(index = 1)] + #[doc = "The decision deposit has been placed."] + DecisionDepositPlaced { + index: ::core::primitive::u32, + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 2)] + #[doc = "The decision deposit has been refunded."] + DecisionDepositRefunded { + index: ::core::primitive::u32, + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 3)] + #[doc = "A deposit has been slashaed."] + DepositSlashed { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 4)] + #[doc = "A referendum has moved into the deciding phase."] + DecisionStarted { + index: ::core::primitive::u32, + track: ::core::primitive::u16, + proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + tally: runtime_types::pallet_conviction_voting::types::Tally< + ::core::primitive::u128, + >, + }, + #[codec(index = 5)] + ConfirmStarted { index: ::core::primitive::u32 }, + #[codec(index = 6)] + ConfirmAborted { index: ::core::primitive::u32 }, + #[codec(index = 7)] + #[doc = "A referendum has ended its confirmation phase and is ready for approval."] + Confirmed { + index: ::core::primitive::u32, + tally: runtime_types::pallet_conviction_voting::types::Tally< + ::core::primitive::u128, + >, + }, + #[codec(index = 8)] + #[doc = "A referendum has been approved and its proposal has been scheduled."] + Approved { index: ::core::primitive::u32 }, + #[codec(index = 9)] + #[doc = "A proposal has been rejected by referendum."] + Rejected { + index: ::core::primitive::u32, + tally: runtime_types::pallet_conviction_voting::types::Tally< + ::core::primitive::u128, + >, + }, + #[codec(index = 10)] + #[doc = "A referendum has been timed out without being decided."] + TimedOut { + index: ::core::primitive::u32, + tally: runtime_types::pallet_conviction_voting::types::Tally< + ::core::primitive::u128, + >, + }, + #[codec(index = 11)] + #[doc = "A referendum has been cancelled."] + Cancelled { + index: ::core::primitive::u32, + tally: runtime_types::pallet_conviction_voting::types::Tally< + ::core::primitive::u128, + >, + }, + #[codec(index = 12)] + #[doc = "A referendum has been killed."] + Killed { + index: ::core::primitive::u32, + tally: runtime_types::pallet_conviction_voting::types::Tally< + ::core::primitive::u128, + >, + }, + #[codec(index = 13)] + #[doc = "The submission deposit has been refunded."] + SubmissionDepositRefunded { + index: ::core::primitive::u32, + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 14)] + #[doc = "Metadata for a referendum has been set."] + MetadataSet { + index: ::core::primitive::u32, + hash: ::subxt::utils::H256, + }, + #[codec(index = 15)] + #[doc = "Metadata for a referendum has been cleared."] + MetadataCleared { + index: ::core::primitive::u32, + hash: ::subxt::utils::H256, + }, + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Curve { + #[codec(index = 0)] + LinearDecreasing { + length: runtime_types::sp_arithmetic::per_things::Perbill, + floor: runtime_types::sp_arithmetic::per_things::Perbill, + ceil: runtime_types::sp_arithmetic::per_things::Perbill, + }, + #[codec(index = 1)] + SteppedDecreasing { + begin: runtime_types::sp_arithmetic::per_things::Perbill, + end: runtime_types::sp_arithmetic::per_things::Perbill, + step: runtime_types::sp_arithmetic::per_things::Perbill, + period: runtime_types::sp_arithmetic::per_things::Perbill, + }, + #[codec(index = 2)] + Reciprocal { + factor: runtime_types::sp_arithmetic::fixed_point::FixedI64, + x_offset: runtime_types::sp_arithmetic::fixed_point::FixedI64, + y_offset: runtime_types::sp_arithmetic::fixed_point::FixedI64, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DecidingStatus<_0> { + pub since: _0, + pub confirming: ::core::option::Option<_0>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Deposit<_0, _1> { + pub who: _0, + pub amount: _1, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum ReferendumInfo<_0, _1, _2, _3, _4, _5, _6, _7> { + #[codec(index = 0)] + Ongoing( + runtime_types::pallet_referenda::types::ReferendumStatus< + _0, + _1, + _2, + _3, + _4, + _5, + _6, + _7, + >, + ), + #[codec(index = 1)] + Approved( + _2, + ::core::option::Option< + runtime_types::pallet_referenda::types::Deposit<_6, _4>, + >, + ::core::option::Option< + runtime_types::pallet_referenda::types::Deposit<_6, _4>, + >, + ), + #[codec(index = 2)] + Rejected( + _2, + ::core::option::Option< + runtime_types::pallet_referenda::types::Deposit<_6, _4>, + >, + ::core::option::Option< + runtime_types::pallet_referenda::types::Deposit<_6, _4>, + >, + ), + #[codec(index = 3)] + Cancelled( + _2, + ::core::option::Option< + runtime_types::pallet_referenda::types::Deposit<_6, _4>, + >, + ::core::option::Option< + runtime_types::pallet_referenda::types::Deposit<_6, _4>, + >, + ), + #[codec(index = 4)] + TimedOut( + _2, + ::core::option::Option< + runtime_types::pallet_referenda::types::Deposit<_6, _4>, + >, + ::core::option::Option< + runtime_types::pallet_referenda::types::Deposit<_6, _4>, + >, + ), + #[codec(index = 5)] + Killed(_2), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReferendumStatus<_0, _1, _2, _3, _4, _5, _6, _7> { + pub track: _0, + pub origin: _1, + pub proposal: _3, + pub enactment: runtime_types::frame_support::traits::schedule::DispatchTime<_2>, + pub submitted: _2, + pub submission_deposit: runtime_types::pallet_referenda::types::Deposit<_6, _4>, + pub decision_deposit: ::core::option::Option< + runtime_types::pallet_referenda::types::Deposit<_6, _4>, + >, + pub deciding: ::core::option::Option< + runtime_types::pallet_referenda::types::DecidingStatus<_2>, + >, + pub tally: _5, + pub in_queue: ::core::primitive::bool, + pub alarm: ::core::option::Option<(_2, _7)>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TrackInfo<_0, _1> { + pub name: ::std::string::String, + pub max_deciding: _1, + pub decision_deposit: _0, + pub prepare_period: _1, + pub decision_period: _1, + pub confirm_period: _1, + pub min_enactment_period: _1, + pub min_approval: runtime_types::pallet_referenda::types::Curve, + pub min_support: runtime_types::pallet_referenda::types::Curve, + } + } + } pub mod pallet_scheduler { use super::runtime_types; pub mod pallet { @@ -38843,10 +42953,6 @@ pub mod api { }, #[codec(index = 4)] #[doc = "Anonymously schedule a task after a delay."] - #[doc = ""] - #[doc = "# "] - #[doc = "Same as [`schedule`]."] - #[doc = "# "] schedule_after { after: ::core::primitive::u32, maybe_periodic: ::core::option::Option<( @@ -38858,10 +42964,6 @@ pub mod api { }, #[codec(index = 5)] #[doc = "Schedule a named task after a delay."] - #[doc = ""] - #[doc = "# "] - #[doc = "Same as [`schedule_named`](Self::schedule_named)."] - #[doc = "# "] schedule_named_after { id: [::core::primitive::u8; 32usize], after: ::core::primitive::u32, @@ -38996,14 +43098,9 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin of this function must be signed."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(1)`. Actual cost depends on the number of length of"] - #[doc = " `T::Keys::key_ids()` which is fixed."] - #[doc = "- DbReads: `origin account`, `T::ValidatorIdOf`, `NextKeys`"] - #[doc = "- DbWrites: `origin account`, `NextKeys`"] - #[doc = "- DbReads per key id: `KeyOwner`"] - #[doc = "- DbWrites per key id: `KeyOwner`"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- `O(1)`. Actual cost depends on the number of length of `T::Keys::key_ids()` which is"] + #[doc = " fixed."] set_keys { keys: runtime_types::polkadot_runtime::SessionKeys, proof: ::std::vec::Vec<::core::primitive::u8>, @@ -39018,13 +43115,9 @@ pub mod api { #[doc = "means being a controller account) or directly convertible into a validator ID (which"] #[doc = "usually means being a stash account)."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(1)` in number of key types. Actual cost depends on the number of length"] - #[doc = " of `T::Keys::key_ids()` which is fixed."] - #[doc = "- DbReads: `T::ValidatorIdOf`, `NextKeys`, `origin account`"] - #[doc = "- DbWrites: `NextKeys`, `origin account`"] - #[doc = "- DbWrites per key id: `KeyOwner`"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- `O(1)` in number of key types. Actual cost depends on the number of length of"] + #[doc = " `T::Keys::key_ids()` which is fixed."] purge_keys, } #[derive( @@ -39103,15 +43196,13 @@ pub mod api { #[doc = "The dispatch origin for this call must be _Signed_ by the stash account."] #[doc = ""] #[doc = "Emits `Bonded`."] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- Independent of the arguments. Moderate complexity."] #[doc = "- O(1)."] #[doc = "- Three extra DB entries."] #[doc = ""] #[doc = "NOTE: Two of the storage writes (`Self::bonded`, `Self::payee`) are _never_ cleaned"] #[doc = "unless the `origin` falls below _existential deposit_ and gets removed as dust."] - #[doc = "------------------"] - #[doc = "# "] bond { controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -39133,10 +43224,9 @@ pub mod api { #[doc = ""] #[doc = "Emits `Bonded`."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- Independent of the arguments. Insignificant complexity."] #[doc = "- O(1)."] - #[doc = "# "] bond_extra { #[codec(compact)] max_additional: ::core::primitive::u128, @@ -39152,8 +43242,8 @@ pub mod api { #[doc = "the funds out of management ready for transfer."] #[doc = ""] #[doc = "No more than a limited number of unlocking chunks (see `MaxUnlockingChunks`)"] - #[doc = "can co-exists at the same time. In that case, [`Call::withdraw_unbonded`] need"] - #[doc = "to be called first to remove some of the chunks (if possible)."] + #[doc = "can co-exists at the same time. If there are no unlocking chunks slots available"] + #[doc = "[`Call::withdraw_unbonded`] is called to remove some of the chunks (if possible)."] #[doc = ""] #[doc = "If a user encounters the `InsufficientBond` error when calling this extrinsic,"] #[doc = "they should call `chill` first in order to free up their bonded funds."] @@ -39177,10 +43267,9 @@ pub mod api { #[doc = ""] #[doc = "See also [`Call::unbond`]."] #[doc = ""] - #[doc = "# "] - #[doc = "Complexity O(S) where S is the number of slashing spans to remove"] + #[doc = "## Complexity"] + #[doc = "O(S) where S is the number of slashing spans to remove"] #[doc = "NOTE: Weight annotation is the kill scenario, we refund otherwise."] - #[doc = "# "] withdraw_unbonded { num_slashing_spans: ::core::primitive::u32, }, @@ -39200,11 +43289,10 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- The transaction's complexity is proportional to the size of `targets` (N)"] #[doc = "which is capped at CompactAssignments::LIMIT (T::MaxNominations)."] #[doc = "- Both the reads and writes follow a similar pattern."] - #[doc = "# "] nominate { targets: ::std::vec::Vec< ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -39217,11 +43305,10 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- Independent of the arguments. Insignificant complexity."] #[doc = "- Contains one read."] #[doc = "- Writes are limited to the `origin` account key."] - #[doc = "# "] chill, #[codec(index = 7)] #[doc = "(Re-)set the payment target for a controller."] @@ -39230,16 +43317,12 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- O(1)"] #[doc = "- Independent of the arguments. Insignificant complexity."] #[doc = "- Contains a limited number of reads."] #[doc = "- Writes are limited to the `origin` account key."] #[doc = "---------"] - #[doc = "- Weight: O(1)"] - #[doc = "- DB Weight:"] - #[doc = " - Read: Ledger"] - #[doc = " - Write: Payee"] - #[doc = "# "] set_payee { payee: runtime_types::pallet_staking::RewardDestination< ::subxt::utils::AccountId32, @@ -39252,16 +43335,11 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin for this call must be _Signed_ by the stash, not the controller."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "O(1)"] #[doc = "- Independent of the arguments. Insignificant complexity."] #[doc = "- Contains a limited number of reads."] #[doc = "- Writes are limited to the `origin` account key."] - #[doc = "----------"] - #[doc = "Weight: O(1)"] - #[doc = "DB Weight:"] - #[doc = "- Read: Bonded, Ledger New Controller, Ledger Old Controller"] - #[doc = "- Write: Bonded, Ledger New Controller, Ledger Old Controller"] - #[doc = "# "] set_controller { controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -39271,10 +43349,8 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin must be Root."] #[doc = ""] - #[doc = "# "] - #[doc = "Weight: O(1)"] - #[doc = "Write: Validator Count"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "O(1)"] set_validator_count { #[codec(compact)] new: ::core::primitive::u32, @@ -39285,9 +43361,8 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin must be Root."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "Same as [`Self::set_validator_count`]."] - #[doc = "# "] increase_validator_count { #[codec(compact)] additional: ::core::primitive::u32, @@ -39298,9 +43373,8 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin must be Root."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "Same as [`Self::set_validator_count`]."] - #[doc = "# "] scale_validator_count { factor: runtime_types::sp_arithmetic::per_things::Percent, }, @@ -39315,11 +43389,9 @@ pub mod api { #[doc = "Thus the election process may be ongoing when this is called. In this case the"] #[doc = "election will continue until the next era is triggered."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- No arguments."] #[doc = "- Weight: O(1)"] - #[doc = "- Write: ForceEra"] - #[doc = "# "] force_no_eras, #[codec(index = 13)] #[doc = "Force there to be a new era at the end of the next session. After this, it will be"] @@ -39333,11 +43405,9 @@ pub mod api { #[doc = "If this is called just before a new era is triggered, the election process may not"] #[doc = "have enough blocks to get a result."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- No arguments."] #[doc = "- Weight: O(1)"] - #[doc = "- Write ForceEra"] - #[doc = "# "] force_new_era, #[codec(index = 14)] #[doc = "Set the validators who cannot be slashed (if any)."] @@ -39368,7 +43438,7 @@ pub mod api { #[codec(index = 17)] #[doc = "Cancel enactment of a deferred slash."] #[doc = ""] - #[doc = "Can be called by the `T::SlashCancelOrigin`."] + #[doc = "Can be called by the `T::AdminOrigin`."] #[doc = ""] #[doc = "Parameters: era and indices of the slashes for that era to kill."] cancel_deferred_slash { @@ -39385,18 +43455,8 @@ pub mod api { #[doc = "The origin of this call must be _Signed_. Any account can call this function, even if"] #[doc = "it is not one of the stakers."] #[doc = ""] - #[doc = "# "] - #[doc = "- Time complexity: at most O(MaxNominatorRewardedPerValidator)."] - #[doc = "- Contains a limited number of reads and writes."] - #[doc = "-----------"] - #[doc = "N is the Number of payouts for the validator (including the validator)"] - #[doc = "Weight:"] - #[doc = "- Reward Destination Staked: O(N)"] - #[doc = "- Reward Destination Controller (Creating): O(N)"] - #[doc = ""] - #[doc = " NOTE: weights are assuming that payouts are made to alive stash account (Staked)."] - #[doc = " Paying even a dead controller is cheaper weight-wise. We don't do any refunds here."] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- At most O(MaxNominatorRewardedPerValidator)."] payout_stakers { validator_stash: ::subxt::utils::AccountId32, era: ::core::primitive::u32, @@ -39406,11 +43466,9 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin must be signed by the controller."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- Time complexity: O(L), where L is unlocking chunks"] #[doc = "- Bounded by `MaxUnlockingChunks`."] - #[doc = "- Storage changes: Can't increase storage, only decrease it."] - #[doc = "# "] rebond { #[codec(compact)] value: ::core::primitive::u128, @@ -39529,6 +43587,14 @@ pub mod api { force_apply_min_commission { validator_stash: ::subxt::utils::AccountId32, }, + #[codec(index = 25)] + #[doc = "Sets the minimum amount of commission that each validators must maintain."] + #[doc = ""] + #[doc = "This call has lower privilege requirements than `set_staking_config` and can be called"] + #[doc = "by the `T::AdminOrigin`. Root can always call this."] + set_min_commission { + new: runtime_types::sp_arithmetic::per_things::Perbill, + }, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -39667,21 +43733,29 @@ pub mod api { amount: ::core::primitive::u128, }, #[codec(index = 2)] - #[doc = "One staker (and potentially its nominators) has been slashed by the given amount."] + #[doc = "A staker (validator or nominator) has been slashed by the given amount."] Slashed { staker: ::subxt::utils::AccountId32, amount: ::core::primitive::u128, }, #[codec(index = 3)] + #[doc = "A slash for the given validator, for the given percentage of their stake, at the given"] + #[doc = "era as been reported."] + SlashReported { + validator: ::subxt::utils::AccountId32, + fraction: runtime_types::sp_arithmetic::per_things::Perbill, + slash_era: ::core::primitive::u32, + }, + #[codec(index = 4)] #[doc = "An old slashing report from a prior era was discarded because it could"] #[doc = "not be processed."] OldSlashingReportDiscarded { session_index: ::core::primitive::u32, }, - #[codec(index = 4)] + #[codec(index = 5)] #[doc = "A new set of stakers was elected."] StakersElected, - #[codec(index = 5)] + #[codec(index = 6)] #[doc = "An account has bonded this amount. \\[stash, amount\\]"] #[doc = ""] #[doc = "NOTE: This event is only emitted when funds are bonded via a dispatchable. Notably,"] @@ -39690,43 +43764,48 @@ pub mod api { stash: ::subxt::utils::AccountId32, amount: ::core::primitive::u128, }, - #[codec(index = 6)] + #[codec(index = 7)] #[doc = "An account has unbonded this amount."] Unbonded { stash: ::subxt::utils::AccountId32, amount: ::core::primitive::u128, }, - #[codec(index = 7)] + #[codec(index = 8)] #[doc = "An account has called `withdraw_unbonded` and removed unbonding chunks worth `Balance`"] #[doc = "from the unlocking queue."] Withdrawn { stash: ::subxt::utils::AccountId32, amount: ::core::primitive::u128, }, - #[codec(index = 8)] + #[codec(index = 9)] #[doc = "A nominator has been kicked from a validator."] Kicked { nominator: ::subxt::utils::AccountId32, stash: ::subxt::utils::AccountId32, }, - #[codec(index = 9)] + #[codec(index = 10)] #[doc = "The election failed. No new era is planned."] StakingElectionFailed, - #[codec(index = 10)] + #[codec(index = 11)] #[doc = "An account has stopped participating as either a validator or nominator."] Chilled { stash: ::subxt::utils::AccountId32 }, - #[codec(index = 11)] + #[codec(index = 12)] #[doc = "The stakers' rewards are getting paid."] PayoutStarted { era_index: ::core::primitive::u32, validator_stash: ::subxt::utils::AccountId32, }, - #[codec(index = 12)] + #[codec(index = 13)] #[doc = "A validator has set their preferences."] ValidatorPrefsSet { stash: ::subxt::utils::AccountId32, prefs: runtime_types::pallet_staking::ValidatorPrefs, }, + #[codec(index = 14)] + #[doc = "A new force era mode was set."] + ForceEra { + mode: runtime_types::pallet_staking::Forcing, + }, } } } @@ -39855,7 +43934,7 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Nominations { - pub targets: runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + pub targets: runtime_types::bounded_collections::bounded_vec::BoundedVec< ::subxt::utils::AccountId32, >, pub submitted_in: ::core::primitive::u32, @@ -39871,42 +43950,6 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Releases { - #[codec(index = 0)] - V1_0_0Ancient, - #[codec(index = 1)] - V2_0_0, - #[codec(index = 2)] - V3_0_0, - #[codec(index = 3)] - V4_0_0, - #[codec(index = 4)] - V5_0_0, - #[codec(index = 5)] - V6_0_0, - #[codec(index = 6)] - V7_0_0, - #[codec(index = 7)] - V8_0_0, - #[codec(index = 8)] - V9_0_0, - #[codec(index = 9)] - V10_0_0, - #[codec(index = 10)] - V11_0_0, - #[codec(index = 11)] - V12_0_0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum RewardDestination<_0> { #[codec(index = 0)] Staked, @@ -39935,10 +43978,10 @@ pub mod api { pub total: ::core::primitive::u128, #[codec(compact)] pub active: ::core::primitive::u128, - pub unlocking: runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + pub unlocking: runtime_types::bounded_collections::bounded_vec::BoundedVec< runtime_types::pallet_staking::UnlockChunk<::core::primitive::u128>, >, - pub claimed_rewards: runtime_types::sp_core::bounded::bounded_vec::BoundedVec< + pub claimed_rewards: runtime_types::bounded_collections::bounded_vec::BoundedVec< ::core::primitive::u32, >, } @@ -40018,12 +44061,11 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin for this call must be `Inherent`."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)` (Note that implementations of `OnTimestampSet` must also be `O(1)`)"] #[doc = "- 1 storage read and 1 storage mutation (codec `O(1)`). (because of `DidUpdate::take` in"] #[doc = " `on_finalize`)"] #[doc = "- 1 event handler `on_timestamp_set`. Must be `O(1)`."] - #[doc = "# "] set { #[codec(compact)] now: ::core::primitive::u64, @@ -40061,12 +44103,9 @@ pub mod api { #[doc = ""] #[doc = "Emits `NewTip` if successful."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(R)` where `R` length of `reason`."] + #[doc = "## Complexity"] + #[doc = "- `O(R)` where `R` length of `reason`."] #[doc = " - encoding and hashing of 'reason'"] - #[doc = "- DbReads: `Reasons`, `Tips`"] - #[doc = "- DbWrites: `Reasons`, `Tips`"] - #[doc = "# "] report_awesome { reason: ::std::vec::Vec<::core::primitive::u8>, who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -40085,12 +44124,9 @@ pub mod api { #[doc = ""] #[doc = "Emits `TipRetracted` if successful."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(1)`"] + #[doc = "## Complexity"] + #[doc = "- `O(1)`"] #[doc = " - Depends on the length of `T::Hash` which is fixed."] - #[doc = "- DbReads: `Tips`, `origin account`"] - #[doc = "- DbWrites: `Reasons`, `Tips`, `origin account`"] - #[doc = "# "] retract_tip { hash: ::subxt::utils::H256 }, #[codec(index = 2)] #[doc = "Give a tip for something new; no finder's fee will be taken."] @@ -40106,15 +44142,12 @@ pub mod api { #[doc = ""] #[doc = "Emits `NewTip` if successful."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(R + T)` where `R` length of `reason`, `T` is the number of tippers."] + #[doc = "## Complexity"] + #[doc = "- `O(R + T)` where `R` length of `reason`, `T` is the number of tippers."] #[doc = " - `O(T)`: decoding `Tipper` vec of length `T`. `T` is charged as upper bound given by"] #[doc = " `ContainsLengthBound`. The actual cost depends on the implementation of"] #[doc = " `T::Tippers`."] #[doc = " - `O(R)`: hashing and encoding of reason of length `R`"] - #[doc = "- DbReads: `Tippers`, `Reasons`"] - #[doc = "- DbWrites: `Reasons`, `Tips`"] - #[doc = "# "] tip_new { reason: ::std::vec::Vec<::core::primitive::u8>, who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -40136,16 +44169,13 @@ pub mod api { #[doc = "Emits `TipClosing` if the threshold of tippers has been reached and the countdown period"] #[doc = "has started."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(T)` where `T` is the number of tippers. decoding `Tipper` vec of length"] - #[doc = " `T`, insert tip and check closing, `T` is charged as upper bound given by"] - #[doc = " `ContainsLengthBound`. The actual cost depends on the implementation of `T::Tippers`."] + #[doc = "## Complexity"] + #[doc = "- `O(T)` where `T` is the number of tippers. decoding `Tipper` vec of length `T`, insert"] + #[doc = " tip and check closing, `T` is charged as upper bound given by `ContainsLengthBound`."] + #[doc = " The actual cost depends on the implementation of `T::Tippers`."] #[doc = ""] #[doc = " Actually weight could be lower as it depends on how many tips are in `OpenTip` but it"] #[doc = " is weighted as if almost full i.e of length `T-1`."] - #[doc = "- DbReads: `Tippers`, `Tips`"] - #[doc = "- DbWrites: `Tips`"] - #[doc = "# "] tip { hash: ::subxt::utils::H256, #[codec(compact)] @@ -40161,13 +44191,10 @@ pub mod api { #[doc = "- `hash`: The identity of the open tip for which a tip value is declared. This is formed"] #[doc = " as the hash of the tuple of the original tip `reason` and the beneficiary account ID."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: `O(T)` where `T` is the number of tippers. decoding `Tipper` vec of length"] - #[doc = " `T`. `T` is charged as upper bound given by `ContainsLengthBound`. The actual cost"] - #[doc = " depends on the implementation of `T::Tippers`."] - #[doc = "- DbReads: `Tips`, `Tippers`, `tip finder`"] - #[doc = "- DbWrites: `Reasons`, `Tips`, `Tippers`, `tip finder`"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- : `O(T)` where `T` is the number of tippers. decoding `Tipper` vec of length `T`. `T`"] + #[doc = " is charged as upper bound given by `ContainsLengthBound`. The actual cost depends on"] + #[doc = " the implementation of `T::Tippers`."] close_tip { hash: ::subxt::utils::H256 }, #[codec(index = 5)] #[doc = "Remove and slash an already-open tip."] @@ -40178,10 +44205,8 @@ pub mod api { #[doc = ""] #[doc = "Emits `TipSlashed` if successful."] #[doc = ""] - #[doc = "# "] - #[doc = " `T` is charged as upper bound given by `ContainsLengthBound`."] - #[doc = " The actual cost depends on the implementation of `T::Tippers`."] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- O(1)."] slash_tip { hash: ::subxt::utils::H256 }, } #[derive( @@ -40347,11 +44372,8 @@ pub mod api { #[doc = "is reserved and slashed if the proposal is rejected. It is returned once the"] #[doc = "proposal is awarded."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(1)"] - #[doc = "- DbReads: `ProposalCount`, `origin account`"] - #[doc = "- DbWrites: `ProposalCount`, `Proposals`, `origin account`"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- O(1)"] propose_spend { #[codec(compact)] value: ::core::primitive::u128, @@ -40362,11 +44384,8 @@ pub mod api { #[doc = ""] #[doc = "May only be called from `T::RejectOrigin`."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(1)"] - #[doc = "- DbReads: `Proposals`, `rejected proposer account`"] - #[doc = "- DbWrites: `Proposals`, `rejected proposer account`"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- O(1)"] reject_proposal { #[codec(compact)] proposal_id: ::core::primitive::u32, @@ -40377,11 +44396,8 @@ pub mod api { #[doc = ""] #[doc = "May only be called from `T::ApproveOrigin`."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(1)."] - #[doc = "- DbReads: `Proposals`, `Approvals`"] - #[doc = "- DbWrite: `Approvals`"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = " - O(1)."] approve_proposal { #[codec(compact)] proposal_id: ::core::primitive::u32, @@ -40407,10 +44423,8 @@ pub mod api { #[doc = "May only be called from `T::RejectOrigin`."] #[doc = "- `proposal_id`: The index of a proposal"] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(A) where `A` is the number of approvals"] - #[doc = "- Db reads and writes: `Approvals`"] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- O(A) where `A` is the number of approvals"] #[doc = ""] #[doc = "Errors:"] #[doc = "- `ProposalNotApproved`: The `proposal_id` supplied was not found in the approval queue,"] @@ -40505,6 +44519,12 @@ pub mod api { amount: ::core::primitive::u128, beneficiary: ::subxt::utils::AccountId32, }, + #[codec(index = 8)] + #[doc = "The inactive funds of the pallet have been updated."] + UpdatedInactive { + reactivated: ::core::primitive::u128, + deactivated: ::core::primitive::u128, + }, } } #[derive( @@ -40551,9 +44571,8 @@ pub mod api { #[doc = "If origin is root then the calls are dispatched without checking origin filter. (This"] #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(C) where C is the number of calls to be batched."] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- O(C) where C is the number of calls to be batched."] #[doc = ""] #[doc = "This will return `Ok` in all circumstances. To determine the success of the batch, an"] #[doc = "event is deposited. If a call failed and the batch was interrupted, then the"] @@ -40593,9 +44612,8 @@ pub mod api { #[doc = "If origin is root then the calls are dispatched without checking origin filter. (This"] #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(C) where C is the number of calls to be batched."] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- O(C) where C is the number of calls to be batched."] batch_all { calls: ::std::vec::Vec, }, @@ -40604,12 +44622,8 @@ pub mod api { #[doc = ""] #[doc = "The dispatch origin for this call must be _Root_."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- O(1)."] - #[doc = "- Limited storage reads."] - #[doc = "- One DB write (event)."] - #[doc = "- Weight of derivative `call` execution + T::WeightInfo::dispatch_as()."] - #[doc = "# "] dispatch_as { as_origin: ::std::boxed::Box, call: ::std::boxed::Box, @@ -40626,12 +44640,22 @@ pub mod api { #[doc = "If origin is root then the calls are dispatch without checking origin filter. (This"] #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] #[doc = ""] - #[doc = "# "] - #[doc = "- Complexity: O(C) where C is the number of calls to be batched."] - #[doc = "# "] + #[doc = "## Complexity"] + #[doc = "- O(C) where C is the number of calls to be batched."] force_batch { calls: ::std::vec::Vec, }, + #[codec(index = 5)] + #[doc = "Dispatch a function call with a specified weight."] + #[doc = ""] + #[doc = "This function does not check the weight of the call, and instead allows the"] + #[doc = "Root origin to specify the weight of the call."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Root_."] + with_weight { + call: ::std::boxed::Box, + weight: runtime_types::sp_weights::weight_v2::Weight, + }, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -40715,12 +44739,8 @@ pub mod api { #[doc = ""] #[doc = "Emits either `VestingCompleted` or `VestingUpdated`."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- DbWeight: 2 Reads, 2 Writes"] - #[doc = " - Reads: Vesting Storage, Balances Locks, [Sender Account]"] - #[doc = " - Writes: Vesting Storage, Balances Locks, [Sender Account]"] - #[doc = "# "] vest, #[codec(index = 1)] #[doc = "Unlock any vested funds of a `target` account."] @@ -40732,12 +44752,8 @@ pub mod api { #[doc = ""] #[doc = "Emits either `VestingCompleted` or `VestingUpdated`."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- DbWeight: 3 Reads, 3 Writes"] - #[doc = " - Reads: Vesting Storage, Balances Locks, Target Account"] - #[doc = " - Writes: Vesting Storage, Balances Locks, Target Account"] - #[doc = "# "] vest_other { target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, }, @@ -40753,12 +44769,8 @@ pub mod api { #[doc = ""] #[doc = "NOTE: This will unlock all schedules through the current block."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- DbWeight: 3 Reads, 3 Writes"] - #[doc = " - Reads: Vesting Storage, Balances Locks, Target Account, [Sender Account]"] - #[doc = " - Writes: Vesting Storage, Balances Locks, Target Account, [Sender Account]"] - #[doc = "# "] vested_transfer { target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< @@ -40779,12 +44791,8 @@ pub mod api { #[doc = ""] #[doc = "NOTE: This will unlock all schedules through the current block."] #[doc = ""] - #[doc = "# "] + #[doc = "## Complexity"] #[doc = "- `O(1)`."] - #[doc = "- DbWeight: 4 Reads, 4 Writes"] - #[doc = " - Reads: Vesting Storage, Balances Locks, Target Account, Source Account"] - #[doc = " - Writes: Vesting Storage, Balances Locks, Target Account, Source Account"] - #[doc = "# "] force_vested_transfer { source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, @@ -40910,6 +44918,94 @@ pub mod api { V1, } } + pub mod pallet_whitelist { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub enum Call { + #[codec(index = 0)] + whitelist_call { call_hash: ::subxt::utils::H256 }, + #[codec(index = 1)] + remove_whitelisted_call { call_hash: ::subxt::utils::H256 }, + #[codec(index = 2)] + dispatch_whitelisted_call { + call_hash: ::subxt::utils::H256, + call_encoded_len: ::core::primitive::u32, + call_weight_witness: runtime_types::sp_weights::weight_v2::Weight, + }, + #[codec(index = 3)] + dispatch_whitelisted_call_with_preimage { + call: ::std::boxed::Box, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub enum Error { + #[codec(index = 0)] + #[doc = "The preimage of the call hash could not be loaded."] + UnavailablePreImage, + #[codec(index = 1)] + #[doc = "The call could not be decoded."] + UndecodableCall, + #[codec(index = 2)] + #[doc = "The weight of the decoded call was higher than the witness."] + InvalidCallWeightWitness, + #[codec(index = 3)] + #[doc = "The call was not whitelisted."] + CallIsNotWhitelisted, + #[codec(index = 4)] + #[doc = "The call was already whitelisted; No-Op."] + CallAlreadyWhitelisted, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub enum Event { + #[codec(index = 0)] + CallWhitelisted { call_hash: ::subxt::utils::H256 }, + #[codec(index = 1)] + WhitelistedCallRemoved { call_hash: ::subxt::utils::H256 }, + #[codec(index = 2)] + WhitelistedCallDispatched { + call_hash: ::subxt::utils::H256, + result: ::core::result::Result< + runtime_types::frame_support::dispatch::PostDispatchInfo, + runtime_types::sp_runtime::DispatchErrorWithPostInfo< + runtime_types::frame_support::dispatch::PostDispatchInfo, + >, + >, + }, + } + } + } pub mod pallet_xcm { use super::runtime_types; pub mod pallet { @@ -40990,25 +45086,25 @@ pub mod api { #[doc = "to completion; only that *some* of it was executed."] execute { message: ::std::boxed::Box, - max_weight: ::core::primitive::u64, + max_weight: runtime_types::sp_weights::weight_v2::Weight, }, #[codec(index = 4)] #[doc = "Extoll that a particular destination can be communicated with through a particular"] #[doc = "version of XCM."] #[doc = ""] - #[doc = "- `origin`: Must be Root."] + #[doc = "- `origin`: Must be an origin specified by AdminOrigin."] #[doc = "- `location`: The destination that is being described."] #[doc = "- `xcm_version`: The latest version of XCM that `location` supports."] force_xcm_version { location: - ::std::boxed::Box, + ::std::boxed::Box, xcm_version: ::core::primitive::u32, }, #[codec(index = 5)] #[doc = "Set a safe XCM version (the version that XCM should be encoded with if the most recent"] #[doc = "version a destination can accept is unknown)."] #[doc = ""] - #[doc = "- `origin`: Must be Root."] + #[doc = "- `origin`: Must be an origin specified by AdminOrigin."] #[doc = "- `maybe_xcm_version`: The default XCM encoding version, or `None` to disable."] force_default_xcm_version { maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, @@ -41016,7 +45112,7 @@ pub mod api { #[codec(index = 6)] #[doc = "Ask a location to notify us regarding their XCM version and any changes to it."] #[doc = ""] - #[doc = "- `origin`: Must be Root."] + #[doc = "- `origin`: Must be an origin specified by AdminOrigin."] #[doc = "- `location`: The location to which we should subscribe for XCM version notifications."] force_subscribe_version_notify { location: ::std::boxed::Box, @@ -41025,7 +45121,7 @@ pub mod api { #[doc = "Require that a particular destination should no longer notify us regarding any XCM"] #[doc = "version changes."] #[doc = ""] - #[doc = "- `origin`: Must be Root."] + #[doc = "- `origin`: Must be an origin specified by AdminOrigin."] #[doc = "- `location`: The location to which we are currently subscribed for XCM version"] #[doc = " notifications which we no longer desire."] force_unsubscribe_version_notify { @@ -41055,7 +45151,7 @@ pub mod api { beneficiary: ::std::boxed::Box, assets: ::std::boxed::Box, fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v2::WeightLimit, + weight_limit: runtime_types::xcm::v3::WeightLimit, }, #[codec(index = 9)] #[doc = "Teleport some assets from the local chain to some destination chain."] @@ -41080,8 +45176,14 @@ pub mod api { beneficiary: ::std::boxed::Box, assets: ::std::boxed::Box, fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v2::WeightLimit, + weight_limit: runtime_types::xcm::v3::WeightLimit, }, + #[codec(index = 10)] + #[doc = "Set or unset the global suspension state of the XCM executor."] + #[doc = ""] + #[doc = "- `origin`: Must be an origin specified by AdminOrigin."] + #[doc = "- `suspended`: `true` to suspend, `false` to resume."] + force_suspension { suspended: ::core::primitive::bool }, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -41137,6 +45239,27 @@ pub mod api { #[codec(index = 12)] #[doc = "The location is invalid since it already has a subscription from us."] AlreadySubscribed, + #[codec(index = 13)] + #[doc = "Invalid asset for the operation."] + InvalidAsset, + #[codec(index = 14)] + #[doc = "The owner does not own (all) of the asset that they wish to do the operation on."] + LowBalance, + #[codec(index = 15)] + #[doc = "The asset owner has too many locks on the asset."] + TooManyLocks, + #[codec(index = 16)] + #[doc = "The given account is not an identifiable sovereign account for any location."] + AccountNotSovereign, + #[codec(index = 17)] + #[doc = "The operation required fees to be paid which the initiator could not meet."] + FeesNotMet, + #[codec(index = 18)] + #[doc = "A remote lock with the corresponding data could not be found."] + LockNotFound, + #[codec(index = 19)] + #[doc = "The unlock operation cannot succeed because there are still users of the lock."] + InUse, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -41154,15 +45277,15 @@ pub mod api { #[doc = "Execution of an XCM message was attempted."] #[doc = ""] #[doc = "\\[ outcome \\]"] - Attempted(runtime_types::xcm::v2::traits::Outcome), + Attempted(runtime_types::xcm::v3::traits::Outcome), #[codec(index = 1)] #[doc = "A XCM message was sent."] #[doc = ""] #[doc = "\\[ origin, destination, message \\]"] Sent( - runtime_types::xcm::v1::multilocation::MultiLocation, - runtime_types::xcm::v1::multilocation::MultiLocation, - runtime_types::xcm::v2::Xcm, + runtime_types::xcm::v3::multilocation::MultiLocation, + runtime_types::xcm::v3::multilocation::MultiLocation, + runtime_types::xcm::v3::Xcm, ), #[codec(index = 2)] #[doc = "Query response received which does not match a registered query. This may be because a"] @@ -41171,7 +45294,7 @@ pub mod api { #[doc = ""] #[doc = "\\[ origin location, id \\]"] UnexpectedResponse( - runtime_types::xcm::v1::multilocation::MultiLocation, + runtime_types::xcm::v3::multilocation::MultiLocation, ::core::primitive::u64, ), #[codec(index = 3)] @@ -41179,7 +45302,7 @@ pub mod api { #[doc = "no registered notification call."] #[doc = ""] #[doc = "\\[ id, response \\]"] - ResponseReady(::core::primitive::u64, runtime_types::xcm::v2::Response), + ResponseReady(::core::primitive::u64, runtime_types::xcm::v3::Response), #[codec(index = 4)] #[doc = "Query response has been received and query is removed. The registered notification has"] #[doc = "been dispatched and executed successfully."] @@ -41231,10 +45354,10 @@ pub mod api { #[doc = ""] #[doc = "\\[ origin location, id, expected location \\]"] InvalidResponder( - runtime_types::xcm::v1::multilocation::MultiLocation, + runtime_types::xcm::v3::multilocation::MultiLocation, ::core::primitive::u64, ::core::option::Option< - runtime_types::xcm::v1::multilocation::MultiLocation, + runtime_types::xcm::v3::multilocation::MultiLocation, >, ), #[codec(index = 9)] @@ -41248,7 +45371,7 @@ pub mod api { #[doc = ""] #[doc = "\\[ origin location, id \\]"] InvalidResponderVersion( - runtime_types::xcm::v1::multilocation::MultiLocation, + runtime_types::xcm::v3::multilocation::MultiLocation, ::core::primitive::u64, ), #[codec(index = 10)] @@ -41262,16 +45385,19 @@ pub mod api { #[doc = "\\[ hash, origin, assets \\]"] AssetsTrapped( ::subxt::utils::H256, - runtime_types::xcm::v1::multilocation::MultiLocation, + runtime_types::xcm::v3::multilocation::MultiLocation, runtime_types::xcm::VersionedMultiAssets, ), #[codec(index = 12)] #[doc = "An XCM version change notification message has been attempted to be sent."] #[doc = ""] - #[doc = "\\[ destination, result \\]"] + #[doc = "The cost of sending it (borne by the chain) is included."] + #[doc = ""] + #[doc = "\\[ destination, result, cost \\]"] VersionChangeNotified( - runtime_types::xcm::v1::multilocation::MultiLocation, + runtime_types::xcm::v3::multilocation::MultiLocation, ::core::primitive::u32, + runtime_types::xcm::v3::multiasset::MultiAssets, ), #[codec(index = 13)] #[doc = "The supported version of a location has been changed. This might be through an"] @@ -41279,7 +45405,7 @@ pub mod api { #[doc = ""] #[doc = "\\[ location, XCM version \\]"] SupportedVersionChanged( - runtime_types::xcm::v1::multilocation::MultiLocation, + runtime_types::xcm::v3::multilocation::MultiLocation, ::core::primitive::u32, ), #[codec(index = 14)] @@ -41288,9 +45414,9 @@ pub mod api { #[doc = ""] #[doc = "\\[ location, query ID, error \\]"] NotifyTargetSendFail( - runtime_types::xcm::v1::multilocation::MultiLocation, + runtime_types::xcm::v3::multilocation::MultiLocation, ::core::primitive::u64, - runtime_types::xcm::v2::traits::Error, + runtime_types::xcm::v3::traits::Error, ), #[codec(index = 15)] #[doc = "A given location which had a version change subscription was dropped owing to an error"] @@ -41302,12 +45428,73 @@ pub mod api { ::core::primitive::u64, ), #[codec(index = 16)] + #[doc = "Expected query response has been received but the expected querier location placed in"] + #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] + #[doc = ""] + #[doc = "This is unexpected (since a location placed in storage in a previously executing"] + #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] + #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] + #[doc = "needed."] + #[doc = ""] + #[doc = "\\[ origin location, id \\]"] + InvalidQuerierVersion( + runtime_types::xcm::v3::multilocation::MultiLocation, + ::core::primitive::u64, + ), + #[codec(index = 17)] + #[doc = "Expected query response has been received but the querier location of the response does"] + #[doc = "not match the expected. The query remains registered for a later, valid, response to"] + #[doc = "be received and acted upon."] + #[doc = ""] + #[doc = "\\[ origin location, id, expected querier, maybe actual querier \\]"] + InvalidQuerier( + runtime_types::xcm::v3::multilocation::MultiLocation, + ::core::primitive::u64, + runtime_types::xcm::v3::multilocation::MultiLocation, + ::core::option::Option< + runtime_types::xcm::v3::multilocation::MultiLocation, + >, + ), + #[codec(index = 18)] + #[doc = "A remote has requested XCM version change notification from us and we have honored it."] + #[doc = "A version information message is sent to them and its cost is included."] + #[doc = ""] + #[doc = "\\[ destination location, cost \\]"] + VersionNotifyStarted( + runtime_types::xcm::v3::multilocation::MultiLocation, + runtime_types::xcm::v3::multiasset::MultiAssets, + ), + #[codec(index = 19)] + #[doc = "We have requested that a remote chain sends us XCM version change notifications."] + #[doc = ""] + #[doc = "\\[ destination location, cost \\]"] + VersionNotifyRequested( + runtime_types::xcm::v3::multilocation::MultiLocation, + runtime_types::xcm::v3::multiasset::MultiAssets, + ), + #[codec(index = 20)] + #[doc = "We have requested that a remote chain stops sending us XCM version change notifications."] + #[doc = ""] + #[doc = "\\[ destination location, cost \\]"] + VersionNotifyUnrequested( + runtime_types::xcm::v3::multilocation::MultiLocation, + runtime_types::xcm::v3::multiasset::MultiAssets, + ), + #[codec(index = 21)] + #[doc = "Fees were paid from a location for an operation (often for using `SendXcm`)."] + #[doc = ""] + #[doc = "\\[ paying location, fees \\]"] + FeesPaid( + runtime_types::xcm::v3::multilocation::MultiLocation, + runtime_types::xcm::v3::multiasset::MultiAssets, + ), + #[codec(index = 22)] #[doc = "Some assets have been claimed from an asset trap"] #[doc = ""] #[doc = "\\[ hash, origin, assets \\]"] AssetsClaimed( ::subxt::utils::H256, - runtime_types::xcm::v1::multilocation::MultiLocation, + runtime_types::xcm::v3::multilocation::MultiLocation, runtime_types::xcm::VersionedMultiAssets, ), } @@ -41323,9 +45510,9 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Origin { #[codec(index = 0)] - Xcm(runtime_types::xcm::v1::multilocation::MultiLocation), + Xcm(runtime_types::xcm::v3::multilocation::MultiLocation), #[codec(index = 1)] - Response(runtime_types::xcm::v1::multilocation::MultiLocation), + Response(runtime_types::xcm::v3::multilocation::MultiLocation), } #[derive( :: subxt :: ext :: codec :: Decode, @@ -41341,6 +45528,8 @@ pub mod api { #[codec(index = 0)] Pending { responder: runtime_types::xcm::VersionedMultiLocation, + maybe_match_querier: + ::core::option::Option, maybe_notify: ::core::option::Option<(::core::primitive::u8, ::core::primitive::u8)>, timeout: _0, @@ -41366,6 +45555,22 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoteLockedFungibleRecord { + pub amount: ::core::primitive::u128, + pub owner: runtime_types::xcm::VersionedMultiLocation, + pub locker: runtime_types::xcm::VersionedMultiLocation, + pub users: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum VersionMigrationStage { #[codec(index = 0)] MigrateSupportedVersion, @@ -41503,7 +45708,7 @@ pub mod api { } pub mod polkadot_primitives { use super::runtime_types; - pub mod v2 { + pub mod v4 { use super::runtime_types; pub mod assignment_app { use super::runtime_types; @@ -41544,6 +45749,56 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); } + pub mod executor_params { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum ExecutorParam { + #[codec(index = 1)] + MaxMemoryPages(::core::primitive::u32), + #[codec(index = 2)] + StackLogicalMax(::core::primitive::u32), + #[codec(index = 3)] + StackNativeMax(::core::primitive::u32), + #[codec(index = 4)] + PrecheckingMaxMemory(::core::primitive::u64), + #[codec(index = 5)] + PvfPrepTimeout( + runtime_types::polkadot_primitives::v4::PvfPrepTimeoutKind, + ::core::primitive::u64, + ), + #[codec(index = 6)] + PvfExecTimeout( + runtime_types::polkadot_primitives::v4::PvfExecTimeoutKind, + ::core::primitive::u64, + ), + #[codec(index = 7)] + WasmExtBulkMemory, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ExecutorParams( + pub ::std::vec::Vec< + runtime_types::polkadot_primitives::v4::executor_params::ExecutorParam, + >, + ); + } pub mod signed { use super::runtime_types; #[derive( @@ -41558,9 +45813,9 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct UncheckedSigned<_0, _1> { pub payload: _0, - pub validator_index: runtime_types::polkadot_primitives::v2::ValidatorIndex, + pub validator_index: runtime_types::polkadot_primitives::v4::ValidatorIndex, pub signature: - runtime_types::polkadot_primitives::v2::validator_app::Signature, + runtime_types::polkadot_primitives::v4::validator_app::Signature, #[codec(skip)] pub __subxt_unused_type_params: ::core::marker::PhantomData<_1>, } @@ -41618,9 +45873,9 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BackedCandidate<_0> { pub candidate: - runtime_types::polkadot_primitives::v2::CommittedCandidateReceipt<_0>, + runtime_types::polkadot_primitives::v4::CommittedCandidateReceipt<_0>, pub validity_votes: ::std::vec::Vec< - runtime_types::polkadot_primitives::v2::ValidityAttestation, + runtime_types::polkadot_primitives::v4::ValidityAttestation, >, pub validator_indices: ::subxt::utils::bits::DecodedBits< ::core::primitive::u8, @@ -41638,12 +45893,16 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CandidateCommitments<_0> { - pub upward_messages: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - pub horizontal_messages: ::std::vec::Vec< - runtime_types::polkadot_core_primitives::OutboundHrmpMessage< - runtime_types::polkadot_parachain::primitives::Id, + pub upward_messages: + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::std::vec::Vec<::core::primitive::u8>, + >, + pub horizontal_messages: + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::polkadot_core_primitives::OutboundHrmpMessage< + runtime_types::polkadot_parachain::primitives::Id, + >, >, - >, pub new_validation_code: ::core::option::Option< runtime_types::polkadot_parachain::primitives::ValidationCode, >, @@ -41664,11 +45923,11 @@ pub mod api { pub struct CandidateDescriptor<_0> { pub para_id: runtime_types::polkadot_parachain::primitives::Id, pub relay_parent: _0, - pub collator: runtime_types::polkadot_primitives::v2::collator_app::Public, + pub collator: runtime_types::polkadot_primitives::v4::collator_app::Public, pub persisted_validation_data_hash: _0, pub pov_hash: _0, pub erasure_root: _0, - pub signature: runtime_types::polkadot_primitives::v2::collator_app::Signature, + pub signature: runtime_types::polkadot_primitives::v4::collator_app::Signature, pub para_head: _0, pub validation_code_hash: runtime_types::polkadot_parachain::primitives::ValidationCodeHash, @@ -41684,7 +45943,7 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CandidateReceipt<_0> { - pub descriptor: runtime_types::polkadot_primitives::v2::CandidateDescriptor<_0>, + pub descriptor: runtime_types::polkadot_primitives::v4::CandidateDescriptor<_0>, pub commitments_hash: _0, } #[derive( @@ -41698,8 +45957,8 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CommittedCandidateReceipt<_0> { - pub descriptor: runtime_types::polkadot_primitives::v2::CandidateDescriptor<_0>, - pub commitments: runtime_types::polkadot_primitives::v2::CandidateCommitments< + pub descriptor: runtime_types::polkadot_primitives::v4::CandidateDescriptor<_0>, + pub commitments: runtime_types::polkadot_primitives::v4::CandidateCommitments< ::core::primitive::u32, >, } @@ -41727,7 +45986,7 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum CoreOccupied { #[codec(index = 0)] - Parathread(runtime_types::polkadot_primitives::v2::ParathreadEntry), + Parathread(runtime_types::polkadot_primitives::v4::ParathreadEntry), #[codec(index = 1)] Parachain, } @@ -41765,9 +46024,9 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum DisputeStatement { #[codec(index = 0)] - Valid(runtime_types::polkadot_primitives::v2::ValidDisputeStatementKind), + Valid(runtime_types::polkadot_primitives::v4::ValidDisputeStatementKind), #[codec(index = 1)] - Invalid(runtime_types::polkadot_primitives::v2::InvalidDisputeStatementKind), + Invalid(runtime_types::polkadot_primitives::v4::InvalidDisputeStatementKind), } #[derive( :: subxt :: ext :: codec :: Decode, @@ -41783,9 +46042,9 @@ pub mod api { pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, pub session: ::core::primitive::u32, pub statements: ::std::vec::Vec<( - runtime_types::polkadot_primitives::v2::DisputeStatement, - runtime_types::polkadot_primitives::v2::ValidatorIndex, - runtime_types::polkadot_primitives::v2::validator_app::Signature, + runtime_types::polkadot_primitives::v4::DisputeStatement, + runtime_types::polkadot_primitives::v4::ValidatorIndex, + runtime_types::polkadot_primitives::v4::validator_app::Signature, )>, } #[derive( @@ -41826,18 +46085,18 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct InherentData<_0> { pub bitfields: ::std::vec::Vec< - runtime_types::polkadot_primitives::v2::signed::UncheckedSigned< - runtime_types::polkadot_primitives::v2::AvailabilityBitfield, - runtime_types::polkadot_primitives::v2::AvailabilityBitfield, + runtime_types::polkadot_primitives::v4::signed::UncheckedSigned< + runtime_types::polkadot_primitives::v4::AvailabilityBitfield, + runtime_types::polkadot_primitives::v4::AvailabilityBitfield, >, >, pub backed_candidates: ::std::vec::Vec< - runtime_types::polkadot_primitives::v2::BackedCandidate< + runtime_types::polkadot_primitives::v4::BackedCandidate< ::subxt::utils::H256, >, >, pub disputes: ::std::vec::Vec< - runtime_types::polkadot_primitives::v2::DisputeStatementSet, + runtime_types::polkadot_primitives::v4::DisputeStatementSet, >, pub parent_header: _0, } @@ -41867,7 +46126,7 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ParathreadClaim( pub runtime_types::polkadot_parachain::primitives::Id, - pub runtime_types::polkadot_primitives::v2::collator_app::Public, + pub runtime_types::polkadot_primitives::v4::collator_app::Public, ); #[derive( :: subxt :: ext :: codec :: Decode, @@ -41880,7 +46139,7 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ParathreadEntry { - pub claim: runtime_types::polkadot_primitives::v2::ParathreadClaim, + pub claim: runtime_types::polkadot_primitives::v4::ParathreadClaim, pub retries: ::core::primitive::u32, } #[derive( @@ -41897,7 +46156,39 @@ pub mod api { pub accept: ::core::primitive::bool, pub subject: runtime_types::polkadot_parachain::primitives::ValidationCodeHash, pub session_index: ::core::primitive::u32, - pub validator_index: runtime_types::polkadot_primitives::v2::ValidatorIndex, + pub validator_index: runtime_types::polkadot_primitives::v4::ValidatorIndex, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum PvfExecTimeoutKind { + #[codec(index = 0)] + Backing, + #[codec(index = 1)] + Approval, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum PvfPrepTimeoutKind { + #[codec(index = 0)] + Precheck, + #[codec(index = 1)] + Lenient, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -41912,14 +46203,14 @@ pub mod api { pub struct ScrapedOnChainVotes<_0> { pub session: ::core::primitive::u32, pub backing_validators_per_candidate: ::std::vec::Vec<( - runtime_types::polkadot_primitives::v2::CandidateReceipt<_0>, + runtime_types::polkadot_primitives::v4::CandidateReceipt<_0>, ::std::vec::Vec<( - runtime_types::polkadot_primitives::v2::ValidatorIndex, - runtime_types::polkadot_primitives::v2::ValidityAttestation, + runtime_types::polkadot_primitives::v4::ValidatorIndex, + runtime_types::polkadot_primitives::v4::ValidityAttestation, )>, )>, pub disputes: ::std::vec::Vec< - runtime_types::polkadot_primitives::v2::DisputeStatementSet, + runtime_types::polkadot_primitives::v4::DisputeStatementSet, >, } #[derive( @@ -41934,21 +46225,21 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SessionInfo { pub active_validator_indices: - ::std::vec::Vec, + ::std::vec::Vec, pub random_seed: [::core::primitive::u8; 32usize], pub dispute_period: ::core::primitive::u32, - pub validators: runtime_types::polkadot_primitives::v2::IndexedVec< - runtime_types::polkadot_primitives::v2::ValidatorIndex, - runtime_types::polkadot_primitives::v2::validator_app::Public, + pub validators: runtime_types::polkadot_primitives::v4::IndexedVec< + runtime_types::polkadot_primitives::v4::ValidatorIndex, + runtime_types::polkadot_primitives::v4::validator_app::Public, >, pub discovery_keys: ::std::vec::Vec, pub assignment_keys: ::std::vec::Vec< - runtime_types::polkadot_primitives::v2::assignment_app::Public, + runtime_types::polkadot_primitives::v4::assignment_app::Public, >, - pub validator_groups: runtime_types::polkadot_primitives::v2::IndexedVec< - runtime_types::polkadot_primitives::v2::GroupIndex, - ::std::vec::Vec, + pub validator_groups: runtime_types::polkadot_primitives::v4::IndexedVec< + runtime_types::polkadot_primitives::v4::GroupIndex, + ::std::vec::Vec, >, pub n_cores: ::core::primitive::u32, pub zeroth_delay_tranche_width: ::core::primitive::u32, @@ -42031,14 +46322,80 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum ValidityAttestation { #[codec(index = 1)] - Implicit(runtime_types::polkadot_primitives::v2::validator_app::Signature), + Implicit(runtime_types::polkadot_primitives::v4::validator_app::Signature), #[codec(index = 2)] - Explicit(runtime_types::polkadot_primitives::v2::validator_app::Signature), + Explicit(runtime_types::polkadot_primitives::v4::validator_app::Signature), + } + } + pub mod vstaging { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AsyncBackingParams { + pub max_candidate_depth: ::core::primitive::u32, + pub allowed_ancestry_len: ::core::primitive::u32, } } } pub mod polkadot_runtime { use super::runtime_types; + pub mod governance { + use super::runtime_types; + pub mod origins { + use super::runtime_types; + pub mod pallet_custom_origins { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Origin { + #[codec(index = 0)] + StakingAdmin, + #[codec(index = 1)] + Treasurer, + #[codec(index = 2)] + FellowshipAdmin, + #[codec(index = 3)] + GeneralAdmin, + #[codec(index = 4)] + AuctionAdmin, + #[codec(index = 5)] + LeaseAdmin, + #[codec(index = 6)] + ReferendumCanceller, + #[codec(index = 7)] + ReferendumKiller, + #[codec(index = 8)] + SmallTipper, + #[codec(index = 9)] + BigTipper, + #[codec(index = 10)] + SmallSpender, + #[codec(index = 11)] + MediumSpender, + #[codec(index = 12)] + BigSpender, + #[codec(index = 13)] + WhitelistedCaller, + } + } + } + } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -42216,25 +46573,7 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum OriginCaller { - #[codec(index = 0)] - system( - runtime_types::frame_support::dispatch::RawOrigin<::subxt::utils::AccountId32>, - ), - #[codec(index = 15)] - Council(runtime_types::pallet_collective::RawOrigin<::subxt::utils::AccountId32>), - #[codec(index = 16)] - TechnicalCommittee( - runtime_types::pallet_collective::RawOrigin<::subxt::utils::AccountId32>, - ), - #[codec(index = 50)] - ParachainsOrigin( - runtime_types::polkadot_runtime_parachains::origin::pallet::Origin, - ), - #[codec(index = 99)] - XcmPallet(runtime_types::pallet_xcm::pallet::Origin), - #[codec(index = 5)] - Void(runtime_types::sp_core::Void), - } + # [codec (index = 0)] system (runtime_types :: frame_support :: dispatch :: RawOrigin < :: subxt :: utils :: AccountId32 > ,) , # [codec (index = 15)] Council (runtime_types :: pallet_collective :: RawOrigin < :: subxt :: utils :: AccountId32 > ,) , # [codec (index = 16)] TechnicalCommittee (runtime_types :: pallet_collective :: RawOrigin < :: subxt :: utils :: AccountId32 > ,) , # [codec (index = 22)] Origins (runtime_types :: polkadot_runtime :: governance :: origins :: pallet_custom_origins :: Origin ,) , # [codec (index = 50)] ParachainsOrigin (runtime_types :: polkadot_runtime_parachains :: origin :: pallet :: Origin ,) , # [codec (index = 99)] XcmPallet (runtime_types :: pallet_xcm :: pallet :: Origin ,) , # [codec (index = 6)] Void (runtime_types :: sp_core :: Void ,) , } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -42260,6 +46599,8 @@ pub mod api { CancelProxy, #[codec(index = 7)] Auction, + #[codec(index = 8)] + NominationPools, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -42297,8 +46638,6 @@ pub mod api { Indices(runtime_types::pallet_indices::pallet::Call), #[codec(index = 5)] Balances(runtime_types::pallet_balances::pallet::Call), - #[codec(index = 6)] - Authorship(runtime_types::pallet_authorship::pallet::Call), #[codec(index = 7)] Staking(runtime_types::pallet_staking::pallet::pallet::Call), #[codec(index = 9)] @@ -42319,6 +46658,12 @@ pub mod api { TechnicalMembership(runtime_types::pallet_membership::pallet::Call), #[codec(index = 19)] Treasury(runtime_types::pallet_treasury::pallet::Call), + #[codec(index = 20)] + ConvictionVoting(runtime_types::pallet_conviction_voting::pallet::Call), + #[codec(index = 21)] + Referenda(runtime_types::pallet_referenda::pallet::Call), + #[codec(index = 23)] + Whitelist(runtime_types::pallet_whitelist::pallet::Call), #[codec(index = 24)] Claims(runtime_types::polkadot_runtime_common::claims::pallet::Call), #[codec(index = 25)] @@ -42363,14 +46708,16 @@ pub mod api { Paras(runtime_types::polkadot_runtime_parachains::paras::pallet::Call), #[codec(index = 57)] Initializer(runtime_types::polkadot_runtime_parachains::initializer::pallet::Call), - #[codec(index = 58)] - Dmp(runtime_types::polkadot_runtime_parachains::dmp::pallet::Call), #[codec(index = 59)] Ump(runtime_types::polkadot_runtime_parachains::ump::pallet::Call), #[codec(index = 60)] Hrmp(runtime_types::polkadot_runtime_parachains::hrmp::pallet::Call), #[codec(index = 62)] ParasDisputes(runtime_types::polkadot_runtime_parachains::disputes::pallet::Call), + #[codec(index = 63)] + ParasSlashing( + runtime_types::polkadot_runtime_parachains::disputes::slashing::pallet::Call, + ), #[codec(index = 70)] Registrar(runtime_types::polkadot_runtime_common::paras_registrar::pallet::Call), #[codec(index = 71)] @@ -42427,6 +46774,12 @@ pub mod api { TechnicalMembership(runtime_types::pallet_membership::pallet::Event), #[codec(index = 19)] Treasury(runtime_types::pallet_treasury::pallet::Event), + #[codec(index = 20)] + ConvictionVoting(runtime_types::pallet_conviction_voting::pallet::Event), + #[codec(index = 21)] + Referenda(runtime_types::pallet_referenda::pallet::Event), + #[codec(index = 23)] + Whitelist(runtime_types::pallet_whitelist::pallet::Event), #[codec(index = 24)] Claims(runtime_types::polkadot_runtime_common::claims::pallet::Event), #[codec(index = 25)] @@ -42487,11 +46840,11 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct SessionKeys { - pub grandpa: runtime_types::sp_finality_grandpa::app::Public, + pub grandpa: runtime_types::sp_consensus_grandpa::app::Public, pub babe: runtime_types::sp_consensus_babe::app::Public, pub im_online: runtime_types::pallet_im_online::sr25519::app_sr25519::Public, - pub para_validator: runtime_types::polkadot_primitives::v2::validator_app::Public, - pub para_assignment: runtime_types::polkadot_primitives::v2::assignment_app::Public, + pub para_validator: runtime_types::polkadot_primitives::v4::validator_app::Public, + pub para_assignment: runtime_types::polkadot_primitives::v4::assignment_app::Public, pub authority_discovery: runtime_types::sp_authority_discovery::app::Public, } } @@ -43433,6 +47786,11 @@ pub mod api { para_id: runtime_types::polkadot_parachain::primitives::Id, who: ::subxt::utils::AccountId32, }, + #[codec(index = 3)] + Swapped { + para_id: runtime_types::polkadot_parachain::primitives::Id, + other_id: runtime_types::polkadot_parachain::primitives::Id, + }, } } #[derive( @@ -43568,158 +47926,7 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub enum Call { - #[codec(index = 0)] - #[doc = "Set the validation upgrade cooldown."] - set_validation_upgrade_cooldown { new: ::core::primitive::u32 }, - #[codec(index = 1)] - #[doc = "Set the validation upgrade delay."] - set_validation_upgrade_delay { new: ::core::primitive::u32 }, - #[codec(index = 2)] - #[doc = "Set the acceptance period for an included candidate."] - set_code_retention_period { new: ::core::primitive::u32 }, - #[codec(index = 3)] - #[doc = "Set the max validation code size for incoming upgrades."] - set_max_code_size { new: ::core::primitive::u32 }, - #[codec(index = 4)] - #[doc = "Set the max POV block size for incoming upgrades."] - set_max_pov_size { new: ::core::primitive::u32 }, - #[codec(index = 5)] - #[doc = "Set the max head data size for paras."] - set_max_head_data_size { new: ::core::primitive::u32 }, - #[codec(index = 6)] - #[doc = "Set the number of parathread execution cores."] - set_parathread_cores { new: ::core::primitive::u32 }, - #[codec(index = 7)] - #[doc = "Set the number of retries for a particular parathread."] - set_parathread_retries { new: ::core::primitive::u32 }, - #[codec(index = 8)] - #[doc = "Set the parachain validator-group rotation frequency"] - set_group_rotation_frequency { new: ::core::primitive::u32 }, - #[codec(index = 9)] - #[doc = "Set the availability period for parachains."] - set_chain_availability_period { new: ::core::primitive::u32 }, - #[codec(index = 10)] - #[doc = "Set the availability period for parathreads."] - set_thread_availability_period { new: ::core::primitive::u32 }, - #[codec(index = 11)] - #[doc = "Set the scheduling lookahead, in expected number of blocks at peak throughput."] - set_scheduling_lookahead { new: ::core::primitive::u32 }, - #[codec(index = 12)] - #[doc = "Set the maximum number of validators to assign to any core."] - set_max_validators_per_core { - new: ::core::option::Option<::core::primitive::u32>, - }, - #[codec(index = 13)] - #[doc = "Set the maximum number of validators to use in parachain consensus."] - set_max_validators { - new: ::core::option::Option<::core::primitive::u32>, - }, - #[codec(index = 14)] - #[doc = "Set the dispute period, in number of sessions to keep for disputes."] - set_dispute_period { new: ::core::primitive::u32 }, - #[codec(index = 15)] - #[doc = "Set the dispute post conclusion acceptance period."] - set_dispute_post_conclusion_acceptance_period { - new: ::core::primitive::u32, - }, - #[codec(index = 16)] - #[doc = "Set the maximum number of dispute spam slots."] - set_dispute_max_spam_slots { new: ::core::primitive::u32 }, - #[codec(index = 17)] - #[doc = "Set the dispute conclusion by time out period."] - set_dispute_conclusion_by_time_out_period { new: ::core::primitive::u32 }, - #[codec(index = 18)] - #[doc = "Set the no show slots, in number of number of consensus slots."] - #[doc = "Must be at least 1."] - set_no_show_slots { new: ::core::primitive::u32 }, - #[codec(index = 19)] - #[doc = "Set the total number of delay tranches."] - set_n_delay_tranches { new: ::core::primitive::u32 }, - #[codec(index = 20)] - #[doc = "Set the zeroth delay tranche width."] - set_zeroth_delay_tranche_width { new: ::core::primitive::u32 }, - #[codec(index = 21)] - #[doc = "Set the number of validators needed to approve a block."] - set_needed_approvals { new: ::core::primitive::u32 }, - #[codec(index = 22)] - #[doc = "Set the number of samples to do of the `RelayVRFModulo` approval assignment criterion."] - set_relay_vrf_modulo_samples { new: ::core::primitive::u32 }, - #[codec(index = 23)] - #[doc = "Sets the maximum items that can present in a upward dispatch queue at once."] - set_max_upward_queue_count { new: ::core::primitive::u32 }, - #[codec(index = 24)] - #[doc = "Sets the maximum total size of items that can present in a upward dispatch queue at once."] - set_max_upward_queue_size { new: ::core::primitive::u32 }, - #[codec(index = 25)] - #[doc = "Set the critical downward message size."] - set_max_downward_message_size { new: ::core::primitive::u32 }, - #[codec(index = 26)] - #[doc = "Sets the soft limit for the phase of dispatching dispatchable upward messages."] - set_ump_service_total_weight { - new: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 27)] - #[doc = "Sets the maximum size of an upward message that can be sent by a candidate."] - set_max_upward_message_size { new: ::core::primitive::u32 }, - #[codec(index = 28)] - #[doc = "Sets the maximum number of messages that a candidate can contain."] - set_max_upward_message_num_per_candidate { new: ::core::primitive::u32 }, - #[codec(index = 29)] - #[doc = "Sets the number of sessions after which an HRMP open channel request expires."] - set_hrmp_open_request_ttl { new: ::core::primitive::u32 }, - #[codec(index = 30)] - #[doc = "Sets the amount of funds that the sender should provide for opening an HRMP channel."] - set_hrmp_sender_deposit { new: ::core::primitive::u128 }, - #[codec(index = 31)] - #[doc = "Sets the amount of funds that the recipient should provide for accepting opening an HRMP"] - #[doc = "channel."] - set_hrmp_recipient_deposit { new: ::core::primitive::u128 }, - #[codec(index = 32)] - #[doc = "Sets the maximum number of messages allowed in an HRMP channel at once."] - set_hrmp_channel_max_capacity { new: ::core::primitive::u32 }, - #[codec(index = 33)] - #[doc = "Sets the maximum total size of messages in bytes allowed in an HRMP channel at once."] - set_hrmp_channel_max_total_size { new: ::core::primitive::u32 }, - #[codec(index = 34)] - #[doc = "Sets the maximum number of inbound HRMP channels a parachain is allowed to accept."] - set_hrmp_max_parachain_inbound_channels { new: ::core::primitive::u32 }, - #[codec(index = 35)] - #[doc = "Sets the maximum number of inbound HRMP channels a parathread is allowed to accept."] - set_hrmp_max_parathread_inbound_channels { new: ::core::primitive::u32 }, - #[codec(index = 36)] - #[doc = "Sets the maximum size of a message that could ever be put into an HRMP channel."] - set_hrmp_channel_max_message_size { new: ::core::primitive::u32 }, - #[codec(index = 37)] - #[doc = "Sets the maximum number of outbound HRMP channels a parachain is allowed to open."] - set_hrmp_max_parachain_outbound_channels { new: ::core::primitive::u32 }, - #[codec(index = 38)] - #[doc = "Sets the maximum number of outbound HRMP channels a parathread is allowed to open."] - set_hrmp_max_parathread_outbound_channels { new: ::core::primitive::u32 }, - #[codec(index = 39)] - #[doc = "Sets the maximum number of outbound HRMP messages can be sent by a candidate."] - set_hrmp_max_message_num_per_candidate { new: ::core::primitive::u32 }, - #[codec(index = 40)] - #[doc = "Sets the maximum amount of weight any individual upward message may consume."] - set_ump_max_individual_weight { - new: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 41)] - #[doc = "Enable or disable PVF pre-checking. Consult the field documentation prior executing."] - set_pvf_checking_enabled { new: ::core::primitive::bool }, - #[codec(index = 42)] - #[doc = "Set the number of session changes after which a PVF pre-checking voting is rejected."] - set_pvf_voting_ttl { new: ::core::primitive::u32 }, - #[codec(index = 43)] - #[doc = "Sets the minimum delay between announcing the upgrade block for a parachain until the"] - #[doc = "upgrade taking place."] - #[doc = ""] - #[doc = "See the field documentation for information and constraints for the new value."] - set_minimum_validation_upgrade_delay { new: ::core::primitive::u32 }, - #[codec(index = 44)] - #[doc = "Setting this to true will disable consistency checks for the configuration setters."] - #[doc = "Use with caution."] - set_bypass_consistency_check { new: ::core::primitive::bool }, - } + # [codec (index = 0)] # [doc = "Set the validation upgrade cooldown."] set_validation_upgrade_cooldown { new : :: core :: primitive :: u32 , } , # [codec (index = 1)] # [doc = "Set the validation upgrade delay."] set_validation_upgrade_delay { new : :: core :: primitive :: u32 , } , # [codec (index = 2)] # [doc = "Set the acceptance period for an included candidate."] set_code_retention_period { new : :: core :: primitive :: u32 , } , # [codec (index = 3)] # [doc = "Set the max validation code size for incoming upgrades."] set_max_code_size { new : :: core :: primitive :: u32 , } , # [codec (index = 4)] # [doc = "Set the max POV block size for incoming upgrades."] set_max_pov_size { new : :: core :: primitive :: u32 , } , # [codec (index = 5)] # [doc = "Set the max head data size for paras."] set_max_head_data_size { new : :: core :: primitive :: u32 , } , # [codec (index = 6)] # [doc = "Set the number of parathread execution cores."] set_parathread_cores { new : :: core :: primitive :: u32 , } , # [codec (index = 7)] # [doc = "Set the number of retries for a particular parathread."] set_parathread_retries { new : :: core :: primitive :: u32 , } , # [codec (index = 8)] # [doc = "Set the parachain validator-group rotation frequency"] set_group_rotation_frequency { new : :: core :: primitive :: u32 , } , # [codec (index = 9)] # [doc = "Set the availability period for parachains."] set_chain_availability_period { new : :: core :: primitive :: u32 , } , # [codec (index = 10)] # [doc = "Set the availability period for parathreads."] set_thread_availability_period { new : :: core :: primitive :: u32 , } , # [codec (index = 11)] # [doc = "Set the scheduling lookahead, in expected number of blocks at peak throughput."] set_scheduling_lookahead { new : :: core :: primitive :: u32 , } , # [codec (index = 12)] # [doc = "Set the maximum number of validators to assign to any core."] set_max_validators_per_core { new : :: core :: option :: Option < :: core :: primitive :: u32 > , } , # [codec (index = 13)] # [doc = "Set the maximum number of validators to use in parachain consensus."] set_max_validators { new : :: core :: option :: Option < :: core :: primitive :: u32 > , } , # [codec (index = 14)] # [doc = "Set the dispute period, in number of sessions to keep for disputes."] set_dispute_period { new : :: core :: primitive :: u32 , } , # [codec (index = 15)] # [doc = "Set the dispute post conclusion acceptance period."] set_dispute_post_conclusion_acceptance_period { new : :: core :: primitive :: u32 , } , # [codec (index = 18)] # [doc = "Set the no show slots, in number of number of consensus slots."] # [doc = "Must be at least 1."] set_no_show_slots { new : :: core :: primitive :: u32 , } , # [codec (index = 19)] # [doc = "Set the total number of delay tranches."] set_n_delay_tranches { new : :: core :: primitive :: u32 , } , # [codec (index = 20)] # [doc = "Set the zeroth delay tranche width."] set_zeroth_delay_tranche_width { new : :: core :: primitive :: u32 , } , # [codec (index = 21)] # [doc = "Set the number of validators needed to approve a block."] set_needed_approvals { new : :: core :: primitive :: u32 , } , # [codec (index = 22)] # [doc = "Set the number of samples to do of the `RelayVRFModulo` approval assignment criterion."] set_relay_vrf_modulo_samples { new : :: core :: primitive :: u32 , } , # [codec (index = 23)] # [doc = "Sets the maximum items that can present in a upward dispatch queue at once."] set_max_upward_queue_count { new : :: core :: primitive :: u32 , } , # [codec (index = 24)] # [doc = "Sets the maximum total size of items that can present in a upward dispatch queue at once."] set_max_upward_queue_size { new : :: core :: primitive :: u32 , } , # [codec (index = 25)] # [doc = "Set the critical downward message size."] set_max_downward_message_size { new : :: core :: primitive :: u32 , } , # [codec (index = 26)] # [doc = "Sets the soft limit for the phase of dispatching dispatchable upward messages."] set_ump_service_total_weight { new : runtime_types :: sp_weights :: weight_v2 :: Weight , } , # [codec (index = 27)] # [doc = "Sets the maximum size of an upward message that can be sent by a candidate."] set_max_upward_message_size { new : :: core :: primitive :: u32 , } , # [codec (index = 28)] # [doc = "Sets the maximum number of messages that a candidate can contain."] set_max_upward_message_num_per_candidate { new : :: core :: primitive :: u32 , } , # [codec (index = 29)] # [doc = "Sets the number of sessions after which an HRMP open channel request expires."] set_hrmp_open_request_ttl { new : :: core :: primitive :: u32 , } , # [codec (index = 30)] # [doc = "Sets the amount of funds that the sender should provide for opening an HRMP channel."] set_hrmp_sender_deposit { new : :: core :: primitive :: u128 , } , # [codec (index = 31)] # [doc = "Sets the amount of funds that the recipient should provide for accepting opening an HRMP"] # [doc = "channel."] set_hrmp_recipient_deposit { new : :: core :: primitive :: u128 , } , # [codec (index = 32)] # [doc = "Sets the maximum number of messages allowed in an HRMP channel at once."] set_hrmp_channel_max_capacity { new : :: core :: primitive :: u32 , } , # [codec (index = 33)] # [doc = "Sets the maximum total size of messages in bytes allowed in an HRMP channel at once."] set_hrmp_channel_max_total_size { new : :: core :: primitive :: u32 , } , # [codec (index = 34)] # [doc = "Sets the maximum number of inbound HRMP channels a parachain is allowed to accept."] set_hrmp_max_parachain_inbound_channels { new : :: core :: primitive :: u32 , } , # [codec (index = 35)] # [doc = "Sets the maximum number of inbound HRMP channels a parathread is allowed to accept."] set_hrmp_max_parathread_inbound_channels { new : :: core :: primitive :: u32 , } , # [codec (index = 36)] # [doc = "Sets the maximum size of a message that could ever be put into an HRMP channel."] set_hrmp_channel_max_message_size { new : :: core :: primitive :: u32 , } , # [codec (index = 37)] # [doc = "Sets the maximum number of outbound HRMP channels a parachain is allowed to open."] set_hrmp_max_parachain_outbound_channels { new : :: core :: primitive :: u32 , } , # [codec (index = 38)] # [doc = "Sets the maximum number of outbound HRMP channels a parathread is allowed to open."] set_hrmp_max_parathread_outbound_channels { new : :: core :: primitive :: u32 , } , # [codec (index = 39)] # [doc = "Sets the maximum number of outbound HRMP messages can be sent by a candidate."] set_hrmp_max_message_num_per_candidate { new : :: core :: primitive :: u32 , } , # [codec (index = 40)] # [doc = "Sets the maximum amount of weight any individual upward message may consume."] set_ump_max_individual_weight { new : runtime_types :: sp_weights :: weight_v2 :: Weight , } , # [codec (index = 41)] # [doc = "Enable or disable PVF pre-checking. Consult the field documentation prior executing."] set_pvf_checking_enabled { new : :: core :: primitive :: bool , } , # [codec (index = 42)] # [doc = "Set the number of session changes after which a PVF pre-checking voting is rejected."] set_pvf_voting_ttl { new : :: core :: primitive :: u32 , } , # [codec (index = 43)] # [doc = "Sets the minimum delay between announcing the upgrade block for a parachain until the"] # [doc = "upgrade taking place."] # [doc = ""] # [doc = "See the field documentation for information and constraints for the new value."] set_minimum_validation_upgrade_delay { new : :: core :: primitive :: u32 , } , # [codec (index = 44)] # [doc = "Setting this to true will disable consistency checks for the configuration setters."] # [doc = "Use with caution."] set_bypass_consistency_check { new : :: core :: primitive :: bool , } , # [codec (index = 45)] # [doc = "Set the asynchronous backing parameters."] set_async_backing_params { new : runtime_types :: polkadot_primitives :: vstaging :: AsyncBackingParams , } , # [codec (index = 46)] # [doc = "Set PVF executor parameters."] set_executor_params { new : runtime_types :: polkadot_primitives :: v4 :: executor_params :: ExecutorParams , } , } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -43757,6 +47964,8 @@ pub mod api { pub hrmp_max_message_num_per_candidate: _0, pub validation_upgrade_cooldown: _0, pub validation_upgrade_delay: _0, + pub async_backing_params: + runtime_types::polkadot_primitives::vstaging::AsyncBackingParams, pub max_pov_size: _0, pub max_downward_message_size: _0, pub ump_service_total_weight: runtime_types::sp_weights::weight_v2::Weight, @@ -43769,6 +47978,8 @@ pub mod api { pub hrmp_max_parachain_inbound_channels: _0, pub hrmp_max_parathread_inbound_channels: _0, pub hrmp_channel_max_message_size: _0, + pub executor_params: + runtime_types::polkadot_primitives::v4::executor_params::ExecutorParams, pub code_retention_period: _0, pub parathread_cores: _0, pub parathread_retries: _0, @@ -43780,8 +47991,6 @@ pub mod api { pub max_validators: ::core::option::Option<_0>, pub dispute_period: _0, pub dispute_post_conclusion_acceptance_period: _0, - pub dispute_max_spam_slots: _0, - pub dispute_conclusion_by_time_out_period: _0, pub no_show_slots: _0, pub n_delay_tranches: _0, pub zeroth_delay_tranche_width: _0, @@ -43840,11 +48049,17 @@ pub mod api { #[doc = "Validator vote submitted more than once to dispute."] DuplicateStatement, #[codec(index = 5)] - #[doc = "Too many spam slots used by some specific validator."] - PotentialSpam, - #[codec(index = 6)] #[doc = "A dispute where there are only votes on one side."] SingleSidedDispute, + #[codec(index = 6)] + #[doc = "A dispute vote from a malicious backer."] + MaliciousBacker, + #[codec(index = 7)] + #[doc = "No backing votes were provides along dispute statements."] + MissingBackingVotes, + #[codec(index = 8)] + #[doc = "Unconfirmed dispute statement sets provided."] + UnconfirmedDispute, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -43872,10 +48087,6 @@ pub mod api { runtime_types::polkadot_runtime_parachains::disputes::DisputeResult, ), #[codec(index = 2)] - #[doc = "A dispute has timed out due to insufficient participation."] - #[doc = "`\\[para id, candidate hash\\]`"] - DisputeTimedOut(runtime_types::polkadot_core_primitives::CandidateHash), - #[codec(index = 3)] #[doc = "A dispute has concluded with supermajority against a candidate."] #[doc = "Block authors should no longer build on top of this head and should"] #[doc = "instead revert the block at the given height. This should be the"] @@ -43883,6 +48094,109 @@ pub mod api { Revert(::core::primitive::u32), } } + pub mod slashing { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub enum Call { + # [codec (index = 0)] report_dispute_lost_unsigned { dispute_proof : :: std :: boxed :: Box < runtime_types :: polkadot_runtime_parachains :: disputes :: slashing :: DisputeProof > , key_owner_proof : runtime_types :: sp_session :: MembershipProof , } , } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub enum Error { + #[codec(index = 0)] + #[doc = "The key ownership proof is invalid."] + InvalidKeyOwnershipProof, + #[codec(index = 1)] + #[doc = "The session index is too old or invalid."] + InvalidSessionIndex, + #[codec(index = 2)] + #[doc = "The candidate hash is invalid."] + InvalidCandidateHash, + #[codec(index = 3)] + #[doc = "There is no pending slash for the given validator index and time"] + #[doc = "slot."] + InvalidValidatorIndex, + #[codec(index = 4)] + #[doc = "The validator index does not match the validator id."] + ValidatorIndexIdMismatch, + #[codec(index = 5)] + #[doc = "The given slashing report is valid but already previously reported."] + DuplicateSlashingReport, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DisputeProof { pub time_slot : runtime_types :: polkadot_runtime_parachains :: disputes :: slashing :: DisputesTimeSlot , pub kind : runtime_types :: polkadot_runtime_parachains :: disputes :: slashing :: SlashingOffenceKind , pub validator_index : runtime_types :: polkadot_primitives :: v4 :: ValidatorIndex , pub validator_id : runtime_types :: polkadot_primitives :: v4 :: validator_app :: Public , } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DisputesTimeSlot { + pub session_index: ::core::primitive::u32, + pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PendingSlashes { pub keys : :: subxt :: utils :: KeyedVec < runtime_types :: polkadot_primitives :: v4 :: ValidatorIndex , runtime_types :: polkadot_primitives :: v4 :: validator_app :: Public > , pub kind : runtime_types :: polkadot_runtime_parachains :: disputes :: slashing :: SlashingOffenceKind , } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum SlashingOffenceKind { + #[codec(index = 0)] + ForInvalid, + #[codec(index = 1)] + AgainstValid, + } + } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -43916,24 +48230,6 @@ pub mod api { Invalid, } } - pub mod dmp { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub enum Call {} - } - } pub mod hrmp { use super::runtime_types; pub mod pallet { @@ -44333,31 +48629,31 @@ pub mod api { #[codec(index = 0)] #[doc = "A candidate was backed. `[candidate, head_data]`"] CandidateBacked( - runtime_types::polkadot_primitives::v2::CandidateReceipt< + runtime_types::polkadot_primitives::v4::CandidateReceipt< ::subxt::utils::H256, >, runtime_types::polkadot_parachain::primitives::HeadData, - runtime_types::polkadot_primitives::v2::CoreIndex, - runtime_types::polkadot_primitives::v2::GroupIndex, + runtime_types::polkadot_primitives::v4::CoreIndex, + runtime_types::polkadot_primitives::v4::GroupIndex, ), #[codec(index = 1)] #[doc = "A candidate was included. `[candidate, head_data]`"] CandidateIncluded( - runtime_types::polkadot_primitives::v2::CandidateReceipt< + runtime_types::polkadot_primitives::v4::CandidateReceipt< ::subxt::utils::H256, >, runtime_types::polkadot_parachain::primitives::HeadData, - runtime_types::polkadot_primitives::v2::CoreIndex, - runtime_types::polkadot_primitives::v2::GroupIndex, + runtime_types::polkadot_primitives::v4::CoreIndex, + runtime_types::polkadot_primitives::v4::GroupIndex, ), #[codec(index = 2)] #[doc = "A candidate timed out. `[candidate, head_data]`"] CandidateTimedOut( - runtime_types::polkadot_primitives::v2::CandidateReceipt< + runtime_types::polkadot_primitives::v4::CandidateReceipt< ::subxt::utils::H256, >, runtime_types::polkadot_parachain::primitives::HeadData, - runtime_types::polkadot_primitives::v2::CoreIndex, + runtime_types::polkadot_primitives::v4::CoreIndex, ), } } @@ -44372,7 +48668,7 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct AvailabilityBitfieldRecord<_0> { - pub bitfield: runtime_types::polkadot_primitives::v2::AvailabilityBitfield, + pub bitfield: runtime_types::polkadot_primitives::v4::AvailabilityBitfield, pub submitted_at: _0, } #[derive( @@ -44386,9 +48682,9 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CandidatePendingAvailability<_0, _1> { - pub core: runtime_types::polkadot_primitives::v2::CoreIndex, + pub core: runtime_types::polkadot_primitives::v4::CoreIndex, pub hash: runtime_types::polkadot_core_primitives::CandidateHash, - pub descriptor: runtime_types::polkadot_primitives::v2::CandidateDescriptor<_0>, + pub descriptor: runtime_types::polkadot_primitives::v4::CandidateDescriptor<_0>, pub availability_votes: ::subxt::utils::bits::DecodedBits< ::core::primitive::u8, ::subxt::utils::bits::Lsb0, @@ -44399,7 +48695,7 @@ pub mod api { >, pub relay_parent_number: _1, pub backed_in_number: _1, - pub backing_group: runtime_types::polkadot_primitives::v2::GroupIndex, + pub backing_group: runtime_types::polkadot_primitives::v4::GroupIndex, } } pub mod initializer { @@ -44437,10 +48733,10 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BufferedSessionChange { pub validators: ::std::vec::Vec< - runtime_types::polkadot_primitives::v2::validator_app::Public, + runtime_types::polkadot_primitives::v4::validator_app::Public, >, pub queued: ::std::vec::Vec< - runtime_types::polkadot_primitives::v2::validator_app::Public, + runtime_types::polkadot_primitives::v4::validator_app::Public, >, pub session_index: ::core::primitive::u32, } @@ -44545,9 +48841,9 @@ pub mod api { #[doc = "Includes a statement for a PVF pre-checking vote. Potentially, finalizes the vote and"] #[doc = "enacts the results if that was the last vote before achieving the supermajority."] include_pvf_check_statement { - stmt: runtime_types::polkadot_primitives::v2::PvfCheckStatement, + stmt: runtime_types::polkadot_primitives::v4::PvfCheckStatement, signature: - runtime_types::polkadot_primitives::v2::validator_app::Signature, + runtime_types::polkadot_primitives::v4::validator_app::Signature, }, } #[derive( @@ -44792,7 +49088,7 @@ pub mod api { #[codec(index = 0)] #[doc = "Enter the paras inherent. This will process bitfields and backed candidates."] enter { - data: runtime_types::polkadot_primitives::v2::InherentData< + data: runtime_types::polkadot_primitives::v4::InherentData< runtime_types::sp_runtime::generic::header::Header< ::core::primitive::u32, runtime_types::sp_runtime::traits::BlakeTwo256, @@ -44851,7 +49147,7 @@ pub mod api { Parachain, #[codec(index = 1)] Parathread( - runtime_types::polkadot_primitives::v2::collator_app::Public, + runtime_types::polkadot_primitives::v4::collator_app::Public, ::core::primitive::u32, ), } @@ -44866,10 +49162,10 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CoreAssignment { - pub core: runtime_types::polkadot_primitives::v2::CoreIndex, + pub core: runtime_types::polkadot_primitives::v4::CoreIndex, pub para_id: runtime_types::polkadot_parachain::primitives::Id, pub kind: runtime_types::polkadot_runtime_parachains::scheduler::AssignmentKind, - pub group_idx: runtime_types::polkadot_primitives::v2::GroupIndex, + pub group_idx: runtime_types::polkadot_primitives::v4::GroupIndex, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -44898,7 +49194,7 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct QueuedParathread { - pub claim: runtime_types::polkadot_primitives::v2::ParathreadEntry, + pub claim: runtime_types::polkadot_primitives::v4::ParathreadEntry, pub core_offset: ::core::primitive::u32, } } @@ -44998,7 +49294,7 @@ pub mod api { #[doc = "\\[ id, outcome \\]"] ExecutedUpward( [::core::primitive::u8; 32usize], - runtime_types::xcm::v2::traits::Outcome, + runtime_types::xcm::v3::traits::Outcome, ), #[codec(index = 3)] #[doc = "The weight limit for handling upward messages was reached."] @@ -45046,6 +49342,17 @@ pub mod api { use super::runtime_types; pub mod fixed_point { use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct FixedI64(pub ::core::primitive::i64); #[derive( :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, @@ -45110,6 +49417,24 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Permill(pub ::core::primitive::u32); } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum ArithmeticError { + #[codec(index = 0)] + Underflow, + #[codec(index = 1)] + Overflow, + #[codec(index = 2)] + DivisionByZero, + } } pub mod sp_authority_discovery { use super::runtime_types; @@ -45196,8 +49521,7 @@ pub mod api { pub struct PrimaryPreDigest { pub authority_index: ::core::primitive::u32, pub slot: runtime_types::sp_consensus_slots::Slot, - pub vrf_output: [::core::primitive::u8; 32usize], - pub vrf_proof: [::core::primitive::u8; 64usize], + pub vrf_signature: runtime_types::sp_core::sr25519::vrf::VrfSignature, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -45226,8 +49550,7 @@ pub mod api { pub struct SecondaryVRFPreDigest { pub authority_index: ::core::primitive::u32, pub slot: runtime_types::sp_consensus_slots::Slot, - pub vrf_output: [::core::primitive::u8; 32usize], - pub vrf_proof: [::core::primitive::u8; 64usize], + pub vrf_signature: runtime_types::sp_core::sr25519::vrf::VrfSignature, } } #[derive( @@ -45263,6 +49586,76 @@ pub mod api { pub allowed_slots: runtime_types::sp_consensus_babe::AllowedSlots, } } + pub mod sp_consensus_grandpa { + use super::runtime_types; + pub mod app { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Public(pub runtime_types::sp_core::ed25519::Public); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Signature(pub runtime_types::sp_core::ed25519::Signature); + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Equivocation<_0, _1> { + #[codec(index = 0)] + Prevote( + runtime_types::finality_grandpa::Equivocation< + runtime_types::sp_consensus_grandpa::app::Public, + runtime_types::finality_grandpa::Prevote<_0, _1>, + runtime_types::sp_consensus_grandpa::app::Signature, + >, + ), + #[codec(index = 1)] + Precommit( + runtime_types::finality_grandpa::Equivocation< + runtime_types::sp_consensus_grandpa::app::Public, + runtime_types::finality_grandpa::Precommit<_0, _1>, + runtime_types::sp_consensus_grandpa::app::Signature, + >, + ), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct EquivocationProof<_0, _1> { + pub set_id: ::core::primitive::u64, + pub equivocation: runtime_types::sp_consensus_grandpa::Equivocation<_0, _1>, + } + } pub mod sp_consensus_slots { use super::runtime_types; #[derive( @@ -45296,51 +49689,6 @@ pub mod api { } pub mod sp_core { use super::runtime_types; - pub mod bounded { - use super::runtime_types; - pub mod bounded_btree_map { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BoundedBTreeMap<_0, _1>(pub ::subxt::utils::KeyedVec<_0, _1>); - } - pub mod bounded_vec { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BoundedVec<_0>(pub ::std::vec::Vec<_0>); - } - pub mod weak_bounded_vec { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WeakBoundedVec<_0>(pub ::std::vec::Vec<_0>); - } - } pub mod crypto { use super::runtime_types; #[derive( @@ -45405,86 +49753,7 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct Signature(pub [::core::primitive::u8; 64usize]); } - pub mod offchain { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OpaqueMultiaddr(pub ::std::vec::Vec<::core::primitive::u8>); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OpaqueNetworkState { - pub peer_id: runtime_types::sp_core::OpaquePeerId, - pub external_addresses: - ::std::vec::Vec, - } - } - pub mod sr25519 { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub [::core::primitive::u8; 32usize]); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Signature(pub [::core::primitive::u8; 64usize]); - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OpaquePeerId(pub ::std::vec::Vec<::core::primitive::u8>); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Void {} - } - pub mod sp_finality_grandpa { - use super::runtime_types; - pub mod app { + pub mod offchain { use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, @@ -45496,7 +49765,7 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub runtime_types::sp_core::ed25519::Public); + pub struct OpaqueMultiaddr(pub ::std::vec::Vec<::core::primitive::u8>); #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -45507,7 +49776,53 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Signature(pub runtime_types::sp_core::ed25519::Signature); + pub struct OpaqueNetworkState { + pub peer_id: runtime_types::sp_core::OpaquePeerId, + pub external_addresses: + ::std::vec::Vec, + } + } + pub mod sr25519 { + use super::runtime_types; + pub mod vrf { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct VrfSignature { + pub output: [::core::primitive::u8; 32usize], + pub proof: [::core::primitive::u8; 64usize], + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Public(pub [::core::primitive::u8; 32usize]); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Signature(pub [::core::primitive::u8; 64usize]); } #[derive( :: subxt :: ext :: codec :: Decode, @@ -45519,24 +49834,7 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Equivocation<_0, _1> { - #[codec(index = 0)] - Prevote( - runtime_types::finality_grandpa::Equivocation< - runtime_types::sp_finality_grandpa::app::Public, - runtime_types::finality_grandpa::Prevote<_0, _1>, - runtime_types::sp_finality_grandpa::app::Signature, - >, - ), - #[codec(index = 1)] - Precommit( - runtime_types::finality_grandpa::Equivocation< - runtime_types::sp_finality_grandpa::app::Public, - runtime_types::finality_grandpa::Precommit<_0, _1>, - runtime_types::sp_finality_grandpa::app::Signature, - >, - ), - } + pub struct OpaquePeerId(pub ::std::vec::Vec<::core::primitive::u8>); #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -45547,10 +49845,7 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EquivocationProof<_0, _1> { - pub set_id: ::core::primitive::u64, - pub equivocation: runtime_types::sp_finality_grandpa::Equivocation<_0, _1>, - } + pub enum Void {} } pub mod sp_npos_elections { use super::runtime_types; @@ -46163,7 +50458,379 @@ pub mod api { Mortal255(::core::primitive::u8), } } - pub mod header { + pub mod header { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Header<_0, _1> { + pub parent_hash: ::subxt::utils::H256, + #[codec(compact)] + pub number: _0, + pub state_root: ::subxt::utils::H256, + pub extrinsics_root: ::subxt::utils::H256, + pub digest: runtime_types::sp_runtime::generic::digest::Digest, + #[codec(skip)] + pub __subxt_unused_type_params: ::core::marker::PhantomData<_1>, + } + } + pub mod unchecked_extrinsic { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UncheckedExtrinsic<_0, _1, _2, _3>( + pub ::std::vec::Vec<::core::primitive::u8>, + #[codec(skip)] pub ::core::marker::PhantomData<(_1, _0, _2, _3)>, + ); + } + } + pub mod traits { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BlakeTwo256; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum DispatchError { + #[codec(index = 0)] + Other, + #[codec(index = 1)] + CannotLookup, + #[codec(index = 2)] + BadOrigin, + #[codec(index = 3)] + Module(runtime_types::sp_runtime::ModuleError), + #[codec(index = 4)] + ConsumerRemaining, + #[codec(index = 5)] + NoProviders, + #[codec(index = 6)] + TooManyConsumers, + #[codec(index = 7)] + Token(runtime_types::sp_runtime::TokenError), + #[codec(index = 8)] + Arithmetic(runtime_types::sp_arithmetic::ArithmeticError), + #[codec(index = 9)] + Transactional(runtime_types::sp_runtime::TransactionalError), + #[codec(index = 10)] + Exhausted, + #[codec(index = 11)] + Corruption, + #[codec(index = 12)] + Unavailable, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DispatchErrorWithPostInfo<_0> { + pub post_info: _0, + pub error: runtime_types::sp_runtime::DispatchError, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ModuleError { + pub index: ::core::primitive::u8, + pub error: [::core::primitive::u8; 4usize], + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum MultiSignature { + #[codec(index = 0)] + Ed25519(runtime_types::sp_core::ed25519::Signature), + #[codec(index = 1)] + Sr25519(runtime_types::sp_core::sr25519::Signature), + #[codec(index = 2)] + Ecdsa(runtime_types::sp_core::ecdsa::Signature), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum MultiSigner { + #[codec(index = 0)] + Ed25519(runtime_types::sp_core::ed25519::Public), + #[codec(index = 1)] + Sr25519(runtime_types::sp_core::sr25519::Public), + #[codec(index = 2)] + Ecdsa(runtime_types::sp_core::ecdsa::Public), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum TokenError { + #[codec(index = 0)] + FundsUnavailable, + #[codec(index = 1)] + OnlyProvider, + #[codec(index = 2)] + BelowMinimum, + #[codec(index = 3)] + CannotCreate, + #[codec(index = 4)] + UnknownAsset, + #[codec(index = 5)] + Frozen, + #[codec(index = 6)] + Unsupported, + #[codec(index = 7)] + CannotCreateHold, + #[codec(index = 8)] + NotExpendable, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum TransactionalError { + #[codec(index = 0)] + LimitReached, + #[codec(index = 1)] + NoLayer, + } + } + pub mod sp_session { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MembershipProof { + pub session: ::core::primitive::u32, + pub trie_nodes: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + pub validator_count: ::core::primitive::u32, + } + } + pub mod sp_staking { + use super::runtime_types; + pub mod offence { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OffenceDetails<_0, _1> { + pub offender: _1, + pub reporters: ::std::vec::Vec<_0>, + } + } + } + pub mod sp_version { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RuntimeVersion { + pub spec_name: ::std::string::String, + pub impl_name: ::std::string::String, + pub authoring_version: ::core::primitive::u32, + pub spec_version: ::core::primitive::u32, + pub impl_version: ::core::primitive::u32, + pub apis: + ::std::vec::Vec<([::core::primitive::u8; 8usize], ::core::primitive::u32)>, + pub transaction_version: ::core::primitive::u32, + pub state_version: ::core::primitive::u8, + } + } + pub mod sp_weights { + use super::runtime_types; + pub mod weight_v2 { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Weight { + #[codec(compact)] + pub ref_time: ::core::primitive::u64, + #[codec(compact)] + pub proof_size: ::core::primitive::u64, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RuntimeDbWeight { + pub read: ::core::primitive::u64, + pub write: ::core::primitive::u64, + } + } + pub mod xcm { + use super::runtime_types; + pub mod double_encoded { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DoubleEncoded { + pub encoded: ::std::vec::Vec<::core::primitive::u8>, + } + } + pub mod v2 { + use super::runtime_types; + pub mod junction { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Junction { + #[codec(index = 0)] + Parachain(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 1)] + AccountId32 { + network: runtime_types::xcm::v2::NetworkId, + id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + AccountIndex64 { + network: runtime_types::xcm::v2::NetworkId, + #[codec(compact)] + index: ::core::primitive::u64, + }, + #[codec(index = 3)] + AccountKey20 { + network: runtime_types::xcm::v2::NetworkId, + key: [::core::primitive::u8; 20usize], + }, + #[codec(index = 4)] + PalletInstance(::core::primitive::u8), + #[codec(index = 5)] + GeneralIndex(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 6)] + GeneralKey( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 7)] + OnlyChild, + #[codec(index = 8)] + Plurality { + id: runtime_types::xcm::v2::BodyId, + part: runtime_types::xcm::v2::BodyPart, + }, + } + } + pub mod multiasset { use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, @@ -46175,37 +50842,514 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Header<_0, _1> { - pub parent_hash: ::subxt::utils::H256, + pub enum AssetId { + #[codec(index = 0)] + Concrete(runtime_types::xcm::v2::multilocation::MultiLocation), + #[codec(index = 1)] + Abstract(::std::vec::Vec<::core::primitive::u8>), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum AssetInstance { + #[codec(index = 0)] + Undefined, + #[codec(index = 1)] + Index(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 2)] + Array4([::core::primitive::u8; 4usize]), + #[codec(index = 3)] + Array8([::core::primitive::u8; 8usize]), + #[codec(index = 4)] + Array16([::core::primitive::u8; 16usize]), + #[codec(index = 5)] + Array32([::core::primitive::u8; 32usize]), + #[codec(index = 6)] + Blob(::std::vec::Vec<::core::primitive::u8>), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Fungibility { + #[codec(index = 0)] + Fungible(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 1)] + NonFungible(runtime_types::xcm::v2::multiasset::AssetInstance), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MultiAsset { + pub id: runtime_types::xcm::v2::multiasset::AssetId, + pub fun: runtime_types::xcm::v2::multiasset::Fungibility, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum MultiAssetFilter { + #[codec(index = 0)] + Definite(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 1)] + Wild(runtime_types::xcm::v2::multiasset::WildMultiAsset), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MultiAssets( + pub ::std::vec::Vec, + ); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum WildFungibility { + #[codec(index = 0)] + Fungible, + #[codec(index = 1)] + NonFungible, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum WildMultiAsset { + #[codec(index = 0)] + All, + #[codec(index = 1)] + AllOf { + id: runtime_types::xcm::v2::multiasset::AssetId, + fun: runtime_types::xcm::v2::multiasset::WildFungibility, + }, + } + } + pub mod multilocation { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Junctions { + #[codec(index = 0)] + Here, + #[codec(index = 1)] + X1(runtime_types::xcm::v2::junction::Junction), + #[codec(index = 2)] + X2( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + #[codec(index = 3)] + X3( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + #[codec(index = 4)] + X4( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + #[codec(index = 5)] + X5( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + #[codec(index = 6)] + X6( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + #[codec(index = 7)] + X7( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + #[codec(index = 8)] + X8( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MultiLocation { + pub parents: ::core::primitive::u8, + pub interior: runtime_types::xcm::v2::multilocation::Junctions, + } + } + pub mod traits { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Error { + #[codec(index = 0)] + Overflow, + #[codec(index = 1)] + Unimplemented, + #[codec(index = 2)] + UntrustedReserveLocation, + #[codec(index = 3)] + UntrustedTeleportLocation, + #[codec(index = 4)] + MultiLocationFull, + #[codec(index = 5)] + MultiLocationNotInvertible, + #[codec(index = 6)] + BadOrigin, + #[codec(index = 7)] + InvalidLocation, + #[codec(index = 8)] + AssetNotFound, + #[codec(index = 9)] + FailedToTransactAsset, + #[codec(index = 10)] + NotWithdrawable, + #[codec(index = 11)] + LocationCannotHold, + #[codec(index = 12)] + ExceedsMaxMessageSize, + #[codec(index = 13)] + DestinationUnsupported, + #[codec(index = 14)] + Transport, + #[codec(index = 15)] + Unroutable, + #[codec(index = 16)] + UnknownClaim, + #[codec(index = 17)] + FailedToDecode, + #[codec(index = 18)] + MaxWeightInvalid, + #[codec(index = 19)] + NotHoldingFees, + #[codec(index = 20)] + TooExpensive, + #[codec(index = 21)] + Trap(::core::primitive::u64), + #[codec(index = 22)] + UnhandledXcmVersion, + #[codec(index = 23)] + WeightLimitReached(::core::primitive::u64), + #[codec(index = 24)] + Barrier, + #[codec(index = 25)] + WeightNotComputable, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum BodyId { + #[codec(index = 0)] + Unit, + #[codec(index = 1)] + Named( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 2)] + Index(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 3)] + Executive, + #[codec(index = 4)] + Technical, + #[codec(index = 5)] + Legislative, + #[codec(index = 6)] + Judicial, + #[codec(index = 7)] + Defense, + #[codec(index = 8)] + Administration, + #[codec(index = 9)] + Treasury, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum BodyPart { + #[codec(index = 0)] + Voice, + #[codec(index = 1)] + Members { + #[codec(compact)] + count: ::core::primitive::u32, + }, + #[codec(index = 2)] + Fraction { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 3)] + AtLeastProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 4)] + MoreThanProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Instruction { + #[codec(index = 0)] + WithdrawAsset(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 1)] + ReserveAssetDeposited(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 2)] + ReceiveTeleportedAsset(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 3)] + QueryResponse { + #[codec(compact)] + query_id: ::core::primitive::u64, + response: runtime_types::xcm::v2::Response, + #[codec(compact)] + max_weight: ::core::primitive::u64, + }, + #[codec(index = 4)] + TransferAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssets, + beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 5)] + TransferReserveAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssets, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::xcm::v2::Xcm, + }, + #[codec(index = 6)] + Transact { + origin_type: runtime_types::xcm::v2::OriginKind, + #[codec(compact)] + require_weight_at_most: ::core::primitive::u64, + call: runtime_types::xcm::double_encoded::DoubleEncoded, + }, + #[codec(index = 7)] + HrmpNewChannelOpenRequest { + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + max_message_size: ::core::primitive::u32, #[codec(compact)] - pub number: _0, - pub state_root: ::subxt::utils::H256, - pub extrinsics_root: ::subxt::utils::H256, - pub digest: runtime_types::sp_runtime::generic::digest::Digest, - #[codec(skip)] - pub __subxt_unused_type_params: ::core::marker::PhantomData<_1>, - } - } - pub mod unchecked_extrinsic { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UncheckedExtrinsic<_0, _1, _2, _3>( - pub ::std::vec::Vec<::core::primitive::u8>, - #[codec(skip)] pub ::core::marker::PhantomData<(_1, _0, _2, _3)>, - ); + max_capacity: ::core::primitive::u32, + }, + #[codec(index = 8)] + HrmpChannelAccepted { + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 9)] + HrmpChannelClosing { + #[codec(compact)] + initiator: ::core::primitive::u32, + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 10)] + ClearOrigin, + #[codec(index = 11)] + DescendOrigin(runtime_types::xcm::v2::multilocation::Junctions), + #[codec(index = 12)] + ReportError { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 13)] + DepositAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 14)] + DepositReserveAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::xcm::v2::Xcm, + }, + #[codec(index = 15)] + ExchangeAsset { + give: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + receive: runtime_types::xcm::v2::multiasset::MultiAssets, + }, + #[codec(index = 16)] + InitiateReserveWithdraw { + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + reserve: runtime_types::xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::xcm::v2::Xcm, + }, + #[codec(index = 17)] + InitiateTeleport { + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::xcm::v2::Xcm, + }, + #[codec(index = 18)] + QueryHolding { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 19)] + BuyExecution { + fees: runtime_types::xcm::v2::multiasset::MultiAsset, + weight_limit: runtime_types::xcm::v2::WeightLimit, + }, + #[codec(index = 20)] + RefundSurplus, + #[codec(index = 21)] + SetErrorHandler(runtime_types::xcm::v2::Xcm), + #[codec(index = 22)] + SetAppendix(runtime_types::xcm::v2::Xcm), + #[codec(index = 23)] + ClearError, + #[codec(index = 24)] + ClaimAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssets, + ticket: runtime_types::xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 25)] + Trap(#[codec(compact)] ::core::primitive::u64), + #[codec(index = 26)] + SubscribeVersion { + #[codec(compact)] + query_id: ::core::primitive::u64, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 27)] + UnsubscribeVersion, } - } - pub mod traits { - use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -46216,179 +51360,20 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BlakeTwo256; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum ArithmeticError { - #[codec(index = 0)] - Underflow, - #[codec(index = 1)] - Overflow, - #[codec(index = 2)] - DivisionByZero, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum DispatchError { - #[codec(index = 0)] - Other, - #[codec(index = 1)] - CannotLookup, - #[codec(index = 2)] - BadOrigin, - #[codec(index = 3)] - Module(runtime_types::sp_runtime::ModuleError), - #[codec(index = 4)] - ConsumerRemaining, - #[codec(index = 5)] - NoProviders, - #[codec(index = 6)] - TooManyConsumers, - #[codec(index = 7)] - Token(runtime_types::sp_runtime::TokenError), - #[codec(index = 8)] - Arithmetic(runtime_types::sp_runtime::ArithmeticError), - #[codec(index = 9)] - Transactional(runtime_types::sp_runtime::TransactionalError), - #[codec(index = 10)] - Exhausted, - #[codec(index = 11)] - Corruption, - #[codec(index = 12)] - Unavailable, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ModuleError { - pub index: ::core::primitive::u8, - pub error: [::core::primitive::u8; 4usize], - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MultiSignature { - #[codec(index = 0)] - Ed25519(runtime_types::sp_core::ed25519::Signature), - #[codec(index = 1)] - Sr25519(runtime_types::sp_core::sr25519::Signature), - #[codec(index = 2)] - Ecdsa(runtime_types::sp_core::ecdsa::Signature), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MultiSigner { - #[codec(index = 0)] - Ed25519(runtime_types::sp_core::ed25519::Public), - #[codec(index = 1)] - Sr25519(runtime_types::sp_core::sr25519::Public), - #[codec(index = 2)] - Ecdsa(runtime_types::sp_core::ecdsa::Public), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum TokenError { - #[codec(index = 0)] - NoFunds, - #[codec(index = 1)] - WouldDie, - #[codec(index = 2)] - BelowMinimum, - #[codec(index = 3)] - CannotCreate, - #[codec(index = 4)] - UnknownAsset, - #[codec(index = 5)] - Frozen, - #[codec(index = 6)] - Unsupported, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum TransactionalError { - #[codec(index = 0)] - LimitReached, - #[codec(index = 1)] - NoLayer, - } - } - pub mod sp_session { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MembershipProof { - pub session: ::core::primitive::u32, - pub trie_nodes: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - pub validator_count: ::core::primitive::u32, - } - } - pub mod sp_staking { - use super::runtime_types; - pub mod offence { - use super::runtime_types; + pub enum NetworkId { + #[codec(index = 0)] + Any, + #[codec(index = 1)] + Named( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 2)] + Polkadot, + #[codec(index = 3)] + Kusama, + } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -46399,40 +51384,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OffenceDetails<_0, _1> { - pub offender: _1, - pub reporters: ::std::vec::Vec<_0>, + pub enum OriginKind { + #[codec(index = 0)] + Native, + #[codec(index = 1)] + SovereignAccount, + #[codec(index = 2)] + Superuser, + #[codec(index = 3)] + Xcm, } - } - } - pub mod sp_version { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RuntimeVersion { - pub spec_name: ::std::string::String, - pub impl_name: ::std::string::String, - pub authoring_version: ::core::primitive::u32, - pub spec_version: ::core::primitive::u32, - pub impl_version: ::core::primitive::u32, - pub apis: - ::std::vec::Vec<([::core::primitive::u8; 8usize], ::core::primitive::u32)>, - pub transaction_version: ::core::primitive::u32, - pub state_version: ::core::primitive::u8, - } - } - pub mod sp_weights { - use super::runtime_types; - pub mod weight_v2 { - use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -46443,44 +51404,21 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Weight { - #[codec(compact)] - pub ref_time: ::core::primitive::u64, - #[codec(compact)] - pub proof_size: ::core::primitive::u64, + pub enum Response { + #[codec(index = 0)] + Null, + #[codec(index = 1)] + Assets(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 2)] + ExecutionResult( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::xcm::v2::traits::Error, + )>, + ), + #[codec(index = 3)] + Version(::core::primitive::u32), } - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OldWeight(pub ::core::primitive::u64); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RuntimeDbWeight { - pub read: ::core::primitive::u64, - pub write: ::core::primitive::u64, - } - } - pub mod xcm { - use super::runtime_types; - pub mod double_encoded { - use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -46491,11 +51429,25 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DoubleEncoded { - pub encoded: ::std::vec::Vec<::core::primitive::u8>, + pub enum WeightLimit { + #[codec(index = 0)] + Unlimited, + #[codec(index = 1)] + Limited(#[codec(compact)] ::core::primitive::u64), } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Xcm(pub ::std::vec::Vec); } - pub mod v0 { + pub mod v3 { use super::runtime_types; pub mod junction { use super::runtime_types; @@ -46513,11 +51465,7 @@ pub mod api { #[codec(index = 0)] Unit, #[codec(index = 1)] - Named( - runtime_types::sp_core::bounded::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), + Moniker([::core::primitive::u8; 4usize]), #[codec(index = 2)] Index(#[codec(compact)] ::core::primitive::u32), #[codec(index = 3)] @@ -46528,6 +51476,12 @@ pub mod api { Legislative, #[codec(index = 6)] Judicial, + #[codec(index = 7)] + Defense, + #[codec(index = 8)] + Administration, + #[codec(index = 9)] + Treasury, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -46552,160 +51506,23 @@ pub mod api { #[codec(compact)] nom: ::core::primitive::u32, #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 3)] - AtLeastProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 4)] - MoreThanProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junction { - #[codec(index = 0)] - Parent, - #[codec(index = 1)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 2)] - AccountId32 { - network: runtime_types::xcm::v0::junction::NetworkId, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 3)] - AccountIndex64 { - network: runtime_types::xcm::v0::junction::NetworkId, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 4)] - AccountKey20 { - network: runtime_types::xcm::v0::junction::NetworkId, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 5)] - PalletInstance(::core::primitive::u8), - #[codec(index = 6)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 7)] - GeneralKey( - runtime_types::sp_core::bounded::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 8)] - OnlyChild, - #[codec(index = 9)] - Plurality { - id: runtime_types::xcm::v0::junction::BodyId, - part: runtime_types::xcm::v0::junction::BodyPart, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum NetworkId { - #[codec(index = 0)] - Any, - #[codec(index = 1)] - Named( - runtime_types::sp_core::bounded::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - } - } - pub mod multi_asset { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MultiAsset { - #[codec(index = 0)] - None, - #[codec(index = 1)] - All, - #[codec(index = 2)] - AllFungible, - #[codec(index = 3)] - AllNonFungible, - #[codec(index = 4)] - AllAbstractFungible { - id: ::std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 5)] - AllAbstractNonFungible { - class: ::std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 6)] - AllConcreteFungible { - id: runtime_types::xcm::v0::multi_location::MultiLocation, - }, - #[codec(index = 7)] - AllConcreteNonFungible { - class: runtime_types::xcm::v0::multi_location::MultiLocation, - }, - #[codec(index = 8)] - AbstractFungible { - id: ::std::vec::Vec<::core::primitive::u8>, - #[codec(compact)] - amount: ::core::primitive::u128, - }, - #[codec(index = 9)] - AbstractNonFungible { - class: ::std::vec::Vec<::core::primitive::u8>, - instance: runtime_types::xcm::v1::multiasset::AssetInstance, + denom: ::core::primitive::u32, }, - #[codec(index = 10)] - ConcreteFungible { - id: runtime_types::xcm::v0::multi_location::MultiLocation, + #[codec(index = 3)] + AtLeastProportion { #[codec(compact)] - amount: ::core::primitive::u128, + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, }, - #[codec(index = 11)] - ConcreteNonFungible { - class: runtime_types::xcm::v0::multi_location::MultiLocation, - instance: runtime_types::xcm::v1::multiasset::AssetInstance, + #[codec(index = 4)] + MoreThanProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, }, } - } - pub mod multi_location { - use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -46716,71 +51533,47 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MultiLocation { + pub enum Junction { #[codec(index = 0)] - Null, + Parachain(#[codec(compact)] ::core::primitive::u32), #[codec(index = 1)] - X1(runtime_types::xcm::v0::junction::Junction), + AccountId32 { + network: + ::core::option::Option, + id: [::core::primitive::u8; 32usize], + }, #[codec(index = 2)] - X2( - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - ), + AccountIndex64 { + network: + ::core::option::Option, + #[codec(compact)] + index: ::core::primitive::u64, + }, #[codec(index = 3)] - X3( - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - ), + AccountKey20 { + network: + ::core::option::Option, + key: [::core::primitive::u8; 20usize], + }, #[codec(index = 4)] - X4( - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - ), + PalletInstance(::core::primitive::u8), #[codec(index = 5)] - X5( - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - ), + GeneralIndex(#[codec(compact)] ::core::primitive::u128), #[codec(index = 6)] - X6( - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - ), + GeneralKey { + length: ::core::primitive::u8, + data: [::core::primitive::u8; 32usize], + }, #[codec(index = 7)] - X7( - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - ), + OnlyChild, #[codec(index = 8)] - X8( - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - runtime_types::xcm::v0::junction::Junction, - ), + Plurality { + id: runtime_types::xcm::v3::junction::BodyId, + part: runtime_types::xcm::v3::junction::BodyPart, + }, + #[codec(index = 9)] + GlobalConsensus(runtime_types::xcm::v3::junction::NetworkId), } - } - pub mod order { - use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -46791,176 +51584,36 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Order { + pub enum NetworkId { #[codec(index = 0)] - Null, + ByGenesis([::core::primitive::u8; 32usize]), #[codec(index = 1)] - DepositAsset { - assets: - ::std::vec::Vec, - dest: runtime_types::xcm::v0::multi_location::MultiLocation, + ByFork { + block_number: ::core::primitive::u64, + block_hash: [::core::primitive::u8; 32usize], }, #[codec(index = 2)] - DepositReserveAsset { - assets: - ::std::vec::Vec, - dest: runtime_types::xcm::v0::multi_location::MultiLocation, - effects: ::std::vec::Vec, - }, + Polkadot, #[codec(index = 3)] - ExchangeAsset { - give: ::std::vec::Vec, - receive: - ::std::vec::Vec, - }, + Kusama, #[codec(index = 4)] - InitiateReserveWithdraw { - assets: - ::std::vec::Vec, - reserve: runtime_types::xcm::v0::multi_location::MultiLocation, - effects: ::std::vec::Vec, - }, + Westend, #[codec(index = 5)] - InitiateTeleport { - assets: - ::std::vec::Vec, - dest: runtime_types::xcm::v0::multi_location::MultiLocation, - effects: ::std::vec::Vec, - }, + Rococo, #[codec(index = 6)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v0::multi_location::MultiLocation, - assets: - ::std::vec::Vec, - }, + Wococo, #[codec(index = 7)] - BuyExecution { - fees: runtime_types::xcm::v0::multi_asset::MultiAsset, - weight: ::core::primitive::u64, - debt: ::core::primitive::u64, - halt_on_error: ::core::primitive::bool, - xcm: ::std::vec::Vec, + Ethereum { + #[codec(compact)] + chain_id: ::core::primitive::u64, }, + #[codec(index = 8)] + BitcoinCore, + #[codec(index = 9)] + BitcoinCash, } } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum OriginKind { - #[codec(index = 0)] - Native, - #[codec(index = 1)] - SovereignAccount, - #[codec(index = 2)] - Superuser, - #[codec(index = 3)] - Xcm, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Response { - #[codec(index = 0)] - Assets(::std::vec::Vec), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Xcm { - #[codec(index = 0)] - WithdrawAsset { - assets: ::std::vec::Vec, - effects: ::std::vec::Vec, - }, - #[codec(index = 1)] - ReserveAssetDeposit { - assets: ::std::vec::Vec, - effects: ::std::vec::Vec, - }, - #[codec(index = 2)] - TeleportAsset { - assets: ::std::vec::Vec, - effects: ::std::vec::Vec, - }, - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::xcm::v0::Response, - }, - #[codec(index = 4)] - TransferAsset { - assets: ::std::vec::Vec, - dest: runtime_types::xcm::v0::multi_location::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: ::std::vec::Vec, - dest: runtime_types::xcm::v0::multi_location::MultiLocation, - effects: ::std::vec::Vec, - }, - #[codec(index = 6)] - Transact { - origin_type: runtime_types::xcm::v0::OriginKind, - require_weight_at_most: ::core::primitive::u64, - call: runtime_types::xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - RelayedFrom { - who: runtime_types::xcm::v0::multi_location::MultiLocation, - message: ::std::boxed::Box, - }, - } - } - pub mod v1 { - use super::runtime_types; - pub mod junction { + pub mod junctions { use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, @@ -46972,42 +51625,67 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junction { + pub enum Junctions { #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), + Here, #[codec(index = 1)] - AccountId32 { - network: runtime_types::xcm::v0::junction::NetworkId, - id: [::core::primitive::u8; 32usize], - }, + X1(runtime_types::xcm::v3::junction::Junction), #[codec(index = 2)] - AccountIndex64 { - network: runtime_types::xcm::v0::junction::NetworkId, - #[codec(compact)] - index: ::core::primitive::u64, - }, + X2( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + ), #[codec(index = 3)] - AccountKey20 { - network: runtime_types::xcm::v0::junction::NetworkId, - key: [::core::primitive::u8; 20usize], - }, + X3( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + ), #[codec(index = 4)] - PalletInstance(::core::primitive::u8), + X4( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + ), #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), + X5( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + ), #[codec(index = 6)] - GeneralKey( - runtime_types::sp_core::bounded::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, + X6( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, ), #[codec(index = 7)] - OnlyChild, + X7( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + ), #[codec(index = 8)] - Plurality { - id: runtime_types::xcm::v0::junction::BodyId, - part: runtime_types::xcm::v0::junction::BodyPart, - }, + X8( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + ), } } pub mod multiasset { @@ -47024,9 +51702,9 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum AssetId { #[codec(index = 0)] - Concrete(runtime_types::xcm::v1::multilocation::MultiLocation), + Concrete(runtime_types::xcm::v3::multilocation::MultiLocation), #[codec(index = 1)] - Abstract(::std::vec::Vec<::core::primitive::u8>), + Abstract([::core::primitive::u8; 32usize]), } #[derive( :: subxt :: ext :: codec :: Decode, @@ -47051,8 +51729,6 @@ pub mod api { Array16([::core::primitive::u8; 16usize]), #[codec(index = 5)] Array32([::core::primitive::u8; 32usize]), - #[codec(index = 6)] - Blob(::std::vec::Vec<::core::primitive::u8>), } #[derive( :: subxt :: ext :: codec :: Decode, @@ -47068,7 +51744,7 @@ pub mod api { #[codec(index = 0)] Fungible(#[codec(compact)] ::core::primitive::u128), #[codec(index = 1)] - NonFungible(runtime_types::xcm::v1::multiasset::AssetInstance), + NonFungible(runtime_types::xcm::v3::multiasset::AssetInstance), } #[derive( :: subxt :: ext :: codec :: Decode, @@ -47081,8 +51757,8 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct MultiAsset { - pub id: runtime_types::xcm::v1::multiasset::AssetId, - pub fun: runtime_types::xcm::v1::multiasset::Fungibility, + pub id: runtime_types::xcm::v3::multiasset::AssetId, + pub fun: runtime_types::xcm::v3::multiasset::Fungibility, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -47096,9 +51772,9 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum MultiAssetFilter { #[codec(index = 0)] - Definite(runtime_types::xcm::v1::multiasset::MultiAssets), + Definite(runtime_types::xcm::v3::multiasset::MultiAssets), #[codec(index = 1)] - Wild(runtime_types::xcm::v1::multiasset::WildMultiAsset), + Wild(runtime_types::xcm::v3::multiasset::WildMultiAsset), } #[derive( :: subxt :: ext :: codec :: Decode, @@ -47111,7 +51787,7 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct MultiAssets( - pub ::std::vec::Vec, + pub ::std::vec::Vec, ); #[derive( :: subxt :: ext :: codec :: Decode, @@ -47144,8 +51820,17 @@ pub mod api { All, #[codec(index = 1)] AllOf { - id: runtime_types::xcm::v1::multiasset::AssetId, - fun: runtime_types::xcm::v1::multiasset::WildFungibility, + id: runtime_types::xcm::v3::multiasset::AssetId, + fun: runtime_types::xcm::v3::multiasset::WildFungibility, + }, + #[codec(index = 2)] + AllCounted(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 3)] + AllOfCounted { + id: runtime_types::xcm::v3::multiasset::AssetId, + fun: runtime_types::xcm::v3::multiasset::WildFungibility, + #[codec(compact)] + count: ::core::primitive::u32, }, } } @@ -47161,251 +51846,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1(runtime_types::xcm::v1::junction::Junction), - #[codec(index = 2)] - X2( - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - ), - #[codec(index = 3)] - X3( - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - ), - #[codec(index = 4)] - X4( - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - ), - #[codec(index = 5)] - X5( - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - ), - #[codec(index = 6)] - X6( - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - ), - #[codec(index = 7)] - X7( - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - ), - #[codec(index = 8)] - X8( - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - runtime_types::xcm::v1::junction::Junction, - ), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct MultiLocation { pub parents: ::core::primitive::u8, - pub interior: runtime_types::xcm::v1::multilocation::Junctions, - } - } - pub mod order { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Order { - #[codec(index = 0)] - Noop, - #[codec(index = 1)] - DepositAsset { - assets: runtime_types::xcm::v1::multiasset::MultiAssetFilter, - max_assets: ::core::primitive::u32, - beneficiary: runtime_types::xcm::v1::multilocation::MultiLocation, - }, - #[codec(index = 2)] - DepositReserveAsset { - assets: runtime_types::xcm::v1::multiasset::MultiAssetFilter, - max_assets: ::core::primitive::u32, - dest: runtime_types::xcm::v1::multilocation::MultiLocation, - effects: ::std::vec::Vec, - }, - #[codec(index = 3)] - ExchangeAsset { - give: runtime_types::xcm::v1::multiasset::MultiAssetFilter, - receive: runtime_types::xcm::v1::multiasset::MultiAssets, - }, - #[codec(index = 4)] - InitiateReserveWithdraw { - assets: runtime_types::xcm::v1::multiasset::MultiAssetFilter, - reserve: runtime_types::xcm::v1::multilocation::MultiLocation, - effects: ::std::vec::Vec, - }, - #[codec(index = 5)] - InitiateTeleport { - assets: runtime_types::xcm::v1::multiasset::MultiAssetFilter, - dest: runtime_types::xcm::v1::multilocation::MultiLocation, - effects: ::std::vec::Vec, - }, - #[codec(index = 6)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v1::multilocation::MultiLocation, - assets: runtime_types::xcm::v1::multiasset::MultiAssetFilter, - }, - #[codec(index = 7)] - BuyExecution { - fees: runtime_types::xcm::v1::multiasset::MultiAsset, - weight: ::core::primitive::u64, - debt: ::core::primitive::u64, - halt_on_error: ::core::primitive::bool, - instructions: ::std::vec::Vec, - }, + pub interior: runtime_types::xcm::v3::junctions::Junctions, } } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Response { - #[codec(index = 0)] - Assets(runtime_types::xcm::v1::multiasset::MultiAssets), - #[codec(index = 1)] - Version(::core::primitive::u32), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Xcm { - #[codec(index = 0)] - WithdrawAsset { - assets: runtime_types::xcm::v1::multiasset::MultiAssets, - effects: ::std::vec::Vec, - }, - #[codec(index = 1)] - ReserveAssetDeposited { - assets: runtime_types::xcm::v1::multiasset::MultiAssets, - effects: ::std::vec::Vec, - }, - #[codec(index = 2)] - ReceiveTeleportedAsset { - assets: runtime_types::xcm::v1::multiasset::MultiAssets, - effects: ::std::vec::Vec, - }, - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::xcm::v1::Response, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::xcm::v1::multiasset::MultiAssets, - beneficiary: runtime_types::xcm::v1::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::xcm::v1::multiasset::MultiAssets, - dest: runtime_types::xcm::v1::multilocation::MultiLocation, - effects: ::std::vec::Vec, - }, - #[codec(index = 6)] - Transact { - origin_type: runtime_types::xcm::v0::OriginKind, - require_weight_at_most: ::core::primitive::u64, - call: runtime_types::xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - RelayedFrom { - who: runtime_types::xcm::v1::multilocation::Junctions, - message: ::std::boxed::Box, - }, - #[codec(index = 11)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 12)] - UnsubscribeVersion, - } - } - pub mod v2 { - use super::runtime_types; pub mod traits { use super::runtime_types; #[derive( @@ -47428,9 +51873,9 @@ pub mod api { #[codec(index = 3)] UntrustedTeleportLocation, #[codec(index = 4)] - MultiLocationFull, + LocationFull, #[codec(index = 5)] - MultiLocationNotInvertible, + LocationNotInvertible, #[codec(index = 6)] BadOrigin, #[codec(index = 7)] @@ -47464,13 +51909,41 @@ pub mod api { #[codec(index = 21)] Trap(::core::primitive::u64), #[codec(index = 22)] - UnhandledXcmVersion, + ExpectationFalse, #[codec(index = 23)] - WeightLimitReached(::core::primitive::u64), + PalletNotFound, #[codec(index = 24)] - Barrier, + NameMismatch, #[codec(index = 25)] + VersionIncompatible, + #[codec(index = 26)] + HoldingWouldOverflow, + #[codec(index = 27)] + ExportError, + #[codec(index = 28)] + ReanchorFailed, + #[codec(index = 29)] + NoDeal, + #[codec(index = 30)] + FeesNotMet, + #[codec(index = 31)] + LockError, + #[codec(index = 32)] + NoPermission, + #[codec(index = 33)] + Unanchored, + #[codec(index = 34)] + NotDepositable, + #[codec(index = 35)] + UnhandledXcmVersion, + #[codec(index = 36)] + WeightLimitReached(runtime_types::sp_weights::weight_v2::Weight), + #[codec(index = 37)] + Barrier, + #[codec(index = 38)] WeightNotComputable, + #[codec(index = 39)] + ExceedsStackLimit, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -47484,14 +51957,14 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Outcome { #[codec(index = 0)] - Complete(::core::primitive::u64), + Complete(runtime_types::sp_weights::weight_v2::Weight), #[codec(index = 1)] Incomplete( - ::core::primitive::u64, - runtime_types::xcm::v2::traits::Error, + runtime_types::sp_weights::weight_v2::Weight, + runtime_types::xcm::v3::traits::Error, ), #[codec(index = 2)] - Error(runtime_types::xcm::v2::traits::Error), + Error(runtime_types::xcm::v3::traits::Error), } } #[derive( @@ -47506,35 +51979,36 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Instruction { #[codec(index = 0)] - WithdrawAsset(runtime_types::xcm::v1::multiasset::MultiAssets), + WithdrawAsset(runtime_types::xcm::v3::multiasset::MultiAssets), #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::xcm::v1::multiasset::MultiAssets), + ReserveAssetDeposited(runtime_types::xcm::v3::multiasset::MultiAssets), #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::xcm::v1::multiasset::MultiAssets), + ReceiveTeleportedAsset(runtime_types::xcm::v3::multiasset::MultiAssets), #[codec(index = 3)] QueryResponse { #[codec(compact)] query_id: ::core::primitive::u64, - response: runtime_types::xcm::v2::Response, - #[codec(compact)] - max_weight: ::core::primitive::u64, + response: runtime_types::xcm::v3::Response, + max_weight: runtime_types::sp_weights::weight_v2::Weight, + querier: ::core::option::Option< + runtime_types::xcm::v3::multilocation::MultiLocation, + >, }, #[codec(index = 4)] TransferAsset { - assets: runtime_types::xcm::v1::multiasset::MultiAssets, - beneficiary: runtime_types::xcm::v1::multilocation::MultiLocation, + assets: runtime_types::xcm::v3::multiasset::MultiAssets, + beneficiary: runtime_types::xcm::v3::multilocation::MultiLocation, }, #[codec(index = 5)] TransferReserveAsset { - assets: runtime_types::xcm::v1::multiasset::MultiAssets, - dest: runtime_types::xcm::v1::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, + assets: runtime_types::xcm::v3::multiasset::MultiAssets, + dest: runtime_types::xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::xcm::v3::Xcm, }, #[codec(index = 6)] Transact { - origin_type: runtime_types::xcm::v0::OriginKind, - #[codec(compact)] - require_weight_at_most: ::core::primitive::u64, + origin_kind: runtime_types::xcm::v2::OriginKind, + require_weight_at_most: runtime_types::sp_weights::weight_v2::Weight, call: runtime_types::xcm::double_encoded::DoubleEncoded, }, #[codec(index = 7)] @@ -47563,73 +52037,60 @@ pub mod api { #[codec(index = 10)] ClearOrigin, #[codec(index = 11)] - DescendOrigin(runtime_types::xcm::v1::multilocation::Junctions), + DescendOrigin(runtime_types::xcm::v3::junctions::Junctions), #[codec(index = 12)] - ReportError { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v1::multilocation::MultiLocation, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, + ReportError(runtime_types::xcm::v3::QueryResponseInfo), #[codec(index = 13)] DepositAsset { - assets: runtime_types::xcm::v1::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - beneficiary: runtime_types::xcm::v1::multilocation::MultiLocation, + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + beneficiary: runtime_types::xcm::v3::multilocation::MultiLocation, }, #[codec(index = 14)] DepositReserveAsset { - assets: runtime_types::xcm::v1::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - dest: runtime_types::xcm::v1::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + dest: runtime_types::xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::xcm::v3::Xcm, }, #[codec(index = 15)] ExchangeAsset { - give: runtime_types::xcm::v1::multiasset::MultiAssetFilter, - receive: runtime_types::xcm::v1::multiasset::MultiAssets, + give: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + want: runtime_types::xcm::v3::multiasset::MultiAssets, + maximal: ::core::primitive::bool, }, #[codec(index = 16)] InitiateReserveWithdraw { - assets: runtime_types::xcm::v1::multiasset::MultiAssetFilter, - reserve: runtime_types::xcm::v1::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + reserve: runtime_types::xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::xcm::v3::Xcm, }, #[codec(index = 17)] InitiateTeleport { - assets: runtime_types::xcm::v1::multiasset::MultiAssetFilter, - dest: runtime_types::xcm::v1::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + dest: runtime_types::xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::xcm::v3::Xcm, }, #[codec(index = 18)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v1::multilocation::MultiLocation, - assets: runtime_types::xcm::v1::multiasset::MultiAssetFilter, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, + ReportHolding { + response_info: runtime_types::xcm::v3::QueryResponseInfo, + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, }, #[codec(index = 19)] BuyExecution { - fees: runtime_types::xcm::v1::multiasset::MultiAsset, - weight_limit: runtime_types::xcm::v2::WeightLimit, + fees: runtime_types::xcm::v3::multiasset::MultiAsset, + weight_limit: runtime_types::xcm::v3::WeightLimit, }, #[codec(index = 20)] RefundSurplus, #[codec(index = 21)] - SetErrorHandler(runtime_types::xcm::v2::Xcm), + SetErrorHandler(runtime_types::xcm::v3::Xcm), #[codec(index = 22)] - SetAppendix(runtime_types::xcm::v2::Xcm), + SetAppendix(runtime_types::xcm::v3::Xcm), #[codec(index = 23)] ClearError, #[codec(index = 24)] ClaimAsset { - assets: runtime_types::xcm::v1::multiasset::MultiAssets, - ticket: runtime_types::xcm::v1::multilocation::MultiLocation, + assets: runtime_types::xcm::v3::multiasset::MultiAssets, + ticket: runtime_types::xcm::v3::multilocation::MultiLocation, }, #[codec(index = 25)] Trap(#[codec(compact)] ::core::primitive::u64), @@ -47637,11 +52098,162 @@ pub mod api { SubscribeVersion { #[codec(compact)] query_id: ::core::primitive::u64, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, + max_response_weight: runtime_types::sp_weights::weight_v2::Weight, }, #[codec(index = 27)] UnsubscribeVersion, + #[codec(index = 28)] + BurnAsset(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 29)] + ExpectAsset(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 30)] + ExpectOrigin( + ::core::option::Option< + runtime_types::xcm::v3::multilocation::MultiLocation, + >, + ), + #[codec(index = 31)] + ExpectError( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::xcm::v3::traits::Error, + )>, + ), + #[codec(index = 32)] + ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), + #[codec(index = 33)] + QueryPallet { + module_name: ::std::vec::Vec<::core::primitive::u8>, + response_info: runtime_types::xcm::v3::QueryResponseInfo, + }, + #[codec(index = 34)] + ExpectPallet { + #[codec(compact)] + index: ::core::primitive::u32, + name: ::std::vec::Vec<::core::primitive::u8>, + module_name: ::std::vec::Vec<::core::primitive::u8>, + #[codec(compact)] + crate_major: ::core::primitive::u32, + #[codec(compact)] + min_crate_minor: ::core::primitive::u32, + }, + #[codec(index = 35)] + ReportTransactStatus(runtime_types::xcm::v3::QueryResponseInfo), + #[codec(index = 36)] + ClearTransactStatus, + #[codec(index = 37)] + UniversalOrigin(runtime_types::xcm::v3::junction::Junction), + #[codec(index = 38)] + ExportMessage { + network: runtime_types::xcm::v3::junction::NetworkId, + destination: runtime_types::xcm::v3::junctions::Junctions, + xcm: runtime_types::xcm::v3::Xcm, + }, + #[codec(index = 39)] + LockAsset { + asset: runtime_types::xcm::v3::multiasset::MultiAsset, + unlocker: runtime_types::xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 40)] + UnlockAsset { + asset: runtime_types::xcm::v3::multiasset::MultiAsset, + target: runtime_types::xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 41)] + NoteUnlockable { + asset: runtime_types::xcm::v3::multiasset::MultiAsset, + owner: runtime_types::xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 42)] + RequestUnlock { + asset: runtime_types::xcm::v3::multiasset::MultiAsset, + locker: runtime_types::xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 43)] + SetFeesMode { + jit_withdraw: ::core::primitive::bool, + }, + #[codec(index = 44)] + SetTopic([::core::primitive::u8; 32usize]), + #[codec(index = 45)] + ClearTopic, + #[codec(index = 46)] + AliasOrigin(runtime_types::xcm::v3::multilocation::MultiLocation), + #[codec(index = 47)] + UnpaidExecution { + weight_limit: runtime_types::xcm::v3::WeightLimit, + check_origin: ::core::option::Option< + runtime_types::xcm::v3::multilocation::MultiLocation, + >, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum MaybeErrorCode { + #[codec(index = 0)] + Success, + #[codec(index = 1)] + Error( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 2)] + TruncatedError( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + ), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PalletInfo { + #[codec(compact)] + pub index: ::core::primitive::u32, + pub name: runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + pub module_name: runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + #[codec(compact)] + pub major: ::core::primitive::u32, + #[codec(compact)] + pub minor: ::core::primitive::u32, + #[codec(compact)] + pub patch: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryResponseInfo { + pub destination: runtime_types::xcm::v3::multilocation::MultiLocation, + #[codec(compact)] + pub query_id: ::core::primitive::u64, + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -47657,16 +52269,24 @@ pub mod api { #[codec(index = 0)] Null, #[codec(index = 1)] - Assets(runtime_types::xcm::v1::multiasset::MultiAssets), + Assets(runtime_types::xcm::v3::multiasset::MultiAssets), #[codec(index = 2)] ExecutionResult( ::core::option::Option<( ::core::primitive::u32, - runtime_types::xcm::v2::traits::Error, + runtime_types::xcm::v3::traits::Error, )>, ), #[codec(index = 3)] Version(::core::primitive::u32), + #[codec(index = 4)] + PalletsInfo( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::xcm::v3::PalletInfo, + >, + ), + #[codec(index = 5)] + DispatchResult(runtime_types::xcm::v3::MaybeErrorCode), } #[derive( :: subxt :: ext :: codec :: Decode, @@ -47682,7 +52302,7 @@ pub mod api { #[codec(index = 0)] Unlimited, #[codec(index = 1)] - Limited(#[codec(compact)] ::core::primitive::u64), + Limited(runtime_types::sp_weights::weight_v2::Weight), } #[derive( :: subxt :: ext :: codec :: Decode, @@ -47694,7 +52314,21 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Xcm(pub ::std::vec::Vec); + pub struct Xcm(pub ::std::vec::Vec); + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum VersionedAssetId { + #[codec(index = 3)] + V3(runtime_types::xcm::v3::multiasset::AssetId), } #[derive( :: subxt :: ext :: codec :: Decode, @@ -47707,10 +52341,10 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum VersionedMultiAssets { - #[codec(index = 0)] - V0(::std::vec::Vec), #[codec(index = 1)] - V1(runtime_types::xcm::v1::multiasset::MultiAssets), + V2(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 3)] + V3(runtime_types::xcm::v3::multiasset::MultiAssets), } #[derive( :: subxt :: ext :: codec :: Decode, @@ -47723,10 +52357,10 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum VersionedMultiLocation { - #[codec(index = 0)] - V0(runtime_types::xcm::v0::multi_location::MultiLocation), #[codec(index = 1)] - V1(runtime_types::xcm::v1::multilocation::MultiLocation), + V2(runtime_types::xcm::v2::multilocation::MultiLocation), + #[codec(index = 3)] + V3(runtime_types::xcm::v3::multilocation::MultiLocation), } #[derive( :: subxt :: ext :: codec :: Decode, @@ -47739,12 +52373,10 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum VersionedResponse { - #[codec(index = 0)] - V0(runtime_types::xcm::v0::Response), - #[codec(index = 1)] - V1(runtime_types::xcm::v1::Response), #[codec(index = 2)] V2(runtime_types::xcm::v2::Response), + #[codec(index = 3)] + V3(runtime_types::xcm::v3::Response), } #[derive( :: subxt :: ext :: codec :: Decode, @@ -47757,12 +52389,10 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum VersionedXcm { - #[codec(index = 0)] - V0(runtime_types::xcm::v0::Xcm), - #[codec(index = 1)] - V1(runtime_types::xcm::v1::Xcm), #[codec(index = 2)] V2(runtime_types::xcm::v2::Xcm), + #[codec(index = 3)] + V3(runtime_types::xcm::v3::Xcm), } } } From 2d8301930b2754fa1f25a427ffaeccc0da11d62c Mon Sep 17 00:00:00 2001 From: Andrew Jones Date: Wed, 3 May 2023 13:14:27 +0100 Subject: [PATCH 11/22] Upgrade to `syn 2.0` (#875) * WIP updating to syn 2.0.0 * WIP darling compat * Update darling and syn workspace deps * NestedMeta::parse_meta_list * Rename attribute keyword type property to path * Fmt * Update more type to path * Unused darling * Cargo.lock * Add missing syn features --- Cargo.lock | 56 +++++++++++++++---- Cargo.toml | 4 +- codegen/Cargo.toml | 1 - codegen/src/types/mod.rs | 3 +- examples/examples/custom_type_derives.rs | 4 +- macro/src/lib.rs | 34 ++++++----- .../ui-tests/src/correct/generic_params.rs | 16 +++--- .../incorrect/substitute_path_not_absolute.rs | 2 +- 8 files changed, 79 insertions(+), 41 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 37ec76ad34..eb041f83ed 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -831,8 +831,18 @@ version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7b750cb3417fd1b327431a470f388520309479ab0bf5e323505daf0290cd3850" dependencies = [ - "darling_core", - "darling_macro", + "darling_core 0.14.4", + "darling_macro 0.14.4", +] + +[[package]] +name = "darling" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e7c99d16b88c92aef47e58dadd53e87b4bd234c29934947a6cec8b466300f99b" +dependencies = [ + "darling_core 0.20.0", + "darling_macro 0.20.0", ] [[package]] @@ -849,17 +859,42 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "darling_core" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2ea05d2fcb27b53f7a98faddaf5f2914760330ab7703adfc9df13332b42189f9" +dependencies = [ + "fnv", + "ident_case", + "proc-macro2", + "quote", + "strsim", + "syn 2.0.15", +] + [[package]] name = "darling_macro" version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a4aab4dbc9f7611d8b55048a3a16d2d010c2c8334e46304b40ac1cc14bf3b48e" dependencies = [ - "darling_core", + "darling_core 0.14.4", "quote", "syn 1.0.109", ] +[[package]] +name = "darling_macro" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7bfb82b62b1b8a2a9808fb4caf844ede819a76cfc23b2827d7f94eefb49551eb" +dependencies = [ + "darling_core 0.20.0", + "quote", + "syn 2.0.15", +] + [[package]] name = "derivative" version = "2.2.0" @@ -1628,7 +1663,7 @@ dependencies = [ "subxt", "subxt-codegen", "subxt-metadata", - "syn 1.0.109", + "syn 2.0.15", "test-runtime", "tokio", "tracing", @@ -2692,7 +2727,7 @@ version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b38741b2f78e4391b94eac6b102af0f6ea2b0f7fe65adb55d7f4004f507854db" dependencies = [ - "darling", + "darling 0.14.4", "proc-macro-crate", "proc-macro2", "quote", @@ -2719,7 +2754,7 @@ version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dd983cf0a9effd76138554ead18a6de542d1af175ac12fd5e91836c5c0268082" dependencies = [ - "darling", + "darling 0.14.4", "proc-macro-crate", "proc-macro2", "quote", @@ -3549,7 +3584,7 @@ dependencies = [ "serde_json", "subxt-codegen", "subxt-metadata", - "syn 1.0.109", + "syn 2.0.15", "tokio", ] @@ -3558,7 +3593,6 @@ name = "subxt-codegen" version = "0.28.0" dependencies = [ "bitvec", - "darling", "frame-metadata", "heck", "hex", @@ -3569,7 +3603,7 @@ dependencies = [ "quote", "scale-info", "subxt-metadata", - "syn 1.0.109", + "syn 2.0.15", "thiserror", "tokio", ] @@ -3593,10 +3627,10 @@ dependencies = [ name = "subxt-macro" version = "0.28.0" dependencies = [ - "darling", + "darling 0.20.0", "proc-macro-error", "subxt-codegen", - "syn 1.0.109", + "syn 2.0.15", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index c59ceaeea4..cf87f98ec1 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -38,7 +38,7 @@ criterion = "0.4" codec = { package = "parity-scale-codec", version = "3.4.0", default-features = false } color-eyre = "0.6.1" console_error_panic_hook = "0.1.7" -darling = "0.14.4" +darling = "0.20.0" derivative = "2.2.0" either = "1.8.1" frame-metadata = { version = "15.1.0", features = ["v14", "v15-unstable", "std"] } @@ -61,7 +61,7 @@ scale-decode = "0.5.0" scale-encode = "0.1.0" serde = { version = "1.0.159" } serde_json = { version = "1.0.96" } -syn = "1.0.109" +syn = { version = "2.0.15", features = ["full", "extra-traits"] } thiserror = "1.0.40" tokio = { version = "1.28", features = ["macros", "time", "rt-multi-thread"] } tracing = "0.1.34" diff --git a/codegen/Cargo.toml b/codegen/Cargo.toml index 6c776d30b0..3db79d4829 100644 --- a/codegen/Cargo.toml +++ b/codegen/Cargo.toml @@ -14,7 +14,6 @@ description = "Generate an API for interacting with a substrate node from FRAME [dependencies] codec = { package = "parity-scale-codec", workspace = true, features = ["derive"] } -darling = { workspace = true } frame-metadata = { workspace = true } heck = { workspace = true } proc-macro2 = { workspace = true } diff --git a/codegen/src/types/mod.rs b/codegen/src/types/mod.rs index caaa427df6..4dedb14fc3 100644 --- a/codegen/src/types/mod.rs +++ b/codegen/src/types/mod.rs @@ -11,7 +11,6 @@ mod type_def; mod type_def_params; mod type_path; -use darling::FromMeta; use proc_macro2::{Ident, Span, TokenStream}; use quote::{quote, ToTokens}; use scale_info::{form::PortableForm, PortableRegistry, Type, TypeDef}; @@ -353,7 +352,7 @@ impl ToTokens for CratePath { impl From<&str> for CratePath { fn from(crate_path: &str) -> Self { - Self(syn::Path::from_string(crate_path).unwrap_or_else(|err| { + Self(syn::parse_str(crate_path).unwrap_or_else(|err| { panic!("failed converting {crate_path:?} to `syn::Path`: {err:?}"); })) } diff --git a/examples/examples/custom_type_derives.rs b/examples/examples/custom_type_derives.rs index 9e7a22a1c7..b8cf6433c7 100644 --- a/examples/examples/custom_type_derives.rs +++ b/examples/examples/custom_type_derives.rs @@ -17,8 +17,8 @@ // mapping the type path to the derives which should be added for that type only. // Note that these derives will be in addition to those specified above in // `derive_for_all_types` - derive_for_type(type = "frame_support::PalletId", derive = "Eq, Ord, PartialOrd"), - derive_for_type(type = "sp_runtime::ModuleError", derive = "Eq, Hash"), + derive_for_type(path = "frame_support::PalletId", derive = "Eq, Ord, PartialOrd"), + derive_for_type(path = "sp_runtime::ModuleError", derive = "Eq, Hash"), )] pub mod polkadot {} diff --git a/macro/src/lib.rs b/macro/src/lib.rs index bb0ac0b7fb..f0621a1ec4 100644 --- a/macro/src/lib.rs +++ b/macro/src/lib.rs @@ -31,7 +31,7 @@ //! ```ignore //! #[subxt::subxt( //! runtime_metadata_path = "polkadot_metadata.scale", -//! substitute_type(type = "sp_arithmetic::per_things::Perbill", with = "sp_runtime::Perbill") +//! substitute_type(path = "sp_arithmetic::per_things::Perbill", with = "sp_runtime::Perbill") //! )] //! pub mod polkadot {} //! ``` @@ -67,8 +67,8 @@ //! #[subxt::subxt( //! runtime_metadata_path = "polkadot_metadata.scale", //! derive_for_all_types = "Eq, PartialEq", -//! derive_for_type(type = "frame_support::PalletId", derive = "Ord, PartialOrd"), -//! derive_for_type(type = "sp_runtime::ModuleError", derive = "Hash"), +//! derive_for_type(path = "frame_support::PalletId", derive = "Ord, PartialOrd"), +//! derive_for_type(path = "sp_runtime::ModuleError", derive = "Hash"), //! )] //! pub mod polkadot {} //! ``` @@ -113,7 +113,7 @@ extern crate proc_macro; use std::str::FromStr; -use darling::FromMeta; +use darling::{ast::NestedMeta, FromMeta}; use proc_macro::TokenStream; use proc_macro_error::{abort_call_site, proc_macro_error}; use subxt_codegen::{utils::Uri, CodegenError, DerivesRegistry, TypeSubstitutes}; @@ -158,29 +158,31 @@ struct RuntimeMetadataArgs { #[derive(Debug, FromMeta)] struct DeriveForType { - #[darling(rename = "type")] - ty: syn::TypePath, + path: syn::TypePath, derive: Punctuated, } #[derive(Debug, FromMeta)] struct AttributesForType { - #[darling(rename = "type")] - ty: syn::TypePath, + path: syn::TypePath, attributes: Punctuated, } #[derive(Debug, FromMeta)] struct SubstituteType { - #[darling(rename = "type")] - ty: syn::Path, + path: syn::Path, with: syn::Path, } #[proc_macro_attribute] #[proc_macro_error] pub fn subxt(args: TokenStream, input: TokenStream) -> TokenStream { - let attr_args = parse_macro_input!(args as syn::AttributeArgs); + let attr_args = match NestedMeta::parse_meta_list(args.into()) { + Ok(v) => v, + Err(e) => { + return TokenStream::from(darling::Error::from(e).write_errors()); + } + }; let item_mod = parse_macro_input!(input as syn::ItemMod); let args = match RuntimeMetadataArgs::from_list(&attr_args) { Ok(v) => v, @@ -205,11 +207,15 @@ pub fn subxt(args: TokenStream, input: TokenStream) -> TokenStream { ); for derives in &args.derive_for_type { - derives_registry.extend_for_type(derives.ty.clone(), derives.derive.iter().cloned(), vec![]) + derives_registry.extend_for_type( + derives.path.clone(), + derives.derive.iter().cloned(), + vec![], + ) } for attributes in &args.attributes_for_type { derives_registry.extend_for_type( - attributes.ty.clone(), + attributes.path.clone(), vec![], attributes.attributes.iter().map(|a| a.0.clone()), ) @@ -223,7 +229,7 @@ pub fn subxt(args: TokenStream, input: TokenStream) -> TokenStream { let substitute_args_res: Result<(), _> = args.substitute_type.into_iter().try_for_each(|sub| { sub.with .try_into() - .and_then(|with| type_substitutes.insert(sub.ty, with)) + .and_then(|with| type_substitutes.insert(sub.path, with)) }); if let Err(err) = substitute_args_res { diff --git a/testing/ui-tests/src/correct/generic_params.rs b/testing/ui-tests/src/correct/generic_params.rs index 00ae5b976f..30f024fe12 100644 --- a/testing/ui-tests/src/correct/generic_params.rs +++ b/testing/ui-tests/src/correct/generic_params.rs @@ -22,7 +22,7 @@ pub struct DoesntImplEncodeDecodeAsType(u16); #[subxt::subxt( runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( - type = "sp_runtime::multiaddress::MultiAddress", + path = "sp_runtime::multiaddress::MultiAddress", // Discarding both params: with = "crate::CustomAddress" ) @@ -32,7 +32,7 @@ pub mod node_runtime {} #[subxt::subxt( runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( - type = "sp_runtime::multiaddress::MultiAddress", + path = "sp_runtime::multiaddress::MultiAddress", // Discarding second param: with = "crate::Generic" ) @@ -42,7 +42,7 @@ pub mod node_runtime2 {} #[subxt::subxt( runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( - type = "sp_runtime::multiaddress::MultiAddress", + path = "sp_runtime::multiaddress::MultiAddress", // Discarding first param: with = "crate::Generic" ) @@ -52,7 +52,7 @@ pub mod node_runtime3 {} #[subxt::subxt( runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( - type = "sp_runtime::multiaddress::MultiAddress", + path = "sp_runtime::multiaddress::MultiAddress", // Swapping params: with = "crate::Second" ) @@ -62,7 +62,7 @@ pub mod node_runtime4 {} #[subxt::subxt( runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( - type = "sp_runtime::multiaddress::MultiAddress", + path = "sp_runtime::multiaddress::MultiAddress", // Ignore input params and just use concrete types on output: with = "crate::Second>" ) @@ -72,7 +72,7 @@ pub mod node_runtime5 {} #[subxt::subxt( runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( - type = "sp_runtime::multiaddress::MultiAddress", + path = "sp_runtime::multiaddress::MultiAddress", // We can put a static type in, too: with = "crate::Second" ) @@ -82,7 +82,7 @@ pub mod node_runtime6 {} #[subxt::subxt( runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( - type = "sp_runtime::multiaddress::MultiAddress", + path = "sp_runtime::multiaddress::MultiAddress", // Check that things can be wrapped in our Static type: with = "::subxt::utils::Static" ) @@ -92,7 +92,7 @@ pub mod node_runtime7 {} #[subxt::subxt( runtime_metadata_path = "../../../../artifacts/polkadot_metadata_small.scale", substitute_type( - type = "sp_runtime::multiaddress::MultiAddress", + path = "sp_runtime::multiaddress::MultiAddress", // Recursive type param substitution should work too (swapping out nested A and B): with = "::subxt::utils::Static>" ) diff --git a/testing/ui-tests/src/incorrect/substitute_path_not_absolute.rs b/testing/ui-tests/src/incorrect/substitute_path_not_absolute.rs index 154b857c9d..470ea83a7b 100644 --- a/testing/ui-tests/src/incorrect/substitute_path_not_absolute.rs +++ b/testing/ui-tests/src/incorrect/substitute_path_not_absolute.rs @@ -1,7 +1,7 @@ #[subxt::subxt( runtime_metadata_path = "../../../../artifacts/polkadot_metadata_tiny.scale", substitute_type( - type = "sp_arithmetic::per_things::Perbill", + path = "sp_arithmetic::per_things::Perbill", with = "sp_runtime::Perbill" ) )] From 5f4610eb5e38fb7899ebaf602b1453471bdec7d0 Mon Sep 17 00:00:00 2001 From: Alexandru Vasile <60601340+lexnv@users.noreply.github.com> Date: Wed, 3 May 2023 17:31:27 +0300 Subject: [PATCH 12/22] Metadata V15: Generate Runtime APIs (#918) * Update frame-metadata to v15.1.0 Signed-off-by: Alexandru Vasile * Enable V15 unstable metadata in frame-metadata Signed-off-by: Alexandru Vasile * metadata: Move validation hashing to dedicated file Signed-off-by: Alexandru Vasile * Use sp-metadata-ir from substrate to work with metadata Signed-off-by: Alexandru Vasile * Revert using sp-metadata-ir in favor of conversion to v15 Signed-off-by: Alexandru Vasile * metadata: Convert v14 to v15 Signed-off-by: Alexandru Vasile * metadata: Use v15 for validation Signed-off-by: Alexandru Vasile * codegen: Use v15 for codegen Signed-off-by: Alexandru Vasile * metadata/bench: Use v15 Signed-off-by: Alexandru Vasile * Adjust to v15 metadata Signed-off-by: Alexandru Vasile * Adjust testing Signed-off-by: Alexandru Vasile * Improve documentation Signed-off-by: Alexandru Vasile * force CI Signed-off-by: Alexandru Vasile * rpc: Fetch metadata at version Signed-off-by: Alexandru Vasile * artifacts: Update polkadot.scale from commit 6dc9e84dde2 Signed-off-by: Alexandru Vasile * codegen: Fetch V15 using the new API Signed-off-by: Alexandru Vasile * codegen: Add runtime API interface Signed-off-by: Alexandru Vasile * metadata: Hash runtime API metadata for validation Signed-off-by: Alexandru Vasile * metadata: Extract runtime API metadata wrapper from subxt::Metadata Signed-off-by: Alexandru Vasile * subxt: Adjust hashing cache to reflect root+item keys Signed-off-by: Alexandru Vasile * rpc: Add raw state_call API method Signed-off-by: Alexandru Vasile * runtime_api: Add payload with static and dynamic variants Signed-off-by: Alexandru Vasile * subxt: Allow payloads to call into the runtime Signed-off-by: Alexandru Vasile * examples: Add example to make a runtime API call both static and dynamic Signed-off-by: Alexandru Vasile * Update polkadot.rs Signed-off-by: Alexandru Vasile * codegen: Simplify client fetching Signed-off-by: Alexandru Vasile * Address feedback and fallback to old API if needed Signed-off-by: Alexandru Vasile * runtime_api: Make mutability conditional on input params Signed-off-by: Alexandru Vasile * Regenerate polkadot.rs Signed-off-by: Alexandru Vasile * metadata: Retain only pallets without runtime API info Signed-off-by: Alexandru Vasile * codegen: Retry via `Metadata_metadata` without conversion Signed-off-by: Alexandru Vasile * payload: Remove `Decode` and change validation fn Signed-off-by: Alexandru Vasile * metadata: Retain runtime API types Signed-off-by: Alexandru Vasile * codegen: Runtime APIs documentation based on flag Signed-off-by: Alexandru Vasile * Update examples/examples/custom_metadata_url.rs Co-authored-by: James Wilson * Update artifacts from polkadot-a6cfdb16e9 Signed-off-by: Alexandru Vasile * Update polkadot.rs with polkadot-a6cfdb16e9 Signed-off-by: Alexandru Vasile * codegen: Generate input structures for runtime API Signed-off-by: Alexandru Vasile * runtime_api: Remove the static paylaod and use single impl Signed-off-by: Alexandru Vasile * examples: Fetch account nonce Signed-off-by: Alexandru Vasile * testing: Adjust build script to fetch latest metadata Signed-off-by: Alexandru Vasile * testing: Check account nonce from runtime API Signed-off-by: Alexandru Vasile * Update cargo.lock Signed-off-by: Alexandru Vasile * codegen: Fix doc generation for runtime types Signed-off-by: Alexandru Vasile * codegen: Rename `inputs` runtime calls module to `types` Signed-off-by: Alexandru Vasile * codegen: Generate Calls structs inside the types module Signed-off-by: Alexandru Vasile * testing: Check Alice account nonce before submitting the tx Signed-off-by: Alexandru Vasile * cli: Add metadata version option flag supporting v14 and unstable Signed-off-by: Alexandru Vasile * cli: Specify version to fetch Signed-off-by: Alexandru Vasile * subxt: Fallback to fetching latest stable metadata Signed-off-by: Alexandru Vasile * subxt: Add unstable-metadata feature to fetch the latest Signed-off-by: Alexandru Vasile * RuntimeVersion with Latest and Version(u32) Signed-off-by: Alexandru Vasile * Update polkadot.rs Signed-off-by: Alexandru Vasile * codegen: Adjust fetch_metadata to inspect version list Signed-off-by: Alexandru Vasile * testing: Adjust metadata to metadata_legacy Signed-off-by: Alexandru Vasile * events: Adjust docs to use metadata_legacy Signed-off-by: Alexandru Vasile * have a pass over fetch_metadata * cargo fmt * Option when fetch metadata via latest API * clippy * fmt * cli: Use the MetadataVersion from codegen Signed-off-by: Alexandru Vasile * cli: Specify latest as default for MetadataVersion Signed-off-by: Alexandru Vasile * cli: Remove version from metadata and use the one from file_or_url Signed-off-by: Alexandru Vasile * Fix clippy Signed-off-by: Alexandru Vasile * codegen: Decode metadata independently for different RPC calls Signed-off-by: Alexandru Vasile --------- Signed-off-by: Alexandru Vasile Co-authored-by: James Wilson --- Cargo.lock | 2 + cli/src/commands/compatibility.rs | 39 +- cli/src/utils.rs | 42 +- codegen/src/api/calls.rs | 10 +- codegen/src/api/mod.rs | 23 +- codegen/src/api/runtime_apis.rs | 168 + codegen/src/error.rs | 7 + codegen/src/utils/fetch_metadata.rs | 197 +- codegen/src/utils/mod.rs | 2 +- examples/examples/runtime_calls.rs | 88 + metadata/src/lib.rs | 2 +- metadata/src/retain.rs | 36 +- metadata/src/validation.rs | 131 +- subxt/Cargo.toml | 6 + subxt/src/client/online_client.rs | 21 +- subxt/src/dynamic.rs | 3 + subxt/src/events/events_type.rs | 2 +- subxt/src/metadata/hash_cache.rs | 25 +- subxt/src/metadata/metadata_type.rs | 119 +- subxt/src/rpc/rpc.rs | 53 +- subxt/src/runtime_api/mod.rs | 2 + subxt/src/runtime_api/runtime_payload.rs | 162 + subxt/src/runtime_api/runtime_types.rs | 57 +- testing/integration-tests/Cargo.toml | 2 +- testing/integration-tests/src/blocks/mod.rs | 2 +- testing/integration-tests/src/client/mod.rs | 2 +- .../src/codegen/codegen_documentation.rs | 8 + .../integration-tests/src/codegen/polkadot.rs | 6872 +++++++++-------- testing/integration-tests/src/lib.rs | 2 + .../integration-tests/src/runtime_api/mod.rs | 49 + testing/test-runtime/Cargo.toml | 2 + testing/test-runtime/build.rs | 20 +- 32 files changed, 4721 insertions(+), 3435 deletions(-) create mode 100644 codegen/src/api/runtime_apis.rs create mode 100644 examples/examples/runtime_calls.rs create mode 100644 subxt/src/runtime_api/runtime_payload.rs create mode 100644 testing/integration-tests/src/runtime_api/mod.rs diff --git a/Cargo.lock b/Cargo.lock index eb041f83ed..c58c56f890 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3692,8 +3692,10 @@ dependencies = [ name = "test-runtime" version = "0.28.0" dependencies = [ + "hex", "impl-serde", "jsonrpsee", + "parity-scale-codec", "serde", "substrate-runner", "subxt", diff --git a/cli/src/commands/compatibility.rs b/cli/src/commands/compatibility.rs index 3b0e2cdd44..51d50068c8 100644 --- a/cli/src/commands/compatibility.rs +++ b/cli/src/commands/compatibility.rs @@ -11,6 +11,7 @@ use frame_metadata::{ use jsonrpsee::client_transport::ws::Uri; use serde::{Deserialize, Serialize}; use std::collections::HashMap; +use subxt_codegen::utils::MetadataVersion; use subxt_metadata::{get_metadata_hash, get_pallet_hash, metadata_v14_to_latest}; /// Verify metadata compatibility between substrate nodes. @@ -25,16 +26,35 @@ pub struct Opts { /// The validation will omit the full metadata check and focus instead on the pallet. #[clap(long, value_parser)] pallet: Option, + /// Specify the metadata version. + /// + /// - unstable: + /// + /// Use the latest unstable metadata of the node. + /// + /// - number + /// + /// Use this specific metadata version. + /// + /// Defaults to latest. + #[clap(long = "version", default_value = "latest")] + version: MetadataVersion, } pub async fn run(opts: Opts) -> color_eyre::Result<()> { match opts.pallet { - Some(pallet) => handle_pallet_metadata(opts.nodes.as_slice(), pallet.as_str()).await, - None => handle_full_metadata(opts.nodes.as_slice()).await, + Some(pallet) => { + handle_pallet_metadata(opts.nodes.as_slice(), pallet.as_str(), opts.version).await + } + None => handle_full_metadata(opts.nodes.as_slice(), opts.version).await, } } -async fn handle_pallet_metadata(nodes: &[Uri], name: &str) -> color_eyre::Result<()> { +async fn handle_pallet_metadata( + nodes: &[Uri], + name: &str, + version: MetadataVersion, +) -> color_eyre::Result<()> { #[derive(Serialize, Deserialize, Default)] #[serde(rename_all = "camelCase")] struct CompatibilityPallet { @@ -44,7 +64,7 @@ async fn handle_pallet_metadata(nodes: &[Uri], name: &str) -> color_eyre::Result let mut compatibility: CompatibilityPallet = Default::default(); for node in nodes.iter() { - let metadata = fetch_runtime_metadata(node).await?; + let metadata = fetch_runtime_metadata(node, version).await?; match metadata.pallets.iter().find(|pallet| pallet.name == name) { Some(pallet_metadata) => { @@ -73,10 +93,10 @@ async fn handle_pallet_metadata(nodes: &[Uri], name: &str) -> color_eyre::Result Ok(()) } -async fn handle_full_metadata(nodes: &[Uri]) -> color_eyre::Result<()> { +async fn handle_full_metadata(nodes: &[Uri], version: MetadataVersion) -> color_eyre::Result<()> { let mut compatibility_map: HashMap> = HashMap::new(); for node in nodes.iter() { - let metadata = fetch_runtime_metadata(node).await?; + let metadata = fetch_runtime_metadata(node, version).await?; let hash = get_metadata_hash(&metadata); let hex_hash = hex::encode(hash); println!("Node {node:?} has metadata hash {hex_hash:?}",); @@ -96,8 +116,11 @@ async fn handle_full_metadata(nodes: &[Uri]) -> color_eyre::Result<()> { Ok(()) } -async fn fetch_runtime_metadata(url: &Uri) -> color_eyre::Result { - let bytes = subxt_codegen::utils::fetch_metadata_bytes(url).await?; +async fn fetch_runtime_metadata( + url: &Uri, + version: MetadataVersion, +) -> color_eyre::Result { + let bytes = subxt_codegen::utils::fetch_metadata_bytes(url, version).await?; let metadata = ::decode(&mut &bytes[..])?; if metadata.0 != META_RESERVED { diff --git a/cli/src/utils.rs b/cli/src/utils.rs index c5af8c9cd8..9a8b6edf82 100644 --- a/cli/src/utils.rs +++ b/cli/src/utils.rs @@ -5,7 +5,7 @@ use clap::Args; use color_eyre::eyre; use std::{fs, io::Read, path::PathBuf}; -use subxt_codegen::utils::Uri; +use subxt_codegen::utils::{MetadataVersion, Uri}; /// The source of the metadata. #[derive(Debug, Args)] @@ -16,29 +16,57 @@ pub struct FileOrUrl { /// The path to the encoded metadata file. #[clap(long, value_parser)] file: Option, + /// Specify the metadata version. + /// + /// - unstable: + /// + /// Use the latest unstable metadata of the node. + /// + /// - number + /// + /// Use this specific metadata version. + /// + /// Defaults to 14. + #[clap(long)] + version: Option, } impl FileOrUrl { /// Fetch the metadata bytes. pub async fn fetch(&self) -> color_eyre::Result> { - match (&self.file, &self.url) { + match (&self.file, &self.url, self.version) { // Can't provide both --file and --url - (Some(_), Some(_)) => { + (Some(_), Some(_), _) => { eyre::bail!("specify one of `--url` or `--file` but not both") } // Load from --file path - (Some(path), None) => { + (Some(path), None, None) => { let mut file = fs::File::open(path)?; let mut bytes = Vec::new(); file.read_to_end(&mut bytes)?; Ok(bytes) } + // Cannot load the metadata from the file and specify a version to fetch. + (Some(_), None, Some(_)) => { + // Note: we could provide the ability to convert between metadata versions + // but that would be involved because we'd need to convert + // from each metadata to the latest one and from the + // latest one to each metadata version. For now, disable the conversion. + eyre::bail!("`--file` is incompatible with `--version`") + } // Fetch from --url - (None, Some(uri)) => Ok(subxt_codegen::utils::fetch_metadata_bytes(uri).await?), + (None, Some(uri), version) => Ok(subxt_codegen::utils::fetch_metadata_bytes( + uri, + version.unwrap_or_default(), + ) + .await?), // Default if neither is provided; fetch from local url - (None, None) => { + (None, None, version) => { let uri = Uri::from_static("http://localhost:9933"); - Ok(subxt_codegen::utils::fetch_metadata_bytes(&uri).await?) + Ok( + subxt_codegen::utils::fetch_metadata_bytes(&uri, version.unwrap_or_default()) + .await?, + ) } } } diff --git a/codegen/src/api/calls.rs b/codegen/src/api/calls.rs index 37fe1e0e66..4df5ca637c 100644 --- a/codegen/src/api/calls.rs +++ b/codegen/src/api/calls.rs @@ -90,11 +90,11 @@ pub fn generate_calls( pub fn #fn_name( &self, #( #call_fn_args, )* - ) -> #crate_path::tx::Payload<#struct_name> { + ) -> #crate_path::tx::Payload { #crate_path::tx::Payload::new_static( #pallet_name, #call_name, - #struct_name { #( #call_args, )* }, + types::#struct_name { #( #call_args, )* }, [#(#call_hash,)*] ) } @@ -120,7 +120,11 @@ pub fn generate_calls( type DispatchError = #types_mod_ident::sp_runtime::DispatchError; - #( #call_structs )* + pub mod types { + use super::#types_mod_ident; + + #( #call_structs )* + } pub struct TransactionApi; diff --git a/codegen/src/api/mod.rs b/codegen/src/api/mod.rs index 85d6e6bf00..8f112b088f 100644 --- a/codegen/src/api/mod.rs +++ b/codegen/src/api/mod.rs @@ -8,6 +8,7 @@ mod calls; mod constants; mod errors; mod events; +mod runtime_apis; mod storage; use frame_metadata::v15::RuntimeMetadataV15; @@ -18,7 +19,7 @@ use crate::error::CodegenError; use crate::{ ir, types::{CompositeDef, CompositeDefFields, TypeGenerator, TypeSubstitutes}, - utils::{fetch_metadata_bytes_blocking, Uri}, + utils::{fetch_metadata_bytes_blocking, MetadataVersion, Uri}, CratePath, }; use codec::Decode; @@ -95,7 +96,11 @@ pub fn generate_runtime_api_from_url( should_gen_docs: bool, runtime_types_only: bool, ) -> Result { - let bytes = fetch_metadata_bytes_blocking(url)?; + // Fetch latest unstable version, if that fails fall back to the latest stable. + let bytes = match fetch_metadata_bytes_blocking(url, MetadataVersion::Unstable) { + Ok(bytes) => bytes, + Err(_) => fetch_metadata_bytes_blocking(url, MetadataVersion::Latest)?, + }; generate_runtime_api_from_bytes( item_mod, @@ -434,6 +439,14 @@ impl RuntimeGenerator { let rust_items = item_mod_ir.rust_items(); + let apis_mod = runtime_apis::generate_runtime_apis( + &self.metadata, + &type_gen, + types_mod_ident, + &crate_path, + should_gen_docs, + )?; + Ok(quote! { #( #item_mod_attrs )* #[allow(dead_code, unused_imports, non_camel_case_types)] @@ -487,6 +500,12 @@ impl RuntimeGenerator { TransactionApi } + pub fn apis() -> runtime_apis::RuntimeApi { + runtime_apis::RuntimeApi + } + + #apis_mod + pub struct ConstantsApi; impl ConstantsApi { #( diff --git a/codegen/src/api/runtime_apis.rs b/codegen/src/api/runtime_apis.rs new file mode 100644 index 0000000000..3b96ad4397 --- /dev/null +++ b/codegen/src/api/runtime_apis.rs @@ -0,0 +1,168 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +use crate::{types::TypeGenerator, CodegenError, CratePath}; +use frame_metadata::v15::{RuntimeApiMetadata, RuntimeMetadataV15}; +use heck::ToSnakeCase as _; +use heck::ToUpperCamelCase as _; + +use proc_macro2::TokenStream as TokenStream2; +use quote::{format_ident, quote}; +use scale_info::form::PortableForm; + +/// Generates runtime functions for the given API metadata. +fn generate_runtime_api( + metadata: &RuntimeMetadataV15, + api: &RuntimeApiMetadata, + type_gen: &TypeGenerator, + types_mod_ident: &syn::Ident, + crate_path: &CratePath, + should_gen_docs: bool, +) -> Result<(TokenStream2, TokenStream2), CodegenError> { + // Trait name must remain as is (upper case) to identity the runtime call. + let trait_name = &api.name; + // The snake case for the trait name. + let trait_name_snake = format_ident!("{}", api.name.to_snake_case()); + let docs = &api.docs; + let docs: TokenStream2 = should_gen_docs + .then_some(quote! { #( #[doc = #docs ] )* }) + .unwrap_or_default(); + + let structs_and_methods: Vec<_> = api.methods.iter().map(|method| { + let method_name = format_ident!("{}", method.name); + + // Runtime function name is `TraitName_MethodName`. + let runtime_fn_name = format!("{}_{}", trait_name, method_name); + let docs = &method.docs; + let docs: TokenStream2 = should_gen_docs + .then_some(quote! { #( #[doc = #docs ] )* }) + .unwrap_or_default(); + + let inputs: Vec<_> = method.inputs.iter().map(|input| { + let name = format_ident!("{}", &input.name); + let ty = type_gen.resolve_type_path(input.ty.id); + + let param = quote!(#name: #ty); + (param, name) + }).collect(); + + let params = inputs.iter().map(|(param, _)| param); + let param_names = inputs.iter().map(|(_, name)| name); + + // From the method metadata generate a structure that holds + // all parameter types. This structure is used with metadata + // to encode parameters to the call via `encode_as_fields_to`. + let derives = type_gen.default_derives(); + let struct_name = format_ident!("{}", method.name.to_upper_camel_case()); + let struct_params = params.clone(); + let struct_input = quote!( + #derives + pub struct #struct_name { + #( pub #struct_params, )* + } + ); + + let output = type_gen.resolve_type_path(method.output.id); + + let Ok(call_hash) = + subxt_metadata::get_runtime_api_hash(metadata, trait_name, &method.name) else { + return Err(CodegenError::MissingRuntimeApiMetadata( + trait_name.into(), + method.name.clone(), + )) + }; + + let method = quote!( + #docs + pub fn #method_name(&self, #( #params, )* ) -> #crate_path::runtime_api::Payload { + #crate_path::runtime_api::Payload::new_static( + #runtime_fn_name, + types::#struct_name { #( #param_names, )* }, + [#(#call_hash,)*], + ) + } + ); + + Ok((struct_input, method)) + }).collect::>()?; + + let trait_name = format_ident!("{}", trait_name); + + let structs = structs_and_methods.iter().map(|(struct_, _)| struct_); + let methods = structs_and_methods.iter().map(|(_, method)| method); + + let runtime_api = quote!( + pub mod #trait_name_snake { + use super::root_mod; + use super::#types_mod_ident; + + #docs + pub struct #trait_name; + + impl #trait_name { + #( #methods )* + } + + pub mod types { + use super::#types_mod_ident; + + #( #structs )* + } + } + ); + + // A getter for the `RuntimeApi` to get the trait structure. + let trait_getter = quote!( + pub fn #trait_name_snake(&self) -> #trait_name_snake::#trait_name { + #trait_name_snake::#trait_name + } + ); + + Ok((runtime_api, trait_getter)) +} + +/// Generate the runtime APIs. +pub fn generate_runtime_apis( + metadata: &RuntimeMetadataV15, + type_gen: &TypeGenerator, + types_mod_ident: &syn::Ident, + crate_path: &CratePath, + should_gen_docs: bool, +) -> Result { + let apis = &metadata.apis; + + let runtime_fns: Vec<_> = apis + .iter() + .map(|api| { + generate_runtime_api( + metadata, + api, + type_gen, + types_mod_ident, + crate_path, + should_gen_docs, + ) + }) + .collect::>()?; + + let runtime_apis_def = runtime_fns.iter().map(|(apis, _)| apis); + let runtime_apis_getters = runtime_fns.iter().map(|(_, getters)| getters); + + Ok(quote! { + pub mod runtime_apis { + use super::root_mod; + use super::#types_mod_ident; + + use #crate_path::ext::codec::Encode; + + pub struct RuntimeApi; + + impl RuntimeApi { + #( #runtime_apis_getters )* + } + + #( #runtime_apis_def )* + } + }) +} diff --git a/codegen/src/error.rs b/codegen/src/error.rs index 411225e34a..43bb88c612 100644 --- a/codegen/src/error.rs +++ b/codegen/src/error.rs @@ -42,6 +42,9 @@ pub enum CodegenError { /// Metadata for call could not be found. #[error("Metadata for call entry {0}_{1} could not be found. Make sure you are providing a valid substrate-based metadata")] MissingCallMetadata(String, String), + /// Metadata for call could not be found. + #[error("Metadata for runtime API entry {0}_{1} could not be found. Make sure you are providing a valid substrate-based metadata")] + MissingRuntimeApiMetadata(String, String), /// Call variant must have all named fields. #[error("Call variant for type {0} must have all named fields. Make sure you are providing a valid substrate-based metadata")] InvalidCallVariant(u32), @@ -77,10 +80,14 @@ impl CodegenError { pub enum FetchMetadataError { #[error("Cannot decode hex value: {0}")] DecodeError(#[from] hex::FromHexError), + #[error("Cannot scale encode/decode value: {0}")] + CodecError(#[from] codec::Error), #[error("Request error: {0}")] RequestError(#[from] jsonrpsee::core::Error), #[error("'{0}' not supported, supported URI schemes are http, https, ws or wss.")] InvalidScheme(String), + #[error("Other error: {0}")] + Other(String), } /// Error attempting to do type substitution. diff --git a/codegen/src/utils/fetch_metadata.rs b/codegen/src/utils/fetch_metadata.rs index c7bc489827..9d49e35ac4 100644 --- a/codegen/src/utils/fetch_metadata.rs +++ b/codegen/src/utils/fetch_metadata.rs @@ -3,6 +3,7 @@ // see LICENSE for license details. use crate::error::FetchMetadataError; +use codec::{Decode, Encode}; use jsonrpsee::{ async_client::ClientBuilder, client_transport::ws::{Uri, WsTransportClientBuilder}, @@ -12,14 +13,51 @@ use jsonrpsee::{ }; use std::time::Duration; +/// The metadata version that is fetched from the node. +#[derive(Default, Debug, Clone, Copy)] +pub enum MetadataVersion { + /// Latest stable version of the metadata. + #[default] + Latest, + /// Fetch a specified version of the metadata. + Version(u32), + /// Latest unstable version of the metadata. + Unstable, +} + +// Note: Implementation needed for the CLI tool. +impl std::str::FromStr for MetadataVersion { + type Err = String; + + fn from_str(input: &str) -> Result { + match input { + "unstable" => Ok(MetadataVersion::Unstable), + "latest" => Ok(MetadataVersion::Latest), + version => { + let num: u32 = version + .parse() + .map_err(|_| format!("Invalid metadata version specified {:?}", version))?; + + Ok(MetadataVersion::Version(num)) + } + } + } +} + /// Returns the metadata bytes from the provided URL, blocking the current thread. -pub fn fetch_metadata_bytes_blocking(url: &Uri) -> Result, FetchMetadataError> { - tokio_block_on(fetch_metadata_bytes(url)) +pub fn fetch_metadata_bytes_blocking( + url: &Uri, + version: MetadataVersion, +) -> Result, FetchMetadataError> { + tokio_block_on(fetch_metadata_bytes(url, version)) } /// Returns the raw, 0x prefixed metadata hex from the provided URL, blocking the current thread. -pub fn fetch_metadata_hex_blocking(url: &Uri) -> Result { - tokio_block_on(fetch_metadata_hex(url)) +pub fn fetch_metadata_hex_blocking( + url: &Uri, + version: MetadataVersion, +) -> Result { + tokio_block_on(fetch_metadata_hex(url, version)) } // Block on some tokio runtime for sync contexts @@ -32,26 +70,36 @@ fn tokio_block_on>(fut: Fut) -> T { } /// Returns the metadata bytes from the provided URL. -pub async fn fetch_metadata_bytes(url: &Uri) -> Result, FetchMetadataError> { - let hex = fetch_metadata_hex(url).await?; - let bytes = hex::decode(hex.trim_start_matches("0x"))?; - Ok(bytes) -} - -/// Returns the raw, 0x prefixed metadata hex from the provided URL. -pub async fn fetch_metadata_hex(url: &Uri) -> Result { - let hex_data = match url.scheme_str() { - Some("http") | Some("https") => fetch_metadata_http(url).await, - Some("ws") | Some("wss") => fetch_metadata_ws(url).await, +pub async fn fetch_metadata_bytes( + url: &Uri, + version: MetadataVersion, +) -> Result, FetchMetadataError> { + let bytes = match url.scheme_str() { + Some("http") | Some("https") => fetch_metadata_http(url, version).await, + Some("ws") | Some("wss") => fetch_metadata_ws(url, version).await, invalid_scheme => { let scheme = invalid_scheme.unwrap_or("no scheme"); Err(FetchMetadataError::InvalidScheme(scheme.to_owned())) } }?; + + Ok(bytes) +} + +/// Returns the raw, 0x prefixed metadata hex from the provided URL. +pub async fn fetch_metadata_hex( + url: &Uri, + version: MetadataVersion, +) -> Result { + let bytes = fetch_metadata_bytes(url, version).await?; + let hex_data = format!("0x{}", hex::encode(bytes)); Ok(hex_data) } -async fn fetch_metadata_ws(url: &Uri) -> Result { +async fn fetch_metadata_ws( + url: &Uri, + version: MetadataVersion, +) -> Result, FetchMetadataError> { let (sender, receiver) = WsTransportClientBuilder::default() .build(url.to_string().parse::().unwrap()) .await @@ -62,13 +110,124 @@ async fn fetch_metadata_ws(url: &Uri) -> Result { .max_notifs_per_subscription(4096) .build_with_tokio(sender, receiver); - Ok(client.request("state_getMetadata", rpc_params![]).await?) + fetch_metadata(client, version).await } -async fn fetch_metadata_http(url: &Uri) -> Result { +async fn fetch_metadata_http( + url: &Uri, + version: MetadataVersion, +) -> Result, FetchMetadataError> { let client = HttpClientBuilder::default() .request_timeout(Duration::from_secs(180)) .build(url.to_string())?; - Ok(client.request("state_getMetadata", rpc_params![]).await?) + fetch_metadata(client, version).await +} + +/// The innermost call to fetch metadata: +async fn fetch_metadata( + client: impl ClientT, + version: MetadataVersion, +) -> Result, FetchMetadataError> { + const UNSTABLE_METADATA_VERSION: u32 = u32::MAX; + + // Fetch metadata using the "new" state_call interface + async fn fetch_inner( + client: &impl ClientT, + version: MetadataVersion, + ) -> Result, FetchMetadataError> { + // Look up supported versions: + let supported_versions: Vec = { + let res: String = client + .request( + "state_call", + rpc_params!["Metadata_metadata_versions", "0x"], + ) + .await?; + let raw_bytes = hex::decode(res.trim_start_matches("0x"))?; + Decode::decode(&mut &raw_bytes[..])? + }; + + // Return the version the user wants if it's supported: + let version = match version { + MetadataVersion::Latest => *supported_versions + .iter() + .filter(|&&v| v != UNSTABLE_METADATA_VERSION) + .max() + .ok_or_else(|| { + FetchMetadataError::Other("No valid metadata versions returned".to_string()) + })?, + MetadataVersion::Unstable => { + if supported_versions.contains(&UNSTABLE_METADATA_VERSION) { + UNSTABLE_METADATA_VERSION + } else { + return Err(FetchMetadataError::Other( + "The node does not have an unstable metadata version available".to_string(), + )); + } + } + MetadataVersion::Version(version) => { + if supported_versions.contains(&version) { + version + } else { + return Err(FetchMetadataError::Other(format!( + "The node does not have version {version} available" + ))); + } + } + }; + + let bytes = version.encode(); + let version: String = format!("0x{}", hex::encode(&bytes)); + + // Fetch the metadata at that version: + let metadata_string: String = client + .request( + "state_call", + rpc_params!["Metadata_metadata_at_version", &version], + ) + .await?; + // Decode the metadata. + let metadata_bytes = hex::decode(metadata_string.trim_start_matches("0x"))?; + let metadata: Option = + Decode::decode(&mut &metadata_bytes[..])?; + let Some(metadata) = metadata else { + return Err(FetchMetadataError::Other(format!( + "The node does not have version {version} available" + ))); + }; + Ok(metadata.0) + } + + // Fetch metadata using the "old" state_call interface + async fn fetch_inner_legacy( + client: &impl ClientT, + version: MetadataVersion, + ) -> Result, FetchMetadataError> { + if !matches!( + version, + MetadataVersion::Latest | MetadataVersion::Version(14) + ) { + return Err(FetchMetadataError::Other( + "The node can only return version 14 metadata but you've asked for something else" + .to_string(), + )); + } + + // Fetch the metadata at that version: + let metadata_string: String = client + .request("state_call", rpc_params!["Metadata_metadata", "0x"]) + .await?; + + // Decode the metadata. + let metadata_bytes = hex::decode(metadata_string.trim_start_matches("0x"))?; + let metadata: frame_metadata::OpaqueMetadata = Decode::decode(&mut &metadata_bytes[..])?; + Ok(metadata.0) + } + + // Fetch using the new interface, falling back to trying old one if there's an error. + match fetch_inner(&client, version).await { + Ok(s) => Ok(s), + Err(_) => fetch_inner_legacy(&client, version).await, + } } diff --git a/codegen/src/utils/mod.rs b/codegen/src/utils/mod.rs index 5c27200310..3f0e77f71e 100644 --- a/codegen/src/utils/mod.rs +++ b/codegen/src/utils/mod.rs @@ -11,5 +11,5 @@ pub use jsonrpsee::client_transport::ws::Uri; pub use fetch_metadata::{ fetch_metadata_bytes, fetch_metadata_bytes_blocking, fetch_metadata_hex, - fetch_metadata_hex_blocking, + fetch_metadata_hex_blocking, MetadataVersion, }; diff --git a/examples/examples/runtime_calls.rs b/examples/examples/runtime_calls.rs new file mode 100644 index 0000000000..f2d52766fd --- /dev/null +++ b/examples/examples/runtime_calls.rs @@ -0,0 +1,88 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. +//! +//! E.g. +//! ```bash +//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location +//! polkadot --dev --tmp +//! ``` + +use sp_keyring::AccountKeyring; +use subxt::dynamic::Value; +use subxt::{config::PolkadotConfig, OnlineClient}; + +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +pub mod polkadot {} + +#[tokio::main] +async fn main() -> Result<(), Box> { + tracing_subscriber::fmt::init(); + + // Create a client to use: + let api = OnlineClient::::new().await?; + + // In the first part of the example calls are made using the static generated code + // and as a result the returned values are strongly typed. + + // Create a runtime API payload that calls into + // `Core_version` function. + let runtime_api_call = polkadot::apis().core().version(); + + // Submit the runtime API call. + let version = api + .runtime_api() + .at_latest() + .await? + .call(runtime_api_call) + .await; + println!("Core_version: {:?}", version); + + // Show the supported metadata versions of the node. + // Calls into `Metadata_metadata_versions` runtime function. + let runtime_api_call = polkadot::apis().metadata().metadata_versions(); + + // Submit the runtime API call. + let versions = api + .runtime_api() + .at_latest() + .await? + .call(runtime_api_call) + .await?; + println!("Metadata_metadata_versions: {:?}", versions); + + // Create a runtime API payload that calls into + // `AccountNonceApi_account_nonce` function. + let account = AccountKeyring::Alice.to_account_id().into(); + let runtime_api_call = polkadot::apis().account_nonce_api().account_nonce(account); + + // Submit the runtime API call. + let nonce = api + .runtime_api() + .at_latest() + .await? + .call(runtime_api_call) + .await; + println!("AccountNonceApi_account_nonce for Alice: {:?}", nonce); + + // Dynamic calls. + let runtime_api_call = subxt::dynamic::runtime_api_call( + "Metadata_metadata_versions", + Vec::>::new(), + None, + ); + let versions = api + .runtime_api() + .at_latest() + .await? + .call(runtime_api_call) + .await?; + println!( + " dynamic Metadata_metadata_versions: {:#?}", + versions.to_value() + ); + + Ok(()) +} diff --git a/metadata/src/lib.rs b/metadata/src/lib.rs index af042f8581..702da037ee 100644 --- a/metadata/src/lib.rs +++ b/metadata/src/lib.rs @@ -10,7 +10,7 @@ use frame_metadata::{v14::RuntimeMetadataV14, v15::RuntimeMetadataV15}; pub use retain::retain_metadata_pallets; pub use validation::{ get_call_hash, get_constant_hash, get_metadata_hash, get_metadata_per_pallet_hash, - get_pallet_hash, get_storage_hash, NotFound, + get_pallet_hash, get_runtime_api_hash, get_runtime_trait_hash, get_storage_hash, NotFound, }; /// Convert the metadata V14 to the latest metadata version. diff --git a/metadata/src/retain.rs b/metadata/src/retain.rs index e34e516894..d1769f282e 100644 --- a/metadata/src/retain.rs +++ b/metadata/src/retain.rs @@ -5,7 +5,7 @@ //! Utility functions to generate a subset of the metadata. use frame_metadata::v15::{ - ExtrinsicMetadata, PalletMetadata, RuntimeMetadataV15, StorageEntryType, + ExtrinsicMetadata, PalletMetadata, RuntimeApiMetadata, RuntimeMetadataV15, StorageEntryType, }; use scale_info::{form::PortableForm, interner::UntrackedSymbol, TypeDef}; use std::{ @@ -105,6 +105,36 @@ fn update_extrinsic_types( } } +/// Collect all type IDs needed to represent the runtime APIs. +fn collect_runtime_api_types( + apis: &[RuntimeApiMetadata], + type_ids: &mut HashSet, +) { + for api in apis { + for method in &api.methods { + for input in &method.inputs { + type_ids.insert(input.ty.id); + } + type_ids.insert(method.output.id); + } + } +} + +/// Update all type IDs of the provided runtime APIs metadata using the new type IDs from the portable registry. +fn update_runtime_api_types( + apis: &mut [RuntimeApiMetadata], + map_ids: &BTreeMap, +) { + for api in apis { + for method in &mut api.methods { + for input in &mut method.inputs { + update_type(&mut input.ty, map_ids); + } + update_type(&mut method.output, map_ids); + } + } +} + /// Update the given type using the new type ID from the portable registry. /// /// # Panics @@ -191,6 +221,9 @@ where // Keep the "runtime" type ID, since it's referenced in our metadata. type_ids.insert(metadata.ty.id); + // Keep the runtime APIs types. + collect_runtime_api_types(&metadata.apis, &mut type_ids); + // Additionally, subxt depends on the `DispatchError` type existing; we use the same // logic here that is used when building our `Metadata`. let dispatch_error_ty = metadata @@ -211,6 +244,7 @@ where } update_extrinsic_types(&mut metadata.extrinsic, &map_ids); update_type(&mut metadata.ty, &map_ids); + update_runtime_api_types(&mut metadata.apis, &map_ids); } #[cfg(test)] diff --git a/metadata/src/validation.rs b/metadata/src/validation.rs index a325d69a4b..eb0f5c4a82 100644 --- a/metadata/src/validation.rs +++ b/metadata/src/validation.rs @@ -5,7 +5,8 @@ //! Utility functions for metadata validation. use frame_metadata::v15::{ - ExtrinsicMetadata, PalletMetadata, RuntimeMetadataV15, StorageEntryMetadata, StorageEntryType, + ExtrinsicMetadata, PalletMetadata, RuntimeApiMetadata, RuntimeApiMethodMetadata, + RuntimeMetadataV15, StorageEntryMetadata, StorageEntryType, }; use scale_info::{form::PortableForm, Field, PortableRegistry, TypeDef, Variant}; use std::collections::HashSet; @@ -253,7 +254,7 @@ pub fn get_storage_hash( .pallets .iter() .find(|p| p.name == pallet_name) - .ok_or(NotFound::Pallet)?; + .ok_or(NotFound::Root)?; let storage = pallet.storage.as_ref().ok_or(NotFound::Item)?; @@ -277,7 +278,7 @@ pub fn get_constant_hash( .pallets .iter() .find(|p| p.name == pallet_name) - .ok_or(NotFound::Pallet)?; + .ok_or(NotFound::Root)?; let constant = pallet .constants @@ -300,7 +301,7 @@ pub fn get_call_hash( .pallets .iter() .find(|p| p.name == pallet_name) - .ok_or(NotFound::Pallet)?; + .ok_or(NotFound::Root)?; let call_id = pallet.calls.as_ref().ok_or(NotFound::Item)?.ty.id; @@ -321,6 +322,96 @@ pub fn get_call_hash( Ok(hash) } +fn get_runtime_method_hash( + metadata: &RuntimeMetadataV15, + trait_metadata: &RuntimeApiMetadata, + method_metadata: &RuntimeApiMethodMetadata, + visited_ids: &mut HashSet, +) -> [u8; 32] { + // The trait name is part of the runtime API call that is being + // generated for this method. Therefore the trait name is strongly + // connected to the method in the same way as a parameter is + // to the method. + let mut bytes = hash(trait_metadata.name.as_bytes()); + bytes = xor(bytes, hash(method_metadata.name.as_bytes())); + + for input in &method_metadata.inputs { + bytes = xor(bytes, hash(input.name.as_bytes())); + bytes = xor( + bytes, + get_type_hash(&metadata.types, input.ty.id, visited_ids), + ); + } + + bytes = xor( + bytes, + get_type_hash(&metadata.types, method_metadata.output.id, visited_ids), + ); + + bytes +} + +/// Obtain the hash of a specific runtime trait. +pub fn get_runtime_trait_hash( + metadata: &RuntimeMetadataV15, + trait_metadata: &RuntimeApiMetadata, +) -> [u8; 32] { + // Start out with any hash, the trait name is already part of the + // runtime method hash. + let mut bytes = hash(trait_metadata.name.as_bytes()); + let mut visited_ids = HashSet::new(); + + let mut methods: Vec<_> = trait_metadata + .methods + .iter() + .map(|method_metadata| { + let bytes = get_runtime_method_hash( + metadata, + trait_metadata, + method_metadata, + &mut visited_ids, + ); + (&*method_metadata.name, bytes) + }) + .collect(); + + // Sort by method name to create a deterministic representation of the underlying metadata. + methods.sort_by_key(|&(name, _hash)| name); + + // Note: Hash already takes into account the method name. + for (_, hash) in methods { + bytes = xor(bytes, hash); + } + + bytes +} + +/// Obtain the hash of a specific runtime API function, or an error if it's not found. +pub fn get_runtime_api_hash( + metadata: &RuntimeMetadataV15, + trait_name: &str, + method_name: &str, +) -> Result<[u8; 32], NotFound> { + let trait_metadata = metadata + .apis + .iter() + .find(|m| m.name == trait_name) + .ok_or(NotFound::Root)?; + + let method_metadata = trait_metadata + .methods + .iter() + .find(|m| m.name == method_name) + .ok_or(NotFound::Item)?; + + Ok(get_runtime_method_hash( + metadata, + trait_metadata, + method_metadata, + &mut HashSet::new(), + )) +} + /// Obtain the hash representation of a `frame_metadata::v15::PalletMetadata`. pub fn get_pallet_hash( registry: &PortableRegistry, @@ -404,6 +495,19 @@ pub fn get_metadata_hash(metadata: &RuntimeMetadataV15) -> [u8; 32] { &mut visited_ids, )); + let mut apis: Vec<_> = metadata + .apis + .iter() + .map(|api| (&*api.name, get_runtime_trait_hash(metadata, api))) + .collect(); + + // Sort the runtime APIs by trait name to provide a deterministic output. + apis.sort_by_key(|&(name, _hash)| name); + + for (_, hash) in apis.iter() { + bytes.extend(hash) + } + hash(&bytes) } @@ -449,11 +553,24 @@ pub fn get_metadata_per_pallet_hash>( hash(&bytes) } -/// An error returned if we attempt to get the hash for a specific call, constant -/// or storage item that doesn't exist. +/// An error returned if we attempt to get the hash for a specific call, constant, +/// storage or runtime API function does not exist. +/// +/// The location of the specific item (call, constant, storage or runtime API function) +/// is stored with two indirections: +/// - Root +/// The root location of the item. For calls, constants, storage this represents the +/// pallet name. While for runtime API function this represents the trait name. +/// - Item +/// The actual item. For calls, constants, storage this represents the actual name. +/// While for runtime API functions this represents the method name. #[derive(Clone, Debug)] pub enum NotFound { - Pallet, + /// The root location of the item cannot be found. + /// - pallet name: for calls, constants, storage + /// - trait name: for runtime API functions + Root, + /// The actual item name cannot be found. Item, } diff --git a/subxt/Cargo.toml b/subxt/Cargo.toml index c9dc8061ed..1a0ebc7977 100644 --- a/subxt/Cargo.toml +++ b/subxt/Cargo.toml @@ -34,6 +34,12 @@ integration-tests = [] jsonrpsee-ws = ["jsonrpsee/async-client", "jsonrpsee/client-ws-transport"] jsonrpsee-web = ["jsonrpsee/async-wasm-client", "jsonrpsee/client-web-transport"] +# Activate this to fetch and utilize the latest unstabl metadata from a node. +# The unstable metadata is subject to breaking changes and the subxt might +# fail to decode the metadata properly. Use this to experiment with the +# latest features exposed by the metadata. +unstable-metadata = [] + [dependencies] codec = { package = "parity-scale-codec", workspace = true, features = ["derive"] } scale-info = { workspace = true } diff --git a/subxt/src/client/online_client.rs b/subxt/src/client/online_client.rs index 703777f26a..44f68635fc 100644 --- a/subxt/src/client/online_client.rs +++ b/subxt/src/client/online_client.rs @@ -17,9 +17,7 @@ use crate::{ tx::TxClient, Config, Metadata, }; -use codec::Compact; use derivative::Derivative; -use frame_metadata::RuntimeMetadataPrefixed; use futures::future; use parking_lot::RwLock; use std::sync::Arc; @@ -136,10 +134,19 @@ impl OnlineClient { /// Fetch the metadata from substrate using the runtime API. async fn fetch_metadata(rpc: &Rpc) -> Result { - let (_, meta) = rpc - .state_call::<(Compact, RuntimeMetadataPrefixed)>("Metadata_metadata", None, None) - .await?; - Ok(meta.try_into()?) + #[cfg(feature = "unstable-metadata")] + { + // Try to fetch the latest unstable metadata, if that fails fall back to + // fetching the latest stable metadata. + const V15_METADATA_VERSION: u32 = u32::MAX; + match rpc.metadata_at_version(V15_METADATA_VERSION).await { + Ok(bytes) => Ok(bytes), + Err(_) => rpc.metadata().await, + } + } + + #[cfg(not(feature = "unstable-metadata"))] + rpc.metadata().await } /// Create an object which can be used to keep the runtime up to date @@ -383,7 +390,7 @@ impl RuntimeUpdaterStream { Err(err) => return Some(Err(err)), }; - let metadata = match self.client.rpc().metadata(None).await { + let metadata = match self.client.rpc().metadata().await { Ok(metadata) => metadata, Err(err) => return Some(Err(err)), }; diff --git a/subxt/src/dynamic.rs b/subxt/src/dynamic.rs index a16611b6f4..df65cffb13 100644 --- a/subxt/src/dynamic.rs +++ b/subxt/src/dynamic.rs @@ -28,6 +28,9 @@ pub use crate::constants::dynamic as constant; // Lookup storage values dynamically. pub use crate::storage::{dynamic as storage, dynamic_root as storage_root}; +// Execute runtime API function call dynamically. +pub use crate::runtime_api::dynamic as runtime_api_call; + /// This is the result of making a dynamic request to a node. From this, /// we can return the raw SCALE bytes that we were handed back, or we can /// complete the decoding of the bytes into a [`DecodedValue`] type. diff --git a/subxt/src/events/events_type.rs b/subxt/src/events/events_type.rs index 4fcec55cb7..1de8b31917 100644 --- a/subxt/src/events/events_type.rs +++ b/subxt/src/events/events_type.rs @@ -76,7 +76,7 @@ impl Events { /// .await? /// .expect("didn't pass a block number; qed"); /// // Fetch the metadata of the given block. - /// let metadata = client.rpc().metadata(Some(block_hash)).await?; + /// let metadata = client.rpc().metadata_legacy(Some(block_hash)).await?; /// // Fetch the events from the client. /// let events = Events::new_from_client(metadata, block_hash, client); /// # Ok(()) diff --git a/subxt/src/metadata/hash_cache.rs b/subxt/src/metadata/hash_cache.rs index 428a934543..0ece71c788 100644 --- a/subxt/src/metadata/hash_cache.rs +++ b/subxt/src/metadata/hash_cache.rs @@ -5,23 +5,23 @@ use parking_lot::RwLock; use std::{borrow::Cow, collections::HashMap}; -/// A cache with the simple goal of storing 32 byte hashes against pallet+item keys +/// A cache with the simple goal of storing 32 byte hashes against root+item keys #[derive(Default, Debug)] pub struct HashCache { - inner: RwLock, [u8; 32]>>, + inner: RwLock, [u8; 32]>>, } impl HashCache { - /// get a hash out of the cache by its pallet and item key. If the item doesn't exist, + /// get a hash out of the cache by its root and item key. If the item doesn't exist, /// run the function provided to obtain a hash to insert (or bail with some error on failure). - pub fn get_or_insert(&self, pallet: &str, item: &str, f: F) -> Result<[u8; 32], E> + pub fn get_or_insert(&self, root: &str, item: &str, f: F) -> Result<[u8; 32], E> where F: FnOnce() -> Result<[u8; 32], E>, { let maybe_hash = self .inner .read() - .get(&PalletItemKey::new(pallet, item)) + .get(&RootItemKey::new(root, item)) .copied(); if let Some(hash) = maybe_hash { @@ -29,10 +29,9 @@ impl HashCache { } let hash = f()?; - self.inner.write().insert( - PalletItemKey::new(pallet.to_string(), item.to_string()), - hash, - ); + self.inner + .write() + .insert(RootItemKey::new(root.to_string(), item.to_string()), hash); Ok(hash) } @@ -41,14 +40,14 @@ impl HashCache { /// This exists so that we can look items up in the cache using &strs, without having to allocate /// Strings first (as you'd have to do to construct something like an `&(String,String)` key). #[derive(Debug, PartialEq, Eq, Hash)] -struct PalletItemKey<'a> { +struct RootItemKey<'a> { pallet: Cow<'a, str>, item: Cow<'a, str>, } -impl<'a> PalletItemKey<'a> { +impl<'a> RootItemKey<'a> { fn new(pallet: impl Into>, item: impl Into>) -> Self { - PalletItemKey { + RootItemKey { pallet: pallet.into(), item: item.into(), } @@ -75,7 +74,7 @@ mod tests { cache .inner .read() - .get(&PalletItemKey::new(pallet, item)) + .get(&RootItemKey::new(pallet, item)) .unwrap(), &value.unwrap() ); diff --git a/subxt/src/metadata/metadata_type.rs b/subxt/src/metadata/metadata_type.rs index 7a8966d3ea..cc400310b0 100644 --- a/subxt/src/metadata/metadata_type.rs +++ b/subxt/src/metadata/metadata_type.rs @@ -30,6 +30,9 @@ pub enum MetadataError { /// Event is not in metadata. #[error("Pallet {0}, Error {0} not found")] ErrorNotFound(u8, u8), + /// Runtime function is not in metadata. + #[error("Runtime function not found")] + RuntimeFnNotFound, /// Storage is not in metadata. #[error("Storage not found")] StorageNotFound, @@ -57,6 +60,9 @@ pub enum MetadataError { /// Runtime storage metadata is incompatible with the static one. #[error("Pallet {0} Storage {0} has incompatible metadata")] IncompatibleStorageMetadata(String, String), + /// Runtime API metadata is incompatible with the static one. + #[error("Runtime API Trait {0} Method {0} has incompatible metadata")] + IncompatibleRuntimeApiMetadata(String, String), /// Runtime metadata is not fully compatible with the static one. #[error("Node metadata is not fully compatible")] IncompatibleMetadata, @@ -79,6 +85,9 @@ struct MetadataInner { // an extrinsic fails. dispatch_error_ty: Option, + // Runtime API metadata + runtime_apis: HashMap, + // The hashes uniquely identify parts of the metadata; different // hashes mean some type difference exists between static and runtime // versions. We cache them here to avoid recalculating: @@ -86,6 +95,7 @@ struct MetadataInner { cached_call_hashes: HashCache, cached_constant_hashes: HashCache, cached_storage_hashes: HashCache, + cached_runtime_hashes: HashCache, } /// A representation of the runtime metadata received from a node. @@ -95,6 +105,14 @@ pub struct Metadata { } impl Metadata { + /// Returns a reference to [`RuntimeFnMetadata`]. + pub fn runtime_fn(&self, name: &str) -> Result<&RuntimeFnMetadata, MetadataError> { + self.inner + .runtime_apis + .get(name) + .ok_or(MetadataError::RuntimeFnNotFound) + } + /// Returns a reference to [`PalletMetadata`]. pub fn pallet(&self, name: &str) -> Result<&PalletMetadata, MetadataError> { self.inner @@ -158,7 +176,7 @@ impl Metadata { .get_or_insert(pallet, storage, || { subxt_metadata::get_storage_hash(&self.inner.metadata, pallet, storage).map_err( |e| match e { - subxt_metadata::NotFound::Pallet => MetadataError::PalletNotFound, + subxt_metadata::NotFound::Root => MetadataError::PalletNotFound, subxt_metadata::NotFound::Item => MetadataError::StorageNotFound, }, ) @@ -172,7 +190,7 @@ impl Metadata { .get_or_insert(pallet, constant, || { subxt_metadata::get_constant_hash(&self.inner.metadata, pallet, constant).map_err( |e| match e { - subxt_metadata::NotFound::Pallet => MetadataError::PalletNotFound, + subxt_metadata::NotFound::Root => MetadataError::PalletNotFound, subxt_metadata::NotFound::Item => MetadataError::ConstantNotFound, }, ) @@ -186,13 +204,27 @@ impl Metadata { .get_or_insert(pallet, function, || { subxt_metadata::get_call_hash(&self.inner.metadata, pallet, function).map_err(|e| { match e { - subxt_metadata::NotFound::Pallet => MetadataError::PalletNotFound, + subxt_metadata::NotFound::Root => MetadataError::PalletNotFound, subxt_metadata::NotFound::Item => MetadataError::CallNotFound, } }) }) } + /// Obtain the unique hash for a runtime API function. + pub fn runtime_api_hash( + &self, + trait_name: &str, + method_name: &str, + ) -> Result<[u8; 32], MetadataError> { + self.inner + .cached_runtime_hashes + .get_or_insert(trait_name, method_name, || { + subxt_metadata::get_runtime_api_hash(&self.inner.metadata, trait_name, method_name) + .map_err(|_| MetadataError::RuntimeFnNotFound) + }) + } + /// Obtain the unique hash for this metadata. pub fn metadata_hash>(&self, pallets: &[T]) -> [u8; 32] { if let Some(hash) = *self.inner.cached_metadata_hash.read() { @@ -206,6 +238,42 @@ impl Metadata { } } +/// Metadata for a specific runtime API function. +#[derive(Clone, Debug)] +pub struct RuntimeFnMetadata { + /// The trait name of the runtime function. + trait_name: String, + /// The method name of the runtime function. + method_name: String, + /// The parameter name and type IDs interpreted as `scale_info::Field` + /// for ease of decoding. + fields: Vec>, + /// The type ID of the return type. + return_id: u32, +} + +impl RuntimeFnMetadata { + /// Get the parameters as fields. + pub fn fields(&self) -> &[scale_info::Field] { + &self.fields + } + + /// Return the trait name of the runtime function. + pub fn trait_name(&self) -> &str { + &self.trait_name + } + + /// Return the method name of the runtime function. + pub fn method_name(&self) -> &str { + &self.method_name + } + + /// Get the type ID of the return type. + pub fn return_id(&self) -> u32 { + self.return_id + } +} + /// Metadata for a specific pallet. #[derive(Clone, Debug)] pub struct PalletMetadata { @@ -376,6 +444,49 @@ impl TryFrom for Metadata { _ => return Err(InvalidMetadataError::InvalidVersion), }; + let runtime_apis: HashMap = metadata + .apis + .iter() + .flat_map(|trait_metadata| { + let trait_name = &trait_metadata.name; + + trait_metadata + .methods + .iter() + .map(|method_metadata| { + // Function named used by substrate to identify the runtime call. + let fn_name = format!("{}_{}", trait_name, method_metadata.name); + + // Parameters mapped as `scale_info::Field` to allow dynamic decoding. + let fields: Vec<_> = method_metadata + .inputs + .iter() + .map(|input| { + let name = input.name.clone(); + let ty = input.ty.id; + scale_info::Field { + name: Some(name), + ty: ty.into(), + type_name: None, + docs: Default::default(), + } + }) + .collect(); + + let return_id = method_metadata.output.id; + let metadata = RuntimeFnMetadata { + fields, + return_id, + trait_name: trait_name.clone(), + method_name: method_metadata.name.clone(), + }; + + (fn_name, metadata) + }) + .collect::>() + }) + .collect(); + let get_type_def_variant = |type_id: u32| { let ty = metadata .types @@ -492,10 +603,12 @@ impl TryFrom for Metadata { events, errors, dispatch_error_ty, + runtime_apis, cached_metadata_hash: Default::default(), cached_call_hashes: Default::default(), cached_constant_hashes: Default::default(), cached_storage_hashes: Default::default(), + cached_runtime_hashes: Default::default(), }), }) } diff --git a/subxt/src/rpc/rpc.rs b/subxt/src/rpc/rpc.rs index 60c33656f3..13b8ad202c 100644 --- a/subxt/src/rpc/rpc.rs +++ b/subxt/src/rpc/rpc.rs @@ -143,8 +143,8 @@ impl Rpc { genesis_hash.ok_or_else(|| "Genesis hash not found".into()) } - /// Fetch the metadata - pub async fn metadata(&self, at: Option) -> Result { + /// Fetch the metadata via the legacy `state_getMetadata` RPC method. + pub async fn metadata_legacy(&self, at: Option) -> Result { let bytes: types::Bytes = self .client .request("state_getMetadata", rpc_params![at]) @@ -347,13 +347,13 @@ impl Rpc { Ok(xt_hash) } - /// Execute a runtime API call. - pub async fn state_call( + /// Execute a runtime API call via `state_call` RPC method. + pub async fn state_call_raw( &self, function: &str, call_parameters: Option<&[u8]>, at: Option, - ) -> Result { + ) -> Result { let call_parameters = call_parameters.unwrap_or_default(); let bytes: types::Bytes = self .client @@ -362,11 +362,54 @@ impl Rpc { rpc_params![function, to_hex(call_parameters), at], ) .await?; + Ok(bytes) + } + + /// Execute a runtime API call and decode the result. + pub async fn state_call( + &self, + function: &str, + call_parameters: Option<&[u8]>, + at: Option, + ) -> Result { + let bytes = self.state_call_raw(function, call_parameters, at).await?; let cursor = &mut &bytes[..]; let res: Res = Decode::decode(cursor)?; Ok(res) } + /// Execute runtime API call and return the specified runtime metadata version. + pub async fn metadata_at_version(&self, version: u32) -> Result { + let param = version.encode(); + let opaque: Option = self + .state_call("Metadata_metadata_at_version", Some(¶m), None) + .await?; + + let bytes = opaque.ok_or(Error::Other("Metadata version not found".into()))?; + + let meta: RuntimeMetadataPrefixed = Decode::decode(&mut &bytes.0[..])?; + + let metadata: Metadata = meta.try_into()?; + Ok(metadata) + } + + /// Execute a runtime API call into `Metadata_metadata` method + /// to fetch the latest available metadata. + /// + /// # Note + /// + /// This returns the same output as [`Self::metadata`], but calls directly + /// into the runtime. + pub async fn metadata(&self) -> Result { + let bytes: frame_metadata::OpaqueMetadata = + self.state_call("Metadata_metadata", None, None).await?; + + let meta: RuntimeMetadataPrefixed = Decode::decode(&mut &bytes.0[..])?; + + let metadata: Metadata = meta.try_into()?; + Ok(metadata) + } + /// Create and submit an extrinsic and return a subscription to the events triggered. pub async fn watch_extrinsic( &self, diff --git a/subxt/src/runtime_api/mod.rs b/subxt/src/runtime_api/mod.rs index c499d1e3a2..49a17a4dd7 100644 --- a/subxt/src/runtime_api/mod.rs +++ b/subxt/src/runtime_api/mod.rs @@ -5,7 +5,9 @@ //! Types associated with executing runtime API calls. mod runtime_client; +mod runtime_payload; mod runtime_types; pub use runtime_client::RuntimeApiClient; +pub use runtime_payload::{dynamic, DynamicRuntimeApiPayload, Payload, RuntimeApiPayload}; pub use runtime_types::RuntimeApi; diff --git a/subxt/src/runtime_api/runtime_payload.rs b/subxt/src/runtime_api/runtime_payload.rs new file mode 100644 index 0000000000..7636ea6a02 --- /dev/null +++ b/subxt/src/runtime_api/runtime_payload.rs @@ -0,0 +1,162 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +use core::marker::PhantomData; +use scale_encode::EncodeAsFields; +use scale_value::Composite; +use std::borrow::Cow; + +use crate::dynamic::DecodedValueThunk; +use crate::{metadata::DecodeWithMetadata, Error, Metadata}; + +/// This represents a runtime API payload that can call into the runtime of node. +/// +/// # Components +/// +/// - associated return type +/// +/// Resulting bytes of the call are interpreted into this type. +/// +/// - runtime function name +/// +/// The function name of the runtime API call. This is obtained by concatenating +/// the runtime trait name with the trait's method. +/// +/// For example, the substrate runtime trait [Metadata](https://github.com/paritytech/substrate/blob/cb954820a8d8d765ce75021e244223a3b4d5722d/primitives/api/src/lib.rs#L745) +/// contains the `metadata_at_version` function. The corresponding runtime function +/// is `Metadata_metadata_at_version`. +/// +/// - encoded arguments +/// +/// Each argument of the runtime function must be scale-encoded. +pub trait RuntimeApiPayload { + /// The return type of the function call. + // Note: `DecodeWithMetadata` is needed to decode the function call result + // with the `subxt::Metadata. + type ReturnType: DecodeWithMetadata; + + /// The runtime API function name. + fn fn_name(&self) -> &str; + + /// Scale encode the arguments data. + fn encode_args_to(&self, metadata: &Metadata, out: &mut Vec) -> Result<(), Error>; + + /// Encode arguments data and return the output. This is a convenience + /// wrapper around [`RuntimeApiPayload::encode_args_to`]. + fn encode_args(&self, metadata: &Metadata) -> Result, Error> { + let mut v = Vec::new(); + self.encode_args_to(metadata, &mut v)?; + Ok(v) + } + + /// Returns the statically generated validation hash. + fn validation_hash(&self) -> Option<[u8; 32]> { + None + } +} + +/// A runtime API payload containing the generic argument data +/// and interpreting the result of the call as `ReturnTy`. +/// +/// This can be created from static values (ie those generated +/// via the `subxt` macro) or dynamic values via [`dynamic`]. +#[derive(Clone, Debug)] +pub struct Payload { + fn_name: Cow<'static, str>, + args_data: ArgsData, + validation_hash: Option<[u8; 32]>, + _marker: PhantomData, +} + +impl RuntimeApiPayload + for Payload +{ + type ReturnType = ReturnTy; + + fn fn_name(&self) -> &str { + &self.fn_name + } + + fn encode_args_to(&self, metadata: &Metadata, out: &mut Vec) -> Result<(), Error> { + let fn_metadata = metadata.runtime_fn(&self.fn_name)?; + + self.args_data + .encode_as_fields_to(fn_metadata.fields(), metadata.types(), out)?; + + Ok(()) + } + + fn validation_hash(&self) -> Option<[u8; 32]> { + self.validation_hash + } +} + +/// A dynamic runtime API payload. +pub type DynamicRuntimeApiPayload = Payload, DecodedValueThunk>; + +impl Payload { + /// Create a new [`Payload`]. + pub fn new( + fn_name: impl Into, + args_data: ArgsData, + validation_hash: Option<[u8; 32]>, + ) -> Self { + Payload { + fn_name: Cow::Owned(fn_name.into()), + args_data, + validation_hash, + _marker: PhantomData, + } + } + + /// Create a new static [`Payload`] using static function name + /// and scale-encoded argument data. + /// + /// This is only expected to be used from codegen. + #[doc(hidden)] + pub fn new_static( + fn_name: &'static str, + args_data: ArgsData, + hash: [u8; 32], + ) -> Payload { + Payload { + fn_name: Cow::Borrowed(fn_name), + args_data, + validation_hash: Some(hash), + _marker: std::marker::PhantomData, + } + } + + /// Do not validate this call prior to submitting it. + pub fn unvalidated(self) -> Self { + Self { + validation_hash: None, + ..self + } + } + + /// Returns the function name. + pub fn fn_name(&self) -> &str { + &self.fn_name + } + + /// Returns the arguments data. + pub fn args_data(&self) -> &ArgsData { + &self.args_data + } +} + +/// Create a new [`DynamicRuntimeApiPayload`]. +pub fn dynamic( + fn_name: impl Into, + args_data: impl Into>, + hash: Option<[u8; 32]>, +) -> DynamicRuntimeApiPayload { + DynamicRuntimeApiPayload { + fn_name: Cow::Owned(fn_name.into()), + args_data: args_data.into(), + validation_hash: hash, + _marker: std::marker::PhantomData, + } +} diff --git a/subxt/src/runtime_api/runtime_types.rs b/subxt/src/runtime_api/runtime_types.rs index 7bcd3436b9..8f9fd5dd21 100644 --- a/subxt/src/runtime_api/runtime_types.rs +++ b/subxt/src/runtime_api/runtime_types.rs @@ -2,11 +2,13 @@ // This file is dual-licensed as Apache-2.0 or GPL-3.0. // see LICENSE for license details. -use crate::{client::OnlineClientT, error::Error, Config}; +use crate::{client::OnlineClientT, error::Error, metadata::DecodeWithMetadata, Config}; use codec::Decode; use derivative::Derivative; use std::{future::Future, marker::PhantomData}; +use super::RuntimeApiPayload; + /// Execute runtime API calls. #[derive(Derivative)] #[derivative(Clone(bound = "Client: Clone"))] @@ -50,4 +52,57 @@ where Ok(data) } } + + /// Execute a runtime API call. + pub fn call( + &self, + payload: Call, + ) -> impl Future> { + let client = self.client.clone(); + let block_hash = self.block_hash; + // Ensure that the returned future doesn't have a lifetime tied to api.runtime_api(), + // which is a temporary thing we'll be throwing away quickly: + async move { + let metadata = client.metadata(); + let function = payload.fn_name(); + + // Check if the function is present in the runtime metadata. + let fn_metadata = metadata.runtime_fn(function)?; + // Return type ID used for dynamic decoding. + let return_id = fn_metadata.return_id(); + + // Validate the runtime API payload hash against the compile hash from codegen. + if let Some(static_hash) = payload.validation_hash() { + let runtime_hash = metadata + .runtime_api_hash(fn_metadata.trait_name(), fn_metadata.method_name())?; + + if static_hash != runtime_hash { + return Err( + crate::metadata::MetadataError::IncompatibleRuntimeApiMetadata( + fn_metadata.trait_name().into(), + fn_metadata.method_name().into(), + ) + .into(), + ); + } + } + + // Encode the arguments of the runtime call. + // For static payloads (codegen) this is pass-through, bytes are not altered. + // For dynamic payloads this relies on `scale_value::encode_as_fields_to`. + let params = payload.encode_args(&metadata)?; + + let bytes = client + .rpc() + .state_call_raw(function, Some(params.as_slice()), Some(block_hash)) + .await?; + + let value = ::decode_with_metadata( + &mut &bytes[..], + return_id, + &metadata, + )?; + Ok(value) + } + } } diff --git a/testing/integration-tests/Cargo.toml b/testing/integration-tests/Cargo.toml index 980301a32f..81239856fb 100644 --- a/testing/integration-tests/Cargo.toml +++ b/testing/integration-tests/Cargo.toml @@ -27,7 +27,7 @@ sp-core = { workspace = true } sp-runtime = { workspace = true } sp-keyring = { workspace = true } syn = { workspace = true } -subxt = { workspace = true } +subxt = { workspace = true, features = ["unstable-metadata"] } subxt-codegen = { workspace = true } subxt-metadata = { workspace = true } test-runtime = { workspace = true } diff --git a/testing/integration-tests/src/blocks/mod.rs b/testing/integration-tests/src/blocks/mod.rs index 57d02972b4..ab14d2202a 100644 --- a/testing/integration-tests/src/blocks/mod.rs +++ b/testing/integration-tests/src/blocks/mod.rs @@ -113,7 +113,7 @@ async fn runtime_api_call() -> Result<(), subxt::Error> { }; // Compare the runtime API call against the `state_getMetadata`. - let metadata = api.rpc().metadata(None).await?; + let metadata = api.rpc().metadata_legacy(None).await?; let metadata = metadata.runtime_metadata(); assert_eq!(&metadata_call, metadata); Ok(()) diff --git a/testing/integration-tests/src/client/mod.rs b/testing/integration-tests/src/client/mod.rs index d95936f508..aeaa30ec43 100644 --- a/testing/integration-tests/src/client/mod.rs +++ b/testing/integration-tests/src/client/mod.rs @@ -438,7 +438,7 @@ async fn rpc_state_call() { _ => panic!("Metadata V14 or V15 unavailable"), }; // Compare the runtime API call against the `state_getMetadata`. - let metadata = api.rpc().metadata(None).await.unwrap(); + let metadata = api.rpc().metadata_legacy(None).await.unwrap(); let metadata = metadata.runtime_metadata(); assert_eq!(&metadata_call, metadata); } diff --git a/testing/integration-tests/src/codegen/codegen_documentation.rs b/testing/integration-tests/src/codegen/codegen_documentation.rs index be4a534f1c..e371b24a70 100644 --- a/testing/integration-tests/src/codegen/codegen_documentation.rs +++ b/testing/integration-tests/src/codegen/codegen_documentation.rs @@ -40,6 +40,14 @@ fn metadata_docs() -> Vec { // Note: Extrinsics do not have associated documentation, but is implied by // associated Type. + // Inspect the runtime API types and collect the documentation. + for api in metadata.apis { + docs.extend(api.docs); + for method in api.methods { + docs.extend(method.docs); + } + } + docs } diff --git a/testing/integration-tests/src/codegen/polkadot.rs b/testing/integration-tests/src/codegen/polkadot.rs index 0063171055..9f327be869 100644 --- a/testing/integration-tests/src/codegen/polkadot.rs +++ b/testing/integration-tests/src/codegen/polkadot.rs @@ -838,6 +838,16 @@ pub mod api { pub fn tx() -> TransactionApi { TransactionApi } + pub fn apis() -> runtime_apis::RuntimeApi { + runtime_apis::RuntimeApi + } + pub mod runtime_apis { + use super::root_mod; + use super::runtime_types; + use subxt::ext::codec::Encode; + pub struct RuntimeApi; + impl RuntimeApi {} + } pub struct ConstantsApi; impl ConstantsApi { pub fn system(&self) -> system::constants::ConstantsApi { @@ -1406,11 +1416,11 @@ pub mod api { pub fn remark( &self, remark: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "System", "remark", - Remark { remark }, + types::Remark { remark }, [ 101u8, 80u8, 195u8, 226u8, 224u8, 247u8, 60u8, 128u8, 3u8, 101u8, 51u8, 147u8, 96u8, 126u8, 76u8, 230u8, 194u8, 227u8, 191u8, 73u8, 160u8, @@ -1423,11 +1433,11 @@ pub mod api { pub fn set_heap_pages( &self, pages: ::core::primitive::u64, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "System", "set_heap_pages", - SetHeapPages { pages }, + types::SetHeapPages { pages }, [ 43u8, 103u8, 128u8, 49u8, 156u8, 136u8, 11u8, 204u8, 80u8, 6u8, 244u8, 86u8, 171u8, 44u8, 140u8, 225u8, 142u8, 198u8, 43u8, 87u8, 26u8, 45u8, @@ -1442,11 +1452,11 @@ pub mod api { pub fn set_code( &self, code: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "System", "set_code", - SetCode { code }, + types::SetCode { code }, [ 27u8, 104u8, 244u8, 205u8, 188u8, 254u8, 121u8, 13u8, 106u8, 120u8, 244u8, 108u8, 97u8, 84u8, 100u8, 68u8, 26u8, 69u8, 93u8, 128u8, 107u8, @@ -1461,11 +1471,11 @@ pub mod api { pub fn set_code_without_checks( &self, code: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "System", "set_code_without_checks", - SetCodeWithoutChecks { code }, + types::SetCodeWithoutChecks { code }, [ 102u8, 160u8, 125u8, 235u8, 30u8, 23u8, 45u8, 239u8, 112u8, 148u8, 159u8, 158u8, 42u8, 93u8, 206u8, 94u8, 80u8, 250u8, 66u8, 195u8, 60u8, @@ -1480,11 +1490,11 @@ pub mod api { ::std::vec::Vec<::core::primitive::u8>, ::std::vec::Vec<::core::primitive::u8>, )>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "System", "set_storage", - SetStorage { items }, + types::SetStorage { items }, [ 74u8, 43u8, 106u8, 255u8, 50u8, 151u8, 192u8, 155u8, 14u8, 90u8, 19u8, 45u8, 165u8, 16u8, 235u8, 242u8, 21u8, 131u8, 33u8, 172u8, 119u8, 78u8, @@ -1496,11 +1506,11 @@ pub mod api { pub fn kill_storage( &self, keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "System", "kill_storage", - KillStorage { keys }, + types::KillStorage { keys }, [ 174u8, 174u8, 13u8, 174u8, 75u8, 138u8, 128u8, 235u8, 222u8, 216u8, 85u8, 18u8, 198u8, 1u8, 138u8, 70u8, 19u8, 108u8, 209u8, 41u8, 228u8, @@ -1517,11 +1527,11 @@ pub mod api { &self, prefix: ::std::vec::Vec<::core::primitive::u8>, subkeys: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "System", "kill_prefix", - KillPrefix { prefix, subkeys }, + types::KillPrefix { prefix, subkeys }, [ 203u8, 116u8, 217u8, 42u8, 154u8, 215u8, 77u8, 217u8, 13u8, 22u8, 193u8, 2u8, 128u8, 115u8, 179u8, 115u8, 187u8, 218u8, 129u8, 34u8, @@ -1534,11 +1544,11 @@ pub mod api { pub fn remark_with_event( &self, remark: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "System", "remark_with_event", - RemarkWithEvent { remark }, + types::RemarkWithEvent { remark }, [ 123u8, 225u8, 180u8, 179u8, 144u8, 74u8, 27u8, 85u8, 101u8, 75u8, 134u8, 44u8, 181u8, 25u8, 183u8, 158u8, 14u8, 213u8, 56u8, 225u8, @@ -2260,102 +2270,105 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Schedule { - pub when: ::core::primitive::u32, - pub maybe_periodic: - ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, - pub priority: ::core::primitive::u8, - pub call: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Cancel { - pub when: ::core::primitive::u32, - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduleNamed { - pub id: [::core::primitive::u8; 32usize], - pub when: ::core::primitive::u32, - pub maybe_periodic: - ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, - pub priority: ::core::primitive::u8, - pub call: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelNamed { - pub id: [::core::primitive::u8; 32usize], - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduleAfter { - pub after: ::core::primitive::u32, - pub maybe_periodic: - ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, - pub priority: ::core::primitive::u8, - pub call: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduleNamedAfter { - pub id: [::core::primitive::u8; 32usize], - pub after: ::core::primitive::u32, - pub maybe_periodic: - ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, - pub priority: ::core::primitive::u8, - pub call: ::std::boxed::Box, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Schedule { + pub when: ::core::primitive::u32, + pub maybe_periodic: + ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, + pub priority: ::core::primitive::u8, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Cancel { + pub when: ::core::primitive::u32, + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ScheduleNamed { + pub id: [::core::primitive::u8; 32usize], + pub when: ::core::primitive::u32, + pub maybe_periodic: + ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, + pub priority: ::core::primitive::u8, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelNamed { + pub id: [::core::primitive::u8; 32usize], + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ScheduleAfter { + pub after: ::core::primitive::u32, + pub maybe_periodic: + ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, + pub priority: ::core::primitive::u8, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ScheduleNamedAfter { + pub id: [::core::primitive::u8; 32usize], + pub after: ::core::primitive::u32, + pub maybe_periodic: + ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, + pub priority: ::core::primitive::u8, + pub call: ::std::boxed::Box, + } } pub struct TransactionApi; impl TransactionApi { @@ -2369,11 +2382,11 @@ pub mod api { )>, priority: ::core::primitive::u8, call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Scheduler", "schedule", - Schedule { + types::Schedule { when, maybe_periodic, priority, @@ -2392,11 +2405,11 @@ pub mod api { &self, when: ::core::primitive::u32, index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Scheduler", "cancel", - Cancel { when, index }, + types::Cancel { when, index }, [ 81u8, 251u8, 234u8, 17u8, 214u8, 75u8, 19u8, 59u8, 19u8, 30u8, 89u8, 74u8, 6u8, 216u8, 238u8, 165u8, 7u8, 19u8, 153u8, 253u8, 161u8, 103u8, @@ -2415,11 +2428,11 @@ pub mod api { )>, priority: ::core::primitive::u8, call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Scheduler", "schedule_named", - ScheduleNamed { + types::ScheduleNamed { id, when, maybe_periodic, @@ -2438,11 +2451,11 @@ pub mod api { pub fn cancel_named( &self, id: [::core::primitive::u8; 32usize], - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Scheduler", "cancel_named", - CancelNamed { id }, + types::CancelNamed { id }, [ 51u8, 3u8, 140u8, 50u8, 214u8, 211u8, 50u8, 4u8, 19u8, 43u8, 230u8, 114u8, 18u8, 108u8, 138u8, 67u8, 99u8, 24u8, 255u8, 11u8, 246u8, 37u8, @@ -2460,11 +2473,11 @@ pub mod api { )>, priority: ::core::primitive::u8, call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Scheduler", "schedule_after", - ScheduleAfter { + types::ScheduleAfter { after, maybe_periodic, priority, @@ -2489,11 +2502,11 @@ pub mod api { )>, priority: ::core::primitive::u8, call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Scheduler", "schedule_named_after", - ScheduleNamedAfter { + types::ScheduleNamedAfter { id, after, maybe_periodic, @@ -2833,57 +2846,60 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NotePreimage { - pub bytes: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnnotePreimage { - pub hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RequestPreimage { - pub hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnrequestPreimage { - pub hash: ::subxt::utils::H256, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct NotePreimage { + pub bytes: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UnnotePreimage { + pub hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RequestPreimage { + pub hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UnrequestPreimage { + pub hash: ::subxt::utils::H256, + } } pub struct TransactionApi; impl TransactionApi { @@ -2894,11 +2910,11 @@ pub mod api { pub fn note_preimage( &self, bytes: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Preimage", "note_preimage", - NotePreimage { bytes }, + types::NotePreimage { bytes }, [ 77u8, 48u8, 104u8, 3u8, 254u8, 65u8, 106u8, 95u8, 204u8, 89u8, 149u8, 29u8, 144u8, 188u8, 99u8, 23u8, 146u8, 142u8, 35u8, 17u8, 125u8, 130u8, @@ -2915,11 +2931,11 @@ pub mod api { pub fn unnote_preimage( &self, hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Preimage", "unnote_preimage", - UnnotePreimage { hash }, + types::UnnotePreimage { hash }, [ 211u8, 204u8, 205u8, 58u8, 33u8, 179u8, 68u8, 74u8, 149u8, 138u8, 213u8, 45u8, 140u8, 27u8, 106u8, 81u8, 68u8, 212u8, 147u8, 116u8, 27u8, @@ -2934,11 +2950,11 @@ pub mod api { pub fn request_preimage( &self, hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Preimage", "request_preimage", - RequestPreimage { hash }, + types::RequestPreimage { hash }, [ 195u8, 26u8, 146u8, 255u8, 79u8, 43u8, 73u8, 60u8, 115u8, 78u8, 99u8, 197u8, 137u8, 95u8, 139u8, 141u8, 79u8, 213u8, 170u8, 169u8, 127u8, @@ -2952,11 +2968,11 @@ pub mod api { pub fn unrequest_preimage( &self, hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Preimage", "unrequest_preimage", - UnrequestPreimage { hash }, + types::UnrequestPreimage { hash }, [ 143u8, 225u8, 239u8, 44u8, 237u8, 83u8, 18u8, 105u8, 101u8, 68u8, 111u8, 116u8, 66u8, 212u8, 63u8, 190u8, 38u8, 32u8, 105u8, 152u8, 69u8, @@ -3142,62 +3158,65 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportEquivocation { - pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReportEquivocation { + pub equivocation_proof: ::std::boxed::Box< + runtime_types::sp_consensus_slots::EquivocationProof< + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + runtime_types::sp_consensus_babe::app::Public, >, - runtime_types::sp_consensus_babe::app::Public, >, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportEquivocationUnsigned { - pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, + pub key_owner_proof: runtime_types::sp_session::MembershipProof, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReportEquivocationUnsigned { + pub equivocation_proof: ::std::boxed::Box< + runtime_types::sp_consensus_slots::EquivocationProof< + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + runtime_types::sp_consensus_babe::app::Public, >, - runtime_types::sp_consensus_babe::app::Public, >, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PlanConfigChange { - pub config: runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, + pub key_owner_proof: runtime_types::sp_session::MembershipProof, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PlanConfigChange { + pub config: runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, + } } pub struct TransactionApi; impl TransactionApi { @@ -3215,11 +3234,11 @@ pub mod api { runtime_types::sp_consensus_babe::app::Public, >, key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Babe", "report_equivocation", - ReportEquivocation { + types::ReportEquivocation { equivocation_proof: ::std::boxed::Box::new(equivocation_proof), key_owner_proof, }, @@ -3249,11 +3268,11 @@ pub mod api { runtime_types::sp_consensus_babe::app::Public, >, key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Babe", "report_equivocation_unsigned", - ReportEquivocationUnsigned { + types::ReportEquivocationUnsigned { equivocation_proof: ::std::boxed::Box::new(equivocation_proof), key_owner_proof, }, @@ -3272,11 +3291,11 @@ pub mod api { pub fn plan_config_change( &self, config: runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Babe", "plan_config_change", - PlanConfigChange { config }, + types::PlanConfigChange { config }, [ 229u8, 157u8, 41u8, 58u8, 56u8, 4u8, 52u8, 107u8, 104u8, 20u8, 42u8, 110u8, 1u8, 17u8, 45u8, 196u8, 30u8, 135u8, 63u8, 46u8, 40u8, 137u8, @@ -3800,19 +3819,22 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Set { - #[codec(compact)] - pub now: ::core::primitive::u64, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Set { + #[codec(compact)] + pub now: ::core::primitive::u64, + } } pub struct TransactionApi; impl TransactionApi { @@ -3835,7 +3857,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "Timestamp", "set", - Set { now }, + types::Set { now }, [ 6u8, 97u8, 172u8, 236u8, 118u8, 238u8, 228u8, 114u8, 15u8, 115u8, 102u8, 85u8, 66u8, 151u8, 16u8, 33u8, 187u8, 17u8, 166u8, 88u8, 127u8, @@ -3928,76 +3950,79 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Claim { - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Transfer { - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Free { - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceTransfer { - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub index: ::core::primitive::u32, - pub freeze: ::core::primitive::bool, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Freeze { - pub index: ::core::primitive::u32, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Claim { + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Transfer { + pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Free { + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceTransfer { + pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub index: ::core::primitive::u32, + pub freeze: ::core::primitive::bool, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Freeze { + pub index: ::core::primitive::u32, + } } pub struct TransactionApi; impl TransactionApi { @@ -4017,7 +4042,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "Indices", "claim", - Claim { index }, + types::Claim { index }, [ 5u8, 24u8, 11u8, 173u8, 226u8, 170u8, 0u8, 30u8, 193u8, 102u8, 214u8, 59u8, 252u8, 32u8, 221u8, 88u8, 196u8, 189u8, 244u8, 18u8, 233u8, 37u8, @@ -4041,11 +4066,11 @@ pub mod api { &self, new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Indices", "transfer", - Transfer { new, index }, + types::Transfer { new, index }, [ 154u8, 191u8, 183u8, 50u8, 185u8, 69u8, 126u8, 132u8, 12u8, 77u8, 146u8, 189u8, 254u8, 7u8, 72u8, 191u8, 118u8, 102u8, 180u8, 2u8, 161u8, @@ -4069,7 +4094,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "Indices", "free", - Free { index }, + types::Free { index }, [ 133u8, 202u8, 225u8, 127u8, 69u8, 145u8, 43u8, 13u8, 160u8, 248u8, 215u8, 243u8, 232u8, 166u8, 74u8, 203u8, 235u8, 138u8, 255u8, 27u8, @@ -4096,11 +4121,11 @@ pub mod api { new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, index: ::core::primitive::u32, freeze: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Indices", "force_transfer", - ForceTransfer { new, index, freeze }, + types::ForceTransfer { new, index, freeze }, [ 37u8, 220u8, 91u8, 118u8, 222u8, 81u8, 225u8, 131u8, 101u8, 203u8, 60u8, 149u8, 102u8, 92u8, 58u8, 91u8, 227u8, 64u8, 229u8, 62u8, 201u8, @@ -4124,11 +4149,11 @@ pub mod api { pub fn freeze( &self, index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Indices", "freeze", - Freeze { index }, + types::Freeze { index }, [ 121u8, 45u8, 118u8, 2u8, 72u8, 48u8, 38u8, 7u8, 234u8, 204u8, 68u8, 20u8, 76u8, 251u8, 205u8, 246u8, 149u8, 31u8, 168u8, 186u8, 208u8, @@ -4484,11 +4509,11 @@ pub mod api { source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Balances", "force_transfer", - ForceTransfer { + types::ForceTransfer { source, dest, value, @@ -4511,11 +4536,11 @@ pub mod api { &self, dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Balances", "transfer_keep_alive", - TransferKeepAlive { dest, value }, + types::TransferKeepAlive { dest, value }, [ 112u8, 179u8, 75u8, 168u8, 193u8, 221u8, 9u8, 82u8, 190u8, 113u8, 253u8, 13u8, 130u8, 134u8, 170u8, 216u8, 136u8, 111u8, 242u8, 220u8, @@ -4543,11 +4568,11 @@ pub mod api { &self, dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, keep_alive: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Balances", "transfer_all", - TransferAll { dest, keep_alive }, + types::TransferAll { dest, keep_alive }, [ 46u8, 129u8, 29u8, 177u8, 221u8, 107u8, 245u8, 69u8, 238u8, 126u8, 145u8, 26u8, 219u8, 208u8, 14u8, 80u8, 149u8, 1u8, 214u8, 63u8, 67u8, @@ -4563,11 +4588,11 @@ pub mod api { &self, who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, amount: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Balances", "force_unreserve", - ForceUnreserve { who, amount }, + types::ForceUnreserve { who, amount }, [ 160u8, 146u8, 137u8, 76u8, 157u8, 187u8, 66u8, 148u8, 207u8, 76u8, 32u8, 254u8, 82u8, 215u8, 35u8, 161u8, 213u8, 52u8, 32u8, 98u8, 102u8, @@ -5648,53 +5673,380 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Bond { - pub controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, - pub payee: - runtime_types::pallet_staking::RewardDestination<::subxt::utils::AccountId32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BondExtra { - #[codec(compact)] - pub max_additional: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Unbond { - #[codec(compact)] - pub value: ::core::primitive::u128, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Bond { + pub controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub value: ::core::primitive::u128, + pub payee: runtime_types::pallet_staking::RewardDestination< + ::subxt::utils::AccountId32, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BondExtra { + #[codec(compact)] + pub max_additional: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Unbond { + #[codec(compact)] + pub value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct WithdrawUnbonded { + pub num_slashing_spans: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Validate { + pub prefs: runtime_types::pallet_staking::ValidatorPrefs, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Nominate { + pub targets: ::std::vec::Vec< + ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Chill; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetPayee { + pub payee: runtime_types::pallet_staking::RewardDestination< + ::subxt::utils::AccountId32, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetController { + pub controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetValidatorCount { + #[codec(compact)] + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct IncreaseValidatorCount { + #[codec(compact)] + pub additional: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ScaleValidatorCount { + pub factor: runtime_types::sp_arithmetic::per_things::Percent, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceNoEras; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceNewEra; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetInvulnerables { + pub invulnerables: ::std::vec::Vec<::subxt::utils::AccountId32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceUnstake { + pub stash: ::subxt::utils::AccountId32, + pub num_slashing_spans: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceNewEraAlways; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelDeferredSlash { + pub era: ::core::primitive::u32, + pub slash_indices: ::std::vec::Vec<::core::primitive::u32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PayoutStakers { + pub validator_stash: ::subxt::utils::AccountId32, + pub era: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Rebond { + #[codec(compact)] + pub value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReapStash { + pub stash: ::subxt::utils::AccountId32, + pub num_slashing_spans: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Kick { + pub who: ::std::vec::Vec< + ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetStakingConfigs { + pub min_nominator_bond: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + ::core::primitive::u128, + >, + pub min_validator_bond: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + ::core::primitive::u128, + >, + pub max_nominator_count: + runtime_types::pallet_staking::pallet::pallet::ConfigOp< + ::core::primitive::u32, + >, + pub max_validator_count: + runtime_types::pallet_staking::pallet::pallet::ConfigOp< + ::core::primitive::u32, + >, + pub chill_threshold: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + runtime_types::sp_arithmetic::per_things::Percent, + >, + pub min_commission: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + runtime_types::sp_arithmetic::per_things::Perbill, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ChillOther { + pub controller: ::subxt::utils::AccountId32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceApplyMinCommission { + pub validator_stash: ::subxt::utils::AccountId32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMinCommission { + pub new: runtime_types::sp_arithmetic::per_things::Perbill, + } } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -5704,311 +6056,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WithdrawUnbonded { - pub num_slashing_spans: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Validate { - pub prefs: runtime_types::pallet_staking::ValidatorPrefs, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Nominate { - pub targets: - ::std::vec::Vec<::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Chill; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetPayee { - pub payee: - runtime_types::pallet_staking::RewardDestination<::subxt::utils::AccountId32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetController { - pub controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetValidatorCount { - #[codec(compact)] - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct IncreaseValidatorCount { - #[codec(compact)] - pub additional: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScaleValidatorCount { - pub factor: runtime_types::sp_arithmetic::per_things::Percent, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceNoEras; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceNewEra; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetInvulnerables { - pub invulnerables: ::std::vec::Vec<::subxt::utils::AccountId32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceUnstake { - pub stash: ::subxt::utils::AccountId32, - pub num_slashing_spans: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceNewEraAlways; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelDeferredSlash { - pub era: ::core::primitive::u32, - pub slash_indices: ::std::vec::Vec<::core::primitive::u32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PayoutStakers { - pub validator_stash: ::subxt::utils::AccountId32, - pub era: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Rebond { - #[codec(compact)] - pub value: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReapStash { - pub stash: ::subxt::utils::AccountId32, - pub num_slashing_spans: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Kick { - pub who: - ::std::vec::Vec<::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetStakingConfigs { - pub min_nominator_bond: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - ::core::primitive::u128, - >, - pub min_validator_bond: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - ::core::primitive::u128, - >, - pub max_nominator_count: - runtime_types::pallet_staking::pallet::pallet::ConfigOp<::core::primitive::u32>, - pub max_validator_count: - runtime_types::pallet_staking::pallet::pallet::ConfigOp<::core::primitive::u32>, - pub chill_threshold: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - runtime_types::sp_arithmetic::per_things::Percent, - >, - pub min_commission: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - runtime_types::sp_arithmetic::per_things::Perbill, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ChillOther { - pub controller: ::subxt::utils::AccountId32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceApplyMinCommission { - pub validator_stash: ::subxt::utils::AccountId32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMinCommission { - pub new: runtime_types::sp_arithmetic::per_things::Perbill, + pub struct SetMinCommission { + pub new: runtime_types::sp_arithmetic::per_things::Perbill, } pub struct TransactionApi; impl TransactionApi { @@ -6034,11 +6083,11 @@ pub mod api { payee: runtime_types::pallet_staking::RewardDestination< ::subxt::utils::AccountId32, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "bond", - Bond { + types::Bond { controller, value, payee, @@ -6068,11 +6117,11 @@ pub mod api { pub fn bond_extra( &self, max_additional: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "bond_extra", - BondExtra { max_additional }, + types::BondExtra { max_additional }, [ 60u8, 45u8, 82u8, 223u8, 113u8, 95u8, 0u8, 71u8, 59u8, 108u8, 228u8, 9u8, 95u8, 210u8, 113u8, 106u8, 252u8, 15u8, 19u8, 128u8, 11u8, 187u8, @@ -6102,11 +6151,11 @@ pub mod api { pub fn unbond( &self, value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "unbond", - Unbond { value }, + types::Unbond { value }, [ 85u8, 62u8, 34u8, 127u8, 60u8, 241u8, 134u8, 60u8, 125u8, 91u8, 31u8, 193u8, 50u8, 230u8, 237u8, 42u8, 114u8, 230u8, 240u8, 146u8, 14u8, @@ -6132,11 +6181,11 @@ pub mod api { pub fn withdraw_unbonded( &self, num_slashing_spans: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "withdraw_unbonded", - WithdrawUnbonded { num_slashing_spans }, + types::WithdrawUnbonded { num_slashing_spans }, [ 95u8, 223u8, 122u8, 217u8, 76u8, 208u8, 86u8, 129u8, 31u8, 104u8, 70u8, 154u8, 23u8, 250u8, 165u8, 192u8, 149u8, 249u8, 158u8, 159u8, 194u8, @@ -6153,11 +6202,11 @@ pub mod api { pub fn validate( &self, prefs: runtime_types::pallet_staking::ValidatorPrefs, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "validate", - Validate { prefs }, + types::Validate { prefs }, [ 191u8, 116u8, 139u8, 35u8, 250u8, 211u8, 86u8, 240u8, 35u8, 9u8, 19u8, 44u8, 148u8, 35u8, 91u8, 106u8, 200u8, 172u8, 108u8, 145u8, 194u8, @@ -6181,11 +6230,11 @@ pub mod api { targets: ::std::vec::Vec< ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "nominate", - Nominate { targets }, + types::Nominate { targets }, [ 112u8, 162u8, 70u8, 26u8, 74u8, 7u8, 188u8, 193u8, 210u8, 247u8, 27u8, 189u8, 133u8, 137u8, 33u8, 155u8, 255u8, 171u8, 122u8, 68u8, 175u8, @@ -6208,7 +6257,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "Staking", "chill", - Chill {}, + types::Chill {}, [ 94u8, 20u8, 196u8, 31u8, 220u8, 125u8, 115u8, 167u8, 140u8, 3u8, 20u8, 132u8, 81u8, 120u8, 215u8, 166u8, 230u8, 56u8, 16u8, 222u8, 31u8, @@ -6234,11 +6283,11 @@ pub mod api { payee: runtime_types::pallet_staking::RewardDestination< ::subxt::utils::AccountId32, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "set_payee", - SetPayee { payee }, + types::SetPayee { payee }, [ 96u8, 8u8, 254u8, 164u8, 87u8, 46u8, 120u8, 11u8, 197u8, 63u8, 20u8, 178u8, 167u8, 236u8, 149u8, 245u8, 14u8, 171u8, 108u8, 195u8, 250u8, @@ -6260,11 +6309,11 @@ pub mod api { pub fn set_controller( &self, controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "set_controller", - SetController { controller }, + types::SetController { controller }, [ 165u8, 250u8, 213u8, 32u8, 179u8, 163u8, 15u8, 35u8, 14u8, 152u8, 56u8, 171u8, 43u8, 101u8, 7u8, 167u8, 178u8, 60u8, 89u8, 186u8, 59u8, 28u8, @@ -6281,11 +6330,11 @@ pub mod api { pub fn set_validator_count( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "set_validator_count", - SetValidatorCount { new }, + types::SetValidatorCount { new }, [ 55u8, 232u8, 95u8, 66u8, 228u8, 217u8, 11u8, 27u8, 3u8, 202u8, 199u8, 242u8, 70u8, 160u8, 250u8, 187u8, 194u8, 91u8, 15u8, 36u8, 215u8, 36u8, @@ -6303,11 +6352,11 @@ pub mod api { pub fn increase_validator_count( &self, additional: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "increase_validator_count", - IncreaseValidatorCount { additional }, + types::IncreaseValidatorCount { additional }, [ 239u8, 184u8, 155u8, 213u8, 25u8, 22u8, 193u8, 13u8, 102u8, 192u8, 82u8, 153u8, 249u8, 192u8, 60u8, 158u8, 8u8, 78u8, 175u8, 219u8, 46u8, @@ -6325,11 +6374,11 @@ pub mod api { pub fn scale_validator_count( &self, factor: runtime_types::sp_arithmetic::per_things::Percent, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "scale_validator_count", - ScaleValidatorCount { factor }, + types::ScaleValidatorCount { factor }, [ 198u8, 68u8, 227u8, 94u8, 110u8, 157u8, 209u8, 217u8, 112u8, 37u8, 78u8, 142u8, 12u8, 193u8, 219u8, 167u8, 149u8, 112u8, 49u8, 139u8, @@ -6355,7 +6404,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "Staking", "force_no_eras", - ForceNoEras {}, + types::ForceNoEras {}, [ 16u8, 81u8, 207u8, 168u8, 23u8, 236u8, 11u8, 75u8, 141u8, 107u8, 92u8, 2u8, 53u8, 111u8, 252u8, 116u8, 91u8, 120u8, 75u8, 24u8, 125u8, 53u8, @@ -6381,7 +6430,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "Staking", "force_new_era", - ForceNewEra {}, + types::ForceNewEra {}, [ 230u8, 242u8, 169u8, 196u8, 78u8, 145u8, 24u8, 191u8, 113u8, 68u8, 5u8, 138u8, 48u8, 51u8, 109u8, 126u8, 73u8, 136u8, 162u8, 158u8, 174u8, @@ -6395,11 +6444,11 @@ pub mod api { pub fn set_invulnerables( &self, invulnerables: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "set_invulnerables", - SetInvulnerables { invulnerables }, + types::SetInvulnerables { invulnerables }, [ 2u8, 148u8, 221u8, 111u8, 153u8, 48u8, 222u8, 36u8, 228u8, 84u8, 18u8, 35u8, 168u8, 239u8, 53u8, 245u8, 27u8, 76u8, 18u8, 203u8, 206u8, 9u8, @@ -6414,11 +6463,11 @@ pub mod api { &self, stash: ::subxt::utils::AccountId32, num_slashing_spans: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "force_unstake", - ForceUnstake { + types::ForceUnstake { stash, num_slashing_spans, }, @@ -6439,11 +6488,13 @@ pub mod api { #[doc = "The election process starts multiple blocks before the end of the era."] #[doc = "If this is called just before a new era is triggered, the election process may not"] #[doc = "have enough blocks to get a result."] - pub fn force_new_era_always(&self) -> ::subxt::tx::Payload { + pub fn force_new_era_always( + &self, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "force_new_era_always", - ForceNewEraAlways {}, + types::ForceNewEraAlways {}, [ 179u8, 118u8, 189u8, 54u8, 248u8, 141u8, 207u8, 142u8, 80u8, 37u8, 241u8, 185u8, 138u8, 254u8, 117u8, 147u8, 225u8, 118u8, 34u8, 177u8, @@ -6461,11 +6512,11 @@ pub mod api { &self, era: ::core::primitive::u32, slash_indices: ::std::vec::Vec<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "cancel_deferred_slash", - CancelDeferredSlash { era, slash_indices }, + types::CancelDeferredSlash { era, slash_indices }, [ 120u8, 57u8, 162u8, 105u8, 91u8, 250u8, 129u8, 240u8, 110u8, 234u8, 170u8, 98u8, 164u8, 65u8, 106u8, 101u8, 19u8, 88u8, 146u8, 210u8, @@ -6489,11 +6540,11 @@ pub mod api { &self, validator_stash: ::subxt::utils::AccountId32, era: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "payout_stakers", - PayoutStakers { + types::PayoutStakers { validator_stash, era, }, @@ -6514,11 +6565,11 @@ pub mod api { pub fn rebond( &self, value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "rebond", - Rebond { value }, + types::Rebond { value }, [ 25u8, 22u8, 191u8, 172u8, 133u8, 101u8, 139u8, 102u8, 134u8, 16u8, 136u8, 56u8, 137u8, 162u8, 4u8, 253u8, 196u8, 30u8, 234u8, 49u8, 102u8, @@ -6543,11 +6594,11 @@ pub mod api { &self, stash: ::subxt::utils::AccountId32, num_slashing_spans: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "reap_stash", - ReapStash { + types::ReapStash { stash, num_slashing_spans, }, @@ -6575,11 +6626,11 @@ pub mod api { who: ::std::vec::Vec< ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "kick", - Kick { who }, + types::Kick { who }, [ 32u8, 26u8, 202u8, 6u8, 186u8, 180u8, 58u8, 121u8, 185u8, 208u8, 123u8, 10u8, 53u8, 179u8, 167u8, 203u8, 96u8, 229u8, 7u8, 144u8, 231u8, 172u8, @@ -6624,11 +6675,11 @@ pub mod api { min_commission: runtime_types::pallet_staking::pallet::pallet::ConfigOp< runtime_types::sp_arithmetic::per_things::Perbill, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "set_staking_configs", - SetStakingConfigs { + types::SetStakingConfigs { min_nominator_bond, min_validator_bond, max_nominator_count, @@ -6672,11 +6723,11 @@ pub mod api { pub fn chill_other( &self, controller: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "chill_other", - ChillOther { controller }, + types::ChillOther { controller }, [ 140u8, 98u8, 4u8, 203u8, 91u8, 131u8, 123u8, 119u8, 169u8, 47u8, 188u8, 23u8, 205u8, 170u8, 82u8, 220u8, 166u8, 170u8, 135u8, 176u8, 68u8, @@ -6690,11 +6741,11 @@ pub mod api { pub fn force_apply_min_commission( &self, validator_stash: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Staking", "force_apply_min_commission", - ForceApplyMinCommission { validator_stash }, + types::ForceApplyMinCommission { validator_stash }, [ 136u8, 163u8, 85u8, 134u8, 240u8, 247u8, 183u8, 227u8, 226u8, 202u8, 102u8, 186u8, 138u8, 119u8, 78u8, 123u8, 229u8, 135u8, 129u8, 241u8, @@ -8706,31 +8757,34 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetKeys { - pub keys: runtime_types::polkadot_runtime::SessionKeys, - pub proof: ::std::vec::Vec<::core::primitive::u8>, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetKeys { + pub keys: runtime_types::polkadot_runtime::SessionKeys, + pub proof: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PurgeKeys; } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PurgeKeys; pub struct TransactionApi; impl TransactionApi { #[doc = "Sets the session key(s) of the function caller to `keys`."] @@ -8746,11 +8800,11 @@ pub mod api { &self, keys: runtime_types::polkadot_runtime::SessionKeys, proof: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Session", "set_keys", - SetKeys { keys, proof }, + types::SetKeys { keys, proof }, [ 17u8, 127u8, 23u8, 71u8, 118u8, 133u8, 89u8, 105u8, 93u8, 52u8, 46u8, 201u8, 151u8, 19u8, 124u8, 195u8, 228u8, 229u8, 22u8, 216u8, 32u8, @@ -8774,7 +8828,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "Session", "purge_keys", - PurgeKeys {}, + types::PurgeKeys {}, [ 200u8, 255u8, 4u8, 213u8, 188u8, 92u8, 99u8, 116u8, 163u8, 152u8, 29u8, 35u8, 133u8, 119u8, 246u8, 44u8, 91u8, 31u8, 145u8, 23u8, 213u8, 64u8, @@ -9073,22 +9127,22 @@ pub mod api { ::subxt::utils::H256, ::core::primitive::u32, >, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NoteStalled { - pub delay: ::core::primitive::u32, - pub best_finalized_block_number: ::core::primitive::u32, + pub key_owner_proof: runtime_types::sp_session::MembershipProof, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct NoteStalled { + pub delay: ::core::primitive::u32, + pub best_finalized_block_number: ::core::primitive::u32, + } } pub struct TransactionApi; impl TransactionApi { @@ -9103,11 +9157,11 @@ pub mod api { ::core::primitive::u32, >, key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Grandpa", "report_equivocation", - ReportEquivocation { + types::ReportEquivocation { equivocation_proof: ::std::boxed::Box::new(equivocation_proof), key_owner_proof, }, @@ -9134,11 +9188,11 @@ pub mod api { ::core::primitive::u32, >, key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Grandpa", "report_equivocation_unsigned", - ReportEquivocationUnsigned { + types::ReportEquivocationUnsigned { equivocation_proof: ::std::boxed::Box::new(equivocation_proof), key_owner_proof, }, @@ -9166,11 +9220,11 @@ pub mod api { &self, delay: ::core::primitive::u32, best_finalized_block_number: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Grandpa", "note_stalled", - NoteStalled { + types::NoteStalled { delay, best_finalized_block_number, }, @@ -9474,19 +9528,23 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Heartbeat { - pub heartbeat: runtime_types::pallet_im_online::Heartbeat<::core::primitive::u32>, - pub signature: runtime_types::pallet_im_online::sr25519::app_sr25519::Signature, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Heartbeat { + pub heartbeat: + runtime_types::pallet_im_online::Heartbeat<::core::primitive::u32>, + pub signature: runtime_types::pallet_im_online::sr25519::app_sr25519::Signature, + } } pub struct TransactionApi; impl TransactionApi { @@ -9499,11 +9557,11 @@ pub mod api { &self, heartbeat: runtime_types::pallet_im_online::Heartbeat<::core::primitive::u32>, signature: runtime_types::pallet_im_online::sr25519::app_sr25519::Signature, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ImOnline", "heartbeat", - Heartbeat { + types::Heartbeat { heartbeat, signature, }, @@ -9787,206 +9845,278 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Propose { - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - #[codec(compact)] - pub value: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Second { - #[codec(compact)] - pub proposal: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vote { - #[codec(compact)] - pub ref_index: ::core::primitive::u32, - pub vote: - runtime_types::pallet_democracy::vote::AccountVote<::core::primitive::u128>, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EmergencyCancel { - pub ref_index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExternalPropose { - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExternalProposeMajority { - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExternalProposeDefault { - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FastTrack { - pub proposal_hash: ::subxt::utils::H256, - pub voting_period: ::core::primitive::u32, - pub delay: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VetoExternal { - pub proposal_hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelReferendum { - #[codec(compact)] - pub ref_index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Delegate { - pub to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub conviction: runtime_types::pallet_democracy::conviction::Conviction, - pub balance: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Undelegate; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClearPublicProposals; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Unlock { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Propose { + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + #[codec(compact)] + pub value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Second { + #[codec(compact)] + pub proposal: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Vote { + #[codec(compact)] + pub ref_index: ::core::primitive::u32, + pub vote: + runtime_types::pallet_democracy::vote::AccountVote<::core::primitive::u128>, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct EmergencyCancel { + pub ref_index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ExternalPropose { + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ExternalProposeMajority { + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ExternalProposeDefault { + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct FastTrack { + pub proposal_hash: ::subxt::utils::H256, + pub voting_period: ::core::primitive::u32, + pub delay: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct VetoExternal { + pub proposal_hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelReferendum { + #[codec(compact)] + pub ref_index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Delegate { + pub to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub conviction: runtime_types::pallet_democracy::conviction::Conviction, + pub balance: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Undelegate; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClearPublicProposals; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Unlock { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveVote { + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveOtherVote { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Blacklist { + pub proposal_hash: ::subxt::utils::H256, + pub maybe_ref_index: ::core::option::Option<::core::primitive::u32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelProposal { + #[codec(compact)] + pub prop_index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMetadata { + pub owner: runtime_types::pallet_democracy::types::MetadataOwner, + pub maybe_hash: ::core::option::Option<::subxt::utils::H256>, + } } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -9996,64 +10126,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveVote { - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveOtherVote { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Blacklist { - pub proposal_hash: ::subxt::utils::H256, - pub maybe_ref_index: ::core::option::Option<::core::primitive::u32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelProposal { - #[codec(compact)] - pub prop_index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMetadata { - pub owner: runtime_types::pallet_democracy::types::MetadataOwner, - pub maybe_hash: ::core::option::Option<::subxt::utils::H256>, + pub struct SetMetadata { + pub owner: runtime_types::pallet_democracy::types::MetadataOwner, + pub maybe_hash: ::core::option::Option<::subxt::utils::H256>, } pub struct TransactionApi; impl TransactionApi { @@ -10072,11 +10147,11 @@ pub mod api { runtime_types::polkadot_runtime::RuntimeCall, >, value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "propose", - Propose { proposal, value }, + types::Propose { proposal, value }, [ 123u8, 3u8, 204u8, 140u8, 194u8, 195u8, 214u8, 39u8, 167u8, 126u8, 45u8, 4u8, 219u8, 17u8, 143u8, 185u8, 29u8, 224u8, 230u8, 68u8, 253u8, @@ -10093,11 +10168,11 @@ pub mod api { pub fn second( &self, proposal: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "second", - Second { proposal }, + types::Second { proposal }, [ 59u8, 240u8, 183u8, 218u8, 61u8, 93u8, 184u8, 67u8, 10u8, 4u8, 138u8, 196u8, 168u8, 49u8, 42u8, 69u8, 154u8, 42u8, 90u8, 112u8, 179u8, 69u8, @@ -10118,11 +10193,11 @@ pub mod api { vote: runtime_types::pallet_democracy::vote::AccountVote< ::core::primitive::u128, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "vote", - Vote { ref_index, vote }, + types::Vote { ref_index, vote }, [ 138u8, 213u8, 229u8, 111u8, 1u8, 191u8, 73u8, 3u8, 145u8, 28u8, 44u8, 88u8, 163u8, 188u8, 129u8, 188u8, 64u8, 15u8, 64u8, 103u8, 250u8, 97u8, @@ -10141,11 +10216,11 @@ pub mod api { pub fn emergency_cancel( &self, ref_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "emergency_cancel", - EmergencyCancel { ref_index }, + types::EmergencyCancel { ref_index }, [ 139u8, 213u8, 133u8, 75u8, 34u8, 206u8, 124u8, 245u8, 35u8, 237u8, 132u8, 92u8, 49u8, 167u8, 117u8, 80u8, 188u8, 93u8, 198u8, 237u8, @@ -10165,11 +10240,11 @@ pub mod api { proposal: runtime_types::frame_support::traits::preimages::Bounded< runtime_types::polkadot_runtime::RuntimeCall, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "external_propose", - ExternalPropose { proposal }, + types::ExternalPropose { proposal }, [ 164u8, 193u8, 14u8, 122u8, 105u8, 232u8, 20u8, 194u8, 99u8, 227u8, 36u8, 105u8, 218u8, 146u8, 16u8, 208u8, 56u8, 62u8, 100u8, 65u8, 35u8, @@ -10193,11 +10268,11 @@ pub mod api { proposal: runtime_types::frame_support::traits::preimages::Bounded< runtime_types::polkadot_runtime::RuntimeCall, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "external_propose_majority", - ExternalProposeMajority { proposal }, + types::ExternalProposeMajority { proposal }, [ 129u8, 124u8, 147u8, 253u8, 69u8, 115u8, 230u8, 186u8, 155u8, 4u8, 220u8, 103u8, 28u8, 132u8, 115u8, 153u8, 196u8, 88u8, 9u8, 130u8, @@ -10222,11 +10297,11 @@ pub mod api { proposal: runtime_types::frame_support::traits::preimages::Bounded< runtime_types::polkadot_runtime::RuntimeCall, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "external_propose_default", - ExternalProposeDefault { proposal }, + types::ExternalProposeDefault { proposal }, [ 96u8, 15u8, 108u8, 208u8, 141u8, 247u8, 4u8, 73u8, 2u8, 30u8, 231u8, 40u8, 184u8, 250u8, 42u8, 161u8, 248u8, 45u8, 217u8, 50u8, 53u8, 13u8, @@ -10255,11 +10330,11 @@ pub mod api { proposal_hash: ::subxt::utils::H256, voting_period: ::core::primitive::u32, delay: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "fast_track", - FastTrack { + types::FastTrack { proposal_hash, voting_period, delay, @@ -10283,11 +10358,11 @@ pub mod api { pub fn veto_external( &self, proposal_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "veto_external", - VetoExternal { proposal_hash }, + types::VetoExternal { proposal_hash }, [ 209u8, 18u8, 18u8, 103u8, 186u8, 160u8, 214u8, 124u8, 150u8, 207u8, 112u8, 90u8, 84u8, 197u8, 95u8, 157u8, 165u8, 65u8, 109u8, 101u8, 75u8, @@ -10306,11 +10381,11 @@ pub mod api { pub fn cancel_referendum( &self, ref_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "cancel_referendum", - CancelReferendum { ref_index }, + types::CancelReferendum { ref_index }, [ 51u8, 25u8, 25u8, 251u8, 236u8, 115u8, 130u8, 230u8, 72u8, 186u8, 119u8, 71u8, 165u8, 137u8, 55u8, 167u8, 187u8, 128u8, 55u8, 8u8, 212u8, @@ -10344,11 +10419,11 @@ pub mod api { to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, conviction: runtime_types::pallet_democracy::conviction::Conviction, balance: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "delegate", - Delegate { + types::Delegate { to, conviction, balance, @@ -10373,11 +10448,11 @@ pub mod api { #[doc = ""] #[doc = "Weight: `O(R)` where R is the number of referendums the voter delegating to has"] #[doc = " voted on. Weight is charged as if maximum votes."] - pub fn undelegate(&self) -> ::subxt::tx::Payload { + pub fn undelegate(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "undelegate", - Undelegate {}, + types::Undelegate {}, [ 165u8, 40u8, 183u8, 209u8, 57u8, 153u8, 111u8, 29u8, 114u8, 109u8, 107u8, 235u8, 97u8, 61u8, 53u8, 155u8, 44u8, 245u8, 28u8, 220u8, 56u8, @@ -10391,11 +10466,13 @@ pub mod api { #[doc = "The dispatch origin of this call must be _Root_."] #[doc = ""] #[doc = "Weight: `O(1)`."] - pub fn clear_public_proposals(&self) -> ::subxt::tx::Payload { + pub fn clear_public_proposals( + &self, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "clear_public_proposals", - ClearPublicProposals {}, + types::ClearPublicProposals {}, [ 59u8, 126u8, 254u8, 223u8, 252u8, 225u8, 75u8, 185u8, 188u8, 181u8, 42u8, 179u8, 211u8, 73u8, 12u8, 141u8, 243u8, 197u8, 46u8, 130u8, @@ -10414,11 +10491,11 @@ pub mod api { pub fn unlock( &self, target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "unlock", - Unlock { target }, + types::Unlock { target }, [ 126u8, 151u8, 230u8, 89u8, 49u8, 247u8, 242u8, 139u8, 190u8, 15u8, 47u8, 2u8, 132u8, 165u8, 48u8, 205u8, 196u8, 66u8, 230u8, 222u8, 164u8, @@ -10456,11 +10533,11 @@ pub mod api { pub fn remove_vote( &self, index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "remove_vote", - RemoveVote { index }, + types::RemoveVote { index }, [ 148u8, 120u8, 14u8, 172u8, 81u8, 152u8, 159u8, 178u8, 106u8, 244u8, 36u8, 98u8, 120u8, 189u8, 213u8, 93u8, 119u8, 156u8, 112u8, 34u8, @@ -10488,11 +10565,11 @@ pub mod api { &self, target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "remove_other_vote", - RemoveOtherVote { target, index }, + types::RemoveOtherVote { target, index }, [ 151u8, 190u8, 115u8, 124u8, 185u8, 43u8, 70u8, 147u8, 98u8, 167u8, 120u8, 25u8, 231u8, 143u8, 214u8, 25u8, 240u8, 74u8, 35u8, 58u8, 206u8, @@ -10519,11 +10596,11 @@ pub mod api { &self, proposal_hash: ::subxt::utils::H256, maybe_ref_index: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "blacklist", - Blacklist { + types::Blacklist { proposal_hash, maybe_ref_index, }, @@ -10545,11 +10622,11 @@ pub mod api { pub fn cancel_proposal( &self, prop_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Democracy", "cancel_proposal", - CancelProposal { prop_index }, + types::CancelProposal { prop_index }, [ 179u8, 3u8, 198u8, 244u8, 241u8, 124u8, 205u8, 58u8, 100u8, 80u8, 177u8, 254u8, 98u8, 220u8, 189u8, 63u8, 229u8, 60u8, 157u8, 83u8, @@ -11738,11 +11815,11 @@ pub mod api { new_members: ::std::vec::Vec<::subxt::utils::AccountId32>, prime: ::core::option::Option<::subxt::utils::AccountId32>, old_count: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Council", "set_members", - SetMembers { + types::SetMembers { new_members, prime, old_count, @@ -11768,11 +11845,11 @@ pub mod api { &self, proposal: runtime_types::polkadot_runtime::RuntimeCall, length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Council", "execute", - Execute { + types::Execute { proposal: ::std::boxed::Box::new(proposal), length_bound, }, @@ -11802,11 +11879,11 @@ pub mod api { threshold: ::core::primitive::u32, proposal: runtime_types::polkadot_runtime::RuntimeCall, length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Council", "propose", - Propose { + types::Propose { threshold, proposal: ::std::boxed::Box::new(proposal), length_bound, @@ -11832,11 +11909,11 @@ pub mod api { proposal: ::subxt::utils::H256, index: ::core::primitive::u32, approve: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Council", "vote", - Vote { + types::Vote { proposal, index, approve, @@ -11861,11 +11938,11 @@ pub mod api { pub fn disapprove_proposal( &self, proposal_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Council", "disapprove_proposal", - DisapproveProposal { proposal_hash }, + types::DisapproveProposal { proposal_hash }, [ 25u8, 123u8, 1u8, 8u8, 74u8, 37u8, 3u8, 40u8, 97u8, 37u8, 175u8, 224u8, 72u8, 155u8, 123u8, 109u8, 104u8, 43u8, 91u8, 125u8, 199u8, 51u8, 17u8, @@ -11903,11 +11980,11 @@ pub mod api { index: ::core::primitive::u32, proposal_weight_bound: runtime_types::sp_weights::weight_v2::Weight, length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Council", "close", - Close { + types::Close { proposal_hash, index, proposal_weight_bound, @@ -12418,11 +12495,11 @@ pub mod api { new_members: ::std::vec::Vec<::subxt::utils::AccountId32>, prime: ::core::option::Option<::subxt::utils::AccountId32>, old_count: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "TechnicalCommittee", "set_members", - SetMembers { + types::SetMembers { new_members, prime, old_count, @@ -12448,11 +12525,11 @@ pub mod api { &self, proposal: runtime_types::polkadot_runtime::RuntimeCall, length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "TechnicalCommittee", "execute", - Execute { + types::Execute { proposal: ::std::boxed::Box::new(proposal), length_bound, }, @@ -12482,11 +12559,11 @@ pub mod api { threshold: ::core::primitive::u32, proposal: runtime_types::polkadot_runtime::RuntimeCall, length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "TechnicalCommittee", "propose", - Propose { + types::Propose { threshold, proposal: ::std::boxed::Box::new(proposal), length_bound, @@ -12512,11 +12589,11 @@ pub mod api { proposal: ::subxt::utils::H256, index: ::core::primitive::u32, approve: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "TechnicalCommittee", "vote", - Vote { + types::Vote { proposal, index, approve, @@ -12541,11 +12618,11 @@ pub mod api { pub fn disapprove_proposal( &self, proposal_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "TechnicalCommittee", "disapprove_proposal", - DisapproveProposal { proposal_hash }, + types::DisapproveProposal { proposal_hash }, [ 25u8, 123u8, 1u8, 8u8, 74u8, 37u8, 3u8, 40u8, 97u8, 37u8, 175u8, 224u8, 72u8, 155u8, 123u8, 109u8, 104u8, 43u8, 91u8, 125u8, 199u8, 51u8, 17u8, @@ -12583,11 +12660,11 @@ pub mod api { index: ::core::primitive::u32, proposal_weight_bound: runtime_types::sp_weights::weight_v2::Weight, length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "TechnicalCommittee", "close", - Close { + types::Close { proposal_hash, index, proposal_weight_bound, @@ -12973,87 +13050,90 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vote { - pub votes: ::std::vec::Vec<::subxt::utils::AccountId32>, - #[codec(compact)] - pub value: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveVoter; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SubmitCandidacy { - #[codec(compact)] - pub candidate_count: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RenounceCandidacy { - pub renouncing: runtime_types::pallet_elections_phragmen::Renouncing, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveMember { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub slash_bond: ::core::primitive::bool, - pub rerun_election: ::core::primitive::bool, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CleanDefunctVoters { - pub num_voters: ::core::primitive::u32, - pub num_defunct: ::core::primitive::u32, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Vote { + pub votes: ::std::vec::Vec<::subxt::utils::AccountId32>, + #[codec(compact)] + pub value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveVoter; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SubmitCandidacy { + #[codec(compact)] + pub candidate_count: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RenounceCandidacy { + pub renouncing: runtime_types::pallet_elections_phragmen::Renouncing, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveMember { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub slash_bond: ::core::primitive::bool, + pub rerun_election: ::core::primitive::bool, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CleanDefunctVoters { + pub num_voters: ::core::primitive::u32, + pub num_defunct: ::core::primitive::u32, + } } pub struct TransactionApi; impl TransactionApi { @@ -13080,11 +13160,11 @@ pub mod api { &self, votes: ::std::vec::Vec<::subxt::utils::AccountId32>, value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "PhragmenElection", "vote", - Vote { votes, value }, + types::Vote { votes, value }, [ 71u8, 90u8, 175u8, 225u8, 51u8, 202u8, 197u8, 252u8, 183u8, 92u8, 239u8, 83u8, 112u8, 144u8, 128u8, 211u8, 109u8, 33u8, 252u8, 6u8, @@ -13098,11 +13178,11 @@ pub mod api { #[doc = "This removes the lock and returns the deposit."] #[doc = ""] #[doc = "The dispatch origin of this call must be signed and be a voter."] - pub fn remove_voter(&self) -> ::subxt::tx::Payload { + pub fn remove_voter(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "PhragmenElection", "remove_voter", - RemoveVoter {}, + types::RemoveVoter {}, [ 254u8, 46u8, 140u8, 4u8, 218u8, 45u8, 150u8, 72u8, 67u8, 131u8, 108u8, 201u8, 46u8, 157u8, 104u8, 161u8, 53u8, 155u8, 130u8, 50u8, 88u8, @@ -13128,11 +13208,11 @@ pub mod api { pub fn submit_candidacy( &self, candidate_count: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "PhragmenElection", "submit_candidacy", - SubmitCandidacy { candidate_count }, + types::SubmitCandidacy { candidate_count }, [ 228u8, 63u8, 217u8, 99u8, 128u8, 104u8, 175u8, 10u8, 30u8, 35u8, 47u8, 14u8, 254u8, 122u8, 146u8, 239u8, 61u8, 145u8, 82u8, 7u8, 181u8, 98u8, @@ -13163,11 +13243,11 @@ pub mod api { pub fn renounce_candidacy( &self, renouncing: runtime_types::pallet_elections_phragmen::Renouncing, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "PhragmenElection", "renounce_candidacy", - RenounceCandidacy { renouncing }, + types::RenounceCandidacy { renouncing }, [ 70u8, 72u8, 208u8, 36u8, 80u8, 245u8, 224u8, 75u8, 60u8, 142u8, 19u8, 49u8, 142u8, 90u8, 14u8, 69u8, 15u8, 61u8, 170u8, 235u8, 16u8, 252u8, @@ -13196,11 +13276,11 @@ pub mod api { who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, slash_bond: ::core::primitive::bool, rerun_election: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "PhragmenElection", "remove_member", - RemoveMember { + types::RemoveMember { who, slash_bond, rerun_election, @@ -13225,11 +13305,11 @@ pub mod api { &self, num_voters: ::core::primitive::u32, num_defunct: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "PhragmenElection", "clean_defunct_voters", - CleanDefunctVoters { + types::CleanDefunctVoters { num_voters, num_defunct, }, @@ -13729,96 +13809,99 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddMember { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveMember { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SwapMember { - pub remove: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub add: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ResetMembers { - pub members: ::std::vec::Vec<::subxt::utils::AccountId32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ChangeKey { - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetPrime { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddMember { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveMember { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SwapMember { + pub remove: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub add: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ResetMembers { + pub members: ::std::vec::Vec<::subxt::utils::AccountId32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ChangeKey { + pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetPrime { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClearPrime; } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClearPrime; pub struct TransactionApi; impl TransactionApi { #[doc = "Add a member `who` to the set."] @@ -13827,11 +13910,11 @@ pub mod api { pub fn add_member( &self, who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "TechnicalMembership", "add_member", - AddMember { who }, + types::AddMember { who }, [ 165u8, 116u8, 123u8, 50u8, 236u8, 196u8, 108u8, 211u8, 112u8, 214u8, 121u8, 105u8, 7u8, 88u8, 125u8, 99u8, 24u8, 0u8, 168u8, 65u8, 158u8, @@ -13846,11 +13929,11 @@ pub mod api { pub fn remove_member( &self, who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "TechnicalMembership", "remove_member", - RemoveMember { who }, + types::RemoveMember { who }, [ 177u8, 18u8, 217u8, 235u8, 254u8, 40u8, 137u8, 79u8, 146u8, 5u8, 55u8, 187u8, 129u8, 28u8, 54u8, 132u8, 115u8, 220u8, 132u8, 139u8, 91u8, @@ -13867,11 +13950,11 @@ pub mod api { &self, remove: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, add: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "TechnicalMembership", "swap_member", - SwapMember { remove, add }, + types::SwapMember { remove, add }, [ 96u8, 248u8, 50u8, 206u8, 192u8, 242u8, 162u8, 62u8, 28u8, 91u8, 11u8, 208u8, 15u8, 84u8, 188u8, 234u8, 219u8, 233u8, 200u8, 215u8, 157u8, @@ -13887,11 +13970,11 @@ pub mod api { pub fn reset_members( &self, members: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "TechnicalMembership", "reset_members", - ResetMembers { members }, + types::ResetMembers { members }, [ 9u8, 35u8, 28u8, 59u8, 158u8, 232u8, 89u8, 78u8, 101u8, 53u8, 240u8, 98u8, 13u8, 104u8, 235u8, 161u8, 201u8, 150u8, 117u8, 32u8, 75u8, @@ -13907,11 +13990,11 @@ pub mod api { pub fn change_key( &self, new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "TechnicalMembership", "change_key", - ChangeKey { new }, + types::ChangeKey { new }, [ 27u8, 236u8, 241u8, 168u8, 98u8, 39u8, 176u8, 220u8, 145u8, 48u8, 173u8, 25u8, 179u8, 103u8, 170u8, 13u8, 166u8, 181u8, 131u8, 160u8, @@ -13926,11 +14009,11 @@ pub mod api { pub fn set_prime( &self, who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "TechnicalMembership", "set_prime", - SetPrime { who }, + types::SetPrime { who }, [ 0u8, 42u8, 111u8, 52u8, 151u8, 19u8, 239u8, 149u8, 183u8, 252u8, 87u8, 194u8, 145u8, 21u8, 245u8, 112u8, 221u8, 181u8, 87u8, 28u8, 48u8, 39u8, @@ -13941,11 +14024,11 @@ pub mod api { #[doc = "Remove the prime member if it exists."] #[doc = ""] #[doc = "May only be called from `T::PrimeOrigin`."] - pub fn clear_prime(&self) -> ::subxt::tx::Payload { + pub fn clear_prime(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "TechnicalMembership", "clear_prime", - ClearPrime {}, + types::ClearPrime {}, [ 186u8, 182u8, 225u8, 90u8, 71u8, 124u8, 69u8, 100u8, 234u8, 25u8, 53u8, 23u8, 182u8, 32u8, 176u8, 81u8, 54u8, 140u8, 235u8, 126u8, 247u8, 7u8, @@ -14118,77 +14201,80 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeSpend { - #[codec(compact)] - pub value: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RejectProposal { - #[codec(compact)] - pub proposal_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApproveProposal { - #[codec(compact)] - pub proposal_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Spend { - #[codec(compact)] - pub amount: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveApproval { - #[codec(compact)] - pub proposal_id: ::core::primitive::u32, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProposeSpend { + #[codec(compact)] + pub value: ::core::primitive::u128, + pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RejectProposal { + #[codec(compact)] + pub proposal_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ApproveProposal { + #[codec(compact)] + pub proposal_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Spend { + #[codec(compact)] + pub amount: ::core::primitive::u128, + pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveApproval { + #[codec(compact)] + pub proposal_id: ::core::primitive::u32, + } } pub struct TransactionApi; impl TransactionApi { @@ -14202,11 +14288,11 @@ pub mod api { &self, value: ::core::primitive::u128, beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Treasury", "propose_spend", - ProposeSpend { value, beneficiary }, + types::ProposeSpend { value, beneficiary }, [ 109u8, 46u8, 8u8, 159u8, 127u8, 79u8, 27u8, 100u8, 92u8, 244u8, 78u8, 46u8, 105u8, 246u8, 169u8, 210u8, 149u8, 7u8, 108u8, 153u8, 203u8, @@ -14223,11 +14309,11 @@ pub mod api { pub fn reject_proposal( &self, proposal_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Treasury", "reject_proposal", - RejectProposal { proposal_id }, + types::RejectProposal { proposal_id }, [ 106u8, 223u8, 97u8, 22u8, 111u8, 208u8, 128u8, 26u8, 198u8, 140u8, 118u8, 126u8, 187u8, 51u8, 193u8, 50u8, 193u8, 68u8, 143u8, 144u8, @@ -14246,11 +14332,11 @@ pub mod api { pub fn approve_proposal( &self, proposal_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Treasury", "approve_proposal", - ApproveProposal { proposal_id }, + types::ApproveProposal { proposal_id }, [ 164u8, 229u8, 172u8, 98u8, 129u8, 62u8, 84u8, 128u8, 47u8, 108u8, 33u8, 120u8, 89u8, 79u8, 57u8, 121u8, 4u8, 197u8, 170u8, 153u8, 156u8, 17u8, @@ -14270,11 +14356,11 @@ pub mod api { &self, amount: ::core::primitive::u128, beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Treasury", "spend", - Spend { + types::Spend { amount, beneficiary, }, @@ -14301,11 +14387,11 @@ pub mod api { pub fn remove_approval( &self, proposal_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Treasury", "remove_approval", - RemoveApproval { proposal_id }, + types::RemoveApproval { proposal_id }, [ 133u8, 126u8, 181u8, 47u8, 196u8, 243u8, 7u8, 46u8, 25u8, 251u8, 154u8, 125u8, 217u8, 77u8, 54u8, 245u8, 240u8, 180u8, 97u8, 34u8, 186u8, 53u8, @@ -16535,86 +16621,89 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Claim { - pub dest: ::subxt::utils::AccountId32, - pub ethereum_signature: - runtime_types::polkadot_runtime_common::claims::EcdsaSignature, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MintClaim { - pub who: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub value: ::core::primitive::u128, - pub vesting_schedule: ::core::option::Option<( - ::core::primitive::u128, - ::core::primitive::u128, - ::core::primitive::u32, - )>, - pub statement: ::core::option::Option< - runtime_types::polkadot_runtime_common::claims::StatementKind, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimAttest { - pub dest: ::subxt::utils::AccountId32, - pub ethereum_signature: - runtime_types::polkadot_runtime_common::claims::EcdsaSignature, - pub statement: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Attest { - pub statement: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MoveClaim { - pub old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Claim { + pub dest: ::subxt::utils::AccountId32, + pub ethereum_signature: + runtime_types::polkadot_runtime_common::claims::EcdsaSignature, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MintClaim { + pub who: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + pub value: ::core::primitive::u128, + pub vesting_schedule: ::core::option::Option<( + ::core::primitive::u128, + ::core::primitive::u128, + ::core::primitive::u32, + )>, + pub statement: ::core::option::Option< + runtime_types::polkadot_runtime_common::claims::StatementKind, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClaimAttest { + pub dest: ::subxt::utils::AccountId32, + pub ethereum_signature: + runtime_types::polkadot_runtime_common::claims::EcdsaSignature, + pub statement: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Attest { + pub statement: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MoveClaim { + pub old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + pub new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + pub maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, + } } pub struct TransactionApi; impl TransactionApi { @@ -16646,11 +16735,11 @@ pub mod api { &self, dest: ::subxt::utils::AccountId32, ethereum_signature : runtime_types :: polkadot_runtime_common :: claims :: EcdsaSignature, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Claims", "claim", - Claim { + types::Claim { dest, ethereum_signature, }, @@ -16688,11 +16777,11 @@ pub mod api { statement: ::core::option::Option< runtime_types::polkadot_runtime_common::claims::StatementKind, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Claims", "mint_claim", - MintClaim { + types::MintClaim { who, value, vesting_schedule, @@ -16736,11 +16825,11 @@ pub mod api { dest: ::subxt::utils::AccountId32, ethereum_signature : runtime_types :: polkadot_runtime_common :: claims :: EcdsaSignature, statement: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Claims", "claim_attest", - ClaimAttest { + types::ClaimAttest { dest, ethereum_signature, statement, @@ -16773,11 +16862,11 @@ pub mod api { pub fn attest( &self, statement: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Claims", "attest", - Attest { statement }, + types::Attest { statement }, [ 8u8, 218u8, 97u8, 237u8, 185u8, 61u8, 55u8, 4u8, 134u8, 18u8, 244u8, 226u8, 40u8, 97u8, 222u8, 246u8, 221u8, 74u8, 253u8, 22u8, 52u8, 223u8, @@ -16790,11 +16879,11 @@ pub mod api { old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Claims", "move_claim", - MoveClaim { + types::MoveClaim { old, new, maybe_preclaim, @@ -17094,78 +17183,81 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vest; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VestOther { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VestedTransfer { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceVestedTransfer { - pub source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MergeSchedules { - pub schedule1_index: ::core::primitive::u32, - pub schedule2_index: ::core::primitive::u32, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Vest; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct VestOther { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct VestedTransfer { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceVestedTransfer { + pub source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MergeSchedules { + pub schedule1_index: ::core::primitive::u32, + pub schedule2_index: ::core::primitive::u32, + } } pub struct TransactionApi; impl TransactionApi { @@ -17182,7 +17274,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "Vesting", "vest", - Vest {}, + types::Vest {}, [ 123u8, 54u8, 10u8, 208u8, 154u8, 24u8, 39u8, 166u8, 64u8, 27u8, 74u8, 29u8, 243u8, 97u8, 155u8, 5u8, 130u8, 155u8, 65u8, 181u8, 196u8, 125u8, @@ -17204,11 +17296,11 @@ pub mod api { pub fn vest_other( &self, target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Vesting", "vest_other", - VestOther { target }, + types::VestOther { target }, [ 164u8, 19u8, 93u8, 81u8, 235u8, 101u8, 18u8, 52u8, 187u8, 81u8, 243u8, 216u8, 116u8, 84u8, 188u8, 135u8, 1u8, 241u8, 128u8, 90u8, 117u8, @@ -17237,11 +17329,11 @@ pub mod api { ::core::primitive::u128, ::core::primitive::u32, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Vesting", "vested_transfer", - VestedTransfer { target, schedule }, + types::VestedTransfer { target, schedule }, [ 135u8, 172u8, 56u8, 97u8, 45u8, 141u8, 93u8, 173u8, 111u8, 252u8, 75u8, 246u8, 92u8, 181u8, 138u8, 87u8, 145u8, 174u8, 71u8, 108u8, 126u8, @@ -17272,11 +17364,11 @@ pub mod api { ::core::primitive::u128, ::core::primitive::u32, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Vesting", "force_vested_transfer", - ForceVestedTransfer { + types::ForceVestedTransfer { source, target, schedule, @@ -17313,11 +17405,11 @@ pub mod api { &self, schedule1_index: ::core::primitive::u32, schedule2_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Vesting", "merge_schedules", - MergeSchedules { + types::MergeSchedules { schedule1_index, schedule2_index, }, @@ -17502,72 +17594,89 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Batch { - pub calls: ::std::vec::Vec, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsDerivative { - pub index: ::core::primitive::u16, - pub call: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BatchAll { - pub calls: ::std::vec::Vec, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DispatchAs { - pub as_origin: ::std::boxed::Box, - pub call: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceBatch { - pub calls: ::std::vec::Vec, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Batch { + pub calls: ::std::vec::Vec, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AsDerivative { + pub index: ::core::primitive::u16, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BatchAll { + pub calls: ::std::vec::Vec, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DispatchAs { + pub as_origin: ::std::boxed::Box, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceBatch { + pub calls: ::std::vec::Vec, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct WithWeight { + pub call: ::std::boxed::Box, + pub weight: runtime_types::sp_weights::weight_v2::Weight, + } } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17606,11 +17715,11 @@ pub mod api { pub fn batch( &self, calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Utility", "batch", - Batch { calls }, + types::Batch { calls }, [ 221u8, 151u8, 56u8, 10u8, 237u8, 176u8, 153u8, 88u8, 29u8, 225u8, 27u8, 231u8, 98u8, 222u8, 51u8, 94u8, 88u8, 16u8, 40u8, 253u8, 61u8, 35u8, @@ -17635,11 +17744,11 @@ pub mod api { &self, index: ::core::primitive::u16, call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Utility", "as_derivative", - AsDerivative { + types::AsDerivative { index, call: ::std::boxed::Box::new(call), }, @@ -17666,11 +17775,11 @@ pub mod api { pub fn batch_all( &self, calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Utility", "batch_all", - BatchAll { calls }, + types::BatchAll { calls }, [ 255u8, 107u8, 81u8, 108u8, 78u8, 19u8, 231u8, 220u8, 177u8, 177u8, 28u8, 24u8, 100u8, 228u8, 227u8, 45u8, 3u8, 51u8, 132u8, 12u8, 48u8, @@ -17689,11 +17798,11 @@ pub mod api { &self, as_origin: runtime_types::polkadot_runtime::OriginCaller, call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Utility", "dispatch_as", - DispatchAs { + types::DispatchAs { as_origin: ::std::boxed::Box::new(as_origin), call: ::std::boxed::Box::new(call), }, @@ -17720,11 +17829,11 @@ pub mod api { pub fn force_batch( &self, calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Utility", "force_batch", - ForceBatch { calls }, + types::ForceBatch { calls }, [ 183u8, 158u8, 12u8, 76u8, 9u8, 251u8, 54u8, 89u8, 139u8, 70u8, 51u8, 72u8, 181u8, 28u8, 110u8, 207u8, 211u8, 236u8, 224u8, 44u8, 104u8, @@ -17901,220 +18010,224 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddRegistrar { - pub account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetIdentity { - pub info: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetSubs { - pub subs: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::pallet_identity::types::Data, - )>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClearIdentity; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RequestJudgement { - #[codec(compact)] - pub reg_index: ::core::primitive::u32, - #[codec(compact)] - pub max_fee: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelRequest { - pub reg_index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetFee { - #[codec(compact)] - pub index: ::core::primitive::u32, - #[codec(compact)] - pub fee: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetAccountId { - #[codec(compact)] - pub index: ::core::primitive::u32, - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetFields { - #[codec(compact)] - pub index: ::core::primitive::u32, - pub fields: runtime_types::pallet_identity::types::BitFlags< - runtime_types::pallet_identity::types::IdentityField, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProvideJudgement { - #[codec(compact)] - pub reg_index: ::core::primitive::u32, - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub judgement: - runtime_types::pallet_identity::types::Judgement<::core::primitive::u128>, - pub identity: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillIdentity { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddSub { - pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub data: runtime_types::pallet_identity::types::Data, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RenameSub { - pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub data: runtime_types::pallet_identity::types::Data, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveSub { - pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddRegistrar { + pub account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetIdentity { + pub info: + ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetSubs { + pub subs: ::std::vec::Vec<( + ::subxt::utils::AccountId32, + runtime_types::pallet_identity::types::Data, + )>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClearIdentity; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RequestJudgement { + #[codec(compact)] + pub reg_index: ::core::primitive::u32, + #[codec(compact)] + pub max_fee: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelRequest { + pub reg_index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetFee { + #[codec(compact)] + pub index: ::core::primitive::u32, + #[codec(compact)] + pub fee: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetAccountId { + #[codec(compact)] + pub index: ::core::primitive::u32, + pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetFields { + #[codec(compact)] + pub index: ::core::primitive::u32, + pub fields: runtime_types::pallet_identity::types::BitFlags< + runtime_types::pallet_identity::types::IdentityField, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProvideJudgement { + #[codec(compact)] + pub reg_index: ::core::primitive::u32, + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub judgement: + runtime_types::pallet_identity::types::Judgement<::core::primitive::u128>, + pub identity: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct KillIdentity { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddSub { + pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub data: runtime_types::pallet_identity::types::Data, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RenameSub { + pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub data: runtime_types::pallet_identity::types::Data, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveSub { + pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QuitSub; } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QuitSub; pub struct TransactionApi; impl TransactionApi { #[doc = "Add a registrar to the system."] @@ -18130,11 +18243,11 @@ pub mod api { pub fn add_registrar( &self, account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "add_registrar", - AddRegistrar { account }, + types::AddRegistrar { account }, [ 157u8, 232u8, 252u8, 190u8, 203u8, 233u8, 127u8, 63u8, 111u8, 16u8, 118u8, 200u8, 31u8, 234u8, 144u8, 111u8, 161u8, 224u8, 217u8, 86u8, @@ -18161,11 +18274,11 @@ pub mod api { pub fn set_identity( &self, info: runtime_types::pallet_identity::types::IdentityInfo, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "set_identity", - SetIdentity { + types::SetIdentity { info: ::std::boxed::Box::new(info), }, [ @@ -18195,11 +18308,11 @@ pub mod api { ::subxt::utils::AccountId32, runtime_types::pallet_identity::types::Data, )>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "set_subs", - SetSubs { subs }, + types::SetSubs { subs }, [ 177u8, 219u8, 84u8, 183u8, 5u8, 32u8, 192u8, 82u8, 174u8, 68u8, 198u8, 224u8, 56u8, 85u8, 134u8, 171u8, 30u8, 132u8, 140u8, 236u8, 117u8, @@ -18226,7 +18339,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "Identity", "clear_identity", - ClearIdentity {}, + types::ClearIdentity {}, [ 75u8, 44u8, 74u8, 122u8, 149u8, 202u8, 114u8, 230u8, 0u8, 255u8, 140u8, 122u8, 14u8, 196u8, 205u8, 249u8, 220u8, 94u8, 216u8, 34u8, 63u8, 14u8, @@ -18259,11 +18372,11 @@ pub mod api { &self, reg_index: ::core::primitive::u32, max_fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "request_judgement", - RequestJudgement { reg_index, max_fee }, + types::RequestJudgement { reg_index, max_fee }, [ 186u8, 149u8, 61u8, 54u8, 159u8, 194u8, 77u8, 161u8, 220u8, 157u8, 3u8, 216u8, 23u8, 105u8, 119u8, 76u8, 144u8, 198u8, 157u8, 45u8, 235u8, @@ -18289,11 +18402,11 @@ pub mod api { pub fn cancel_request( &self, reg_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "cancel_request", - CancelRequest { reg_index }, + types::CancelRequest { reg_index }, [ 83u8, 180u8, 239u8, 126u8, 32u8, 51u8, 17u8, 20u8, 180u8, 3u8, 59u8, 96u8, 24u8, 32u8, 136u8, 92u8, 58u8, 254u8, 68u8, 70u8, 50u8, 11u8, @@ -18316,11 +18429,11 @@ pub mod api { &self, index: ::core::primitive::u32, fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "set_fee", - SetFee { index, fee }, + types::SetFee { index, fee }, [ 21u8, 157u8, 123u8, 182u8, 160u8, 190u8, 117u8, 37u8, 136u8, 133u8, 104u8, 234u8, 31u8, 145u8, 115u8, 154u8, 125u8, 40u8, 2u8, 87u8, 118u8, @@ -18343,11 +18456,11 @@ pub mod api { &self, index: ::core::primitive::u32, new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "set_account_id", - SetAccountId { index, new }, + types::SetAccountId { index, new }, [ 13u8, 91u8, 36u8, 7u8, 88u8, 64u8, 151u8, 104u8, 94u8, 174u8, 195u8, 99u8, 97u8, 181u8, 236u8, 251u8, 26u8, 236u8, 234u8, 40u8, 183u8, 38u8, @@ -18372,11 +18485,11 @@ pub mod api { fields: runtime_types::pallet_identity::types::BitFlags< runtime_types::pallet_identity::types::IdentityField, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "set_fields", - SetFields { index, fields }, + types::SetFields { index, fields }, [ 50u8, 196u8, 179u8, 71u8, 66u8, 65u8, 235u8, 7u8, 51u8, 14u8, 81u8, 173u8, 201u8, 58u8, 6u8, 151u8, 174u8, 245u8, 102u8, 184u8, 28u8, 84u8, @@ -18409,11 +18522,11 @@ pub mod api { ::core::primitive::u128, >, identity: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "provide_judgement", - ProvideJudgement { + types::ProvideJudgement { reg_index, target, judgement, @@ -18447,11 +18560,11 @@ pub mod api { pub fn kill_identity( &self, target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "kill_identity", - KillIdentity { target }, + types::KillIdentity { target }, [ 76u8, 13u8, 158u8, 219u8, 221u8, 0u8, 151u8, 241u8, 137u8, 136u8, 179u8, 194u8, 188u8, 230u8, 56u8, 16u8, 254u8, 28u8, 127u8, 216u8, @@ -18471,11 +18584,11 @@ pub mod api { &self, sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, data: runtime_types::pallet_identity::types::Data, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "add_sub", - AddSub { sub, data }, + types::AddSub { sub, data }, [ 122u8, 218u8, 25u8, 93u8, 33u8, 176u8, 191u8, 254u8, 223u8, 147u8, 100u8, 135u8, 86u8, 71u8, 47u8, 163u8, 105u8, 222u8, 162u8, 173u8, @@ -18492,11 +18605,11 @@ pub mod api { &self, sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, data: runtime_types::pallet_identity::types::Data, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "rename_sub", - RenameSub { sub, data }, + types::RenameSub { sub, data }, [ 166u8, 167u8, 49u8, 114u8, 199u8, 168u8, 187u8, 221u8, 100u8, 85u8, 147u8, 211u8, 157u8, 31u8, 109u8, 135u8, 194u8, 135u8, 15u8, 89u8, @@ -18515,11 +18628,11 @@ pub mod api { pub fn remove_sub( &self, sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "remove_sub", - RemoveSub { sub }, + types::RemoveSub { sub }, [ 106u8, 223u8, 210u8, 67u8, 54u8, 11u8, 144u8, 222u8, 42u8, 46u8, 157u8, 33u8, 13u8, 245u8, 166u8, 195u8, 227u8, 81u8, 224u8, 149u8, 154u8, @@ -18538,11 +18651,11 @@ pub mod api { #[doc = ""] #[doc = "NOTE: This should not normally be used, but is provided in the case that the non-"] #[doc = "controller of an account is maliciously registered as a sub-account."] - pub fn quit_sub(&self) -> ::subxt::tx::Payload { + pub fn quit_sub(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Identity", "quit_sub", - QuitSub {}, + types::QuitSub {}, [ 62u8, 57u8, 73u8, 72u8, 119u8, 216u8, 250u8, 155u8, 57u8, 169u8, 157u8, 44u8, 87u8, 51u8, 63u8, 231u8, 77u8, 7u8, 0u8, 119u8, 244u8, 42u8, @@ -19064,155 +19177,158 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Proxy { - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub force_proxy_type: - ::core::option::Option, - pub call: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddProxy { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub delay: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveProxy { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub delay: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveProxies; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CreatePure { - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub delay: ::core::primitive::u32, - pub index: ::core::primitive::u16, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillPure { - pub spawner: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub index: ::core::primitive::u16, - #[codec(compact)] - pub height: ::core::primitive::u32, - #[codec(compact)] - pub ext_index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Announce { - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call_hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveAnnouncement { - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call_hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RejectAnnouncement { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call_hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProxyAnnounced { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub force_proxy_type: - ::core::option::Option, - pub call: ::std::boxed::Box, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Proxy { + pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub force_proxy_type: + ::core::option::Option, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddProxy { + pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub delay: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveProxy { + pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub delay: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveProxies; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CreatePure { + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub delay: ::core::primitive::u32, + pub index: ::core::primitive::u16, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct KillPure { + pub spawner: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub index: ::core::primitive::u16, + #[codec(compact)] + pub height: ::core::primitive::u32, + #[codec(compact)] + pub ext_index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Announce { + pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub call_hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveAnnouncement { + pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub call_hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RejectAnnouncement { + pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub call_hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProxyAnnounced { + pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub force_proxy_type: + ::core::option::Option, + pub call: ::std::boxed::Box, + } } pub struct TransactionApi; impl TransactionApi { @@ -19232,11 +19348,11 @@ pub mod api { runtime_types::polkadot_runtime::ProxyType, >, call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Proxy", "proxy", - Proxy { + types::Proxy { real, force_proxy_type, call: ::std::boxed::Box::new(call), @@ -19263,11 +19379,11 @@ pub mod api { delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, proxy_type: runtime_types::polkadot_runtime::ProxyType, delay: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Proxy", "add_proxy", - AddProxy { + types::AddProxy { delegate, proxy_type, delay, @@ -19291,11 +19407,11 @@ pub mod api { delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, proxy_type: runtime_types::polkadot_runtime::ProxyType, delay: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Proxy", "remove_proxy", - RemoveProxy { + types::RemoveProxy { delegate, proxy_type, delay, @@ -19313,11 +19429,11 @@ pub mod api { #[doc = ""] #[doc = "WARNING: This may be called on accounts created by `pure`, however if done, then"] #[doc = "the unreserved fees will be inaccessible. **All access to this account will be lost.**"] - pub fn remove_proxies(&self) -> ::subxt::tx::Payload { + pub fn remove_proxies(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Proxy", "remove_proxies", - RemoveProxies {}, + types::RemoveProxies {}, [ 15u8, 237u8, 27u8, 166u8, 254u8, 218u8, 92u8, 5u8, 213u8, 239u8, 99u8, 59u8, 1u8, 26u8, 73u8, 252u8, 81u8, 94u8, 214u8, 227u8, 169u8, 58u8, @@ -19348,11 +19464,11 @@ pub mod api { proxy_type: runtime_types::polkadot_runtime::ProxyType, delay: ::core::primitive::u32, index: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Proxy", "create_pure", - CreatePure { + types::CreatePure { proxy_type, delay, index, @@ -19387,11 +19503,11 @@ pub mod api { index: ::core::primitive::u16, height: ::core::primitive::u32, ext_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Proxy", "kill_pure", - KillPure { + types::KillPure { spawner, proxy_type, index, @@ -19425,11 +19541,11 @@ pub mod api { &self, real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Proxy", "announce", - Announce { real, call_hash }, + types::Announce { real, call_hash }, [ 235u8, 116u8, 208u8, 53u8, 128u8, 91u8, 100u8, 68u8, 255u8, 254u8, 119u8, 253u8, 108u8, 130u8, 88u8, 56u8, 113u8, 99u8, 105u8, 179u8, @@ -19452,11 +19568,11 @@ pub mod api { &self, real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Proxy", "remove_announcement", - RemoveAnnouncement { real, call_hash }, + types::RemoveAnnouncement { real, call_hash }, [ 140u8, 186u8, 140u8, 129u8, 40u8, 124u8, 57u8, 61u8, 84u8, 247u8, 123u8, 241u8, 148u8, 15u8, 94u8, 146u8, 121u8, 78u8, 190u8, 68u8, @@ -19479,11 +19595,11 @@ pub mod api { &self, delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Proxy", "reject_announcement", - RejectAnnouncement { + types::RejectAnnouncement { delegate, call_hash, }, @@ -19514,11 +19630,11 @@ pub mod api { runtime_types::polkadot_runtime::ProxyType, >, call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Proxy", "proxy_announced", - ProxyAnnounced { + types::ProxyAnnounced { delegate, real, force_proxy_type, @@ -19889,73 +20005,77 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsMultiThreshold1 { - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub call: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - pub call: ::std::boxed::Box, - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApproveAsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - pub call_hash: [::core::primitive::u8; 32usize], - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelAsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub call_hash: [::core::primitive::u8; 32usize], + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AsMultiThreshold1 { + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AsMulti { + pub threshold: ::core::primitive::u16, + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + >, + pub call: ::std::boxed::Box, + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ApproveAsMulti { + pub threshold: ::core::primitive::u16, + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + >, + pub call_hash: [::core::primitive::u8; 32usize], + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelAsMulti { + pub threshold: ::core::primitive::u16, + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub timepoint: + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub call_hash: [::core::primitive::u8; 32usize], + } } pub struct TransactionApi; impl TransactionApi { @@ -19975,11 +20095,11 @@ pub mod api { &self, other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Multisig", "as_multi_threshold_1", - AsMultiThreshold1 { + types::AsMultiThreshold1 { other_signatories, call: ::std::boxed::Box::new(call), }, @@ -20039,11 +20159,11 @@ pub mod api { >, call: runtime_types::polkadot_runtime::RuntimeCall, max_weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Multisig", "as_multi", - AsMulti { + types::AsMulti { threshold, other_signatories, maybe_timepoint, @@ -20097,11 +20217,11 @@ pub mod api { >, call_hash: [::core::primitive::u8; 32usize], max_weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Multisig", "approve_as_multi", - ApproveAsMulti { + types::ApproveAsMulti { threshold, other_signatories, maybe_timepoint, @@ -20143,11 +20263,11 @@ pub mod api { other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, call_hash: [::core::primitive::u8; 32usize], - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Multisig", "cancel_as_multi", - CancelAsMulti { + types::CancelAsMulti { threshold, other_signatories, timepoint, @@ -20377,137 +20497,140 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeBounty { - #[codec(compact)] - pub value: ::core::primitive::u128, - pub description: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApproveBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeCurator { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub fee: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnassignCurator { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AcceptCurator { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AwardBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExtendBountyExpiry { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - pub remark: ::std::vec::Vec<::core::primitive::u8>, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProposeBounty { + #[codec(compact)] + pub value: ::core::primitive::u128, + pub description: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ApproveBounty { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProposeCurator { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub fee: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UnassignCurator { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AcceptCurator { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AwardBounty { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClaimBounty { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CloseBounty { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ExtendBountyExpiry { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + pub remark: ::std::vec::Vec<::core::primitive::u8>, + } } pub struct TransactionApi; impl TransactionApi { @@ -20527,11 +20650,11 @@ pub mod api { &self, value: ::core::primitive::u128, description: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Bounties", "propose_bounty", - ProposeBounty { value, description }, + types::ProposeBounty { value, description }, [ 99u8, 160u8, 94u8, 74u8, 105u8, 161u8, 123u8, 239u8, 241u8, 117u8, 97u8, 99u8, 84u8, 101u8, 87u8, 3u8, 88u8, 175u8, 75u8, 59u8, 114u8, @@ -20550,11 +20673,11 @@ pub mod api { pub fn approve_bounty( &self, bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Bounties", "approve_bounty", - ApproveBounty { bounty_id }, + types::ApproveBounty { bounty_id }, [ 82u8, 228u8, 232u8, 103u8, 198u8, 173u8, 190u8, 148u8, 159u8, 86u8, 48u8, 4u8, 32u8, 169u8, 1u8, 129u8, 96u8, 145u8, 235u8, 68u8, 48u8, @@ -20573,11 +20696,11 @@ pub mod api { bounty_id: ::core::primitive::u32, curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Bounties", "propose_curator", - ProposeCurator { + types::ProposeCurator { bounty_id, curator, fee, @@ -20610,11 +20733,11 @@ pub mod api { pub fn unassign_curator( &self, bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Bounties", "unassign_curator", - UnassignCurator { bounty_id }, + types::UnassignCurator { bounty_id }, [ 218u8, 241u8, 247u8, 89u8, 95u8, 120u8, 93u8, 18u8, 85u8, 114u8, 158u8, 254u8, 68u8, 77u8, 230u8, 186u8, 230u8, 201u8, 63u8, 223u8, 28u8, @@ -20633,11 +20756,11 @@ pub mod api { pub fn accept_curator( &self, bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Bounties", "accept_curator", - AcceptCurator { bounty_id }, + types::AcceptCurator { bounty_id }, [ 106u8, 96u8, 22u8, 67u8, 52u8, 109u8, 180u8, 225u8, 122u8, 253u8, 209u8, 214u8, 132u8, 131u8, 247u8, 131u8, 162u8, 51u8, 144u8, 30u8, @@ -20660,11 +20783,11 @@ pub mod api { &self, bounty_id: ::core::primitive::u32, beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Bounties", "award_bounty", - AwardBounty { + types::AwardBounty { bounty_id, beneficiary, }, @@ -20686,11 +20809,11 @@ pub mod api { pub fn claim_bounty( &self, bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Bounties", "claim_bounty", - ClaimBounty { bounty_id }, + types::ClaimBounty { bounty_id }, [ 102u8, 95u8, 8u8, 89u8, 4u8, 126u8, 189u8, 28u8, 241u8, 16u8, 125u8, 218u8, 42u8, 92u8, 177u8, 91u8, 8u8, 235u8, 33u8, 48u8, 64u8, 115u8, @@ -20710,11 +20833,11 @@ pub mod api { pub fn close_bounty( &self, bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Bounties", "close_bounty", - CloseBounty { bounty_id }, + types::CloseBounty { bounty_id }, [ 64u8, 113u8, 151u8, 228u8, 90u8, 55u8, 251u8, 63u8, 27u8, 211u8, 119u8, 229u8, 137u8, 137u8, 183u8, 240u8, 241u8, 146u8, 69u8, 169u8, 124u8, @@ -20736,11 +20859,11 @@ pub mod api { &self, bounty_id: ::core::primitive::u32, remark: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Bounties", "extend_bounty_expiry", - ExtendBountyExpiry { bounty_id, remark }, + types::ExtendBountyExpiry { bounty_id, remark }, [ 97u8, 69u8, 157u8, 39u8, 59u8, 72u8, 79u8, 88u8, 104u8, 119u8, 91u8, 26u8, 73u8, 216u8, 174u8, 95u8, 254u8, 214u8, 63u8, 138u8, 100u8, @@ -21199,122 +21322,125 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub value: ::core::primitive::u128, - pub description: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeCurator { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub fee: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AcceptCurator { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnassignCurator { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AwardChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddChildBounty { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub value: ::core::primitive::u128, + pub description: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProposeCurator { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, + pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub fee: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AcceptCurator { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UnassignCurator { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AwardChildBounty { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, + pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClaimChildBounty { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CloseChildBounty { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, + } } pub struct TransactionApi; impl TransactionApi { @@ -21342,11 +21468,11 @@ pub mod api { parent_bounty_id: ::core::primitive::u32, value: ::core::primitive::u128, description: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ChildBounties", "add_child_bounty", - AddChildBounty { + types::AddChildBounty { parent_bounty_id, value, description, @@ -21379,11 +21505,11 @@ pub mod api { child_bounty_id: ::core::primitive::u32, curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ChildBounties", "propose_curator", - ProposeCurator { + types::ProposeCurator { parent_bounty_id, child_bounty_id, curator, @@ -21419,11 +21545,11 @@ pub mod api { &self, parent_bounty_id: ::core::primitive::u32, child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ChildBounties", "accept_curator", - AcceptCurator { + types::AcceptCurator { parent_bounty_id, child_bounty_id, }, @@ -21473,11 +21599,11 @@ pub mod api { &self, parent_bounty_id: ::core::primitive::u32, child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ChildBounties", "unassign_curator", - UnassignCurator { + types::UnassignCurator { parent_bounty_id, child_bounty_id, }, @@ -21511,11 +21637,11 @@ pub mod api { parent_bounty_id: ::core::primitive::u32, child_bounty_id: ::core::primitive::u32, beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ChildBounties", "award_child_bounty", - AwardChildBounty { + types::AwardChildBounty { parent_bounty_id, child_bounty_id, beneficiary, @@ -21548,11 +21674,11 @@ pub mod api { &self, parent_bounty_id: ::core::primitive::u32, child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ChildBounties", "claim_child_bounty", - ClaimChildBounty { + types::ClaimChildBounty { parent_bounty_id, child_bounty_id, }, @@ -21590,11 +21716,11 @@ pub mod api { &self, parent_bounty_id: ::core::primitive::u32, child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ChildBounties", "close_child_bounty", - CloseChildBounty { + types::CloseChildBounty { parent_bounty_id, child_bounty_id, }, @@ -21966,89 +22092,92 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportAwesome { - pub reason: ::std::vec::Vec<::core::primitive::u8>, - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RetractTip { - pub hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TipNew { - pub reason: ::std::vec::Vec<::core::primitive::u8>, - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub tip_value: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Tip { - pub hash: ::subxt::utils::H256, - #[codec(compact)] - pub tip_value: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseTip { - pub hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SlashTip { - pub hash: ::subxt::utils::H256, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReportAwesome { + pub reason: ::std::vec::Vec<::core::primitive::u8>, + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RetractTip { + pub hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TipNew { + pub reason: ::std::vec::Vec<::core::primitive::u8>, + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub tip_value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Tip { + pub hash: ::subxt::utils::H256, + #[codec(compact)] + pub tip_value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CloseTip { + pub hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SlashTip { + pub hash: ::subxt::utils::H256, + } } pub struct TransactionApi; impl TransactionApi { @@ -22072,11 +22201,11 @@ pub mod api { &self, reason: ::std::vec::Vec<::core::primitive::u8>, who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Tips", "report_awesome", - ReportAwesome { reason, who }, + types::ReportAwesome { reason, who }, [ 126u8, 68u8, 2u8, 54u8, 195u8, 15u8, 43u8, 27u8, 183u8, 254u8, 157u8, 163u8, 252u8, 14u8, 207u8, 251u8, 215u8, 111u8, 98u8, 209u8, 150u8, @@ -22103,11 +22232,11 @@ pub mod api { pub fn retract_tip( &self, hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Tips", "retract_tip", - RetractTip { hash }, + types::RetractTip { hash }, [ 137u8, 42u8, 229u8, 188u8, 157u8, 195u8, 184u8, 176u8, 64u8, 142u8, 67u8, 175u8, 185u8, 207u8, 214u8, 71u8, 165u8, 29u8, 137u8, 227u8, @@ -22140,11 +22269,11 @@ pub mod api { reason: ::std::vec::Vec<::core::primitive::u8>, who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, tip_value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Tips", "tip_new", - TipNew { + types::TipNew { reason, who, tip_value, @@ -22182,11 +22311,11 @@ pub mod api { &self, hash: ::subxt::utils::H256, tip_value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Tips", "tip", - Tip { hash, tip_value }, + types::Tip { hash, tip_value }, [ 133u8, 52u8, 131u8, 14u8, 71u8, 232u8, 254u8, 31u8, 33u8, 206u8, 50u8, 76u8, 56u8, 167u8, 228u8, 202u8, 195u8, 0u8, 164u8, 107u8, 170u8, 98u8, @@ -22210,11 +22339,11 @@ pub mod api { pub fn close_tip( &self, hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Tips", "close_tip", - CloseTip { hash }, + types::CloseTip { hash }, [ 32u8, 53u8, 0u8, 222u8, 45u8, 157u8, 107u8, 174u8, 203u8, 50u8, 81u8, 230u8, 6u8, 111u8, 79u8, 55u8, 49u8, 151u8, 107u8, 114u8, 81u8, 200u8, @@ -22235,11 +22364,11 @@ pub mod api { pub fn slash_tip( &self, hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Tips", "slash_tip", - SlashTip { hash }, + types::SlashTip { hash }, [ 222u8, 209u8, 22u8, 47u8, 114u8, 230u8, 81u8, 200u8, 131u8, 0u8, 209u8, 54u8, 17u8, 200u8, 175u8, 125u8, 100u8, 254u8, 41u8, 178u8, 20u8, 27u8, @@ -22551,85 +22680,88 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SubmitUnsigned { - pub raw_solution: ::std::boxed::Box< - runtime_types::pallet_election_provider_multi_phase::RawSolution< - runtime_types::polkadot_runtime::NposCompactSolution16, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SubmitUnsigned { + pub raw_solution: ::std::boxed::Box< + runtime_types::pallet_election_provider_multi_phase::RawSolution< + runtime_types::polkadot_runtime::NposCompactSolution16, + >, >, - >, - pub witness: - runtime_types::pallet_election_provider_multi_phase::SolutionOrSnapshotSize, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMinimumUntrustedScore { - pub maybe_next_score: - ::core::option::Option, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetEmergencyElectionResult { - pub supports: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::sp_npos_elections::Support<::subxt::utils::AccountId32>, - )>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Submit { - pub raw_solution: ::std::boxed::Box< - runtime_types::pallet_election_provider_multi_phase::RawSolution< - runtime_types::polkadot_runtime::NposCompactSolution16, + pub witness: + runtime_types::pallet_election_provider_multi_phase::SolutionOrSnapshotSize, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMinimumUntrustedScore { + pub maybe_next_score: + ::core::option::Option, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetEmergencyElectionResult { + pub supports: ::std::vec::Vec<( + ::subxt::utils::AccountId32, + runtime_types::sp_npos_elections::Support<::subxt::utils::AccountId32>, + )>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Submit { + pub raw_solution: ::std::boxed::Box< + runtime_types::pallet_election_provider_multi_phase::RawSolution< + runtime_types::polkadot_runtime::NposCompactSolution16, + >, >, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct GovernanceFallback { - pub maybe_max_voters: ::core::option::Option<::core::primitive::u32>, - pub maybe_max_targets: ::core::option::Option<::core::primitive::u32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct GovernanceFallback { + pub maybe_max_voters: ::core::option::Option<::core::primitive::u32>, + pub maybe_max_targets: ::core::option::Option<::core::primitive::u32>, + } } pub struct TransactionApi; impl TransactionApi { @@ -22653,11 +22785,11 @@ pub mod api { runtime_types::polkadot_runtime::NposCompactSolution16, >, witness : runtime_types :: pallet_election_provider_multi_phase :: SolutionOrSnapshotSize, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ElectionProviderMultiPhase", "submit_unsigned", - SubmitUnsigned { + types::SubmitUnsigned { raw_solution: ::std::boxed::Box::new(raw_solution), witness, }, @@ -22678,11 +22810,11 @@ pub mod api { maybe_next_score: ::core::option::Option< runtime_types::sp_npos_elections::ElectionScore, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ElectionProviderMultiPhase", "set_minimum_untrusted_score", - SetMinimumUntrustedScore { maybe_next_score }, + types::SetMinimumUntrustedScore { maybe_next_score }, [ 63u8, 101u8, 105u8, 146u8, 133u8, 162u8, 149u8, 112u8, 150u8, 219u8, 183u8, 213u8, 234u8, 211u8, 144u8, 74u8, 106u8, 15u8, 62u8, 196u8, @@ -22704,11 +22836,11 @@ pub mod api { ::subxt::utils::AccountId32, runtime_types::sp_npos_elections::Support<::subxt::utils::AccountId32>, )>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ElectionProviderMultiPhase", "set_emergency_election_result", - SetEmergencyElectionResult { supports }, + types::SetEmergencyElectionResult { supports }, [ 115u8, 255u8, 205u8, 58u8, 153u8, 1u8, 246u8, 8u8, 225u8, 36u8, 66u8, 144u8, 250u8, 145u8, 70u8, 76u8, 54u8, 63u8, 251u8, 51u8, 214u8, 204u8, @@ -22730,11 +22862,11 @@ pub mod api { raw_solution: runtime_types::pallet_election_provider_multi_phase::RawSolution< runtime_types::polkadot_runtime::NposCompactSolution16, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ElectionProviderMultiPhase", "submit", - Submit { + types::Submit { raw_solution: ::std::boxed::Box::new(raw_solution), }, [ @@ -22753,11 +22885,11 @@ pub mod api { &self, maybe_max_voters: ::core::option::Option<::core::primitive::u32>, maybe_max_targets: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ElectionProviderMultiPhase", "governance_fallback", - GovernanceFallback { + types::GovernanceFallback { maybe_max_voters, maybe_max_targets, }, @@ -23533,31 +23665,34 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Rebag { - pub dislocated: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PutInFrontOf { - pub lighter: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Rebag { + pub dislocated: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PutInFrontOf { + pub lighter: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } } pub struct TransactionApi; impl TransactionApi { @@ -23574,11 +23709,11 @@ pub mod api { pub fn rebag( &self, dislocated: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "VoterList", "rebag", - Rebag { dislocated }, + types::Rebag { dislocated }, [ 35u8, 182u8, 31u8, 22u8, 190u8, 187u8, 31u8, 138u8, 60u8, 48u8, 236u8, 16u8, 191u8, 143u8, 52u8, 110u8, 228u8, 43u8, 116u8, 13u8, 171u8, @@ -23598,11 +23733,11 @@ pub mod api { pub fn put_in_front_of( &self, lighter: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "VoterList", "put_in_front_of", - PutInFrontOf { lighter }, + types::PutInFrontOf { lighter }, [ 184u8, 194u8, 39u8, 91u8, 28u8, 220u8, 76u8, 199u8, 64u8, 252u8, 233u8, 241u8, 74u8, 19u8, 246u8, 190u8, 108u8, 227u8, 77u8, 162u8, 225u8, @@ -24192,11 +24327,11 @@ pub mod api { &self, amount: ::core::primitive::u128, pool_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "NominationPools", "join", - Join { amount, pool_id }, + types::Join { amount, pool_id }, [ 205u8, 66u8, 42u8, 72u8, 146u8, 148u8, 119u8, 162u8, 101u8, 183u8, 46u8, 176u8, 221u8, 204u8, 197u8, 20u8, 75u8, 226u8, 29u8, 118u8, @@ -24217,11 +24352,11 @@ pub mod api { extra: runtime_types::pallet_nomination_pools::BondExtra< ::core::primitive::u128, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "NominationPools", "bond_extra", - BondExtra { extra }, + types::BondExtra { extra }, [ 50u8, 72u8, 181u8, 216u8, 249u8, 27u8, 250u8, 177u8, 253u8, 22u8, 240u8, 100u8, 184u8, 202u8, 197u8, 34u8, 21u8, 188u8, 248u8, 191u8, @@ -24242,7 +24377,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "NominationPools", "claim_payout", - ClaimPayout {}, + types::ClaimPayout {}, [ 128u8, 58u8, 138u8, 55u8, 64u8, 16u8, 129u8, 25u8, 211u8, 229u8, 193u8, 115u8, 47u8, 45u8, 155u8, 221u8, 218u8, 1u8, 222u8, 5u8, 236u8, 32u8, @@ -24285,11 +24420,11 @@ pub mod api { &self, member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, unbonding_points: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "NominationPools", "unbond", - Unbond { + types::Unbond { member_account, unbonding_points, }, @@ -24310,11 +24445,11 @@ pub mod api { &self, pool_id: ::core::primitive::u32, num_slashing_spans: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "NominationPools", "pool_withdraw_unbonded", - PoolWithdrawUnbonded { + types::PoolWithdrawUnbonded { pool_id, num_slashing_spans, }, @@ -24349,11 +24484,11 @@ pub mod api { &self, member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, num_slashing_spans: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "NominationPools", "withdraw_unbonded", - WithdrawUnbonded { + types::WithdrawUnbonded { member_account, num_slashing_spans, }, @@ -24392,7 +24527,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "NominationPools", "create", - Create { + types::Create { amount, root, nominator, @@ -24419,11 +24554,11 @@ pub mod api { nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, pool_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "NominationPools", "create_with_pool_id", - CreateWithPoolId { + types::CreateWithPoolId { amount, root, nominator, @@ -24448,11 +24583,11 @@ pub mod api { &self, pool_id: ::core::primitive::u32, validators: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "NominationPools", "nominate", - Nominate { + types::Nominate { pool_id, validators, }, @@ -24477,11 +24612,11 @@ pub mod api { &self, pool_id: ::core::primitive::u32, state: runtime_types::pallet_nomination_pools::PoolState, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "NominationPools", "set_state", - SetState { pool_id, state }, + types::SetState { pool_id, state }, [ 104u8, 40u8, 213u8, 88u8, 159u8, 115u8, 35u8, 249u8, 78u8, 180u8, 99u8, 1u8, 225u8, 218u8, 192u8, 151u8, 25u8, 194u8, 192u8, 187u8, 39u8, @@ -24498,11 +24633,11 @@ pub mod api { &self, pool_id: ::core::primitive::u32, metadata: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "NominationPools", "set_metadata", - SetMetadata { pool_id, metadata }, + types::SetMetadata { pool_id, metadata }, [ 156u8, 81u8, 170u8, 161u8, 34u8, 100u8, 183u8, 174u8, 5u8, 81u8, 31u8, 76u8, 12u8, 42u8, 77u8, 1u8, 6u8, 26u8, 168u8, 7u8, 8u8, 115u8, 158u8, @@ -24545,7 +24680,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "NominationPools", "set_configs", - SetConfigs { + types::SetConfigs { min_join_bond, min_create_bond, max_pools, @@ -24580,11 +24715,11 @@ pub mod api { new_bouncer: runtime_types::pallet_nomination_pools::ConfigOp< ::subxt::utils::AccountId32, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "NominationPools", "update_roles", - UpdateRoles { + types::UpdateRoles { pool_id, new_root, new_nominator, @@ -24608,11 +24743,11 @@ pub mod api { pub fn chill( &self, pool_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "NominationPools", "chill", - Chill { pool_id }, + types::Chill { pool_id }, [ 41u8, 114u8, 128u8, 121u8, 244u8, 15u8, 15u8, 52u8, 129u8, 88u8, 239u8, 167u8, 216u8, 38u8, 123u8, 240u8, 172u8, 229u8, 132u8, 64u8, 175u8, @@ -25873,11 +26008,13 @@ pub mod api { #[doc = "If the check fails, the stash remains chilled and waiting for being unbonded as in with"] #[doc = "the normal staking system, but they lose part of their unbonding chunks due to consuming"] #[doc = "the chain's resources."] - pub fn register_fast_unstake(&self) -> ::subxt::tx::Payload { + pub fn register_fast_unstake( + &self, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "FastUnstake", "register_fast_unstake", - RegisterFastUnstake {}, + types::RegisterFastUnstake {}, [ 254u8, 85u8, 128u8, 135u8, 172u8, 170u8, 34u8, 145u8, 79u8, 117u8, 234u8, 90u8, 16u8, 174u8, 159u8, 197u8, 27u8, 239u8, 180u8, 85u8, @@ -25893,11 +26030,11 @@ pub mod api { #[doc = "Note that the associated stash is still fully unbonded and chilled as a consequence of"] #[doc = "calling `register_fast_unstake`. This should probably be followed by a call to"] #[doc = "`Staking::rebond`."] - pub fn deregister(&self) -> ::subxt::tx::Payload { + pub fn deregister(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "FastUnstake", "deregister", - Deregister {}, + types::Deregister {}, [ 198u8, 180u8, 253u8, 148u8, 124u8, 145u8, 175u8, 121u8, 42u8, 181u8, 41u8, 155u8, 229u8, 181u8, 66u8, 140u8, 103u8, 86u8, 242u8, 155u8, @@ -26814,11 +26951,11 @@ pub mod api { pub fn set_validation_upgrade_cooldown( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_validation_upgrade_cooldown", - SetValidationUpgradeCooldown { new }, + types::SetValidationUpgradeCooldown { new }, [ 109u8, 185u8, 0u8, 59u8, 177u8, 198u8, 76u8, 90u8, 108u8, 190u8, 56u8, 126u8, 147u8, 110u8, 76u8, 111u8, 38u8, 200u8, 230u8, 144u8, 42u8, @@ -26831,11 +26968,11 @@ pub mod api { pub fn set_validation_upgrade_delay( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_validation_upgrade_delay", - SetValidationUpgradeDelay { new }, + types::SetValidationUpgradeDelay { new }, [ 18u8, 130u8, 158u8, 253u8, 160u8, 194u8, 220u8, 120u8, 9u8, 68u8, 232u8, 176u8, 34u8, 81u8, 200u8, 236u8, 141u8, 139u8, 62u8, 110u8, @@ -26848,11 +26985,11 @@ pub mod api { pub fn set_code_retention_period( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_code_retention_period", - SetCodeRetentionPeriod { new }, + types::SetCodeRetentionPeriod { new }, [ 221u8, 140u8, 253u8, 111u8, 64u8, 236u8, 93u8, 52u8, 214u8, 245u8, 178u8, 30u8, 77u8, 166u8, 242u8, 252u8, 203u8, 106u8, 12u8, 195u8, @@ -26865,11 +27002,11 @@ pub mod api { pub fn set_max_code_size( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_max_code_size", - SetMaxCodeSize { new }, + types::SetMaxCodeSize { new }, [ 232u8, 106u8, 45u8, 195u8, 27u8, 162u8, 188u8, 213u8, 137u8, 13u8, 123u8, 89u8, 215u8, 141u8, 231u8, 82u8, 205u8, 215u8, 73u8, 142u8, @@ -26882,11 +27019,11 @@ pub mod api { pub fn set_max_pov_size( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_max_pov_size", - SetMaxPovSize { new }, + types::SetMaxPovSize { new }, [ 15u8, 176u8, 13u8, 19u8, 177u8, 160u8, 211u8, 238u8, 29u8, 194u8, 187u8, 235u8, 244u8, 65u8, 158u8, 47u8, 102u8, 221u8, 95u8, 10u8, 21u8, @@ -26898,11 +27035,11 @@ pub mod api { pub fn set_max_head_data_size( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_max_head_data_size", - SetMaxHeadDataSize { new }, + types::SetMaxHeadDataSize { new }, [ 219u8, 128u8, 213u8, 65u8, 190u8, 224u8, 87u8, 80u8, 172u8, 112u8, 160u8, 229u8, 52u8, 1u8, 189u8, 125u8, 177u8, 139u8, 103u8, 39u8, 21u8, @@ -26914,11 +27051,11 @@ pub mod api { pub fn set_parathread_cores( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_parathread_cores", - SetParathreadCores { new }, + types::SetParathreadCores { new }, [ 155u8, 102u8, 168u8, 202u8, 236u8, 87u8, 16u8, 128u8, 141u8, 99u8, 154u8, 162u8, 216u8, 198u8, 236u8, 233u8, 104u8, 230u8, 137u8, 132u8, @@ -26931,11 +27068,11 @@ pub mod api { pub fn set_parathread_retries( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_parathread_retries", - SetParathreadRetries { new }, + types::SetParathreadRetries { new }, [ 192u8, 81u8, 152u8, 41u8, 40u8, 3u8, 251u8, 205u8, 244u8, 133u8, 42u8, 197u8, 21u8, 221u8, 80u8, 196u8, 222u8, 69u8, 153u8, 39u8, 161u8, 90u8, @@ -26947,11 +27084,11 @@ pub mod api { pub fn set_group_rotation_frequency( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_group_rotation_frequency", - SetGroupRotationFrequency { new }, + types::SetGroupRotationFrequency { new }, [ 205u8, 222u8, 129u8, 36u8, 136u8, 186u8, 114u8, 70u8, 214u8, 22u8, 112u8, 65u8, 56u8, 42u8, 103u8, 93u8, 108u8, 242u8, 188u8, 229u8, @@ -26964,11 +27101,11 @@ pub mod api { pub fn set_chain_availability_period( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_chain_availability_period", - SetChainAvailabilityPeriod { new }, + types::SetChainAvailabilityPeriod { new }, [ 171u8, 21u8, 54u8, 241u8, 19u8, 100u8, 54u8, 143u8, 97u8, 191u8, 193u8, 96u8, 7u8, 86u8, 255u8, 109u8, 255u8, 93u8, 113u8, 28u8, 182u8, 75u8, @@ -26980,11 +27117,11 @@ pub mod api { pub fn set_thread_availability_period( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_thread_availability_period", - SetThreadAvailabilityPeriod { new }, + types::SetThreadAvailabilityPeriod { new }, [ 208u8, 27u8, 246u8, 33u8, 90u8, 200u8, 75u8, 177u8, 19u8, 107u8, 236u8, 43u8, 159u8, 156u8, 184u8, 10u8, 146u8, 71u8, 212u8, 129u8, 44u8, 19u8, @@ -26996,11 +27133,11 @@ pub mod api { pub fn set_scheduling_lookahead( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_scheduling_lookahead", - SetSchedulingLookahead { new }, + types::SetSchedulingLookahead { new }, [ 220u8, 74u8, 0u8, 150u8, 45u8, 29u8, 56u8, 210u8, 66u8, 12u8, 119u8, 176u8, 103u8, 24u8, 216u8, 55u8, 211u8, 120u8, 233u8, 204u8, 167u8, @@ -27013,11 +27150,11 @@ pub mod api { pub fn set_max_validators_per_core( &self, new: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_max_validators_per_core", - SetMaxValidatorsPerCore { new }, + types::SetMaxValidatorsPerCore { new }, [ 227u8, 113u8, 192u8, 116u8, 114u8, 171u8, 27u8, 22u8, 84u8, 117u8, 146u8, 152u8, 94u8, 101u8, 14u8, 52u8, 228u8, 170u8, 163u8, 82u8, @@ -27030,11 +27167,11 @@ pub mod api { pub fn set_max_validators( &self, new: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_max_validators", - SetMaxValidators { new }, + types::SetMaxValidators { new }, [ 143u8, 212u8, 59u8, 147u8, 4u8, 55u8, 142u8, 209u8, 237u8, 76u8, 7u8, 178u8, 41u8, 81u8, 4u8, 203u8, 184u8, 149u8, 32u8, 1u8, 106u8, 180u8, @@ -27046,11 +27183,11 @@ pub mod api { pub fn set_dispute_period( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_dispute_period", - SetDisputePeriod { new }, + types::SetDisputePeriod { new }, [ 36u8, 191u8, 142u8, 240u8, 48u8, 101u8, 10u8, 197u8, 117u8, 125u8, 156u8, 189u8, 130u8, 77u8, 242u8, 130u8, 205u8, 154u8, 152u8, 47u8, @@ -27063,12 +27200,12 @@ pub mod api { pub fn set_dispute_post_conclusion_acceptance_period( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_dispute_post_conclusion_acceptance_period", - SetDisputePostConclusionAcceptancePeriod { new }, + types::SetDisputePostConclusionAcceptancePeriod { new }, [ 66u8, 56u8, 45u8, 87u8, 51u8, 49u8, 91u8, 95u8, 255u8, 185u8, 54u8, 165u8, 85u8, 142u8, 238u8, 251u8, 174u8, 81u8, 3u8, 61u8, 92u8, 97u8, @@ -27081,11 +27218,11 @@ pub mod api { pub fn set_no_show_slots( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_no_show_slots", - SetNoShowSlots { new }, + types::SetNoShowSlots { new }, [ 94u8, 230u8, 89u8, 131u8, 188u8, 246u8, 251u8, 34u8, 249u8, 16u8, 134u8, 63u8, 238u8, 115u8, 19u8, 97u8, 97u8, 218u8, 238u8, 115u8, @@ -27098,11 +27235,11 @@ pub mod api { pub fn set_n_delay_tranches( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_n_delay_tranches", - SetNDelayTranches { new }, + types::SetNDelayTranches { new }, [ 195u8, 168u8, 178u8, 51u8, 20u8, 107u8, 227u8, 236u8, 57u8, 30u8, 130u8, 93u8, 149u8, 2u8, 161u8, 66u8, 48u8, 37u8, 71u8, 108u8, 195u8, @@ -27115,11 +27252,11 @@ pub mod api { pub fn set_zeroth_delay_tranche_width( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_zeroth_delay_tranche_width", - SetZerothDelayTrancheWidth { new }, + types::SetZerothDelayTrancheWidth { new }, [ 69u8, 56u8, 125u8, 24u8, 181u8, 62u8, 99u8, 92u8, 166u8, 107u8, 91u8, 134u8, 230u8, 128u8, 214u8, 135u8, 245u8, 64u8, 62u8, 78u8, 96u8, @@ -27131,11 +27268,11 @@ pub mod api { pub fn set_needed_approvals( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_needed_approvals", - SetNeededApprovals { new }, + types::SetNeededApprovals { new }, [ 238u8, 55u8, 134u8, 30u8, 67u8, 153u8, 150u8, 5u8, 226u8, 227u8, 185u8, 188u8, 66u8, 60u8, 147u8, 118u8, 46u8, 174u8, 104u8, 100u8, 26u8, @@ -27147,11 +27284,11 @@ pub mod api { pub fn set_relay_vrf_modulo_samples( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_relay_vrf_modulo_samples", - SetRelayVrfModuloSamples { new }, + types::SetRelayVrfModuloSamples { new }, [ 76u8, 101u8, 207u8, 184u8, 211u8, 8u8, 43u8, 4u8, 165u8, 147u8, 166u8, 3u8, 189u8, 42u8, 125u8, 130u8, 21u8, 43u8, 189u8, 120u8, 239u8, 131u8, @@ -27163,11 +27300,11 @@ pub mod api { pub fn set_max_upward_queue_count( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_max_upward_queue_count", - SetMaxUpwardQueueCount { new }, + types::SetMaxUpwardQueueCount { new }, [ 116u8, 186u8, 216u8, 17u8, 150u8, 187u8, 86u8, 154u8, 92u8, 122u8, 178u8, 167u8, 215u8, 165u8, 55u8, 86u8, 229u8, 114u8, 10u8, 149u8, @@ -27180,11 +27317,11 @@ pub mod api { pub fn set_max_upward_queue_size( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_max_upward_queue_size", - SetMaxUpwardQueueSize { new }, + types::SetMaxUpwardQueueSize { new }, [ 18u8, 60u8, 141u8, 57u8, 134u8, 96u8, 140u8, 85u8, 137u8, 9u8, 209u8, 123u8, 10u8, 165u8, 33u8, 184u8, 34u8, 82u8, 59u8, 60u8, 30u8, 47u8, @@ -27196,11 +27333,11 @@ pub mod api { pub fn set_max_downward_message_size( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_max_downward_message_size", - SetMaxDownwardMessageSize { new }, + types::SetMaxDownwardMessageSize { new }, [ 104u8, 25u8, 229u8, 184u8, 53u8, 246u8, 206u8, 180u8, 13u8, 156u8, 14u8, 224u8, 215u8, 115u8, 104u8, 127u8, 167u8, 189u8, 239u8, 183u8, @@ -27213,11 +27350,11 @@ pub mod api { pub fn set_ump_service_total_weight( &self, new: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_ump_service_total_weight", - SetUmpServiceTotalWeight { new }, + types::SetUmpServiceTotalWeight { new }, [ 178u8, 63u8, 233u8, 183u8, 160u8, 109u8, 10u8, 162u8, 150u8, 110u8, 66u8, 166u8, 197u8, 207u8, 91u8, 208u8, 137u8, 106u8, 140u8, 184u8, @@ -27230,11 +27367,11 @@ pub mod api { pub fn set_max_upward_message_size( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_max_upward_message_size", - SetMaxUpwardMessageSize { new }, + types::SetMaxUpwardMessageSize { new }, [ 213u8, 120u8, 21u8, 247u8, 101u8, 21u8, 164u8, 228u8, 33u8, 115u8, 20u8, 138u8, 28u8, 174u8, 247u8, 39u8, 194u8, 113u8, 34u8, 73u8, 142u8, @@ -27247,11 +27384,12 @@ pub mod api { pub fn set_max_upward_message_num_per_candidate( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload + { ::subxt::tx::Payload::new_static( "Configuration", "set_max_upward_message_num_per_candidate", - SetMaxUpwardMessageNumPerCandidate { new }, + types::SetMaxUpwardMessageNumPerCandidate { new }, [ 54u8, 133u8, 226u8, 138u8, 184u8, 27u8, 130u8, 153u8, 130u8, 196u8, 54u8, 79u8, 124u8, 10u8, 37u8, 139u8, 59u8, 190u8, 169u8, 87u8, 255u8, @@ -27263,11 +27401,11 @@ pub mod api { pub fn set_hrmp_open_request_ttl( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_hrmp_open_request_ttl", - SetHrmpOpenRequestTtl { new }, + types::SetHrmpOpenRequestTtl { new }, [ 192u8, 113u8, 113u8, 133u8, 197u8, 75u8, 88u8, 67u8, 130u8, 207u8, 37u8, 192u8, 157u8, 159u8, 114u8, 75u8, 83u8, 180u8, 194u8, 180u8, @@ -27280,11 +27418,11 @@ pub mod api { pub fn set_hrmp_sender_deposit( &self, new: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_hrmp_sender_deposit", - SetHrmpSenderDeposit { new }, + types::SetHrmpSenderDeposit { new }, [ 49u8, 38u8, 173u8, 114u8, 66u8, 140u8, 15u8, 151u8, 193u8, 54u8, 128u8, 108u8, 72u8, 71u8, 28u8, 65u8, 129u8, 199u8, 105u8, 61u8, 96u8, 119u8, @@ -27297,11 +27435,11 @@ pub mod api { pub fn set_hrmp_recipient_deposit( &self, new: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_hrmp_recipient_deposit", - SetHrmpRecipientDeposit { new }, + types::SetHrmpRecipientDeposit { new }, [ 209u8, 212u8, 164u8, 56u8, 71u8, 215u8, 98u8, 250u8, 202u8, 150u8, 228u8, 6u8, 166u8, 94u8, 171u8, 142u8, 10u8, 253u8, 89u8, 43u8, 6u8, @@ -27313,11 +27451,11 @@ pub mod api { pub fn set_hrmp_channel_max_capacity( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_hrmp_channel_max_capacity", - SetHrmpChannelMaxCapacity { new }, + types::SetHrmpChannelMaxCapacity { new }, [ 148u8, 109u8, 67u8, 220u8, 1u8, 115u8, 70u8, 93u8, 138u8, 190u8, 60u8, 220u8, 80u8, 137u8, 246u8, 230u8, 115u8, 162u8, 30u8, 197u8, 11u8, @@ -27329,11 +27467,11 @@ pub mod api { pub fn set_hrmp_channel_max_total_size( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_hrmp_channel_max_total_size", - SetHrmpChannelMaxTotalSize { new }, + types::SetHrmpChannelMaxTotalSize { new }, [ 79u8, 40u8, 207u8, 173u8, 168u8, 143u8, 130u8, 240u8, 205u8, 34u8, 61u8, 217u8, 215u8, 106u8, 61u8, 181u8, 8u8, 21u8, 105u8, 64u8, 183u8, @@ -27345,11 +27483,12 @@ pub mod api { pub fn set_hrmp_max_parachain_inbound_channels( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload + { ::subxt::tx::Payload::new_static( "Configuration", "set_hrmp_max_parachain_inbound_channels", - SetHrmpMaxParachainInboundChannels { new }, + types::SetHrmpMaxParachainInboundChannels { new }, [ 91u8, 215u8, 212u8, 131u8, 140u8, 185u8, 119u8, 184u8, 61u8, 121u8, 120u8, 73u8, 202u8, 98u8, 124u8, 187u8, 171u8, 84u8, 136u8, 77u8, @@ -27362,11 +27501,12 @@ pub mod api { pub fn set_hrmp_max_parathread_inbound_channels( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload + { ::subxt::tx::Payload::new_static( "Configuration", "set_hrmp_max_parathread_inbound_channels", - SetHrmpMaxParathreadInboundChannels { new }, + types::SetHrmpMaxParathreadInboundChannels { new }, [ 209u8, 66u8, 180u8, 20u8, 87u8, 242u8, 219u8, 71u8, 22u8, 145u8, 220u8, 48u8, 44u8, 42u8, 77u8, 69u8, 255u8, 82u8, 27u8, 125u8, 231u8, 111u8, @@ -27378,11 +27518,11 @@ pub mod api { pub fn set_hrmp_channel_max_message_size( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_hrmp_channel_max_message_size", - SetHrmpChannelMaxMessageSize { new }, + types::SetHrmpChannelMaxMessageSize { new }, [ 17u8, 224u8, 230u8, 9u8, 114u8, 221u8, 138u8, 46u8, 234u8, 151u8, 27u8, 34u8, 179u8, 67u8, 113u8, 228u8, 128u8, 212u8, 209u8, 125u8, 122u8, @@ -27394,11 +27534,12 @@ pub mod api { pub fn set_hrmp_max_parachain_outbound_channels( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload + { ::subxt::tx::Payload::new_static( "Configuration", "set_hrmp_max_parachain_outbound_channels", - SetHrmpMaxParachainOutboundChannels { new }, + types::SetHrmpMaxParachainOutboundChannels { new }, [ 26u8, 146u8, 150u8, 88u8, 236u8, 8u8, 63u8, 103u8, 71u8, 11u8, 20u8, 210u8, 205u8, 106u8, 101u8, 112u8, 116u8, 73u8, 116u8, 136u8, 149u8, @@ -27410,11 +27551,12 @@ pub mod api { pub fn set_hrmp_max_parathread_outbound_channels( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload + { ::subxt::tx::Payload::new_static( "Configuration", "set_hrmp_max_parathread_outbound_channels", - SetHrmpMaxParathreadOutboundChannels { new }, + types::SetHrmpMaxParathreadOutboundChannels { new }, [ 31u8, 72u8, 93u8, 21u8, 180u8, 156u8, 101u8, 24u8, 145u8, 220u8, 194u8, 93u8, 176u8, 164u8, 53u8, 123u8, 36u8, 113u8, 152u8, 13u8, 222u8, 54u8, @@ -27426,11 +27568,11 @@ pub mod api { pub fn set_hrmp_max_message_num_per_candidate( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_hrmp_max_message_num_per_candidate", - SetHrmpMaxMessageNumPerCandidate { new }, + types::SetHrmpMaxMessageNumPerCandidate { new }, [ 244u8, 94u8, 225u8, 194u8, 133u8, 116u8, 202u8, 238u8, 8u8, 57u8, 122u8, 125u8, 6u8, 131u8, 84u8, 102u8, 180u8, 67u8, 250u8, 136u8, 30u8, @@ -27443,11 +27585,11 @@ pub mod api { pub fn set_ump_max_individual_weight( &self, new: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_ump_max_individual_weight", - SetUmpMaxIndividualWeight { new }, + types::SetUmpMaxIndividualWeight { new }, [ 66u8, 190u8, 15u8, 172u8, 67u8, 16u8, 117u8, 247u8, 176u8, 25u8, 163u8, 130u8, 147u8, 224u8, 226u8, 101u8, 219u8, 173u8, 176u8, 49u8, 90u8, @@ -27459,11 +27601,11 @@ pub mod api { pub fn set_pvf_checking_enabled( &self, new: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_pvf_checking_enabled", - SetPvfCheckingEnabled { new }, + types::SetPvfCheckingEnabled { new }, [ 123u8, 76u8, 1u8, 112u8, 174u8, 245u8, 18u8, 67u8, 13u8, 29u8, 219u8, 197u8, 201u8, 112u8, 230u8, 191u8, 37u8, 148u8, 73u8, 125u8, 54u8, @@ -27475,11 +27617,11 @@ pub mod api { pub fn set_pvf_voting_ttl( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_pvf_voting_ttl", - SetPvfVotingTtl { new }, + types::SetPvfVotingTtl { new }, [ 17u8, 11u8, 98u8, 217u8, 208u8, 102u8, 238u8, 83u8, 118u8, 123u8, 20u8, 18u8, 46u8, 212u8, 21u8, 164u8, 61u8, 104u8, 208u8, 204u8, 91u8, 210u8, @@ -27494,11 +27636,11 @@ pub mod api { pub fn set_minimum_validation_upgrade_delay( &self, new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_minimum_validation_upgrade_delay", - SetMinimumValidationUpgradeDelay { new }, + types::SetMinimumValidationUpgradeDelay { new }, [ 205u8, 188u8, 75u8, 136u8, 228u8, 26u8, 112u8, 27u8, 119u8, 37u8, 252u8, 109u8, 23u8, 145u8, 21u8, 212u8, 7u8, 28u8, 242u8, 210u8, 182u8, @@ -27512,11 +27654,11 @@ pub mod api { pub fn set_bypass_consistency_check( &self, new: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_bypass_consistency_check", - SetBypassConsistencyCheck { new }, + types::SetBypassConsistencyCheck { new }, [ 80u8, 66u8, 200u8, 98u8, 54u8, 207u8, 64u8, 99u8, 162u8, 121u8, 26u8, 173u8, 113u8, 224u8, 240u8, 106u8, 69u8, 191u8, 177u8, 107u8, 34u8, @@ -27641,6 +27783,9 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + } pub struct TransactionApi; impl TransactionApi {} } @@ -27727,6 +27872,9 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + } pub struct TransactionApi; impl TransactionApi {} } @@ -27933,7 +28081,7 @@ pub mod api { ::core::primitive::u32, runtime_types::sp_runtime::traits::BlakeTwo256, >, - >, + } } pub struct TransactionApi; impl TransactionApi { @@ -27946,11 +28094,11 @@ pub mod api { runtime_types::sp_runtime::traits::BlakeTwo256, >, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ParaInherent", "enter", - Enter { data }, + types::Enter { data }, [ 196u8, 247u8, 84u8, 213u8, 181u8, 15u8, 195u8, 125u8, 252u8, 46u8, 165u8, 1u8, 23u8, 159u8, 187u8, 34u8, 8u8, 15u8, 44u8, 240u8, 136u8, @@ -28321,11 +28469,11 @@ pub mod api { &self, para: runtime_types::polkadot_parachain::primitives::Id, new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Paras", "force_set_current_code", - ForceSetCurrentCode { para, new_code }, + types::ForceSetCurrentCode { para, new_code }, [ 56u8, 59u8, 48u8, 185u8, 106u8, 99u8, 250u8, 32u8, 207u8, 2u8, 4u8, 110u8, 165u8, 131u8, 22u8, 33u8, 248u8, 175u8, 186u8, 6u8, 118u8, 51u8, @@ -28338,11 +28486,11 @@ pub mod api { &self, para: runtime_types::polkadot_parachain::primitives::Id, new_head: runtime_types::polkadot_parachain::primitives::HeadData, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Paras", "force_set_current_head", - ForceSetCurrentHead { para, new_head }, + types::ForceSetCurrentHead { para, new_head }, [ 203u8, 70u8, 33u8, 168u8, 133u8, 64u8, 146u8, 137u8, 156u8, 104u8, 183u8, 26u8, 74u8, 227u8, 154u8, 224u8, 75u8, 85u8, 143u8, 51u8, 60u8, @@ -28356,11 +28504,11 @@ pub mod api { para: runtime_types::polkadot_parachain::primitives::Id, new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, relay_parent_number: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Paras", "force_schedule_code_upgrade", - ForceScheduleCodeUpgrade { + types::ForceScheduleCodeUpgrade { para, new_code, relay_parent_number, @@ -28378,11 +28526,11 @@ pub mod api { &self, para: runtime_types::polkadot_parachain::primitives::Id, new_head: runtime_types::polkadot_parachain::primitives::HeadData, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Paras", "force_note_new_head", - ForceNoteNewHead { para, new_head }, + types::ForceNoteNewHead { para, new_head }, [ 83u8, 93u8, 166u8, 142u8, 213u8, 1u8, 243u8, 73u8, 192u8, 164u8, 104u8, 206u8, 99u8, 250u8, 31u8, 222u8, 231u8, 54u8, 12u8, 45u8, 92u8, 74u8, @@ -28396,11 +28544,11 @@ pub mod api { pub fn force_queue_action( &self, para: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Paras", "force_queue_action", - ForceQueueAction { para }, + types::ForceQueueAction { para }, [ 195u8, 243u8, 79u8, 34u8, 111u8, 246u8, 109u8, 90u8, 251u8, 137u8, 48u8, 23u8, 117u8, 29u8, 26u8, 200u8, 37u8, 64u8, 36u8, 254u8, 224u8, @@ -28424,11 +28572,11 @@ pub mod api { pub fn add_trusted_validation_code( &self, validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Paras", "add_trusted_validation_code", - AddTrustedValidationCode { validation_code }, + types::AddTrustedValidationCode { validation_code }, [ 160u8, 199u8, 245u8, 178u8, 58u8, 65u8, 79u8, 199u8, 53u8, 60u8, 84u8, 225u8, 2u8, 145u8, 154u8, 204u8, 165u8, 171u8, 173u8, 223u8, 59u8, @@ -28444,11 +28592,11 @@ pub mod api { pub fn poke_unused_validation_code( &self, validation_code_hash : runtime_types :: polkadot_parachain :: primitives :: ValidationCodeHash, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Paras", "poke_unused_validation_code", - PokeUnusedValidationCode { + types::PokeUnusedValidationCode { validation_code_hash, }, [ @@ -28469,7 +28617,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "Paras", "include_pvf_check_statement", - IncludePvfCheckStatement { stmt, signature }, + types::IncludePvfCheckStatement { stmt, signature }, [ 22u8, 136u8, 241u8, 59u8, 36u8, 249u8, 239u8, 255u8, 169u8, 117u8, 19u8, 58u8, 214u8, 16u8, 135u8, 65u8, 13u8, 250u8, 5u8, 41u8, 144u8, @@ -29528,19 +29676,22 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceApprove { - pub up_to: ::core::primitive::u32, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceApprove { + pub up_to: ::core::primitive::u32, + } } pub struct TransactionApi; impl TransactionApi { @@ -29550,11 +29701,11 @@ pub mod api { pub fn force_approve( &self, up_to: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Initializer", "force_approve", - ForceApprove { up_to }, + types::ForceApprove { up_to }, [ 28u8, 117u8, 86u8, 182u8, 19u8, 127u8, 43u8, 17u8, 153u8, 80u8, 193u8, 53u8, 120u8, 41u8, 205u8, 23u8, 252u8, 148u8, 77u8, 227u8, 138u8, 35u8, @@ -29798,19 +29949,22 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ServiceOverweight { - pub index: ::core::primitive::u64, - pub weight_limit: runtime_types::sp_weights::weight_v2::Weight, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ServiceOverweight { + pub index: ::core::primitive::u64, + pub weight_limit: runtime_types::sp_weights::weight_v2::Weight, + } } pub struct TransactionApi; impl TransactionApi { @@ -29830,11 +29984,11 @@ pub mod api { &self, index: ::core::primitive::u64, weight_limit: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Ump", "service_overweight", - ServiceOverweight { + types::ServiceOverweight { index, weight_limit, }, @@ -30285,119 +30439,122 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpInitOpenChannel { - pub recipient: runtime_types::polkadot_parachain::primitives::Id, - pub proposed_max_capacity: ::core::primitive::u32, - pub proposed_max_message_size: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpAcceptOpenChannel { - pub sender: runtime_types::polkadot_parachain::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpCloseChannel { - pub channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceCleanHrmp { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub inbound: ::core::primitive::u32, - pub outbound: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceProcessHrmpOpen { - pub channels: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceProcessHrmpClose { - pub channels: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpCancelOpenRequest { - pub channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, - pub open_requests: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceOpenHrmpChannel { - pub sender: runtime_types::polkadot_parachain::primitives::Id, - pub recipient: runtime_types::polkadot_parachain::primitives::Id, - pub max_capacity: ::core::primitive::u32, - pub max_message_size: ::core::primitive::u32, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct HrmpInitOpenChannel { + pub recipient: runtime_types::polkadot_parachain::primitives::Id, + pub proposed_max_capacity: ::core::primitive::u32, + pub proposed_max_message_size: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct HrmpAcceptOpenChannel { + pub sender: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct HrmpCloseChannel { + pub channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceCleanHrmp { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub inbound: ::core::primitive::u32, + pub outbound: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceProcessHrmpOpen { + pub channels: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceProcessHrmpClose { + pub channels: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct HrmpCancelOpenRequest { + pub channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, + pub open_requests: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceOpenHrmpChannel { + pub sender: runtime_types::polkadot_parachain::primitives::Id, + pub recipient: runtime_types::polkadot_parachain::primitives::Id, + pub max_capacity: ::core::primitive::u32, + pub max_message_size: ::core::primitive::u32, + } } pub struct TransactionApi; impl TransactionApi { @@ -30416,11 +30573,11 @@ pub mod api { recipient: runtime_types::polkadot_parachain::primitives::Id, proposed_max_capacity: ::core::primitive::u32, proposed_max_message_size: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Hrmp", "hrmp_init_open_channel", - HrmpInitOpenChannel { + types::HrmpInitOpenChannel { recipient, proposed_max_capacity, proposed_max_message_size, @@ -30439,11 +30596,11 @@ pub mod api { pub fn hrmp_accept_open_channel( &self, sender: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Hrmp", "hrmp_accept_open_channel", - HrmpAcceptOpenChannel { sender }, + types::HrmpAcceptOpenChannel { sender }, [ 75u8, 111u8, 52u8, 164u8, 204u8, 100u8, 204u8, 111u8, 127u8, 84u8, 60u8, 136u8, 95u8, 255u8, 48u8, 157u8, 189u8, 76u8, 33u8, 177u8, 223u8, @@ -30458,11 +30615,11 @@ pub mod api { pub fn hrmp_close_channel( &self, channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Hrmp", "hrmp_close_channel", - HrmpCloseChannel { channel_id }, + types::HrmpCloseChannel { channel_id }, [ 11u8, 202u8, 76u8, 107u8, 213u8, 21u8, 191u8, 190u8, 40u8, 229u8, 60u8, 115u8, 232u8, 136u8, 41u8, 114u8, 21u8, 19u8, 238u8, 236u8, 202u8, @@ -30482,11 +30639,11 @@ pub mod api { para: runtime_types::polkadot_parachain::primitives::Id, inbound: ::core::primitive::u32, outbound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Hrmp", "force_clean_hrmp", - ForceCleanHrmp { + types::ForceCleanHrmp { para, inbound, outbound, @@ -30508,11 +30665,11 @@ pub mod api { pub fn force_process_hrmp_open( &self, channels: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Hrmp", "force_process_hrmp_open", - ForceProcessHrmpOpen { channels }, + types::ForceProcessHrmpOpen { channels }, [ 231u8, 80u8, 233u8, 15u8, 131u8, 167u8, 223u8, 28u8, 182u8, 185u8, 213u8, 24u8, 154u8, 160u8, 68u8, 94u8, 160u8, 59u8, 78u8, 85u8, 85u8, @@ -30530,11 +30687,11 @@ pub mod api { pub fn force_process_hrmp_close( &self, channels: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Hrmp", "force_process_hrmp_close", - ForceProcessHrmpClose { channels }, + types::ForceProcessHrmpClose { channels }, [ 248u8, 138u8, 30u8, 151u8, 53u8, 16u8, 44u8, 116u8, 51u8, 194u8, 173u8, 252u8, 143u8, 53u8, 184u8, 129u8, 80u8, 80u8, 25u8, 118u8, 47u8, 183u8, @@ -30554,11 +30711,11 @@ pub mod api { &self, channel_id: runtime_types::polkadot_parachain::primitives::HrmpChannelId, open_requests: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Hrmp", "hrmp_cancel_open_request", - HrmpCancelOpenRequest { + types::HrmpCancelOpenRequest { channel_id, open_requests, }, @@ -30582,11 +30739,11 @@ pub mod api { recipient: runtime_types::polkadot_parachain::primitives::Id, max_capacity: ::core::primitive::u32, max_message_size: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Hrmp", "force_open_hrmp_channel", - ForceOpenHrmpChannel { + types::ForceOpenHrmpChannel { sender, recipient, max_capacity, @@ -31516,24 +31673,27 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceUnfreeze; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceUnfreeze; + } pub struct TransactionApi; impl TransactionApi { - pub fn force_unfreeze(&self) -> ::subxt::tx::Payload { + pub fn force_unfreeze(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ParasDisputes", "force_unfreeze", - ForceUnfreeze {}, + types::ForceUnfreeze {}, [ 212u8, 211u8, 58u8, 159u8, 23u8, 220u8, 64u8, 175u8, 65u8, 50u8, 192u8, 122u8, 113u8, 189u8, 74u8, 191u8, 48u8, 93u8, 251u8, 50u8, 237u8, @@ -31981,129 +32141,134 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Register { - pub id: runtime_types::polkadot_parachain::primitives::Id, - pub genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, - pub validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceRegister { - pub who: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - pub id: runtime_types::polkadot_parachain::primitives::Id, - pub genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, - pub validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Deregister { - pub id: runtime_types::polkadot_parachain::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Swap { - pub id: runtime_types::polkadot_parachain::primitives::Id, - pub other: runtime_types::polkadot_parachain::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveLock { - pub para: runtime_types::polkadot_parachain::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Reserve; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddLock { - pub para: runtime_types::polkadot_parachain::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduleCodeUpgrade { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCurrentHead { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub new_head: runtime_types::polkadot_parachain::primitives::HeadData, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Register { + pub id: runtime_types::polkadot_parachain::primitives::Id, + pub genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, + pub validation_code: + runtime_types::polkadot_parachain::primitives::ValidationCode, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceRegister { + pub who: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, + pub id: runtime_types::polkadot_parachain::primitives::Id, + pub genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, + pub validation_code: + runtime_types::polkadot_parachain::primitives::ValidationCode, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Deregister { + pub id: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Swap { + pub id: runtime_types::polkadot_parachain::primitives::Id, + pub other: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveLock { + pub para: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Reserve; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddLock { + pub para: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ScheduleCodeUpgrade { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetCurrentHead { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub new_head: runtime_types::polkadot_parachain::primitives::HeadData, + } } pub struct TransactionApi; impl TransactionApi { @@ -32126,11 +32291,11 @@ pub mod api { id: runtime_types::polkadot_parachain::primitives::Id, genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Registrar", "register", - Register { + types::Register { id, genesis_head, validation_code, @@ -32155,11 +32320,11 @@ pub mod api { id: runtime_types::polkadot_parachain::primitives::Id, genesis_head: runtime_types::polkadot_parachain::primitives::HeadData, validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Registrar", "force_register", - ForceRegister { + types::ForceRegister { who, deposit, id, @@ -32179,11 +32344,11 @@ pub mod api { pub fn deregister( &self, id: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Registrar", "deregister", - Deregister { id }, + types::Deregister { id }, [ 137u8, 9u8, 146u8, 11u8, 126u8, 125u8, 186u8, 222u8, 246u8, 199u8, 94u8, 229u8, 147u8, 245u8, 213u8, 51u8, 203u8, 181u8, 78u8, 87u8, 18u8, @@ -32206,11 +32371,11 @@ pub mod api { &self, id: runtime_types::polkadot_parachain::primitives::Id, other: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Registrar", "swap", - Swap { id, other }, + types::Swap { id, other }, [ 238u8, 154u8, 249u8, 250u8, 57u8, 242u8, 47u8, 17u8, 50u8, 70u8, 124u8, 189u8, 193u8, 137u8, 107u8, 138u8, 216u8, 137u8, 160u8, 103u8, 192u8, @@ -32225,11 +32390,11 @@ pub mod api { pub fn remove_lock( &self, para: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Registrar", "remove_lock", - RemoveLock { para }, + types::RemoveLock { para }, [ 93u8, 50u8, 223u8, 180u8, 185u8, 3u8, 225u8, 27u8, 233u8, 205u8, 101u8, 86u8, 122u8, 19u8, 147u8, 8u8, 202u8, 151u8, 80u8, 24u8, 196u8, 2u8, @@ -32251,11 +32416,11 @@ pub mod api { #[doc = ""] #[doc = "## Events"] #[doc = "The `Reserved` event is emitted in case of success, which provides the ID reserved for use."] - pub fn reserve(&self) -> ::subxt::tx::Payload { + pub fn reserve(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Registrar", "reserve", - Reserve {}, + types::Reserve {}, [ 22u8, 210u8, 13u8, 54u8, 253u8, 13u8, 89u8, 174u8, 232u8, 119u8, 148u8, 206u8, 130u8, 133u8, 199u8, 127u8, 201u8, 205u8, 8u8, 213u8, 108u8, @@ -32271,11 +32436,11 @@ pub mod api { pub fn add_lock( &self, para: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Registrar", "add_lock", - AddLock { para }, + types::AddLock { para }, [ 99u8, 199u8, 192u8, 92u8, 180u8, 52u8, 86u8, 165u8, 249u8, 60u8, 72u8, 79u8, 233u8, 5u8, 83u8, 194u8, 48u8, 83u8, 249u8, 218u8, 141u8, 234u8, @@ -32290,11 +32455,11 @@ pub mod api { &self, para: runtime_types::polkadot_parachain::primitives::Id, new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Registrar", "schedule_code_upgrade", - ScheduleCodeUpgrade { para, new_code }, + types::ScheduleCodeUpgrade { para, new_code }, [ 67u8, 11u8, 148u8, 83u8, 36u8, 106u8, 97u8, 77u8, 79u8, 114u8, 249u8, 218u8, 207u8, 89u8, 209u8, 120u8, 45u8, 101u8, 69u8, 21u8, 61u8, 158u8, @@ -32309,11 +32474,11 @@ pub mod api { &self, para: runtime_types::polkadot_parachain::primitives::Id, new_head: runtime_types::polkadot_parachain::primitives::HeadData, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Registrar", "set_current_head", - SetCurrentHead { para, new_head }, + types::SetCurrentHead { para, new_head }, [ 103u8, 240u8, 206u8, 26u8, 120u8, 189u8, 94u8, 221u8, 174u8, 225u8, 210u8, 176u8, 217u8, 18u8, 94u8, 216u8, 77u8, 205u8, 86u8, 196u8, @@ -32575,48 +32740,51 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceLease { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub leaser: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - pub period_begin: ::core::primitive::u32, - pub period_count: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClearAllLeases { - pub para: runtime_types::polkadot_parachain::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TriggerOnboard { - pub para: runtime_types::polkadot_parachain::primitives::Id, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceLease { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub leaser: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + pub period_begin: ::core::primitive::u32, + pub period_count: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClearAllLeases { + pub para: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TriggerOnboard { + pub para: runtime_types::polkadot_parachain::primitives::Id, + } } pub struct TransactionApi; impl TransactionApi { @@ -32631,11 +32799,11 @@ pub mod api { amount: ::core::primitive::u128, period_begin: ::core::primitive::u32, period_count: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Slots", "force_lease", - ForceLease { + types::ForceLease { para, leaser, amount, @@ -32655,11 +32823,11 @@ pub mod api { pub fn clear_all_leases( &self, para: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Slots", "clear_all_leases", - ClearAllLeases { para }, + types::ClearAllLeases { para }, [ 16u8, 14u8, 185u8, 45u8, 149u8, 70u8, 177u8, 133u8, 130u8, 173u8, 196u8, 244u8, 77u8, 63u8, 218u8, 64u8, 108u8, 83u8, 84u8, 184u8, 175u8, @@ -32677,11 +32845,11 @@ pub mod api { pub fn trigger_onboard( &self, para: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Slots", "trigger_onboard", - TriggerOnboard { para }, + types::TriggerOnboard { para }, [ 74u8, 158u8, 122u8, 37u8, 34u8, 62u8, 61u8, 218u8, 94u8, 222u8, 1u8, 153u8, 131u8, 215u8, 157u8, 180u8, 98u8, 130u8, 151u8, 179u8, 22u8, @@ -32874,55 +33042,58 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NewAuction { - #[codec(compact)] - pub duration: ::core::primitive::u32, - #[codec(compact)] - pub lease_period_index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Bid { - #[codec(compact)] - pub para: runtime_types::polkadot_parachain::primitives::Id, - #[codec(compact)] - pub auction_index: ::core::primitive::u32, - #[codec(compact)] - pub first_slot: ::core::primitive::u32, - #[codec(compact)] - pub last_slot: ::core::primitive::u32, - #[codec(compact)] - pub amount: ::core::primitive::u128, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct NewAuction { + #[codec(compact)] + pub duration: ::core::primitive::u32, + #[codec(compact)] + pub lease_period_index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Bid { + #[codec(compact)] + pub para: runtime_types::polkadot_parachain::primitives::Id, + #[codec(compact)] + pub auction_index: ::core::primitive::u32, + #[codec(compact)] + pub first_slot: ::core::primitive::u32, + #[codec(compact)] + pub last_slot: ::core::primitive::u32, + #[codec(compact)] + pub amount: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelAuction; } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelAuction; pub struct TransactionApi; impl TransactionApi { #[doc = "Create a new auction."] @@ -32934,11 +33105,11 @@ pub mod api { &self, duration: ::core::primitive::u32, lease_period_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Auctions", "new_auction", - NewAuction { + types::NewAuction { duration, lease_period_index, }, @@ -32973,11 +33144,11 @@ pub mod api { first_slot: ::core::primitive::u32, last_slot: ::core::primitive::u32, amount: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Auctions", "bid", - Bid { + types::Bid { para, auction_index, first_slot, @@ -32994,11 +33165,11 @@ pub mod api { #[doc = "Cancel an in-progress auction."] #[doc = ""] #[doc = "Can only be called by Root origin."] - pub fn cancel_auction(&self) -> ::subxt::tx::Payload { + pub fn cancel_auction(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Auctions", "cancel_auction", - CancelAuction {}, + types::CancelAuction {}, [ 182u8, 223u8, 178u8, 136u8, 1u8, 115u8, 229u8, 78u8, 166u8, 128u8, 28u8, 106u8, 6u8, 248u8, 46u8, 55u8, 110u8, 120u8, 213u8, 11u8, 90u8, @@ -33389,153 +33560,158 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Create { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, - #[codec(compact)] - pub cap: ::core::primitive::u128, - #[codec(compact)] - pub first_period: ::core::primitive::u32, - #[codec(compact)] - pub last_period: ::core::primitive::u32, - #[codec(compact)] - pub end: ::core::primitive::u32, - pub verifier: ::core::option::Option, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Contribute { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, - #[codec(compact)] - pub value: ::core::primitive::u128, - pub signature: ::core::option::Option, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Withdraw { - pub who: ::subxt::utils::AccountId32, - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Refund { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Dissolve { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Edit { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, - #[codec(compact)] - pub cap: ::core::primitive::u128, - #[codec(compact)] - pub first_period: ::core::primitive::u32, - #[codec(compact)] - pub last_period: ::core::primitive::u32, - #[codec(compact)] - pub end: ::core::primitive::u32, - pub verifier: ::core::option::Option, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddMemo { - pub index: runtime_types::polkadot_parachain::primitives::Id, - pub memo: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Poke { - pub index: runtime_types::polkadot_parachain::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ContributeAll { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain::primitives::Id, - pub signature: ::core::option::Option, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Create { + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + #[codec(compact)] + pub cap: ::core::primitive::u128, + #[codec(compact)] + pub first_period: ::core::primitive::u32, + #[codec(compact)] + pub last_period: ::core::primitive::u32, + #[codec(compact)] + pub end: ::core::primitive::u32, + pub verifier: ::core::option::Option, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Contribute { + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + #[codec(compact)] + pub value: ::core::primitive::u128, + pub signature: + ::core::option::Option, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Withdraw { + pub who: ::subxt::utils::AccountId32, + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Refund { + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Dissolve { + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Edit { + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + #[codec(compact)] + pub cap: ::core::primitive::u128, + #[codec(compact)] + pub first_period: ::core::primitive::u32, + #[codec(compact)] + pub last_period: ::core::primitive::u32, + #[codec(compact)] + pub end: ::core::primitive::u32, + pub verifier: ::core::option::Option, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddMemo { + pub index: runtime_types::polkadot_parachain::primitives::Id, + pub memo: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Poke { + pub index: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ContributeAll { + #[codec(compact)] + pub index: runtime_types::polkadot_parachain::primitives::Id, + pub signature: + ::core::option::Option, + } } pub struct TransactionApi; impl TransactionApi { @@ -33551,11 +33727,11 @@ pub mod api { last_period: ::core::primitive::u32, end: ::core::primitive::u32, verifier: ::core::option::Option, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Crowdloan", "create", - Create { + types::Create { index, cap, first_period, @@ -33577,11 +33753,11 @@ pub mod api { index: runtime_types::polkadot_parachain::primitives::Id, value: ::core::primitive::u128, signature: ::core::option::Option, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Crowdloan", "contribute", - Contribute { + types::Contribute { index, value, signature, @@ -33615,11 +33791,11 @@ pub mod api { &self, who: ::subxt::utils::AccountId32, index: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Crowdloan", "withdraw", - Withdraw { who, index }, + types::Withdraw { who, index }, [ 147u8, 177u8, 116u8, 152u8, 9u8, 102u8, 4u8, 201u8, 204u8, 145u8, 104u8, 226u8, 86u8, 211u8, 66u8, 109u8, 109u8, 139u8, 229u8, 97u8, @@ -33636,11 +33812,11 @@ pub mod api { pub fn refund( &self, index: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Crowdloan", "refund", - Refund { index }, + types::Refund { index }, [ 223u8, 64u8, 5u8, 135u8, 15u8, 234u8, 60u8, 114u8, 199u8, 216u8, 73u8, 165u8, 198u8, 34u8, 140u8, 142u8, 214u8, 254u8, 203u8, 163u8, 224u8, @@ -33653,11 +33829,11 @@ pub mod api { pub fn dissolve( &self, index: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Crowdloan", "dissolve", - Dissolve { index }, + types::Dissolve { index }, [ 100u8, 67u8, 105u8, 3u8, 213u8, 149u8, 201u8, 146u8, 241u8, 62u8, 31u8, 108u8, 58u8, 30u8, 241u8, 141u8, 134u8, 115u8, 56u8, 131u8, 60u8, 75u8, @@ -33676,11 +33852,11 @@ pub mod api { last_period: ::core::primitive::u32, end: ::core::primitive::u32, verifier: ::core::option::Option, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Crowdloan", "edit", - Edit { + types::Edit { index, cap, first_period, @@ -33703,11 +33879,11 @@ pub mod api { &self, index: runtime_types::polkadot_parachain::primitives::Id, memo: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Crowdloan", "add_memo", - AddMemo { index, memo }, + types::AddMemo { index, memo }, [ 104u8, 199u8, 143u8, 251u8, 28u8, 49u8, 144u8, 186u8, 83u8, 108u8, 26u8, 127u8, 22u8, 141u8, 48u8, 62u8, 194u8, 193u8, 97u8, 10u8, 84u8, @@ -33721,11 +33897,11 @@ pub mod api { pub fn poke( &self, index: runtime_types::polkadot_parachain::primitives::Id, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Crowdloan", "poke", - Poke { index }, + types::Poke { index }, [ 118u8, 60u8, 131u8, 17u8, 27u8, 153u8, 57u8, 24u8, 191u8, 211u8, 101u8, 123u8, 34u8, 145u8, 193u8, 113u8, 244u8, 162u8, 148u8, 143u8, 81u8, @@ -33739,11 +33915,11 @@ pub mod api { &self, index: runtime_types::polkadot_parachain::primitives::Id, signature: ::core::option::Option, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Crowdloan", "contribute_all", - ContributeAll { index, signature }, + types::ContributeAll { index, signature }, [ 94u8, 61u8, 105u8, 107u8, 204u8, 18u8, 223u8, 242u8, 19u8, 162u8, 205u8, 130u8, 203u8, 73u8, 42u8, 85u8, 208u8, 157u8, 115u8, 112u8, @@ -34302,11 +34478,11 @@ pub mod api { &self, dest: runtime_types::xcm::VersionedMultiLocation, message: runtime_types::xcm::VersionedXcm, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "XcmPallet", "send", - Send { + types::Send { dest: ::std::boxed::Box::new(dest), message: ::std::boxed::Box::new(message), }, @@ -34338,11 +34514,11 @@ pub mod api { beneficiary: runtime_types::xcm::VersionedMultiLocation, assets: runtime_types::xcm::VersionedMultiAssets, fee_asset_item: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "XcmPallet", "teleport_assets", - TeleportAssets { + types::TeleportAssets { dest: ::std::boxed::Box::new(dest), beneficiary: ::std::boxed::Box::new(beneficiary), assets: ::std::boxed::Box::new(assets), @@ -34377,11 +34553,11 @@ pub mod api { beneficiary: runtime_types::xcm::VersionedMultiLocation, assets: runtime_types::xcm::VersionedMultiAssets, fee_asset_item: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "XcmPallet", "reserve_transfer_assets", - ReserveTransferAssets { + types::ReserveTransferAssets { dest: ::std::boxed::Box::new(dest), beneficiary: ::std::boxed::Box::new(beneficiary), assets: ::std::boxed::Box::new(assets), @@ -34413,7 +34589,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "XcmPallet", "execute", - Execute { + types::Execute { message: ::std::boxed::Box::new(message), max_weight, }, @@ -34434,11 +34610,11 @@ pub mod api { &self, location: runtime_types::xcm::v3::multilocation::MultiLocation, xcm_version: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "XcmPallet", "force_xcm_version", - ForceXcmVersion { + types::ForceXcmVersion { location: ::std::boxed::Box::new(location), xcm_version, }, @@ -34457,11 +34633,11 @@ pub mod api { pub fn force_default_xcm_version( &self, maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "XcmPallet", "force_default_xcm_version", - ForceDefaultXcmVersion { maybe_xcm_version }, + types::ForceDefaultXcmVersion { maybe_xcm_version }, [ 38u8, 36u8, 59u8, 231u8, 18u8, 79u8, 76u8, 9u8, 200u8, 125u8, 214u8, 166u8, 37u8, 99u8, 111u8, 161u8, 135u8, 2u8, 133u8, 157u8, 165u8, 18u8, @@ -34476,11 +34652,11 @@ pub mod api { pub fn force_subscribe_version_notify( &self, location: runtime_types::xcm::VersionedMultiLocation, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "XcmPallet", "force_subscribe_version_notify", - ForceSubscribeVersionNotify { + types::ForceSubscribeVersionNotify { location: ::std::boxed::Box::new(location), }, [ @@ -34499,11 +34675,11 @@ pub mod api { pub fn force_unsubscribe_version_notify( &self, location: runtime_types::xcm::VersionedMultiLocation, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "XcmPallet", "force_unsubscribe_version_notify", - ForceUnsubscribeVersionNotify { + types::ForceUnsubscribeVersionNotify { location: ::std::boxed::Box::new(location), }, [ @@ -34542,7 +34718,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "XcmPallet", "limited_reserve_transfer_assets", - LimitedReserveTransferAssets { + types::LimitedReserveTransferAssets { dest: ::std::boxed::Box::new(dest), beneficiary: ::std::boxed::Box::new(beneficiary), assets: ::std::boxed::Box::new(assets), @@ -34584,7 +34760,7 @@ pub mod api { ::subxt::tx::Payload::new_static( "XcmPallet", "limited_teleport_assets", - LimitedTeleportAssets { + types::LimitedTeleportAssets { dest: ::std::boxed::Box::new(dest), beneficiary: ::std::boxed::Box::new(beneficiary), assets: ::std::boxed::Box::new(assets), diff --git a/testing/integration-tests/src/lib.rs b/testing/integration-tests/src/lib.rs index 38f0c47490..9b68870e7b 100644 --- a/testing/integration-tests/src/lib.rs +++ b/testing/integration-tests/src/lib.rs @@ -18,6 +18,8 @@ mod frame; #[cfg(test)] mod metadata; #[cfg(test)] +mod runtime_api; +#[cfg(test)] mod storage; #[cfg(test)] diff --git a/testing/integration-tests/src/runtime_api/mod.rs b/testing/integration-tests/src/runtime_api/mod.rs new file mode 100644 index 0000000000..c70b1fdfd2 --- /dev/null +++ b/testing/integration-tests/src/runtime_api/mod.rs @@ -0,0 +1,49 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +use crate::{node_runtime, pair_signer, test_context}; +use sp_keyring::AccountKeyring; +use subxt::utils::AccountId32; + +#[tokio::test] +async fn account_nonce() -> Result<(), subxt::Error> { + let ctx = test_context().await; + let api = ctx.client(); + + let signer = pair_signer(AccountKeyring::Alice.pair()); + let alice: AccountId32 = AccountKeyring::Alice.to_account_id().into(); + + // Check Alice nonce is starting from 0. + let runtime_api_call = node_runtime::apis() + .account_nonce_api() + .account_nonce(alice.clone()); + let nonce = api + .runtime_api() + .at_latest() + .await? + .call(runtime_api_call) + .await?; + assert_eq!(nonce, 0); + + // Do some transaction to bump the Alice nonce to 1: + let remark_tx = node_runtime::tx().system().remark(vec![1, 2, 3, 4, 5]); + api.tx() + .sign_and_submit_then_watch_default(&remark_tx, &signer) + .await? + .wait_for_finalized_success() + .await?; + + let runtime_api_call = node_runtime::apis() + .account_nonce_api() + .account_nonce(alice); + let nonce = api + .runtime_api() + .at_latest() + .await? + .call(runtime_api_call) + .await?; + assert_eq!(nonce, 1); + + Ok(()) +} diff --git a/testing/test-runtime/Cargo.toml b/testing/test-runtime/Cargo.toml index 4236ef57aa..b8085a4b6c 100644 --- a/testing/test-runtime/Cargo.toml +++ b/testing/test-runtime/Cargo.toml @@ -14,3 +14,5 @@ serde = { workspace = true } tokio = { workspace = true } which = { workspace = true } jsonrpsee = { workspace = true, features = ["async-client", "client-ws-transport"] } +hex = { workspace = true } +codec = { workspace = true } diff --git a/testing/test-runtime/build.rs b/testing/test-runtime/build.rs index 8b584d2185..bdd45d08bc 100644 --- a/testing/test-runtime/build.rs +++ b/testing/test-runtime/build.rs @@ -2,6 +2,7 @@ // This file is dual-licensed as Apache-2.0 or GPL-3.0. // see LICENSE for license details. +use codec::{Decode, Encode}; use std::{env, fs, path::Path}; use substrate_runner::{Error as SubstrateNodeError, SubstrateNode}; @@ -36,22 +37,31 @@ async fn run() { // Download metadata from binary. Avoid Subxt dep on `subxt::rpc::types::Bytes`and just impl here. // This may at least prevent this script from running so often (ie whenever we change Subxt). - #[derive(serde::Deserialize)] - pub struct Bytes(#[serde(with = "impl_serde::serialize")] pub Vec); - let metadata_bytes: Bytes = { + const V15_METADATA_VERSION: u32 = u32::MAX; + let bytes = V15_METADATA_VERSION.encode(); + let version: String = format!("0x{}", hex::encode(&bytes)); + let raw: String = { use client::ClientT; client::build(&format!("ws://localhost:{port}")) .await .unwrap_or_else(|e| panic!("Failed to connect to node: {e}")) - .request("state_getMetadata", client::rpc_params![]) + .request( + "state_call", + client::rpc_params!["Metadata_metadata_at_version", &version], + ) .await .unwrap_or_else(|e| panic!("Failed to obtain metadata from node: {e}")) }; + let raw_bytes = hex::decode(raw.trim_start_matches("0x")) + .unwrap_or_else(|e| panic!("Failed to hex-decode metadata: {e}")); + let bytes: Option> = Decode::decode(&mut &raw_bytes[..]) + .unwrap_or_else(|e| panic!("Failed to decode metadata bytes: {e}")); + let metadata_bytes = bytes.expect("Metadata version not found"); // Save metadata to a file: let out_dir = env::var_os("OUT_DIR").unwrap(); let metadata_path = Path::new(&out_dir).join("metadata.scale"); - fs::write(&metadata_path, metadata_bytes.0).expect("Couldn't write metadata output"); + fs::write(&metadata_path, metadata_bytes).expect("Couldn't write metadata output"); // Write out our expression to generate the runtime API to a file. Ideally, we'd just write this code // in lib.rs, but we must pass a string literal (and not `concat!(..)`) as an arg to `runtime_metadata_path`, From 605ed70c75bd1c5434f93dff59e819aae025c2c8 Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Wed, 3 May 2023 09:14:47 +0200 Subject: [PATCH 13/22] add small and tiny versions of polkadot metadata --- artifacts/README.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 artifacts/README.md diff --git a/artifacts/README.md b/artifacts/README.md new file mode 100644 index 0000000000..60d0b8632d --- /dev/null +++ b/artifacts/README.md @@ -0,0 +1,18 @@ +The `polkadot_metadata_full.scale` can be obtained by pointing subxt to a polkadot node. For that just run this command in the root of the repository: + +``` +cargo run --bin subxt metadata --url wss://rpc.polkadot.io:443 > artifacts/polkadot_metadata_full.scale +``` + +It contains the full metadata including all pallets. From this file, two other stripped down versions are created that contain only a subset of pallets: + +- `polkadot_metadata_tiny.scale` contains no pallets at all. +- `polkadot_metadata_small.scale` contains only the pallets balances, staking, system and multisig. + +They are generated running the following commands from the root of the repository: + +``` +cargo run --bin subxt metadata --file artifacts/polkadot_metadata_full.scale --pallets "" > artifacts/polkadot_metadata_tiny.scale + +cargo run --bin subxt metadata --file artifacts/polkadot_metadata_full.scale --pallets "Balances,Staking,System,Multisig" > artifacts/polkadot_metadata_small.scale +``` From 342030c0c2f3dfcab63ce06b2f6131cbfe2feb7f Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Thu, 4 May 2023 13:35:50 +0200 Subject: [PATCH 14/22] add script for generating files --- artifacts/README.md | 18 -- .../integration-tests/src/codegen/polkadot.rs | 171 ++++++++++++++++++ 2 files changed, 171 insertions(+), 18 deletions(-) delete mode 100644 artifacts/README.md diff --git a/artifacts/README.md b/artifacts/README.md deleted file mode 100644 index 60d0b8632d..0000000000 --- a/artifacts/README.md +++ /dev/null @@ -1,18 +0,0 @@ -The `polkadot_metadata_full.scale` can be obtained by pointing subxt to a polkadot node. For that just run this command in the root of the repository: - -``` -cargo run --bin subxt metadata --url wss://rpc.polkadot.io:443 > artifacts/polkadot_metadata_full.scale -``` - -It contains the full metadata including all pallets. From this file, two other stripped down versions are created that contain only a subset of pallets: - -- `polkadot_metadata_tiny.scale` contains no pallets at all. -- `polkadot_metadata_small.scale` contains only the pallets balances, staking, system and multisig. - -They are generated running the following commands from the root of the repository: - -``` -cargo run --bin subxt metadata --file artifacts/polkadot_metadata_full.scale --pallets "" > artifacts/polkadot_metadata_tiny.scale - -cargo run --bin subxt metadata --file artifacts/polkadot_metadata_full.scale --pallets "Balances,Staking,System,Multisig" > artifacts/polkadot_metadata_small.scale -``` diff --git a/testing/integration-tests/src/codegen/polkadot.rs b/testing/integration-tests/src/codegen/polkadot.rs index 9f327be869..14a0cdada0 100644 --- a/testing/integration-tests/src/codegen/polkadot.rs +++ b/testing/integration-tests/src/codegen/polkadot.rs @@ -4449,6 +4449,49 @@ pub mod api { #[codec(compact)] pub new_free: ::core::primitive::u128, } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UpgradeAccounts { + pub who: ::std::vec::Vec<::subxt::utils::AccountId32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Transfer { + pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceSetBalance { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub new_free: ::core::primitive::u128, + } pub struct TransactionApi; impl TransactionApi { #[doc = "Transfer some liquid free balance to another account."] @@ -24311,6 +24354,108 @@ pub mod api { pub struct ClaimCommission { pub pool_id: ::core::primitive::u32, } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BondExtraOther { + pub member: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub extra: + runtime_types::pallet_nomination_pools::BondExtra<::core::primitive::u128>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetClaimPermission { + pub permission: runtime_types::pallet_nomination_pools::ClaimPermission, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClaimPayoutOther { + pub other: ::subxt::utils::AccountId32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetCommission { + pub pool_id: ::core::primitive::u32, + pub new_commission: ::core::option::Option<( + runtime_types::sp_arithmetic::per_things::Perbill, + ::subxt::utils::AccountId32, + )>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetCommissionMax { + pub pool_id: ::core::primitive::u32, + pub max_commission: runtime_types::sp_arithmetic::per_things::Perbill, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetCommissionChangeRate { + pub pool_id: ::core::primitive::u32, + pub change_rate: runtime_types::pallet_nomination_pools::CommissionChangeRate< + ::core::primitive::u32, + >, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClaimCommission { + pub pool_id: ::core::primitive::u32, + } pub struct TransactionApi; impl TransactionApi { #[doc = "Stake funds with a pool. The amount to bond is transferred from the member to the"] @@ -26945,6 +27090,32 @@ pub mod api { pub struct SetExecutorParams { pub new: runtime_types::polkadot_primitives::v4::executor_params::ExecutorParams, } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetAsyncBackingParams { + pub new: runtime_types::polkadot_primitives::vstaging::AsyncBackingParams, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetExecutorParams { + pub new: runtime_types::polkadot_primitives::v4::executor_params::ExecutorParams, + } pub struct TransactionApi; impl TransactionApi { #[doc = "Set the validation upgrade cooldown."] From 2990f3f55cc7553fa31d60c28f801c36508eebb3 Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Thu, 4 May 2023 16:13:59 +0200 Subject: [PATCH 15/22] new metadata --- artifacts/polkadot_metadata_full.scale | Bin 385887 -> 406034 bytes artifacts/polkadot_metadata_small.scale | Bin 116061 -> 141585 bytes artifacts/polkadot_metadata_tiny.scale | Bin 6592 -> 33895 bytes examples/examples/runtime_calls.rs | 2 +- scripts/artifacts.sh | 2 +- .../integration-tests/src/codegen/polkadot.rs | 43117 +++++++++------- 6 files changed, 23087 insertions(+), 20034 deletions(-) diff --git a/artifacts/polkadot_metadata_full.scale b/artifacts/polkadot_metadata_full.scale index 3ee2b601ed519fa5d819ae1043053fdb8f7d7044..d85b0defd7a432aad368e9d433b363ebf1a3842e 100644 GIT binary patch delta 19744 zcmeHveQX@pb?+T&rdmZi%sQc(RZOEJR7S{pHKzQiRuyPhq)3IVDT$J3#eS8sJKVj? zooIJwH8V?zMcZ-E7?9eeO|2G8(G;!w>X&{Qb=tUk>1%-G;kk%ko7O=Q;JI)=T(o}# z4@DEa1dRc^@BPlXcV=fr${&d9hX+I;wA`6H_nvd^`S_i4?(pya^nFkKV|jN+#@@RR zjecbJ2d)KqO&4u3?d8K&cz|V~(V{7f8eraru{x6glrPq+5A&r9zSL4v{ zMt=$W2( zxi3$FqJ|fHLYN|%Hpc16{!u()*=G4nFZP43X|5WEZ4^qUgRT@pl+FhoX<{xR3?cSl z+&LNb+i?NoK58x)HpUjtTr$N+F<2BA!q6198f@Fe39KLXyRqMqD{<&`Bd<=2R5!eK z;y3(wv$i_8dckY+HOvu&!YGU{burFwnBorGSkzx~=q>tcU` za8ne-a`uG<E>6R=n*bmf}=$!s~W}csU3z^?P7)`E>9Q zvsU{oB0KETcp!c9(7Z;@oN|la5$w z-~qqs%dp}kTKS-TciEL|-lQ_h`Ru+``DAHx})DPSwuy z)(WEtwN*PW#Mp9B_pq{XV4pJV;&%w}FdI>lTG0_ZZ$?Lm&SvF7Sv)} zXXGxc3KNcH!CW+^Xd$EMoT=CQJzv7*EWw|o-%h}T&Ma1()6i9M@O-@`8~rv7I%^x# z*;g8ctuCE}($h9Csg;tc{508O!ZB95@Z(ib55~L=&u@EcZF$NzR+T578JZb;aWv4> zRU^M!mx{v*`PORCkE>p+t}N%K#mz%}_jRV7(rf!|?BUk`3eCF@%xkI2s29K|fUNs> z8xy=eOWlUNDz<+8iIMN$yHba{@?q_=y7j`6dG|fy)KDCOcy5g&XR!_N$!C>pI=4s< zzHq$fg=YV3(a$h_!L1Pd-1}(MN}t^0ss5DegSA)Xc>d8Ag5-XC4(Q zOips31SO*ae&H0W6y?uahC?`j#%w+Kqvm+h2xZ&btm-j{7ooQ5k-^=ENp-clWb}0_t$p4@4d^}opZ7-{a!q?xOKU{>t0yK)@=Ru1E%f~^Vy^6 zE)>O)-NtQZ{JsQJZr&0?u8$yuytWrHCfk+ns?Z5ziaBIL%v1r_{81%NXhg;`*uiFnE`?yy?99&YyHpuEywYx{LDE1t8A zX<2VX-mzop#os1rVDYDSBzS%S@o57=l)w*ztYZ0ezq1CUT!MQ5)d$b}$$Hl#P-c9F zco=K?VH7`W8`mxbF%WMQ!DMFCLltMKQE>=8@dIF}9LajnZM@0h;xjujnrv!LL5rT5 znEk3{9M{a|u0OjYpOqY~J8+m|uxL!wgHFef36OpcKJi45q+d0cYM-8ha*zW(NSKb< z{fuqoDg4|{ylm!XpE!{%WKOLzrb%Uwm<&g~*$%wM=k3HGfK0!`A#rT3c6pCV#?WKJ zIG*WOHIgyB{B~s$pWl(JbhT_H2>6S(ag|gwnV2Kx)-=!#YiK!%@bE>_ujg!mA6UKx z^!WUaJ8)5DNDs=*GgpAEqn6)OpdJh5Go>#NS>QD?)MO}Ay2keRm7!tJZ}-8^D?9xv z#tjmxDImcYF_sgmDR>SI1YcBxU$hJJFzQYxtOD9W2mB2gjV&Z9Uz#|sQzUGX4E_2U zLiMGUe$;|P82_M*&mn98n3UDFB6FGkpaiQ3--=UHlrP}H<|cBMsb%RkPY3bIpx_m5%*iNzka9BxhW7~ZH$%Ku^1N2I@%r-6;C~{F zoJr=NAdZ}95^{KS%`AM){)R2ShF?ei*%tr2lem@_y7izzNK0)vkxtf{-{WuW^xzl^ z$t*2;QOlTu0Zg^=DAJ%t;v=Q|^1Db44umHOYFX47gkdLp0I;oM5lg`N3(p1lbGft!i6#*W;GH zxb@`k?t1Upil+mRFQb=t8=oR!OymMi1*!F#%r1OL`s=M2Mr}+GuR*5^=WZGk=dv$1 zKJbYHiLiDed2E5G5TLT6=)uOxt0|2WDzPB?`-V|Ek56GZw{r5P=uO@V!3aQ*EW~IP zjE9L?rZSVP66~JQ{8rhc+rWW6%09q(iO(%ytaq*#VD86h8hQN zOuhTiI050dnGQ0_i2KvXiQ0Y65;4Qw zqeiT=1$J0;9Z$~a#UFqY6=T1bU+C^30ZiU10NWIkN&=IbqL!ivWdpr17Rb|7G@Lar zlD9BqjKdOcy|(N%K8$jZY*eqXk`Ld%`J=yMK3}}~o}1=pM+~v`r=K&shPXNX$L8gC z@ilnS{K32N^{Ia||K+`6Vi9Qx zpdVEy=-&ZM^MA}A+J%8HjaYRHpFdKt{@A=zEN141U91Ni616G%XN#Nfv8{(kG4jKA zTE|A7@W*c6yvw>D1m67S_gNp?gS8%;w4TP-LqA~sG$^_GjBEV{t#Ix>E7^*H^4Z==;(I>yz~T z<%g~Rz3ax@pGCjy5Dt3g&lm>$e!Y`UysvLX3e?c13C9&$8(h8J8?_u z=cb%BNhOg8)4HNht6`;1KqUjGxzcYp{dPNYf^HiN<0<6w>$ubFhrJ-eBuxi1(?z~p zJHy1(ZbOJGZeI9#>s=((+7s4)A~EjzMXO4mYrkZDjy~_)vi_R%;ak6E{cH)Jk3C~u zq4EFvht^q=-{K!xe?@Y>^Yhl-*p-{dzho8Y{^Flm$4P3}{=)h+zTW$n)=y*jr~lw9 z7VYI9eAQaO=coVmMT;kU$$A!>vh{oaVEth-U!qb-aU8lrW+#4ixA_U@oCHMgLMUKa z-ymM;t1b|`)AFjU_fbq>3~8$R_$$S0W&`CjzQe=UfqJ?Qk8zLtU7#SOBR`%#Rc9r+cayN0(GJDaX769@o5A}2NV?#1X?~o9@bUJrAy^Ly3Rg1|?1zED}(r@lO z2`Ka&C76vwiQN^bCM+olt2;G4A(ScVejs+Dey%Mk1tPww#l& zov6iB)%zh8p|nvgr=|S?PmzhKRlR?|{aVqy-*D30A-j>11UMYI+!<6=>z4*yg+gln+)dbTPuk`~hQoz^kPLk%&yms;IUXE3Czr01 zyw#=6%UUDy+qz9Fdb$wK3+uXh!)f-r+|hz`V=xAJuO*}xs7Jvnc~qu}9Z5Bifgon+boIOt0Vd1aOneG zh8-`a#-8JmCxY&$f_I40$elpN{}RNGEimT?ccbd%J~{~IxaOo>GVd7Ph}>9*$7(U? z>mY<60XyM@!;=!6D;`E4WnDIMjghl`*_Y;uE`>jkwxE zemHg5KG=km(^mg|BZYIIU%- zJXCJ9yP(V?i*T&TP6U|JZa5w95-<#^Z!{mmg5ONkdi4N4r5;m`mInIVq^ArA4I#9- zV<&Y!NWo&M9EXlq1NLiZ17JF8N2qX1dP;Ihr{4#_6D$=p(p0)MLDLe5Z4 zlo|jH5h+{~T$6LE?W_}dmqV%z!v#SQDSQcQ7cre%8j1)_a_7%9o9shB6oi*#IGaGX zX99h#dWA2V*(ri+=9e58K^QA2hH;0qC-$OCtkg>QEKny!M-8Ssozzj2k`21kE9lqo z42wY&ub_gQq$Omru-EJ%PAFfUZnM^Vl$hOIIglGp5!!-9Xz~zNR4NZ~s39!>wA}|0 zHKE1SWCa3*sw3TMB*4~eAg#?_0FlL%79nodI|omY%?!*Y=(;&w zsiBg^Ae{D~#+|Tyqq6owY7c8N;l-mqJ0{SrQLZY9rr%h+?qa_6#s@VbG%5=S0+0Bz z4NXsd8o4y`YCtvlN60EjB_jlgw%qU#!s9@#&;06uj%ZD=Rz*n(KZVeNMk%SKllBx{ zhx(R!LV{B*Zvz&A&87LNh79?_#PM*)ZNO4gV~b95P{#lSRw>HE@h52mZvxNh?%E^v zqxP7eu|-16rciNPITZ#9r28~NdjV3gr3Q?HvMTLnA&P8njP>IGIgtNpW&8}36bGpn z00z_Sf+uFxC6AD*o5H+=u(XVr%&m9V%&bKGzQje^ zgk0DIriZOSjnN<_I5UvAimprmNUtCWpt=M7qALULCQ(5n;KzPC_4d%Llu2l`WYKLZ zW!Lgg)Xr^w05JvNmEefic54bB4rZsGcdyS-BNgAczI4QT#@wgDB5Ww10}Y-hgiX(5 z(-5JEa>c557{w{4j&l?6yqhM4n{5U7B;rg>eBjZrUC+3F^ifWn2e=Kv#G7Nn3+BO(K^2dExS z8$_fT#Z;qn88pm6MKHa25W?_rY^57tA9;DNO3qLaK(JsFRhb6#444?;1t5l6q7+=5 zc0z zuHuJw>>1H+9eJHvN3qSJryG1?m{bHFPV>BWL`I{IYPc6~F^}rnCIe=(L~iG>wPcx} zA`;0Y-koUjI6g_J6Q8FjWK zepCSxoa}3FfJ6OgWM(vT(Ox0hPcmdMg282539Y6CS*WaH$xyQ zUKL7F+=)M84VuRLtZPM7Oi=m4BM6&Yl{(I)0Gcus7=ojm489#?GL@?!FG70E2h`B- zluW94dT;SjBS}3kjHjUz0q8SKYURR7Z94ivoL`gJHZV!{1!t($1@M#gpWQz7Q5`g- z-@J@pPsmJtn%)sEA{tpIZ|Ax{ZWkZdo|`R}17^@?mI$k(0f5Oc)qA3&)6`%>2B(e)-v97}h1d#NXruiI9bsddw09bKk#I#aGwRQHt z0sH`T%q=XOe1zPx>Uffc$u4z_8~0)rDws}ZT14j<1Wx6otnmJ&sSX`>hGwbxvPVeM zKC4YIL@yEt8oA=ar(ACQ`SrcYpzc;!9NdB?p#~K+pSEW%$;~P{>ypj^;L7v%mu&|H zi_A#7PG2A8O^b4Vot&>)4jxO@c=Wj%m2*=fEW>Xj-Q5d!p{rfajmLiGPQ$zL@;{6v zuR0St=SQj=tf2)*DS>KL)JULI7_Vle(FqDgUTui)~CcEcN_`)D0z|!VhLCPE6FXcTo;X<3ExF^ zgR@Lcj2~f&7OH>bAUHTG@-%HA{R}mU-~gKawgaC_8<*wa9B!}1ZtwL(U%>e$K4&wf z#D*dzDt}MeU$HBYL0ZD4Y={+!1b_{6ShrZjgRsP9t!x(UJYUtZoSdgKOVHk$Ou(R+*WvoL=6F?Q4k1CcO=th8FrG?P*-b`wB|UVfk^cu+dyST$uAuO zGi85|gUbNcD9oahPrKx$h4gy5tm~|h1x2u)ZM=JwfB{WN}^C^OX<*-@${~- zBy#bfipqrMz*5j(S2cC=QXqq}Zl|Vp0XZzC8}NqY;8@kPtH5Rqm)8)T*1MduvjhhZ zk)2S+K(g3y|^CW%|N=!T z%Yh6*W#Ay*@wuefCU-XQswWeE8DbmhWZWPoB@+sa-{JGINt_VIEgag0nDXkZN=g;Z z_*Co$3s;?hS}dwWgTT(Fo&g=#OdfMc%!5s$J<{$Lunr}r@~KV;zdz>Cp(*TiEO6o~ z?Zoj8r0h7SPMvdTga(N8z~KB29bOvp@m$VH7{}9toZ)4Vg5!^SG_y=LuEI1A(r4qM zXN`+%I3iW$_g7TQQ{Or=^0Hm<2j&I#93vsr$QN` z!{M~A*<<|u8}_&Cv2WsB9vv^s@sm~shBiSlxkfbwGD;+l&pbN1OPBC1Sm=7OBS3Fbky|J3zd4!G$0|qMBFHa{evb>&Dfk0E=ZHD zDI$3>QX0~CIu!<8V*e!{hoghpQ$-jZX^;(XzJ`>MSF5R~YiVvsBoh^Mollt2RM}l} z{3`aM)xzU`Y=vb0=)?IPP?)|A=T$6`Fs63ck#PX~+ir48mY)k^}9ja-)!yA*NJ2SK~ z=1190!F_Q_AFxoBF^N%ie#FJg71;HjM;LWkALXm2kq*W#zEtL(t15n^0P}3$r z%xX*o#X3#l2HK-e5pf$9a@M$t&=Nco-qt~!rmEgu24fY4f%pcVM$n63FZ_nf)=xcW zzAtIeI|$?zK`f>5t~g>iA7bD{n2{q4yEbPI0fl&jMQSKRYE1D1cAVn|dVr0}&?Gp6 z0W$(h8`Wq^MRgP|P#8l$6Hjv(RI5zP-E$a61Mj)7;<&D>z@>JCb67vZQH3uMAWP@U zT3~q!IHlKAA3E&b7LW(s8-Hl53r}i&mQ)8T^KO5I6)lUR8W3L?Qrk%ZZ{#8sn5V zM=rPSHP$I3p%SD{t|M2U1B-C@fleg=v1MXFVBswp9NLSJ7rFwO&MLJ9@I!A?c%iS7 zZB=jR%JqPHG6e22{XRsYOodQgo@z;mR#D^JgM=W&Z0nS8rxsx8rz`y1-KjscnMR5^?HD#40M=@vT~}t;v9YxbrJn~GxXoZ zscanD@A>6vOrqWpAjB(-(c#2v=q>}1x!Jh|cUh}TRUOmkiks*g=6}zMg|sl8)CUEG zB2-C^$*K1z)j>9X)}0=j3hxEvCh@oKJ#OuvOm$N|Fu||R^6&H(0o3xGKDMfc<4wD( zXh_nV1kQv?ldn*JTy=aeLXYqwG*0hAk?7@moDGwW$v3Fbl+;THLj{`4#-7og3N%TR zbm(>!8Y)0!s;W00+BwYPcT}Z8zLCor^_k}3GEG{784&U|#)PRiF4It&vb{=!`pTQB z(m<)+_8JXh!rNV=`FgHIqm+@jCbQ558!`^KHC?Vr(ki(6+Z8+1ni#Ram2%As`Uuc1 z^_rc_H6{IOdj_&^{MYN_dvitZ8;@Pv_u*R+v_1N^7PY@y)7F1g#`*uCrj1hD_PU-* z)|6l2+B8Q+jv1@7DGHuXUs6E;GV||iiMxs>`eE?rsGXrE!}BEc*D+Arq$)A}RT7

`}~1BL%4QJF$c-PMb!S)yD@wwPMp=y!o%wWutQF6^)bv^9bvf}-#b|U zQ1);wSNTT%tO(6f_bHVKzae>*^C8?>RukPU8ysAEMTqq`k5eG)a zvKpb^fWu*Oj5W*Z>%nq*TfIk0XU+Mx`dTUrkw0UtDLMglC8}oB%mj@UX(jsgek0Mu znM;OqmYE+qa7iacVVwN#qEm09_*K!BH3hsu0Le9lJgIWkXxW6( zH9xDDrrFY?*tehc^@T()w6no@0$2s9D8x~3b&E- Qn_6L+-}R*xc3MFEUlWK==Kufz delta 411 zcmW;G&r6eG00(fN_j$g)s|}rInFfMPK`%xID;(tx4wMchh%OJx%l!4i+Hf0)hX|2f zs>4X)$&y0oPt9LlT7O6H5IAawSdnrC2N{d4f{FLh1n!IJ9Y zLP>d>^-c{+RW03iJQ0oAAuC*Vu93T!aZA!&hY*-(z(=L8dr-$74}uj;-#~{kC+ti7 zeG_*Kwt4aVg3foMMsIaup0*#eibq{YOQyQ<#HrnV=-|CRoC@~zV@&9!0SwX^#6mf< zL&$;CBlu*{JC287DvVbKTcbFZVq$J>vYxl&Sgd9tiF_rqFR|z1(=>#v^*^v;R%pVq zBk}t&d)$uv@3%Ad1{WnCzr}08#w>;fXWnB~(Dwla2d@y%+)Qs^O0s?vy#~WMd@iSd t8_iCR72%MK?!zzj(syJS{DD~`^W`TLzaAo>GM+z>Z2F58=)wt>&j9STnBM>Z diff --git a/artifacts/polkadot_metadata_small.scale b/artifacts/polkadot_metadata_small.scale index c3ba19af1d2cd3186897d52275b500c23bcfe6b7..fba6da3a21005daff0eff1e1080bd6f59c9d4b30 100644 GIT binary patch delta 25877 zcmch9eQaFUmEXNHcgCY+m{J=mOS^RP)Rhyep~kdB?b0f3h!m-i2qn=XrC70*na7z& z@C1cBXJuSFi;n9Q6n`r z&aTmQu>m%P4fJ=;z3-G! z*cGQaILrU!29LIC%T80~`)6%`O`b@L0XfpJn@&9_uHl95~hr8m&Oc!FsC} zV#Wz6&0Hae{lE^KV$<`2uJIGj`Jn06eYfmyKVY!pt~!1&EeEIh4h3uz2?6kx#A-0jDD{j*V zqnMYc($cIUgL5B@S^P1YHsj;xWUW_#f}sm?O{5a+-B|V zkM{6Q9IfkQ7rIY&A#8sq-jKP44(T*k-9bWpLYa$1K#7gCyhobR2M#1JV`8!uta(i^ zd9E^I#Y2qnOw5KO*3tV$J`|6N@BBVkgEn84xR{oc?{^D*Clj;1_mH6wulG3iHu{#3 zb%;h#bSst|Sabr?vr#9Zo{vC|JJ`T92(dq<29GsJft6a4d70baf7Gi(^hN)oS96re z3jtBzmFb^vc-1p@#S4m!rVGh(*Bw8%J~p-vEv#J5yje)yliA#Pn;Z?t)FP?QT`+DZ zo$|yII5(NemE!qjujwQfnTJ(eCUux?)*43~-?vvCMJm&mf(q|}B)bh4rnE0*>_^28 z>@i7_;Rlri2iBePfdjNrYaBbxWO72JzL6I9YHBw7ACv>~$mRS0pB0XuBwE>A9r7xy z-(zwpo;sIF^5SWjt1Y~EI?c@3pUL-N#=;?(BHF<@#M)N_*}h_9G$<#+R^y!AtQ2ed zjQ-6Jm0gNNR^dIyntxPZ^xE#&wbZl`z-M{CyX<{51` zclP8&#A>fO2it$1{Ord+u}4lAE_ltNOWR!qXU*{=0ye*PTz*Mj-~7MF<^LIfF)i|N z!XA!NeK9T7l8_@_!)Y=f-em<~L8sJ3oFsEys>)h_OgMd{xLjZmm%**6o^eee>-T z@EyO;O<6ms{e?i{6;}@{5#KLzsPkupO%w(WkIo7og zWt4uhLv7ynptLhPmAKbD+G!r`QrG_dgR+{=>{jBGdA8d;yF+a{Mfsmnd)4N?l3Ymb zQ=4H){`1s+wK-(V@1^cloBz|6pS*oei3>SpO)WJY=ZM|Nsn5wA99kYU9Z{RRm*vUS z{c3Y#S^gw-N?rS68I~kdQ{w5|(C{ z{Jms^V2Nq>D@wd7^AEt>*pcffR$RaAtvk(){N+FR=|32`9ab{+4JDq+CoRZWmjMBk zlAC^0j>xAs|D-8@FI7u#zS@*i@|kNxzP#F-y^Hei%bi!%^Xdh4UA?GYQZK7l z)T^82ugWie=s7ho10-n6*EWCfRXH5KOZ&dA#4qyOq11t8I{yH3A%V>H&=L$LC8p-2 z0kcWuHQdIVZz`w~jB7jzHdglKhR836Fy!OM8ur(JZ&Lw2JpVZ?MIXV(@T_@mop^ zz>riOkrvjJU15j{`lcuAWpXG}ZZlY8?ud+-o;kl}xBS3A?)YA-33Dj2V(<{Y@gT@T z=33+87BPxtjzm^LggG%Ee`=dsu|w>^I6@9iQ+x>C^Ck{=qJE|h`E4H#XUmVmpVYlz z-t*418aU(pQSStz0IXY~?LxLr@XuT51c2*%?=4G-y_k6Lc&6F(nmFu`;Wb1{$!^Bi ziQgycA(ITVgfZLEFT@U9KN#Ao0*Efj^J+%QjLhYZolyclL5MsyR6=H02JYyC^yIFj z#>8&?mD-UJxA%40oGU39oiSWtA7+SK!@k@o%mHc#?uzR)M=S#XAlQ4iEV#hVD4Ii}fs=r0+3%gPH=YP1k2JD^eX2!=xEH&r zLH_9P%E&Er?R)RLnNHlzB8wxW0hgksRfvIkgk9ATS8qWvohCvdfm`4I-YXyEt4=JB z#iRvD$C%iX^NB|b=361HCV|PO;{(*q6Tf&=s5NxSUIn_q8s0i0n9d=|5qqj$ebrfq zm|1cmvCVw+HC!VWY1pf9{t+9+T^%B{JCl&1Q0yi-=#-*Kve{SDqDKGj&4_#ZdZD%H z&mszI97ixpc4n@=;%TUsm-9Z*5ZNBY+?5e0I*i~>;Mgs|awqN%DEt1Nq>e3?*PKeL>QoNF<_hv<$S;I80DlCF zt+H3G5?Z+@BWDc+JY>F_t3bGqbWm|G^l%Fm_i8ol%j5@_-C*4*4|q+)?fvuq@+h$x z3JDW9lM!=<&agWi7(G@lw*c3f&NwtfB4MEppHc+tz%zT@cB}Ss)tSu5B|~b*0U=J~ zo>{2qyY;f8xjRCcnxfazPF#gY0hkl(Mo(|B?5Nq>rPRS(M*jYk8)*F>vGk!29N<$Q zI6%h+A=Bo@9lrrw=7Q?|DLKrdGp4bv952HqFzn}a&xw>Aivs~l{0O zX8JCF_OEUa8Ry1ql6fm)A8-|2V}hAFYQ#0{iCG1#myugULyG>x0BK|mCdrE4pAn~e zidFbPa)(LZZ`C*!gt4*a>g8&y;#9DswFI_T5T-#$puI%Iz0 z@=yM1;G^^LGehOX?B)Ky9{seKjvqww&@c9;f3-LDI5eKV`bI{ydJ@R^u`(UHJ`&Onn;{aw&mnw9h8CbglYm1` zOxfi#h+7wtQABKAQDRhbo*SeB4)ZfUZTmq=9Gq+r9I&elpeX7^>SUvvn$TpCss?XP zZ%dC#(j(4xFJo3YxOF;MK455jDkIIAlUsz*nSp0x$oq6g-k2U}Bd%ZNpUGTJUr7rW zA5zcZB6<=wzm+hg=mcXn(fw4BGZn{7MZd<#ns!>_?2ZX zA5oUdYx+f`S&H$g!zVNHcFDBIh9h4yKFyk-Awlt)4&Gl|$dL8@#AiFi+iygy!3-EAGnUWz_(=ZH3S19qQ(pk@w;OZ+q zGachL7`9rkr6GTpANlF;ggYsce<>q&-|UV^+@6$xw@U2Gw0GRqbNWauJu99-h+ZOO zzV4Wt3E@jAb><@O-J8)6zmx6Y?g$lHyjszBU4iE?n2=9`th}(!vlP!b8~&3DIt)3Flk>P;{g_8j7^Z@!JpAR1 zoaW)0*Z7);9gL|#=?Gxne_6^+rZq zBJciYM!cb7?FJC-sA|k25si{igD?!j4eb_l7M0Z~Jq@=wH1E_Yi9`%~v%SzZ>&%>Y z%AM;B8MldLEbS;m#P3+>b=501iVCn(ZjqJ(7uz*|j8>)33-l2ZIex@Gf5fRFS-k*I z>?7T768B;P-o1Qg-dlB%GQg<#QA&*SqoZ~}emMCkEf%7)!gHLnl7S)h5JR`x2ocOt(LEnW*21Qe{V*2y8Uqgaps#QIs4~GC$yoP*S>K7UD>P>TN zyn|avt|MoK&B-|EC&*+nBOxh|C)8p|%4}DdEVHZ?FG7pbyK#j={6!|u`B0dI0jFH? z?Wo3%eRgCcOZl18LOj)%@2s~kJI>0+U^#4VGy*R%tuHIbc&P&iOub$_O=7zM|MnHr$g_}iWjzB9!Zdms%KXy z_e=lM#qP_>^K`o5DPpa8K($`_5+y={JI`-j4b2!BJlu}NhTFlH8eQVFTU!V_q-F=NG0Mu1VX6SA#`?UWqU0lp4pa??h5pc>B&jm!f;Pk{*%NZ z3@sxTT?>mqNcnouX8If6bG#ldUfh<-hjdBebI!)GbI8E^Yi?tKx>HCxlC_DK+M*r8 zQwCj{4vY??{BnC3Moo5Wz@*lISNn3*aZ{_oM#mNM0h3W5K4`)VTmy9w9iw!9|3ZtB zLt^N&xc}p5{6W@cP+uA1rLoUavk_9Ens_BpO>ep@8z@$c&O7$XQ7<@5WpmUirWa5H zaRPi3Md`4U(T+5h(TvE6B}2s&g3`}Xy+J3GccAOw6&$mjsvkv~^$3p2sd~=-=~Vp@ zeb(1H23yI&7AbJY;J3D8%=}Cp^=e82(rtw;hsfM|LvNDypUR4tP((>t;_dAg8esM) z-FijQ$Y>QSMPSy>>he|01PIwM4=96ofhG4GMb&&R`7eEidhW;!> zU_MXQD>_MlXA4zeI5R<1w;6Eq_+kB+Fy=?XZML1BLdV)6ufF20wsd7)h(R=kfr?_q zd}9IRpg|42E)B1|R;)Vp)nG09Qk5Uh%Hd%Q7_sm_v`>vh6?g=o!v9k~ z80LsJjh*M`9d~stfX9%-I`*j}&{cByI0r)X0Uc#fJ>rf==Z|D%C%Z%@x6RoeplxP| zW_>`!;W|eIPu)%Sdv5WOZMGQT<%wk@nmI1Xc*GmZ9-y*8%%oPlknTbte%`{@o(%it z`85dP!j)di$^;WoNl9LF-*yMOSv}bCk)$3x-mM3ZYdyH0i&5L)LuHLq;4_vs8V&&; zKwLS*G42?E+pQlVT^V~aD|X?p)Kgipvtyg5ySI5-Z*%)cEJ?F2M9f3Qs>6<> zqCv7BhR|BJeP_#LIRqWq`rW);`4S4HeM7uD!+v|!nJNd+VPNekl3X#cq= zZwp^h!7O!1>NJj{6L0>jDtJRp_fthOKZIr&+EBceR$sS{I{;{P-wM_o%RE3EFn=`d z)`c;L16W5FSC#Hnc}oSVf@Cj+whj+pMPOPFEr!;GgKiythalq1(X_aCB~ah8=HjQ8 zt!G&0T(|?Gg4eNhk8wfmmevx!ED`A?%aCN*4HskWz;ZzIhPBvQ_L0f~Az?IvQZ6`^ zXHf?i_oo%CsPiRnQGYo#9Ei7-`lAjWL{EqbcC=q%KKdHzilSkYiWr&yx$6I>StQh) zjD}kv(KaVC(+VOZtvStMebkb9QnFmX{;9z7Ta5 zw4`;ycdQ3Xi%xarz=3GH;(Dm>)-Ro=v!n64Vj(GF*(k{*7LL!~>&mCwE1CtxX_=1> zsm~abnOrSo(eex8d$=~xj`Xp$>{u-{ED}LTYgDaLym*_LrGk>?rjMArDd}6LUVnYp zngxD)JEW{wVj@8uokE*>`OH+ytx_?30{OP;MiIqq-9x4J#DBi7GMWA=Wpt_=yoA1q z_<2FxBV)0^5n?k)+(hWUl{0;g5NKZiF3# zqgkjht~=u+9TBI}YRx(f)$!LhU;di>XgD7=%(PG8D=enFXm(}ZRO()7MbSt6piP8d zVD*V+SS0jXpwXWMi2G z0ZFmQ#uR3cdNsU@KqbBf^r!lh4L3j0fL+F*V$-2+T3_YQt$DeAwI2e2ST8n?W*8Ka zhw%n<@R~!fC$t$cS>|wMu40|DeWUsyrZC;`Tr@rv0}tC!z=7rWOOq)@(iyqY8WDoTqgGm)1`@GY!PhuNA zi+8Czp_#DFPU`QhW2m4Q;>jQ4MF__$?$+;pvbi+);uCDlf}2nEewRHA>arc(%vxg#-;Z0OXyz0Flw>U z4wmkO_!6znLw{c@1P;%pADYm)xWGw}10nXY0by4G-%ztR$X}p3MG_RYnMP7$)u>Jg zcWwnp_QTS^yCqKIf77Z_5J(H~@zL7^-ecGX_zcNJ2E*cxp@PDxmq2%EdzpwVPDs9o zL>uY`ioj9`cMMb#TSE{bN`>iTD=TbGKkqfqI8Bo63A|IqUlq^scPfE{{<8%oXa?Gj zVcb4riEaN3@48C4e)v!74UPd(g$a*Vwe+f_gM~55i}Mn*o*yhE(#R-vss`MIHr3Hh z#A!~ykVtvzLYu&w6OIf!tVBE>@8VD~j`^?K>!9bP^A;#&%m-OVKm+Un@g?!tXrSii z1XR|5yMa}77eb|eM-?M=5Ap&*=(jOhT=pf%)twsa-Aw9J!#X(tU*|lb4V*lBz-uD zD&RNN2wF({^Lh0p7T~N2$Z99)0P(_epe>Qa(u%t13Kn&R@p?d$1fbUJb*Ka`m)55| zFgU9huN5j#72UxVRqkPQ`Na`feoW!E!(mJ_{bHvwc4okhPelaAD`>Z^Z3+X0kYt~R z7@$f5HdldmPxwS(}G78ZDR|FoN#Qr60-L2 z%Qj?_5{K7NKjPO2EGm*01}n9f+=~PfK|wa$k^P6LMTdmuI?THbE&b7raNM%-DO4f& z8UP&ZYN4bNV|#V#`$V&npJ3mR`Rcj!6Ka=1k5H;)9MqmqD4XWv*5I?~Ec(47O1)TR zDq;dOfw5*ke%~X!7j40iG2QVI#&1+;j<;q%@@r|1FT@P z(9#VOP)h3Iv2xgM-JOipue7Za{YG>s>{g=lV3%pFjUaW>K&rMmI-ALzrl>``BVZG1 zw$$z*UISK%VR?s^RW?S=u#20c# zWB@fGD1gx?Oky0uXr*=*G(du|yxId^L~l?&ZbCZ*?{GD&&xRu|8Z1NLc!VDO1}2}1 z21IWJMh`S9G4Pm}Q#em^F}29A2m&kA>rU0*o`6R)Ij4O~5siFJ)oMslBTu&MN(COx z1o%XTb{6qb3J4X=P-X>tv%2^7h{}lk8b^+H)kn_8G=~%(YU>88RB?HO`?gisPnK(U z>Y229B9^4~U~Mruy2URAu$3!}lUh=QTcmf-eY66oyQHOi<)Uu1w)5t>UR^^nG@R@1 zIE$x3TEYs3`d)P%S87_S{K9D49^nOr0k$^z*E0DZ#}u{=5x`QXTQHAC$R<+1v{NaF zTcvgM*wV}aE%s4>OFj@;c=%8w$$+)odCv;KN3?*af;hQzcVP|hVWP*m*jQfy4=B86 ztVJz}xqd&W1<$AB0<&`^jo0qL8JzVlQrdc0_myuUs`R(NzUeDw&CS3!&XXBeXq&oy4xEVju!%g%Sted== zkTS^D-Gx~A#akJ5KE4bxSulp2Sc=sncGo(e95+ZQ{CWf|Hq=vVOeU-TUA&SWOPi4a zLre|03(cu&&}SwV)Q>qTnp~J;twJ=`+=zUpjw--JT7XG{fEdLtSloJoK&^j_`$~$d zI{PjzrBx;puFWtj2g9kEnZu{Z#_M0{AT4z2R28q>i7hB!t6#9E7kj92MBLs!2a8t} zcNsC$>%~$?V)q@Rrf6qF0=UR&8AMc+M=8SMYv|uj1?FZuMj$Qbt=yZPK>uYC{Q_v- zglGg%8clvtnZRihWE25uObDckrYWF7!bKtfI}!BXBoJ2mos4`tR~MCaYzkpS=&nHlc^LedR4iiF)tQ)AJ?15DRyKoBtt`sC0!^rw*tPHNEGfN0B zw~C)p;7AZ$Y)>L>rO*aZC5Wg}F@w`K%oZbN%Z?j@U@G5$O(x~f0c#oQHj|&C+#BEv ziKtGw0UKZ}6iydQ+Sm}p;}>-3GONgNC9JW28@!8h()19Q6p;yW#@~qLKn#bm!5T7B z;8Rk%b!KeDqzecd{1HUNR1ME0~U3U z;obvre>Scm@(o1J#X552xJ4rj{-g=*ekO5Zi+gCNrDz^AHAW_ITOmp_TUnVht*s=I5NV_~HEzbBw1IMs*5X zJAm9^2-e|uY))qfm~bb1HaqaQ=oIBNH_g)LiE1Oqmc;QN255Us^U6k&qQj>=MpbvCrQ1*qmKMf zG@kY%nL#cL0VV7RWQnbra}j0_c!)CFsI)_4VceGyyYg-&eZ*1}qtY@&1$`ek+{I7H z4`^3xfbfG0WYA7Oki3CVhYWZP!q4}URF4koO_Db@4dA8SS8e_n;vK4V$p;y!kP$_-9g}{NnqATuRnSnMfT!dwlZf z^ui<{Q>cH7i_8Q`lWsra@-p~rP#4_~Ocj1Q0B)Rq2bUDXnN%6iE37|7=Gfc z&~ZjgQ4t>HH@}P=3vzs>P==G~O@^mF9o~hG!%yEmVigJnhJ-+j?D(dzzmGPI?~y-? z){2XLNeVcpU?%Omt8gQV1FB| z5C20siVp_tZ-e#28-V?Hx)8I*`cPTeq@GY8@i|2pTY!EKoF9HrK)(mhr(aOALG7;x z=#Lu*XWsA;mU@hnwB3GByFJ8zI%p~E0mMNhMoB2$7XV+%(Hyy*$X#kTfT(fRuB=k9 zLs?SOrsfw+Z(Qt)+P4RX#8=`(gOS*+I0bmZbi?Hmqf)4=fRr(fxBe9Zu<;+ z0UW?|-)I+(WsaIyW+d|UNJ8LsNNNwFcyi-^qj>>8VSt$ieHuPl_6nd3Zk$>Jj#?o* zPJ@3VRPYX`{n|M>c%;C?uj^<$Q1;O6LH%C35diq3g4_pXkoaeqsv89~VdEWwhC4Wh zH4<&@k8TO+@HA{c=BuBYoSG@jM`EP=_BjtI?6mrRoWEo+f{uNh0~p^V3h|*G@$l5b zSjS4@N;a_uw;qJ1p9+<4qkVXZ~oL+!x0O?0+Z z?GU}wh3FsGh(7#P6ZqYbp80vRh(4s0z^{_P?}qg63(?d4|4Iq`Zb<*W5PkToCh)r< z{rf`n;SCb_sFzW4xHE0315FJFxYogrncddXWc2f>c)LmeEC-yRO1?rSo>U4|Lii74 z29a^H!)OZs_PPE+MiVBteHmp2*rCKIgb+iaKVU!I{t|@_y)8E`iu+B=tc}+?U}iWl zH_fu8GN3^{xU;?gzIbwpunJWL2wX*k>V!T0T%`X5p_rtX>_J}igDaoI50~VY;v8#K zl|+reSN*_$PUR^zHUumd6+Jj}%87=k0zqRn0`mCh*$Cj^JdwLL#tSPIV5F9S0(e3K zMRDbyS1@RZ2GExwa0_yMfJy6a{9?*P3}%o6bnx26v%DygihD3`z)%@XSG%oJD_9vX z0fta6ynsHZ2p=$)P_YG8BD_?w77tC%&!E7m>q?E*GJgN6%+waiUa7ZtG3La zAv1LBnQZ@^mk`AIev#E(0+ucCNE7iNYw?Q_we%%kwr>~-ngyaL{mSk#+q z{>6w9U9c0T0Us~QlnL6YG1LI*1>$0zzEMNwV=k}0*8%y>_ee5g7!jf`t7O&-=PGzf z<$p1Mxf0`1dku;@o%4q6Gl){!jpV>As8j4MEG@Oa!!I3B?*xeJALcbs_{PhH`PTX1 zb(KfAfBw0wnAT75+8ust21&oL>L*9MkQMWKgn1DV9sd}s2KC3`{^+rO(Ux8a;K%x7 zzF&xBC%mEP5X6YidSfQhOGo-3qyW0> raI4WM=@;z2yyP8r&}?Q@nBD<$>u6Fem>qiX`KET5=a->-Z6N+X=YjMu delta 856 zcmX|9U2Ifk5WVM{*=$?Zm`Xv4m4H?R(x$sLjpd;a&@{lqnwD{YoO5y} zGdUxd%ckEAhx6LEpVmAS9t&e=v%H@~7TxkNiMuhItO%Aku9vs_Yyu}N)VaI0XZu;# z`5&sy+fK&zU9V`%k{+a?WuOP6$V)VZ9aTlLj)ghW>h5DsV2~`f2Icb<8iFl1Qm6^a zgA|e&GM(FSlAb+8sM)OTg6kA4tG>*#)CgHC%A|5B7D+=IwdEtkomOD;p}d*KaOe}V zVkJ5%joqk{H5qITogk~_30QGrUj7A{(;4(p=oDGq^W3RX5U^+ zu^daFK@JXJ4PKIO2Jos{!E$#1>#^E24r1vuSZCrN;5k&rxQW+t3%Btmj&lchN%1gJ z74=-zw%_;c;7hZIvC6zSiffE6^T;5n&|_Zz7M}uHdGsA7&@X4c$4TrFZyeh&Y%Y&u zvBEp%&JT#Q`iP`?0teM+B$E?pR$r0)Gl9CGn)*q6O=^tH?XxInb&ky3dE}J3L?(F= zUxw6mGLb1vK}`pmD_C4={OaG@-o$=gY1*o@JA3^&``cT4ZEvSec(zlp(~m>nZWr^~@jKYx Y*zW1QflH8lz0UV5biprlv2U~WFYC<@aR2}S diff --git a/artifacts/polkadot_metadata_tiny.scale b/artifacts/polkadot_metadata_tiny.scale index a61038b7b3f4089abe2a26981b643a6553bff262..bb0ead8d79ce85203acedebb709b24da21dfa376 100644 GIT binary patch literal 33895 zcmeHw4|rV1wb#t*I$5{tz6~g#fCAT`P?^fxwIippo)RQmawQ_!vL(At8?$@0dnIkX zyLY{JSGG#SYoLJ^8fc+~7E)-TffgEQA%PTHNFad*8c3jl1`GaNSxrKlMW zm73d)Rx~zKDn;#jYoUDOL4gN7>3^s_@r(YA2hRzS#oN2Y5dQyaF^2!YN{k9|)u0&3 zjG~u|VP#{p6_4xEXO77ocw`=)UrM;py3S}(+vj~J53r>7dt zO0CkWY=wo^b|Z|l^9K*z)P-VPh?Ees7z4(E|2EU~^(H{0|FNa0+^&Xm&1Tf34-Z!A zGp(>gCUVe<)_q;mS)ZtmQKu`UYsk;ojP^mRAKJ;(G#0|ABIX+zvwt`AESgVGBkv~zdZZ9{Ztx7p;3MukO!fJGJsZy`h+BG1~ z9}VjDsCBd%2CYyGi2UjL`FeD*J`=}b3!EN0){H(9*2OL{cDf$78;z*h3d`auF`ayI zKB|_*)nfd3)SA2024fi@~-U zyC^4LAD^wnji6Q9)NhUto@j02Iq-~!wird{+YRt+cB9>Q|XB@*)gjF zV)keR4%NcusjwD+!SxOBZ|rzvxF3Uw)2mUm6x6rPqcJ!+s3y@9d6}HftHr3}l_$n! z7wghuyn_Rtn2^1AvRjPIUD^!VF-_b%#OTqe*=#q6YvP?Wt4>@pLVSV*TYLj*B*gcv z8V-l$gNF_sI6So6UaMA0UBdrFW?3n0Jr2QwxUhklDK~;l&}bxHnU_<#pUFwn(f80- zdT~&E7wWStZkFlkMpQi?l%tl_ol~qsM}uk=lOZZn>9y9Zp;j}fwBoTN)!=-%dNER} zDMSqqUX>Bk*@O}fZ-n)*St$*bD;r_l8l6>tEVRNJbZ~UJ8R`$E#i&$ssm3x_$GnFN z5Ty}0d?qYSwI^=Dq>a!Fst2y%aZhAd!k~HuPwo;dg+@# zhQ^i!lxzyTD~pNCjCF{|3SP@>HQI-jPfSz+Q8aFR1qZedmwnIqQg0*mmgtp|A?!`%HTc+nb-ixbIE6%Rq z|49!9*>#AZ=VP;T7uuDrs1%U8!4O32Y0XO6NH3J-C6SeWw7w3L88$CTkc7J{1FG<3f9X*qALL!!So@MSOkiO-4`dkiR_WN(HTy6ByepYT@XXTjKf6EQ=% zz~j*KBz-tS_~h31B6E9C@%Qs`X!OjOzp@V^%Zzmtu`AWh$`P=#6xHBr-a0dP!;^XG zFMU?X9v$}{(wE-)kiOD2Bu5c1$aGJO-SKrhGMP4#W(4=X zy-*(W?IT*`rsl`|4U|}fi-IsETr>#_{26ZUjwY##5u6Nhx*7*1qi~^iT z)GWY1cXsh@Id2W1ogpC(?0OTZ^JlnESh=H7IV2}Q(0!@=gb+&@Z)!vw-j!KgBc%+> z2=A-aPz7)Cn4xWjrO_k&JN#1`%p37msH5-7A#zx&5SE!;>7pGNtq}^2V~g-Rs;~KG zt+5owaj+43WELKTr5l09RvHy(|AX4lf(gNhBt?i@<;h8WeR7gMLoQy-Ap%N0A#Q%l zke^`4-*=Fg-i&<{o$R9#C!!6puq!D~&vePtGfJLLzS&oNa^kZX^UnScVT_igj+^PN z@nwX2_BKX6o`C$ObeibS}tZ}eudkNLr!UKL6Ox1FUc;bcV3N1 zJ|(Ujfcr+Ii2uF@ikE&ZBksjtQm>0IU+ra%MiX+#|((^yeeug?IM1 zOlKGB$}r7pp)|$`3zw*L-bB@~Qo~qPvrsuN3!Yl7?oa%g~G{L-RR^$W_zg3;1JTPzlv%I@VJr6Ihgmv0jVR@gZXoic=0gev4I&ikf(N8A3GS9%5l)?9uJ#0 zZ#sn7_Q_qze8PkpsB@YKljnHV?1?_Htr%Y6HH#;DJ6v1CxH9$ zOg6vXgdP^+Z7lF>qgX;=SqiOMV2{d<|_URsxoj!vjPRxfq-@O1wk#<>St$j6m9uU>yY zH}vP9&-7ZwX2NEWnQI2HZl1qTt09RMR59e?CH1!h5CW2H-GuPqzm#d-sG0+&Ij)+X zX&zF|U8Z@HYF=fU?^DgIO>;su)24Y?HFpbN!+>n!zjxR+<9erUGq8+pGqOFl&CuRu z+l=iOY@5MlZJW_uW7`bxSJ^h>`_-mRx`Y1)ZJY63Yuk+P*Vs1W`?a>s_=aqo@m*)z zjPKXkHskyCw$1p4ZJY63Z`wC9zTaTmjPEzvHskYcoAK?nZN~STY@6}@X4__bBeu=> zZm?~}_gie6@x9x$#~I(KZ8N@ow$1o{t8FvB_t-Y$8?$Z3x8JrIU(U7}-+OJF@#Srs z@f|SjLyYgBZ8N?bZJY6p+cx7nWZR7ICfjCw@3U>jH(}e1@33t%zDe6=e7|VgH!;2` z+h%+>+cx97#kLvWZ?kR2H*MRDZ^pJ6-x1qpd`E4Y@y*&c_c6X>w$1q7Z`+J- z-nJRvf^9Rt-)`HC?^fGpe2cct_?B#&@g28q#&^QBCm7$dZ8N@;w$1oX**4=_v2Dh; zYTJzOv~4rKGq%n6K49C7@2qVzzS~UuFys56Z8N?P**4?5-L@IuIooD@zr(f}U%|E+ zU(vQ1UtrseZ_TzDUrCG@`^*5#j=%^*M_`ESj=&f<9DzY@Is&7tI0D1`up=F;s`M*2&Rz(_yl2#oYjOVIA+cRK0fsQM*24# zfsuaO5g6%rEJ3@bzv&2!^lv!=BYnsb80o`~z)1hLBQVmx;|PrO5l3L8k2(S){kx99 zNdKN89L%%j|E?o2(#ITuk^X&0V5I-R5g6(B9D$KO?g)(ZA36df{YQ?#NS|;7M*5^B zXdm^D9f6Vl6GvdA-**H?`jjIu(tqj*jP##50weu_BQVmZ9f6Vlb4OsL|H2Zqk9x)t z80oW)z)1h4BQVl`3^~W?W2C|2#oXRsZt)EI4z~hZHO28_cX>mAs18%M^)Mc8K6?A zdnihOb#juk%HqZTz2vzUE~Oe%-Ec9LPQLsYdBLoBIg{ROpjZPNXUV*5BiN=ic=6~a zZ8#??SC;t)jU_~)??_M$fbPV)+VFWLleyjQPBgg~1iJ&s;?##q)u2*~=V_CXH=x3q zRtv=)*rQN6t;dkq^hW07f?Sd((7PsJubx*R~Wt?FnjdjZ(ye zDpBmJ2T;?aYb7M!Ov|CJ3IR$5>S~HRB(?^yv1Q-E{+8U6HdS^LCmO+pcDRIUJlaqJ z%R087cI`=Kh3}GGY2mx1$_szo8#)!nNcYml-Ly9+r(`;P;=CuOX^@c7rbo3Zc=(z< z$r_&Jq?o9AgmBL<)YV@Tf+FOY;x;-P)LuFqJ5p)3HWd$1+BB;RqGI5U+D&X2p`>T%C`zQF8gg8!F7Im8$^~T}4l3^oOG!7djxDIY>z@GRV9_fW%h}{qpH~V)>O#c@kDQf=j#*`ZY zpj`v}?}j~)vh-^sVlV!Z`mz+)@A3R2tIaT63L0teR{0tVIYuyl_tLx9?MY*Q2)kS; z(8FBD`33#ASr%8BCAs~Yl%F+SOqnMZRJq4`C2WrQdT$rPzi&r}%gUIUcStNC#(*rd z(fMH8?$?d2<1^JlNClggIHa2KeK1_61BSK#%_n9yF)=Gj60y^R8DT+1u5}T$Lsa(W zLv_O@%6X^^^3a=iJgufV(L4H*KK6E1g~p&LwLT`Ej%-{=k=1P z(H{>>ar2&j+t;)2M+s2lRD?ZP?1(JX*CXD$&d5cxwTkV*W~-n~Y=%mmWO0MuLH!xO zR9GjTg!R%k|C~W}tooZctVH-x`Ir>@`W9Q{sm#IDTD-}2;^_`M`((GBeUf$OWZ&_Q zufTm#rEwWWo+voMb|Mv)pnye}JopCAQ&42RwSH71Tqr{^mO3yz-HqXC#;|8sW@xR_ z+6qg9Q4`xr*~NG*4^0)jQ8sZkifzQrSNEHhQ8g<%+;H_R;bjUt#%&!!S82)qE91R$ z(B$5FZ?}mX`tIj1S^%?QTxwQOl-~5HPKZ2ZCy(>Zuo`R^xGd6_R8nWzj!8xRElUJd z6QNidTkKSsn=E}GW2WmVxqb$E7j1P?^4QXfQE{gWCG~S7&~ge)LGC#qMCt zXE~mnRDwJ?Ns~E?+9tMDkibal^NeK-9v>Y6gn{lTnz_>9I*`cP$VFCmf0!)ySxoAhuJmMyLGgjpLezIfP1J&EWg(T!*Mdt0(keRaVM^@Iby&aM zsjf(uN;hEuE6VimM$Jdq@y0dXZ(PG~?Con=pfFTM3KL+3;#61)VPV+5q~+)p$&MW3 zGDuaT^&`1#drMSqp)kG!?{(dHuVcK2`dV)~_`xM%zdV@J378!wO&sp~O(pzY4x`;y zrY0=Lxh=$tijguiWvNGk()qBQ6?;?C8FoD!rH4r&6E~z}62J~KfI~mFU!w&-pPpr+ zXQNY@UlwM}=>^j6eJO;O{fm?k{dZMQCaaKC!Fay{B^84At)_f~VzmP)ai`Lp2M?vh z9R%obN^I{4{2xT%kDpQU0@UKRzIwB07BalzR}mgoZYb|);D}14<%x%ERbA9fxIl`f zFaHQW90ISGerYZx0z$r!66X|UZ)zzeZX?pklxX(_$4fRkVbpH1)h4yPwNj`0e*1ll zZ;C__WpgVbRr7}^fU)}QJ(HBk3MN=(l*C=L&*YSltTcc|~%?hB@>S9rbQcu6?o zLf>AdcfJm04{B()rQ~Hsj0L1!W1dUN%fo?*LImk$g49b7i3-)=hM0rCs1|pkLYX$L z+uqzaLylE(Wmj1xpHNX|w33o9QIvqQLY*^-wIl~kx+pZ!wvx6F{`?#bpq3J+-`Ou1 zUR)_Pg9iL%9f`3@{S1z0AbCZBWrk`2dqe!#8cT)=8lz@hKqOfx8Pj|^C9jtXxwTEs zyzxSKwC4yA9VPT>-!1#zL94zp4?n(;l0{YKwv!)<>vwhdmUg#qX|r#+F4K=0qsqo3 z;X%dUx5}4b3iePE?Hb9&)Mvobr~1}zP6XiAhB_TZmF;h`+Pa34Zg-}{-YZ4(q68c) zH$Cxa0?xI4Umvs8y6cg^0lp#~Rm34u=&dflhdHPq_w=yj)pqBEfbU~;j4rC7au0?f zapYA_=n0`ouSDf;5w_om??}me99K;pb+_2k>QD8{MWcoD;dXq3gjz%V?V$}!JO8Yn zo=WhW9=|IkXVv3&8q{Oc77WfIVQC$IG9|yBfaF4I7R()N0IXrE21i!H)CzA>J!5OL zP*x#c3tYmow{WpiZf%-JiX8rJHP;I@I(v)q#{iDO^)X%VeBE|FUdOYW(Zzx~=Vkhv zu44|cN`qV}%WEDNpX?C&ySs({ZWj8xJDz)_E3$k<1(y5zN>e_ma-7A;$_dNbxUe2I zuV`H}pLhpZ7#z22UD11kDpSJ2HL@By-bbbK{c=Pv<&Hx=KSvHelX+QwAtgRTF8+%t z@q*V+;pb5%kK}!W!W*pa*g>X!kT9dA^Kg*Ei(#Gew-k22c-emDE`_DeeulLJMK`{2 znbgnoUcd5hoIngqZ7ddO`5x5baq5)X%hZGvA6jNB7mCi3l z8x>^i@Ra>2B_`BQ#}T4zA-(B-84$~6q;TT4XM3m+Cwe>ilNR@;WG|kXV~D%d8wpON z#nF^)Pq$rNq-$%&UnGUd5DV`6j+i7NO%8 z2+0>Zl;MGHrFnpr<}tX>fxVbMAs*dXnVm52-$@zccq7WP@7Jg~VIhU?qTlt+o)UmAqz&UUW&53{HjWK z+d~iteDr5uNJ;x;nO8|#yU6c&OUQ(miS?1aE>1ttb6UqJ=F;aeGWLKoof>;I<=85p zN+BXkjNnDcwj0D0qldG?BtMEdr0kx{#yy24qzw#(xUVOW?vsd@hl6`0)Zx{aQ}Ppu zF=!}bKFx{!D3IxstylQCc&sPL+j+0>)^Pj8MQnM+o0Y~googn^NS;}HyhEy|yZqg> z@^?>mJoRd~?7zyg|MZ?T9p0|hV3_S$#zDP>H9D=A7nlP&;D4e43C}LKaRw1J{qGN3 zr*POD8LlCoE-aSD>CiwEI}i*V*IeKTLS=m$TZ8$u5em&#FiUyMwD5#1U*i-%3|#@E*=?M64L3+Zyw+GbRW0&X^CRdS_HZJK>w2?Ra=F z`S4)Z!!P$@%i>%eXXoe!4xTCkxpQ`2B(2{wARfn#Wol5g=`5HpUg_1{pyH9I63miT zCHX2kq!VWpyIwoMJIj_6kh4+sfV!|{P>vkOIX>nQu06pCmH4^=IYOp_GWjqSFDO%V z&A{~o;`xrT?;S`EelOUwgH^9~JWd$(ws3L|A%AqW9H;pC5&$#koPDL zk#Lb?*py!jErIJs;40)OFLH3AC-&s%DYfFEhLGdXJmL*U;xhv{0hVNz*p==vw6pY? zIfA@nd}-MY`c1#ki+O{pcVgHWvj(aVUNW4a>;X0uiIw&a2Y)9|{|_*02y%t#To{mj zIk2bKXs%TLcfTts|0lcU|0K)*!)behPKR70@D;1LIEhcQkIG?n&kLa$AgEl{|e^=%*MN5O~;-^JjvO_B|`WEdcr?JLR#Y!@(FP4(Su#rPtBQ-3| zZBud(rAk;A56GPeX>S9kC98$?Fw9ER9ZD3g01*lfup9XWo@rAn@0MINZ^v z9EKL}q%8*J539R@^i^3qeit`%Ov#1rDY?K?viAz`jsoT^s*EbtIEgkb$17$a^!fIH zZ0RLsa)48s)wjTEWLlL*l3SuJy^$Vg8|UP7*Ga_%nb~pja0!N2V+=j3#<{4J2veaqS^a=J%(T1`%G%h@dL>1Bp-NSCHi?3UiA{Zk>Tnd-5RyQqBq z11^YBOus`|%zu;fQja`XexVS9m?M0;^fE5XN(bs@{9LUDALCX(;c-voTuf<5p0ET&h zk|!8abs9eBn`*O+kDI}`?(8nuq_yM+968+lI_nYn6t`5b=Go2%}AiFw?bK)V) z7=R-+?5~A>8#f~m9ONjfe$jUA7+K7DQcv=do|hs|FkQ68)6C>+G_PXc zBkf9+N<*fQG^=jAib`(;6#-nC*p^?!jZ~DJscx$tcoyvMIdNFp$;1e(nIKkTH5vLB zH!G!0pH3!MP~;W+6`Dn1kaL1Q?QmiTfD;{vnSNFtExGG-<>e>|$;k}7pO7H-6daiv3M ziY^euLxpBY*LTET=Hh0Q&U%NOB+&5mQ&2|rlJSyx#9K{FeHPeZI$syx06wTp6u&m3STCsu2VnV0Hy@3SuB) zvbH{T%XJhMf$h0bWGHDH68!gO-LG-sLK}5(-mo4=Hsf8>ISYwref6wnf~Et9@+5{U zx}Tgli+aM1u$-t6JlPK0p=XMbaMvc*1^RZ!%n(=UJ|NSrOKmx-l$UDIwNmw4ptMbkkwW@C^z^b z%F56k)hDrcB@x}ks@im|9{nh*0*0<^KXky@GwxepAjobI^OWJhgUUJ7f^Bjbh?z-x z9LGpte09SIT)E#u;y(7VX!8@}h`-|3=+;$wUkx5*VPHHS+Xj;%l*moM_QE&hJdAl2 zu#3IrA!%tysG(=T1AaoRZHSWiGGq`^l$$-VzOGE@2cqWrut`!qgyu2`eZG{t*Utg2Mq$8iA_=|RY`20+wNSF*Rc z-N2?9-NG7F;b35i1L>2f*qCoKLL8%{!p9q=EKXmddM+U*MI^WoB5}t>wS$+evMoO0 zYej$rkW|KPWsNX{I+m@gdm&9r@isS~tkL5gKe{3hcK^0YScQlu4H?-ogfPihNF7KR zWB7z>xD~)kL;L9SYP8ya!#Pv*iszu6A;MfZ3)J|MK>DWiFy~WIobHbzr_Epss(^{5 z?rD=5Y~{XdxiVCwcMT_uJzk;e+flrwtL1j3_M`?Yc1#4%cEDbmEr|*XNapDYt@|We z3uPz;RatAx3O?Ar@odogL4x;6hg0Nz%m#6Cm(Rk@#0Gex5A@4Ut|Bs<>vj-2Lg>)yv&Au#SKCgs7A)QJJje zmDxv!S5w!3u|K#rl>u+fIDS^<()-TF!ssB@*ZNA%l&&aK1~-Q#6xe~HT2d!<#}`?s z1W!2XH*6e(gFpg72TZQVeJHh{Xiyn(;|d^tX7o_yP_cBI6~fIEdft9F1ezuXQA$wF z71a)El1m7gQH~Tlt`2L;k7m7Vb@&J+OD=~TGzz%sZOkNm7Y&5RNe8uj6huQ9Dnagc zQ&z8XVzeh+P`W2FnICt|ihd3%jog_VpIV}^wrWGcra?TxetgF&hBmLE<`r6N27Zw? zJHU4&{#pqCi#c;a8i@$al^c17K0cQ{E&XF5CPa-ZF=jQvN{0|G1WJf$>L^l5s%7u8 z*y8_9mAV8@ag`=ChQsNksr0O6x;~XYN6Qs|$u1};fu@_aV3Dr2 z)R8H?#fv98*#!g~~x9kRuTaYHbn1)Ka;^I|0qbJG?~0Z9f#+hTvp+t0uQ z1Q{jl(GzO^5nq53@uNQP! zy2Ifp6=se?cvZP1mK^G)Npeu?cXRWg`GKPn9T^j6a+mb01$7l6qJ?@rtj0Y*Ka)x$ z1TYh10IC@R9P_HLuUoTzNxKY8DBpRR!}5^7!fa3;tsZ^aU^L)s$}a}h7|9x4kUm$ynIbdi zyw$r=ox?Gd>2uASuU=JB0xup_w=iT~4i)F}&i>%64_~vN`AjPFj0NZn&pMJa9qv{C zG)5+n3dX~7PFyGb<0n?G^X*z6!{=j++mLVfR&6=3FZ?up7qFT2Ba<1}y|)t!?_fPW&*YT24^7Xq1Ml z<9ux1|NOXaR+Gj7D5>q^1wNO`+?8|#$_HyFv{R~o2AA;j5-2P4;>#)TlAQ=LQLufa zWA+K>l{s;2tDC$X7mR)@64C}PtU4AdVN&h}Y;)-L)lX%jNOZ91%URvb1KP!0iZ5dQC>~`H02|GVimjYo331PkX9A^QCK+6 zH|g(k5`dQGVe>UCz+ql=+D(lqiGY3p-^q~%K2Z1y1(j;>FR%NfZh021VLyh}GuTIh zZ7I@3Q1YHCKp8&0$U`XZQz$S)F1@NU;*?p|Y*C-p-76c3-#ApnH^|_s28VJbgpD`hk)q3ktuG5~= zm>=dga%x$VxWpTyVUE-A@dY>&B}`V>dGTfTGDa&oBxKa`*k+Z`1#UGclND6!LPn>d z0Xh96ER=p(Z&%6OVPZ*+ELU>M< zV$jcH8c9xde#s;P9RvbeiT6mPl9+ks5$Lk=cILu<+C`@+3QV@YWWJh1!6*bihH`a{ zJfKApqFO{~lw61Wv1+%ds}7}MA&7J6g)2I1&7>MHS|WXHWkYDx`aav(Pl&BcaHZMH$%f&mhoDR%iOG~GGdO}B@^n$BP61xYit5dJJd=$N> zoQ{o5l<&$-SOrx&mL69R>2k#Q}_?m%11^fDeeFK9(L9M6CY12zQ8k4Q);6D#>jdC5NncP!O zT!4mg#u*}LV`}9{2vJ8Db_yX~Wh{3P0-F>Ce>j;*p_naKd5by=jmG{EhOhu<^~~B7A(9ArVhanrLnQ04n2iAU&At0eXPg>ESmKw^+F(s zZY$>OuVnez^Xg^ehnC5TojaRkKQ9w-ZXwQO6)Sp7$1qk4edj|vFQW*`0%FO#b4p(C zH6!H+BjVF!gzAfgvQzHW zQ5rIp@MiR{C*;H->3=}QR5Tdnbl5;0fsdiFVxghK9O{i+3N+lfbpoxl%f^`)DRf&! zM`pJjTWoO&sT5@J)T&YWMgGX>k@p-x#o&7mj`_JYazA@a|Bam?{r-WsLwd6DZ-?~B(C23e=@$wVnR!3C-LaK(u+7MMAKWzs6mBTc0$!LRU= zopToTa3i8^Cbj-F|IXQda(e82ZDtJ1BnFhTNa6Nq#Ynrx*p|mK4h!QDS-N$8x1&p9 zK|FZ?7Y1qH?MA@w1HLY(VULYoj_c*hm~rh$FyP1{75vbGar=iTOTc{xcvHujCX*4Y zV@(C=rCop12?x3+26$a%_gtn85qB#pq5ea;|5Ah+4yxYbJ$@iABdtNHA$3z(bvuWO zWYqjODnsMwBXQVZZpWgn<5v~H9GN*Xms>Ov#C7&6xhFpAJz{f|D)K<3y^b|F`G_mfXnleXS~D>(!<6d90rno zNFtfep z31L9J^RU={v+jTNQh#WXgsuD&vw9-%x!LQcQwAy+S)#ymRdr+pYD9BJ!-1*3O|k z$piz6N7#WyR78 z`Mf`?o=Dhe{eF^3Iq^)#*Q?lqq1n=pHiL`iuZlzOQCmZFpe=`E4lDd^W}XcUQN}to zQ&J~*)ji=P&*Rv{Lx|F%e^3rLhY#y!I^#Xm5!P!u@`h9y1{^$7Mcv;*87EAhQ_NNS zDG?RNU}vWDwb9^wkgO<1=!*S@eYw?DR~3$%2dI1k*s`Ol51dKHfxJxnQmZX9DALc= z2E;7?ffQVG-) z_e?Q3Bg@iX&uV1eg7iM#n-_h-t;8vpbbKDhhM@ S1ASP0MITsHhm-q#K>TkRBoplb literal 6592 zcmai&eViQk9LIl?+e^0X(!=7gI4rgtHg|iMO?r*JhfVjmCwF^kq>0UR=a<`YyEAKM z_U<-)Vi?e)hFJLUebFxcawC#DwVT6GHu;jgK@PvtfGXimZ6;rgVEs14G09PjRj9!dCv= zzQKY0LQJSD)Kv=C;u*JDaaxvVHe~;_ZM5pL=s30`)D=n7GUQrJi?{MZOG+R2Xh(xG z)1!MT)3XzcQ^iVgetveoQk)r|ohVLJ7AE%=)g9`cbu(pqSz0Kor3<@Smf{V;j zb)}~sqj#5MACi{n7X6Es+iEs#$CHNGEDD_$mh8GAwusz}?G@LW(lUa(t3hnWb7~ZH z$Mk9q>6z7$Q92B*6X``Y7S2IsrF8pdSHfdWepW#GNTJ z2Cqho)CXc;XTpET4k zYJ85WotzBTkH~84PFHi4nAcZhBB!Nx%j!rgzf;XvI=s!`!1~47MZXMWV*`kGF8@&r!K0qgXv9*|7#JGbx;?#ME?K(Qa?~=6 ziHWfMa89k^b2jnWuJixSzD~XPU8BKmj(5|ANm(^qef>@5qMHnXl|s+XGc=Jb`Vuiw)(U}6=da58#zar{prbcr#civ% zuaS{!p0xZW?UvQ@tS(n9+o~K=i@V~gkA`$g<363SEq}o;1Sl3Ot49~dHZD~{DYq%B z74`M-%NK$=3ySOp2&)|5xJm(4ytSxCKB!S%TVLU(jVt6(VM$ujHQj7*`S}Rp?Qco+ zbS#LJf2Lzr6VlNWMMoE!7VDdAG}ISXud7E+O$SF?WB&W7MNz%PDsGD6U=X{ame2Jc`?cc!uZ;HPjkWH$Iaxyw0Kwu>@t9-HkHT?oJtQ zXH$k;4`tZhgEI8)Ng00kin70km0yxF{O(N|e)pjazxz^#UoU0&-H$T-?oSzh51I}tG0N~8rwqRd%J3^j zc^mw8QHJ07l;KyR48KXr@OuJf_&t#_{H7?wZ<;dvW+=mNHp+SU%~6KmlPJS)o-+Iv zD8sKz8GehD;kTPI{4Ssjzde-U_v9#Vhu>bx@Vk&Q{Pt0X-+s#QdkSUvRVc&n0A={; zl;L*~W%yM^I{H3C&|m;V$pDH68NhLg0VHb-U}-Xd=2IEKbD04|>kMGpAg~pt76X{t z3}D)10Mn;2fT_a(rY-}RdJJINVgS<>1~6SE5N;}K3}D)30MkPZVES|hFg?rwrq5si z(`Pb(>9ZKX^kN1ueKvt`dwC86m_C;QOfO*o(@Pn^^fCr8eI5gt9$^5}=QDum3mCxk zg#^Nl<|qT0zK8)#U(5ieFJS=F%NfA*3I;HJDFc|ki~&rqWB}8v2!vbC%NfA*6%1f{ zH3OJl!vLnQWB}7wF@Wi{3}E_d1~7dM1DL*+K)Ct5jsZ+x&j6-xU;xuMGJxru7{K(+ z3}E^e1~7dq1DL*z0ZiXcAl!!D!2qW3WB}85F@Wj28Nl>C3}E_R1~7de1DL*_0Zc!@ z0Hz-#5N=2xVgS<*Gl1zw7{K(S3}E^(1~C0N1DJk-0Zc#10H&W}0Mkzs2)CxsFo5Z2 z8Nl>&3}AX41DJlE0ZhNZ0H$AL0MqLk!1PNDVEW|<3}o@;{|W<`-oOB+Uu6K(uQ7n> z*BQX{Mg}nb1_PLWlL1V>#Q>(q2!wmow;90nI}Bj@T?Q~c&H$$0V*u0dGl1z27{K%< z1~C001DO7ZK)6T!m;p?0W&qQlFo5Y#8Nl>s3}AW-1DO7t0Zf0v0H(iW0MlCugnQJl z7{K(`3}E^j1~9#i0Zf0(0H(iV0Mp+yfa&cFVEP9JF#RKeaF4o!0Zi{?0MkD)fa#wZ z!1ON+V0wZ9O#jLNrhj7q)4wx->0JcEJ?b9}VERu6F#Q(;nEsmqO#j0GrvDY<=8fAO zBWQOtf+mIOwb3uZAEPP;EsvO}Ye8#6G*qu_vkPGePr2^?|A~tmA2Y zRMpV2daHHaY`CR4 zN3Q5~(@?$kQO}dE=Z0E0sMc#Nz3+fgYpxwWa#UP@+D_3_%L*P(8Wq(^b4=ArtCkic zR*X<*%XH4x;mn4^e artifacts/polkadot_metadata_full.scale +cargo run --bin subxt metadata --version unstable > artifacts/polkadot_metadata_full.scale # use it to generate polkadot.rs cargo run --bin subxt codegen --file artifacts/polkadot_metadata_full.scale | rustfmt > testing/integration-tests/src/codegen/polkadot.rs # generate a metadata file that only contains the pallets Balances, Staking, System and Multisig diff --git a/testing/integration-tests/src/codegen/polkadot.rs b/testing/integration-tests/src/codegen/polkadot.rs index 14a0cdada0..a8915eb72a 100644 --- a/testing/integration-tests/src/codegen/polkadot.rs +++ b/testing/integration-tests/src/codegen/polkadot.rs @@ -846,1430 +846,1687 @@ pub mod api { use super::runtime_types; use subxt::ext::codec::Encode; pub struct RuntimeApi; - impl RuntimeApi {} - } - pub struct ConstantsApi; - impl ConstantsApi { - pub fn system(&self) -> system::constants::ConstantsApi { - system::constants::ConstantsApi - } - pub fn scheduler(&self) -> scheduler::constants::ConstantsApi { - scheduler::constants::ConstantsApi - } - pub fn babe(&self) -> babe::constants::ConstantsApi { - babe::constants::ConstantsApi - } - pub fn timestamp(&self) -> timestamp::constants::ConstantsApi { - timestamp::constants::ConstantsApi - } - pub fn indices(&self) -> indices::constants::ConstantsApi { - indices::constants::ConstantsApi - } - pub fn balances(&self) -> balances::constants::ConstantsApi { - balances::constants::ConstantsApi - } - pub fn transaction_payment(&self) -> transaction_payment::constants::ConstantsApi { - transaction_payment::constants::ConstantsApi - } - pub fn staking(&self) -> staking::constants::ConstantsApi { - staking::constants::ConstantsApi - } - pub fn grandpa(&self) -> grandpa::constants::ConstantsApi { - grandpa::constants::ConstantsApi - } - pub fn im_online(&self) -> im_online::constants::ConstantsApi { - im_online::constants::ConstantsApi - } - pub fn democracy(&self) -> democracy::constants::ConstantsApi { - democracy::constants::ConstantsApi - } - pub fn council(&self) -> council::constants::ConstantsApi { - council::constants::ConstantsApi - } - pub fn technical_committee(&self) -> technical_committee::constants::ConstantsApi { - technical_committee::constants::ConstantsApi - } - pub fn phragmen_election(&self) -> phragmen_election::constants::ConstantsApi { - phragmen_election::constants::ConstantsApi - } - pub fn treasury(&self) -> treasury::constants::ConstantsApi { - treasury::constants::ConstantsApi - } - pub fn conviction_voting(&self) -> conviction_voting::constants::ConstantsApi { - conviction_voting::constants::ConstantsApi - } - pub fn referenda(&self) -> referenda::constants::ConstantsApi { - referenda::constants::ConstantsApi - } - pub fn claims(&self) -> claims::constants::ConstantsApi { - claims::constants::ConstantsApi - } - pub fn vesting(&self) -> vesting::constants::ConstantsApi { - vesting::constants::ConstantsApi - } - pub fn utility(&self) -> utility::constants::ConstantsApi { - utility::constants::ConstantsApi - } - pub fn identity(&self) -> identity::constants::ConstantsApi { - identity::constants::ConstantsApi - } - pub fn proxy(&self) -> proxy::constants::ConstantsApi { - proxy::constants::ConstantsApi - } - pub fn multisig(&self) -> multisig::constants::ConstantsApi { - multisig::constants::ConstantsApi - } - pub fn bounties(&self) -> bounties::constants::ConstantsApi { - bounties::constants::ConstantsApi - } - pub fn child_bounties(&self) -> child_bounties::constants::ConstantsApi { - child_bounties::constants::ConstantsApi - } - pub fn tips(&self) -> tips::constants::ConstantsApi { - tips::constants::ConstantsApi - } - pub fn election_provider_multi_phase( - &self, - ) -> election_provider_multi_phase::constants::ConstantsApi { - election_provider_multi_phase::constants::ConstantsApi - } - pub fn voter_list(&self) -> voter_list::constants::ConstantsApi { - voter_list::constants::ConstantsApi - } - pub fn nomination_pools(&self) -> nomination_pools::constants::ConstantsApi { - nomination_pools::constants::ConstantsApi - } - pub fn fast_unstake(&self) -> fast_unstake::constants::ConstantsApi { - fast_unstake::constants::ConstantsApi - } - pub fn paras(&self) -> paras::constants::ConstantsApi { - paras::constants::ConstantsApi - } - pub fn registrar(&self) -> registrar::constants::ConstantsApi { - registrar::constants::ConstantsApi - } - pub fn slots(&self) -> slots::constants::ConstantsApi { - slots::constants::ConstantsApi - } - pub fn auctions(&self) -> auctions::constants::ConstantsApi { - auctions::constants::ConstantsApi - } - pub fn crowdloan(&self) -> crowdloan::constants::ConstantsApi { - crowdloan::constants::ConstantsApi - } - } - pub struct StorageApi; - impl StorageApi { - pub fn system(&self) -> system::storage::StorageApi { - system::storage::StorageApi - } - pub fn scheduler(&self) -> scheduler::storage::StorageApi { - scheduler::storage::StorageApi - } - pub fn preimage(&self) -> preimage::storage::StorageApi { - preimage::storage::StorageApi - } - pub fn babe(&self) -> babe::storage::StorageApi { - babe::storage::StorageApi - } - pub fn timestamp(&self) -> timestamp::storage::StorageApi { - timestamp::storage::StorageApi - } - pub fn indices(&self) -> indices::storage::StorageApi { - indices::storage::StorageApi - } - pub fn balances(&self) -> balances::storage::StorageApi { - balances::storage::StorageApi - } - pub fn transaction_payment(&self) -> transaction_payment::storage::StorageApi { - transaction_payment::storage::StorageApi - } - pub fn authorship(&self) -> authorship::storage::StorageApi { - authorship::storage::StorageApi - } - pub fn staking(&self) -> staking::storage::StorageApi { - staking::storage::StorageApi - } - pub fn offences(&self) -> offences::storage::StorageApi { - offences::storage::StorageApi + impl RuntimeApi { + pub fn core(&self) -> core::Core { + core::Core + } + pub fn metadata(&self) -> metadata::Metadata { + metadata::Metadata + } + pub fn block_builder(&self) -> block_builder::BlockBuilder { + block_builder::BlockBuilder + } + pub fn nomination_pools_api(&self) -> nomination_pools_api::NominationPoolsApi { + nomination_pools_api::NominationPoolsApi + } + pub fn staking_api(&self) -> staking_api::StakingApi { + staking_api::StakingApi + } + pub fn tagged_transaction_queue( + &self, + ) -> tagged_transaction_queue::TaggedTransactionQueue { + tagged_transaction_queue::TaggedTransactionQueue + } + pub fn offchain_worker_api(&self) -> offchain_worker_api::OffchainWorkerApi { + offchain_worker_api::OffchainWorkerApi + } + pub fn parachain_host(&self) -> parachain_host::ParachainHost { + parachain_host::ParachainHost + } + pub fn beefy_api(&self) -> beefy_api::BeefyApi { + beefy_api::BeefyApi + } + pub fn mmr_api(&self) -> mmr_api::MmrApi { + mmr_api::MmrApi + } + pub fn grandpa_api(&self) -> grandpa_api::GrandpaApi { + grandpa_api::GrandpaApi + } + pub fn babe_api(&self) -> babe_api::BabeApi { + babe_api::BabeApi + } + pub fn authority_discovery_api( + &self, + ) -> authority_discovery_api::AuthorityDiscoveryApi { + authority_discovery_api::AuthorityDiscoveryApi + } + pub fn session_keys(&self) -> session_keys::SessionKeys { + session_keys::SessionKeys + } + pub fn account_nonce_api(&self) -> account_nonce_api::AccountNonceApi { + account_nonce_api::AccountNonceApi + } + pub fn transaction_payment_api( + &self, + ) -> transaction_payment_api::TransactionPaymentApi { + transaction_payment_api::TransactionPaymentApi + } + pub fn transaction_payment_call_api( + &self, + ) -> transaction_payment_call_api::TransactionPaymentCallApi { + transaction_payment_call_api::TransactionPaymentCallApi + } } - pub fn session(&self) -> session::storage::StorageApi { - session::storage::StorageApi + pub mod core { + use super::root_mod; + use super::runtime_types; + #[doc = " The `Core` runtime api that every Substrate runtime needs to implement."] + pub struct Core; + impl Core { + #[doc = " Returns the version of the runtime."] + pub fn version( + &self, + ) -> ::subxt::runtime_api::Payload< + types::Version, + runtime_types::sp_version::RuntimeVersion, + > { + ::subxt::runtime_api::Payload::new_static( + "Core_version", + types::Version {}, + [ + 209u8, 59u8, 156u8, 128u8, 14u8, 210u8, 96u8, 63u8, 140u8, 0u8, 65u8, + 211u8, 118u8, 177u8, 9u8, 208u8, 105u8, 124u8, 132u8, 203u8, 157u8, + 207u8, 186u8, 177u8, 91u8, 170u8, 22u8, 224u8, 88u8, 56u8, 56u8, 13u8, + ], + ) + } + #[doc = " Execute the given block."] + pub fn execute_block( + &self, + block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 , runtime_types :: sp_runtime :: traits :: BlakeTwo256 > , runtime_types :: sp_runtime :: generic :: unchecked_extrinsic :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: polkadot_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment , runtime_types :: polkadot_runtime_common :: claims :: PrevalidateAttests ,) > >, + ) -> ::subxt::runtime_api::Payload { + ::subxt::runtime_api::Payload::new_static( + "Core_execute_block", + types::ExecuteBlock { block }, + [ + 199u8, 164u8, 96u8, 78u8, 188u8, 134u8, 19u8, 247u8, 63u8, 58u8, 93u8, + 227u8, 122u8, 157u8, 93u8, 196u8, 16u8, 7u8, 20u8, 17u8, 178u8, 152u8, + 211u8, 185u8, 56u8, 153u8, 118u8, 241u8, 118u8, 105u8, 85u8, 3u8, + ], + ) + } + #[doc = " Initialize a block with the given header."] + pub fn initialize_block( + &self, + header: runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + ) -> ::subxt::runtime_api::Payload { + ::subxt::runtime_api::Payload::new_static( + "Core_initialize_block", + types::InitializeBlock { header }, + [ + 45u8, 232u8, 143u8, 132u8, 33u8, 211u8, 71u8, 186u8, 169u8, 91u8, + 143u8, 156u8, 174u8, 156u8, 10u8, 25u8, 203u8, 16u8, 208u8, 226u8, + 12u8, 233u8, 145u8, 228u8, 63u8, 118u8, 66u8, 247u8, 71u8, 48u8, 44u8, + 243u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Version {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ExecuteBlock { pub block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 , runtime_types :: sp_runtime :: traits :: BlakeTwo256 > , runtime_types :: sp_runtime :: generic :: unchecked_extrinsic :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: polkadot_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment , runtime_types :: polkadot_runtime_common :: claims :: PrevalidateAttests ,) > > , } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct InitializeBlock { + pub header: runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + } + } } - pub fn grandpa(&self) -> grandpa::storage::StorageApi { - grandpa::storage::StorageApi + pub mod metadata { + use super::root_mod; + use super::runtime_types; + #[doc = " The `Metadata` api trait that returns metadata for the runtime."] + pub struct Metadata; + impl Metadata { + #[doc = " Returns the metadata of a runtime."] + pub fn metadata( + &self, + ) -> ::subxt::runtime_api::Payload< + types::Metadata, + runtime_types::sp_core::OpaqueMetadata, + > { + ::subxt::runtime_api::Payload::new_static( + "Metadata_metadata", + types::Metadata {}, + [ + 158u8, 223u8, 229u8, 177u8, 228u8, 49u8, 24u8, 219u8, 143u8, 82u8, + 255u8, 132u8, 245u8, 210u8, 160u8, 197u8, 218u8, 10u8, 63u8, 165u8, + 115u8, 91u8, 70u8, 151u8, 246u8, 51u8, 18u8, 235u8, 91u8, 143u8, 27u8, + 127u8, + ], + ) + } + #[doc = " Returns the metadata at a given version."] + #[doc = ""] + #[doc = " If the given `version` isn't supported, this will return `None`."] + #[doc = " Use [`Self::metadata_versions`] to find out about supported metadata version of the runtime."] + pub fn metadata_at_version( + &self, + version: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload< + types::MetadataAtVersion, + ::core::option::Option, + > { + ::subxt::runtime_api::Payload::new_static( + "Metadata_metadata_at_version", + types::MetadataAtVersion { version }, + [ + 50u8, 164u8, 234u8, 88u8, 65u8, 62u8, 176u8, 66u8, 188u8, 114u8, 205u8, + 29u8, 137u8, 173u8, 194u8, 54u8, 237u8, 48u8, 221u8, 46u8, 166u8, 44u8, + 220u8, 137u8, 97u8, 128u8, 204u8, 137u8, 29u8, 229u8, 31u8, 134u8, + ], + ) + } + #[doc = " Returns the supported metadata versions."] + #[doc = ""] + #[doc = " This can be used to call `metadata_at_version`."] + pub fn metadata_versions( + &self, + ) -> ::subxt::runtime_api::Payload< + types::MetadataVersions, + ::std::vec::Vec<::core::primitive::u32>, + > { + ::subxt::runtime_api::Payload::new_static( + "Metadata_metadata_versions", + types::MetadataVersions {}, + [ + 255u8, 234u8, 86u8, 244u8, 238u8, 175u8, 175u8, 54u8, 181u8, 181u8, + 23u8, 185u8, 231u8, 242u8, 153u8, 246u8, 205u8, 142u8, 184u8, 21u8, + 240u8, 217u8, 195u8, 231u8, 32u8, 163u8, 127u8, 3u8, 51u8, 130u8, 68u8, + 124u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Metadata {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MetadataAtVersion { + pub version: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MetadataVersions {} + } } - pub fn im_online(&self) -> im_online::storage::StorageApi { - im_online::storage::StorageApi + pub mod block_builder { + use super::root_mod; + use super::runtime_types; + #[doc = " The `BlockBuilder` api trait that provides the required functionality for building a block."] + pub struct BlockBuilder; + impl BlockBuilder { + #[doc = " Apply the given extrinsic."] + #[doc = ""] + #[doc = " Returns an inclusion outcome which specifies if this extrinsic is included in"] + #[doc = " this block or not."] + pub fn apply_extrinsic( + &self, + extrinsic : runtime_types :: sp_runtime :: generic :: unchecked_extrinsic :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: polkadot_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment , runtime_types :: polkadot_runtime_common :: claims :: PrevalidateAttests ,) >, + ) -> ::subxt::runtime_api::Payload< + types::ApplyExtrinsic, + ::core::result::Result< + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + runtime_types::sp_runtime::transaction_validity::TransactionValidityError, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "BlockBuilder_apply_extrinsic", + types::ApplyExtrinsic { extrinsic }, + [ + 151u8, 89u8, 106u8, 151u8, 95u8, 29u8, 10u8, 68u8, 85u8, 149u8, 144u8, + 132u8, 47u8, 46u8, 164u8, 91u8, 225u8, 219u8, 85u8, 120u8, 101u8, + 105u8, 45u8, 79u8, 171u8, 133u8, 121u8, 170u8, 197u8, 248u8, 24u8, + 10u8, + ], + ) + } + #[doc = " Finish the current block."] + pub fn finalize_block( + &self, + ) -> ::subxt::runtime_api::Payload< + types::FinalizeBlock, + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "BlockBuilder_finalize_block", + types::FinalizeBlock {}, + [ + 78u8, 179u8, 67u8, 170u8, 213u8, 230u8, 122u8, 98u8, 76u8, 244u8, + 225u8, 219u8, 83u8, 115u8, 94u8, 229u8, 93u8, 142u8, 120u8, 172u8, + 87u8, 99u8, 120u8, 41u8, 143u8, 184u8, 71u8, 49u8, 126u8, 55u8, 240u8, + 125u8, + ], + ) + } + #[doc = " Generate inherent extrinsics. The inherent data will vary from chain to chain."] pub fn inherent_extrinsics (& self , inherent : runtime_types :: sp_inherents :: InherentData ,) -> :: subxt :: runtime_api :: Payload < types :: InherentExtrinsics , :: std :: vec :: Vec < runtime_types :: sp_runtime :: generic :: unchecked_extrinsic :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: polkadot_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment , runtime_types :: polkadot_runtime_common :: claims :: PrevalidateAttests ,) > > >{ + ::subxt::runtime_api::Payload::new_static( + "BlockBuilder_inherent_extrinsics", + types::InherentExtrinsics { inherent }, + [ + 75u8, 86u8, 85u8, 104u8, 125u8, 169u8, 23u8, 92u8, 162u8, 73u8, 65u8, + 223u8, 100u8, 24u8, 201u8, 157u8, 145u8, 208u8, 238u8, 11u8, 255u8, + 98u8, 0u8, 211u8, 189u8, 94u8, 5u8, 123u8, 25u8, 1u8, 88u8, 234u8, + ], + ) + } + #[doc = " Check that the inherents are valid. The inherent data will vary from chain to chain."] + pub fn check_inherents( + &self, + block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 , runtime_types :: sp_runtime :: traits :: BlakeTwo256 > , runtime_types :: sp_runtime :: generic :: unchecked_extrinsic :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: polkadot_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment , runtime_types :: polkadot_runtime_common :: claims :: PrevalidateAttests ,) > >, + data: runtime_types::sp_inherents::InherentData, + ) -> ::subxt::runtime_api::Payload< + types::CheckInherents, + runtime_types::sp_inherents::CheckInherentsResult, + > { + ::subxt::runtime_api::Payload::new_static( + "BlockBuilder_check_inherents", + types::CheckInherents { block, data }, + [ + 162u8, 99u8, 46u8, 228u8, 124u8, 158u8, 224u8, 212u8, 90u8, 101u8, + 133u8, 173u8, 82u8, 61u8, 131u8, 131u8, 254u8, 209u8, 17u8, 181u8, + 87u8, 190u8, 80u8, 165u8, 172u8, 179u8, 121u8, 202u8, 126u8, 48u8, + 254u8, 112u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ApplyExtrinsic { pub extrinsic : runtime_types :: sp_runtime :: generic :: unchecked_extrinsic :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: polkadot_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment , runtime_types :: polkadot_runtime_common :: claims :: PrevalidateAttests ,) > , } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct FinalizeBlock {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct InherentExtrinsics { + pub inherent: runtime_types::sp_inherents::InherentData, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckInherents { pub block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 , runtime_types :: sp_runtime :: traits :: BlakeTwo256 > , runtime_types :: sp_runtime :: generic :: unchecked_extrinsic :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: polkadot_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment , runtime_types :: polkadot_runtime_common :: claims :: PrevalidateAttests ,) > > , pub data : runtime_types :: sp_inherents :: InherentData , } + } } - pub fn democracy(&self) -> democracy::storage::StorageApi { - democracy::storage::StorageApi + pub mod nomination_pools_api { + use super::root_mod; + use super::runtime_types; + #[doc = " Runtime api for accessing information about nomination pools."] + pub struct NominationPoolsApi; + impl NominationPoolsApi { + #[doc = " Returns the pending rewards for the member that the AccountId was given for."] + pub fn pending_rewards( + &self, + who: ::subxt::utils::AccountId32, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "NominationPoolsApi_pending_rewards", + types::PendingRewards { who }, + [ + 235u8, 64u8, 57u8, 70u8, 111u8, 27u8, 62u8, 236u8, 36u8, 192u8, 103u8, + 89u8, 221u8, 194u8, 46u8, 223u8, 71u8, 249u8, 33u8, 135u8, 43u8, 42u8, + 147u8, 57u8, 130u8, 44u8, 35u8, 132u8, 163u8, 153u8, 201u8, 105u8, + ], + ) + } + #[doc = " Returns the equivalent balance of `points` for a given pool."] + pub fn points_to_balance( + &self, + pool_id: ::core::primitive::u32, + points: ::core::primitive::u128, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "NominationPoolsApi_points_to_balance", + types::PointsToBalance { pool_id, points }, + [ + 30u8, 7u8, 5u8, 95u8, 146u8, 43u8, 110u8, 21u8, 148u8, 160u8, 74u8, + 92u8, 168u8, 188u8, 74u8, 41u8, 129u8, 172u8, 138u8, 30u8, 232u8, + 214u8, 154u8, 18u8, 52u8, 87u8, 71u8, 127u8, 141u8, 177u8, 216u8, + 158u8, + ], + ) + } + #[doc = " Returns the equivalent points of `new_funds` for a given pool."] + pub fn balance_to_points( + &self, + pool_id: ::core::primitive::u32, + new_funds: ::core::primitive::u128, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "NominationPoolsApi_balance_to_points", + types::BalanceToPoints { pool_id, new_funds }, + [ + 152u8, 165u8, 227u8, 129u8, 31u8, 108u8, 224u8, 174u8, 74u8, 192u8, + 102u8, 139u8, 17u8, 119u8, 173u8, 220u8, 52u8, 157u8, 125u8, 107u8, + 110u8, 236u8, 9u8, 93u8, 239u8, 3u8, 18u8, 140u8, 203u8, 136u8, 183u8, + 215u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PendingRewards { + pub who: ::subxt::utils::AccountId32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PointsToBalance { + pub pool_id: ::core::primitive::u32, + pub points: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BalanceToPoints { + pub pool_id: ::core::primitive::u32, + pub new_funds: ::core::primitive::u128, + } + } } - pub fn council(&self) -> council::storage::StorageApi { - council::storage::StorageApi + pub mod staking_api { + use super::root_mod; + use super::runtime_types; + pub struct StakingApi; + impl StakingApi { + #[doc = " Returns the nominations quota for a nominator with a given balance."] + pub fn nominations_quota( + &self, + balance: ::core::primitive::u128, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "StakingApi_nominations_quota", + types::NominationsQuota { balance }, + [ + 181u8, 19u8, 6u8, 134u8, 234u8, 67u8, 127u8, 210u8, 53u8, 38u8, 175u8, + 160u8, 243u8, 71u8, 187u8, 206u8, 178u8, 91u8, 26u8, 115u8, 18u8, + 214u8, 50u8, 208u8, 161u8, 197u8, 81u8, 13u8, 98u8, 53u8, 124u8, 62u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct NominationsQuota { + pub balance: ::core::primitive::u128, + } + } } - pub fn technical_committee(&self) -> technical_committee::storage::StorageApi { - technical_committee::storage::StorageApi + pub mod tagged_transaction_queue { + use super::root_mod; + use super::runtime_types; + #[doc = " The `TaggedTransactionQueue` api trait for interfering with the transaction queue."] + pub struct TaggedTransactionQueue; + impl TaggedTransactionQueue { + #[doc = " Validate the transaction."] + #[doc = ""] + #[doc = " This method is invoked by the transaction pool to learn details about given transaction."] + #[doc = " The implementation should make sure to verify the correctness of the transaction"] + #[doc = " against current state. The given `block_hash` corresponds to the hash of the block"] + #[doc = " that is used as current state."] + #[doc = ""] + #[doc = " Note that this call may be performed by the pool multiple times and transactions"] + #[doc = " might be verified in any possible order."] + pub fn validate_transaction( + &self, + source: runtime_types::sp_runtime::transaction_validity::TransactionSource, + tx : runtime_types :: sp_runtime :: generic :: unchecked_extrinsic :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: polkadot_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment , runtime_types :: polkadot_runtime_common :: claims :: PrevalidateAttests ,) >, + block_hash: ::subxt::utils::H256, + ) -> ::subxt::runtime_api::Payload< + types::ValidateTransaction, + ::core::result::Result< + runtime_types::sp_runtime::transaction_validity::ValidTransaction, + runtime_types::sp_runtime::transaction_validity::TransactionValidityError, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "TaggedTransactionQueue_validate_transaction", + types::ValidateTransaction { + source, + tx, + block_hash, + }, + [ + 93u8, 180u8, 253u8, 37u8, 212u8, 54u8, 180u8, 214u8, 33u8, 5u8, 113u8, + 181u8, 25u8, 48u8, 153u8, 221u8, 78u8, 6u8, 115u8, 191u8, 72u8, 75u8, + 203u8, 171u8, 129u8, 75u8, 56u8, 60u8, 243u8, 92u8, 173u8, 12u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ValidateTransaction { pub source : runtime_types :: sp_runtime :: transaction_validity :: TransactionSource , pub tx : runtime_types :: sp_runtime :: generic :: unchecked_extrinsic :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: polkadot_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment , runtime_types :: polkadot_runtime_common :: claims :: PrevalidateAttests ,) > , pub block_hash : :: subxt :: utils :: H256 , } + } } - pub fn phragmen_election(&self) -> phragmen_election::storage::StorageApi { - phragmen_election::storage::StorageApi + pub mod offchain_worker_api { + use super::root_mod; + use super::runtime_types; + #[doc = " The offchain worker api."] + pub struct OffchainWorkerApi; + impl OffchainWorkerApi { + #[doc = " Starts the off-chain task for given block header."] + pub fn offchain_worker( + &self, + header: runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + ) -> ::subxt::runtime_api::Payload { + ::subxt::runtime_api::Payload::new_static( + "OffchainWorkerApi_offchain_worker", + types::OffchainWorker { header }, + [ + 187u8, 145u8, 211u8, 0u8, 200u8, 151u8, 231u8, 42u8, 187u8, 128u8, + 157u8, 64u8, 191u8, 64u8, 31u8, 158u8, 13u8, 159u8, 227u8, 120u8, + 155u8, 215u8, 228u8, 215u8, 44u8, 8u8, 206u8, 116u8, 241u8, 133u8, 2u8, + 234u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OffchainWorker { + pub header: runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + } + } } - pub fn technical_membership(&self) -> technical_membership::storage::StorageApi { - technical_membership::storage::StorageApi - } - pub fn treasury(&self) -> treasury::storage::StorageApi { - treasury::storage::StorageApi - } - pub fn conviction_voting(&self) -> conviction_voting::storage::StorageApi { - conviction_voting::storage::StorageApi - } - pub fn referenda(&self) -> referenda::storage::StorageApi { - referenda::storage::StorageApi - } - pub fn whitelist(&self) -> whitelist::storage::StorageApi { - whitelist::storage::StorageApi - } - pub fn claims(&self) -> claims::storage::StorageApi { - claims::storage::StorageApi - } - pub fn vesting(&self) -> vesting::storage::StorageApi { - vesting::storage::StorageApi - } - pub fn identity(&self) -> identity::storage::StorageApi { - identity::storage::StorageApi - } - pub fn proxy(&self) -> proxy::storage::StorageApi { - proxy::storage::StorageApi - } - pub fn multisig(&self) -> multisig::storage::StorageApi { - multisig::storage::StorageApi - } - pub fn bounties(&self) -> bounties::storage::StorageApi { - bounties::storage::StorageApi - } - pub fn child_bounties(&self) -> child_bounties::storage::StorageApi { - child_bounties::storage::StorageApi - } - pub fn tips(&self) -> tips::storage::StorageApi { - tips::storage::StorageApi - } - pub fn election_provider_multi_phase( - &self, - ) -> election_provider_multi_phase::storage::StorageApi { - election_provider_multi_phase::storage::StorageApi - } - pub fn voter_list(&self) -> voter_list::storage::StorageApi { - voter_list::storage::StorageApi - } - pub fn nomination_pools(&self) -> nomination_pools::storage::StorageApi { - nomination_pools::storage::StorageApi - } - pub fn fast_unstake(&self) -> fast_unstake::storage::StorageApi { - fast_unstake::storage::StorageApi - } - pub fn configuration(&self) -> configuration::storage::StorageApi { - configuration::storage::StorageApi - } - pub fn paras_shared(&self) -> paras_shared::storage::StorageApi { - paras_shared::storage::StorageApi - } - pub fn para_inclusion(&self) -> para_inclusion::storage::StorageApi { - para_inclusion::storage::StorageApi - } - pub fn para_inherent(&self) -> para_inherent::storage::StorageApi { - para_inherent::storage::StorageApi - } - pub fn para_scheduler(&self) -> para_scheduler::storage::StorageApi { - para_scheduler::storage::StorageApi - } - pub fn paras(&self) -> paras::storage::StorageApi { - paras::storage::StorageApi - } - pub fn initializer(&self) -> initializer::storage::StorageApi { - initializer::storage::StorageApi - } - pub fn dmp(&self) -> dmp::storage::StorageApi { - dmp::storage::StorageApi - } - pub fn ump(&self) -> ump::storage::StorageApi { - ump::storage::StorageApi - } - pub fn hrmp(&self) -> hrmp::storage::StorageApi { - hrmp::storage::StorageApi - } - pub fn para_session_info(&self) -> para_session_info::storage::StorageApi { - para_session_info::storage::StorageApi - } - pub fn paras_disputes(&self) -> paras_disputes::storage::StorageApi { - paras_disputes::storage::StorageApi - } - pub fn paras_slashing(&self) -> paras_slashing::storage::StorageApi { - paras_slashing::storage::StorageApi - } - pub fn registrar(&self) -> registrar::storage::StorageApi { - registrar::storage::StorageApi - } - pub fn slots(&self) -> slots::storage::StorageApi { - slots::storage::StorageApi - } - pub fn auctions(&self) -> auctions::storage::StorageApi { - auctions::storage::StorageApi - } - pub fn crowdloan(&self) -> crowdloan::storage::StorageApi { - crowdloan::storage::StorageApi - } - pub fn xcm_pallet(&self) -> xcm_pallet::storage::StorageApi { - xcm_pallet::storage::StorageApi - } - } - pub struct TransactionApi; - impl TransactionApi { - pub fn system(&self) -> system::calls::TransactionApi { - system::calls::TransactionApi - } - pub fn scheduler(&self) -> scheduler::calls::TransactionApi { - scheduler::calls::TransactionApi - } - pub fn preimage(&self) -> preimage::calls::TransactionApi { - preimage::calls::TransactionApi - } - pub fn babe(&self) -> babe::calls::TransactionApi { - babe::calls::TransactionApi - } - pub fn timestamp(&self) -> timestamp::calls::TransactionApi { - timestamp::calls::TransactionApi - } - pub fn indices(&self) -> indices::calls::TransactionApi { - indices::calls::TransactionApi - } - pub fn balances(&self) -> balances::calls::TransactionApi { - balances::calls::TransactionApi - } - pub fn staking(&self) -> staking::calls::TransactionApi { - staking::calls::TransactionApi - } - pub fn session(&self) -> session::calls::TransactionApi { - session::calls::TransactionApi - } - pub fn grandpa(&self) -> grandpa::calls::TransactionApi { - grandpa::calls::TransactionApi - } - pub fn im_online(&self) -> im_online::calls::TransactionApi { - im_online::calls::TransactionApi - } - pub fn democracy(&self) -> democracy::calls::TransactionApi { - democracy::calls::TransactionApi - } - pub fn council(&self) -> council::calls::TransactionApi { - council::calls::TransactionApi - } - pub fn technical_committee(&self) -> technical_committee::calls::TransactionApi { - technical_committee::calls::TransactionApi - } - pub fn phragmen_election(&self) -> phragmen_election::calls::TransactionApi { - phragmen_election::calls::TransactionApi - } - pub fn technical_membership(&self) -> technical_membership::calls::TransactionApi { - technical_membership::calls::TransactionApi - } - pub fn treasury(&self) -> treasury::calls::TransactionApi { - treasury::calls::TransactionApi - } - pub fn conviction_voting(&self) -> conviction_voting::calls::TransactionApi { - conviction_voting::calls::TransactionApi - } - pub fn referenda(&self) -> referenda::calls::TransactionApi { - referenda::calls::TransactionApi - } - pub fn whitelist(&self) -> whitelist::calls::TransactionApi { - whitelist::calls::TransactionApi - } - pub fn claims(&self) -> claims::calls::TransactionApi { - claims::calls::TransactionApi - } - pub fn vesting(&self) -> vesting::calls::TransactionApi { - vesting::calls::TransactionApi - } - pub fn utility(&self) -> utility::calls::TransactionApi { - utility::calls::TransactionApi - } - pub fn identity(&self) -> identity::calls::TransactionApi { - identity::calls::TransactionApi - } - pub fn proxy(&self) -> proxy::calls::TransactionApi { - proxy::calls::TransactionApi - } - pub fn multisig(&self) -> multisig::calls::TransactionApi { - multisig::calls::TransactionApi - } - pub fn bounties(&self) -> bounties::calls::TransactionApi { - bounties::calls::TransactionApi - } - pub fn child_bounties(&self) -> child_bounties::calls::TransactionApi { - child_bounties::calls::TransactionApi - } - pub fn tips(&self) -> tips::calls::TransactionApi { - tips::calls::TransactionApi - } - pub fn election_provider_multi_phase( - &self, - ) -> election_provider_multi_phase::calls::TransactionApi { - election_provider_multi_phase::calls::TransactionApi - } - pub fn voter_list(&self) -> voter_list::calls::TransactionApi { - voter_list::calls::TransactionApi - } - pub fn nomination_pools(&self) -> nomination_pools::calls::TransactionApi { - nomination_pools::calls::TransactionApi - } - pub fn fast_unstake(&self) -> fast_unstake::calls::TransactionApi { - fast_unstake::calls::TransactionApi - } - pub fn configuration(&self) -> configuration::calls::TransactionApi { - configuration::calls::TransactionApi - } - pub fn paras_shared(&self) -> paras_shared::calls::TransactionApi { - paras_shared::calls::TransactionApi - } - pub fn para_inclusion(&self) -> para_inclusion::calls::TransactionApi { - para_inclusion::calls::TransactionApi - } - pub fn para_inherent(&self) -> para_inherent::calls::TransactionApi { - para_inherent::calls::TransactionApi - } - pub fn paras(&self) -> paras::calls::TransactionApi { - paras::calls::TransactionApi - } - pub fn initializer(&self) -> initializer::calls::TransactionApi { - initializer::calls::TransactionApi - } - pub fn ump(&self) -> ump::calls::TransactionApi { - ump::calls::TransactionApi - } - pub fn hrmp(&self) -> hrmp::calls::TransactionApi { - hrmp::calls::TransactionApi - } - pub fn paras_disputes(&self) -> paras_disputes::calls::TransactionApi { - paras_disputes::calls::TransactionApi - } - pub fn paras_slashing(&self) -> paras_slashing::calls::TransactionApi { - paras_slashing::calls::TransactionApi - } - pub fn registrar(&self) -> registrar::calls::TransactionApi { - registrar::calls::TransactionApi - } - pub fn slots(&self) -> slots::calls::TransactionApi { - slots::calls::TransactionApi - } - pub fn auctions(&self) -> auctions::calls::TransactionApi { - auctions::calls::TransactionApi - } - pub fn crowdloan(&self) -> crowdloan::calls::TransactionApi { - crowdloan::calls::TransactionApi - } - pub fn xcm_pallet(&self) -> xcm_pallet::calls::TransactionApi { - xcm_pallet::calls::TransactionApi - } - } - #[doc = r" check whether the Client you are using is aligned with the statically generated codegen."] - pub fn validate_codegen>( - client: &C, - ) -> Result<(), ::subxt::error::MetadataError> { - let runtime_metadata_hash = client.metadata().metadata_hash(&PALLETS); - if runtime_metadata_hash - != [ - 193u8, 126u8, 5u8, 68u8, 158u8, 198u8, 107u8, 140u8, 166u8, 77u8, 81u8, 160u8, - 213u8, 179u8, 210u8, 41u8, 130u8, 34u8, 133u8, 228u8, 10u8, 134u8, 182u8, 62u8, - 72u8, 116u8, 209u8, 70u8, 115u8, 234u8, 227u8, 18u8, - ] - { - Err(::subxt::error::MetadataError::IncompatibleMetadata) - } else { - Ok(()) - } - } - pub mod system { - use super::root_mod; - use super::runtime_types; - #[doc = "Error for the System pallet"] - pub type Error = runtime_types::frame_system::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { + pub mod parachain_host { use super::root_mod; use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Remark { - pub remark: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHeapPages { - pub pages: ::core::primitive::u64, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCode { - pub code: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCodeWithoutChecks { - pub code: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetStorage { - pub items: ::std::vec::Vec<( - ::std::vec::Vec<::core::primitive::u8>, - ::std::vec::Vec<::core::primitive::u8>, - )>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillStorage { - pub keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillPrefix { - pub prefix: ::std::vec::Vec<::core::primitive::u8>, - pub subkeys: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemarkWithEvent { - pub remark: ::std::vec::Vec<::core::primitive::u8>, - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Make some on-chain remark."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(1)`"] - pub fn remark( + #[doc = " The API for querying the state of parachains on-chain."] + pub struct ParachainHost; + impl ParachainHost { + #[doc = " Get the current validators."] + pub fn validators( &self, - remark: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "remark", - types::Remark { remark }, + ) -> ::subxt::runtime_api::Payload< + types::Validators, + ::std::vec::Vec, + > { + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_validators", + types::Validators {}, [ - 101u8, 80u8, 195u8, 226u8, 224u8, 247u8, 60u8, 128u8, 3u8, 101u8, 51u8, - 147u8, 96u8, 126u8, 76u8, 230u8, 194u8, 227u8, 191u8, 73u8, 160u8, - 146u8, 87u8, 147u8, 243u8, 28u8, 228u8, 116u8, 224u8, 181u8, 129u8, - 160u8, + 105u8, 23u8, 110u8, 209u8, 38u8, 112u8, 199u8, 134u8, 145u8, 131u8, + 38u8, 221u8, 254u8, 147u8, 242u8, 149u8, 94u8, 76u8, 197u8, 67u8, + 228u8, 113u8, 196u8, 50u8, 122u8, 1u8, 121u8, 225u8, 163u8, 210u8, + 66u8, 68u8, ], ) } - #[doc = "Set the number of pages in the WebAssembly environment's heap."] - pub fn set_heap_pages( + #[doc = " Returns the validator groups and rotation info localized based on the hypothetical child"] + #[doc = " of a block whose state this is invoked on. Note that `now` in the `GroupRotationInfo`"] + #[doc = " should be the successor of the number of the block."] + pub fn validator_groups( &self, - pages: ::core::primitive::u64, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "set_heap_pages", - types::SetHeapPages { pages }, + ) -> ::subxt::runtime_api::Payload< + types::ValidatorGroups, + ( + ::std::vec::Vec< + ::std::vec::Vec, + >, + runtime_types::polkadot_primitives::v4::GroupRotationInfo< + ::core::primitive::u32, + >, + ), + > { + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_validator_groups", + types::ValidatorGroups {}, [ - 43u8, 103u8, 128u8, 49u8, 156u8, 136u8, 11u8, 204u8, 80u8, 6u8, 244u8, - 86u8, 171u8, 44u8, 140u8, 225u8, 142u8, 198u8, 43u8, 87u8, 26u8, 45u8, - 125u8, 222u8, 165u8, 254u8, 172u8, 158u8, 39u8, 178u8, 86u8, 87u8, + 185u8, 206u8, 229u8, 10u8, 93u8, 19u8, 23u8, 44u8, 159u8, 13u8, 235u8, + 236u8, 78u8, 153u8, 144u8, 82u8, 106u8, 248u8, 8u8, 92u8, 250u8, 54u8, + 153u8, 53u8, 183u8, 60u8, 67u8, 216u8, 201u8, 88u8, 217u8, 120u8, ], ) } - #[doc = "Set the new runtime code."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(C + S)` where `C` length of `code` and `S` complexity of `can_set_code`"] - pub fn set_code( + #[doc = " Yields information on all availability cores as relevant to the child block."] + #[doc = " Cores are either free or occupied. Free cores can have paras assigned to them."] + pub fn availability_cores( &self, - code: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "set_code", - types::SetCode { code }, + ) -> ::subxt::runtime_api::Payload< + types::AvailabilityCores, + ::std::vec::Vec< + runtime_types::polkadot_primitives::v4::CoreState< + ::subxt::utils::H256, + ::core::primitive::u32, + >, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_availability_cores", + types::AvailabilityCores {}, [ - 27u8, 104u8, 244u8, 205u8, 188u8, 254u8, 121u8, 13u8, 106u8, 120u8, - 244u8, 108u8, 97u8, 84u8, 100u8, 68u8, 26u8, 69u8, 93u8, 128u8, 107u8, - 4u8, 3u8, 142u8, 13u8, 134u8, 196u8, 62u8, 113u8, 181u8, 14u8, 40u8, + 107u8, 20u8, 115u8, 26u8, 118u8, 211u8, 207u8, 122u8, 134u8, 174u8, + 98u8, 237u8, 216u8, 175u8, 39u8, 176u8, 211u8, 78u8, 142u8, 29u8, + 127u8, 56u8, 160u8, 249u8, 174u8, 244u8, 146u8, 181u8, 4u8, 166u8, + 93u8, 13u8, ], ) } - #[doc = "Set the new runtime code without doing any checks of the given `code`."] + #[doc = " Yields the persisted validation data for the given `ParaId` along with an assumption that"] + #[doc = " should be used if the para currently occupies a core."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(C)` where `C` length of `code`"] - pub fn set_code_without_checks( + #[doc = " Returns `None` if either the para is not registered or the assumption is `Freed`"] + #[doc = " and the para already occupies a core."] + pub fn persisted_validation_data( &self, - code: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "set_code_without_checks", - types::SetCodeWithoutChecks { code }, + para_id: runtime_types::polkadot_parachain::primitives::Id, + assumption: runtime_types::polkadot_primitives::v4::OccupiedCoreAssumption, + ) -> ::subxt::runtime_api::Payload< + types::PersistedValidationData, + ::core::option::Option< + runtime_types::polkadot_primitives::v4::PersistedValidationData< + ::subxt::utils::H256, + ::core::primitive::u32, + >, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_persisted_validation_data", + types::PersistedValidationData { + para_id, + assumption, + }, [ - 102u8, 160u8, 125u8, 235u8, 30u8, 23u8, 45u8, 239u8, 112u8, 148u8, - 159u8, 158u8, 42u8, 93u8, 206u8, 94u8, 80u8, 250u8, 66u8, 195u8, 60u8, - 40u8, 142u8, 169u8, 183u8, 80u8, 80u8, 96u8, 3u8, 231u8, 99u8, 216u8, + 230u8, 186u8, 57u8, 116u8, 47u8, 20u8, 186u8, 89u8, 108u8, 211u8, 22u8, + 57u8, 124u8, 234u8, 140u8, 3u8, 104u8, 89u8, 89u8, 188u8, 156u8, 130u8, + 146u8, 77u8, 129u8, 66u8, 227u8, 157u8, 4u8, 134u8, 7u8, 237u8, ], ) } - #[doc = "Set some items of storage."] - pub fn set_storage( + #[doc = " Returns the persisted validation data for the given `ParaId` along with the corresponding"] + #[doc = " validation code hash. Instead of accepting assumption about the para, matches the validation"] + #[doc = " data hash against an expected one and yields `None` if they're not equal."] + pub fn assumed_validation_data( &self, - items: ::std::vec::Vec<( - ::std::vec::Vec<::core::primitive::u8>, - ::std::vec::Vec<::core::primitive::u8>, + para_id: runtime_types::polkadot_parachain::primitives::Id, + expected_persisted_validation_data_hash: ::subxt::utils::H256, + ) -> ::subxt::runtime_api::Payload< + types::AssumedValidationData, + ::core::option::Option<( + runtime_types::polkadot_primitives::v4::PersistedValidationData< + ::subxt::utils::H256, + ::core::primitive::u32, + >, + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, )>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "set_storage", - types::SetStorage { items }, + > { + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_assumed_validation_data", + types::AssumedValidationData { + para_id, + expected_persisted_validation_data_hash, + }, [ - 74u8, 43u8, 106u8, 255u8, 50u8, 151u8, 192u8, 155u8, 14u8, 90u8, 19u8, - 45u8, 165u8, 16u8, 235u8, 242u8, 21u8, 131u8, 33u8, 172u8, 119u8, 78u8, - 140u8, 10u8, 107u8, 202u8, 122u8, 235u8, 181u8, 191u8, 22u8, 116u8, + 53u8, 137u8, 220u8, 72u8, 155u8, 9u8, 200u8, 207u8, 158u8, 108u8, + 204u8, 15u8, 188u8, 162u8, 129u8, 158u8, 62u8, 200u8, 13u8, 0u8, 217u8, + 195u8, 19u8, 151u8, 187u8, 231u8, 197u8, 235u8, 128u8, 244u8, 51u8, + 85u8, ], ) } - #[doc = "Kill some items from storage."] - pub fn kill_storage( + #[doc = " Checks if the given validation outputs pass the acceptance criteria."] + pub fn check_validation_outputs( &self, - keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "kill_storage", - types::KillStorage { keys }, + para_id: runtime_types::polkadot_parachain::primitives::Id, + outputs: runtime_types::polkadot_primitives::v4::CandidateCommitments< + ::core::primitive::u32, + >, + ) -> ::subxt::runtime_api::Payload< + types::CheckValidationOutputs, + ::core::primitive::bool, + > { + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_check_validation_outputs", + types::CheckValidationOutputs { para_id, outputs }, [ - 174u8, 174u8, 13u8, 174u8, 75u8, 138u8, 128u8, 235u8, 222u8, 216u8, - 85u8, 18u8, 198u8, 1u8, 138u8, 70u8, 19u8, 108u8, 209u8, 41u8, 228u8, - 67u8, 130u8, 230u8, 160u8, 207u8, 11u8, 180u8, 139u8, 242u8, 41u8, - 15u8, + 99u8, 191u8, 194u8, 26u8, 245u8, 216u8, 224u8, 232u8, 26u8, 184u8, + 120u8, 64u8, 32u8, 134u8, 215u8, 138u8, 195u8, 30u8, 220u8, 111u8, + 119u8, 182u8, 62u8, 72u8, 5u8, 144u8, 87u8, 157u8, 125u8, 125u8, 237u8, + 34u8, ], ) } - #[doc = "Kill all storage items with a key that starts with the given prefix."] + #[doc = " Returns the session index expected at a child of the block."] #[doc = ""] - #[doc = "**NOTE:** We rely on the Root origin to provide us the number of subkeys under"] - #[doc = "the prefix we are removing to accurately calculate the weight of this function."] - pub fn kill_prefix( + #[doc = " This can be used to instantiate a `SigningContext`."] + pub fn session_index_for_child( &self, - prefix: ::std::vec::Vec<::core::primitive::u8>, - subkeys: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "kill_prefix", - types::KillPrefix { prefix, subkeys }, + ) -> ::subxt::runtime_api::Payload< + types::SessionIndexForChild, + ::core::primitive::u32, + > { + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_session_index_for_child", + types::SessionIndexForChild {}, [ - 203u8, 116u8, 217u8, 42u8, 154u8, 215u8, 77u8, 217u8, 13u8, 22u8, - 193u8, 2u8, 128u8, 115u8, 179u8, 115u8, 187u8, 218u8, 129u8, 34u8, - 80u8, 4u8, 173u8, 120u8, 92u8, 35u8, 237u8, 112u8, 201u8, 207u8, 200u8, - 48u8, + 224u8, 173u8, 95u8, 16u8, 57u8, 180u8, 35u8, 148u8, 243u8, 77u8, 123u8, + 242u8, 212u8, 122u8, 27u8, 32u8, 44u8, 166u8, 66u8, 124u8, 1u8, 190u8, + 93u8, 124u8, 57u8, 127u8, 249u8, 141u8, 173u8, 92u8, 137u8, 165u8, ], ) } - #[doc = "Make some on-chain remark and emit event."] - pub fn remark_with_event( + #[doc = " Fetch the validation code used by a para, making the given `OccupiedCoreAssumption`."] + #[doc = ""] + #[doc = " Returns `None` if either the para is not registered or the assumption is `Freed`"] + #[doc = " and the para already occupies a core."] + pub fn validation_code( &self, - remark: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "remark_with_event", - types::RemarkWithEvent { remark }, - [ - 123u8, 225u8, 180u8, 179u8, 144u8, 74u8, 27u8, 85u8, 101u8, 75u8, - 134u8, 44u8, 181u8, 25u8, 183u8, 158u8, 14u8, 213u8, 56u8, 225u8, - 136u8, 88u8, 26u8, 114u8, 178u8, 43u8, 176u8, 43u8, 240u8, 84u8, 116u8, - 46u8, - ], - ) - } - } - } - #[doc = "Event for the System pallet."] - pub type Event = runtime_types::frame_system::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An extrinsic completed successfully."] - pub struct ExtrinsicSuccess { - pub dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - } - impl ::subxt::events::StaticEvent for ExtrinsicSuccess { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "ExtrinsicSuccess"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An extrinsic failed."] - pub struct ExtrinsicFailed { - pub dispatch_error: runtime_types::sp_runtime::DispatchError, - pub dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - } - impl ::subxt::events::StaticEvent for ExtrinsicFailed { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "ExtrinsicFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "`:code` was updated."] - pub struct CodeUpdated; - impl ::subxt::events::StaticEvent for CodeUpdated { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "CodeUpdated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new account was created."] - pub struct NewAccount { - pub account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for NewAccount { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "NewAccount"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was reaped."] - pub struct KilledAccount { - pub account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for KilledAccount { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "KilledAccount"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "On on-chain remark happened."] - pub struct Remarked { - pub sender: ::subxt::utils::AccountId32, - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Remarked { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "Remarked"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The full account information for a particular account ID."] - pub fn account( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::AccountInfo< - ::core::primitive::u32, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, + para_id: runtime_types::polkadot_parachain::primitives::Id, + assumption: runtime_types::polkadot_primitives::v4::OccupiedCoreAssumption, + ) -> ::subxt::runtime_api::Payload< + types::ValidationCode, + ::core::option::Option< + runtime_types::polkadot_parachain::primitives::ValidationCode, >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, > { - ::subxt::storage::address::Address::new_static( - "System", - "Account", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_validation_code", + types::ValidationCode { + para_id, + assumption, + }, [ - 248u8, 178u8, 160u8, 222u8, 45u8, 231u8, 115u8, 164u8, 98u8, 184u8, - 174u8, 206u8, 149u8, 190u8, 175u8, 34u8, 202u8, 230u8, 69u8, 218u8, - 83u8, 43u8, 170u8, 41u8, 106u8, 77u8, 233u8, 97u8, 114u8, 14u8, 155u8, - 131u8, + 231u8, 64u8, 145u8, 133u8, 197u8, 196u8, 177u8, 229u8, 152u8, 70u8, + 16u8, 159u8, 65u8, 66u8, 172u8, 58u8, 60u8, 50u8, 232u8, 28u8, 36u8, + 211u8, 161u8, 28u8, 192u8, 153u8, 89u8, 186u8, 9u8, 246u8, 228u8, 84u8, ], ) } - #[doc = " The full account information for a particular account ID."] - pub fn account_root( + #[doc = " Get the receipt of a candidate pending availability. This returns `Some` for any paras"] + #[doc = " assigned to occupied cores in `availability_cores` and `None` otherwise."] + pub fn candidate_pending_availability( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::AccountInfo< - ::core::primitive::u32, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, + para_id: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::runtime_api::Payload< + types::CandidatePendingAvailability, + ::core::option::Option< + runtime_types::polkadot_primitives::v4::CommittedCandidateReceipt< + ::subxt::utils::H256, + >, >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "System", - "Account", - Vec::new(), - [ - 248u8, 178u8, 160u8, 222u8, 45u8, 231u8, 115u8, 164u8, 98u8, 184u8, - 174u8, 206u8, 149u8, 190u8, 175u8, 34u8, 202u8, 230u8, 69u8, 218u8, - 83u8, 43u8, 170u8, 41u8, 106u8, 77u8, 233u8, 97u8, 114u8, 14u8, 155u8, - 131u8, - ], - ) - } - #[doc = " Total extrinsics count for the current block."] - pub fn extrinsic_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), > { - ::subxt::storage::address::Address::new_static( - "System", - "ExtrinsicCount", - vec![], + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_candidate_pending_availability", + types::CandidatePendingAvailability { para_id }, [ - 223u8, 60u8, 201u8, 120u8, 36u8, 44u8, 180u8, 210u8, 242u8, 53u8, - 222u8, 154u8, 123u8, 176u8, 249u8, 8u8, 225u8, 28u8, 232u8, 4u8, 136u8, - 41u8, 151u8, 82u8, 189u8, 149u8, 49u8, 166u8, 139u8, 9u8, 163u8, 231u8, + 175u8, 68u8, 187u8, 74u8, 138u8, 129u8, 153u8, 251u8, 216u8, 70u8, + 251u8, 151u8, 169u8, 252u8, 31u8, 16u8, 61u8, 242u8, 169u8, 15u8, + 123u8, 58u8, 177u8, 131u8, 6u8, 79u8, 30u8, 105u8, 51u8, 67u8, 19u8, + 208u8, ], ) } - #[doc = " The current weight for the block."] - pub fn block_weight( + #[doc = " Get a vector of events concerning candidates that occurred within a block."] + pub fn candidate_events( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_support::dispatch::PerDispatchClass< - runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::runtime_api::Payload< + types::CandidateEvents, + ::std::vec::Vec< + runtime_types::polkadot_primitives::v4::CandidateEvent< + ::subxt::utils::H256, + >, >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "BlockWeight", - vec![], - [ - 120u8, 67u8, 71u8, 163u8, 36u8, 202u8, 52u8, 106u8, 143u8, 155u8, - 144u8, 87u8, 142u8, 241u8, 232u8, 183u8, 56u8, 235u8, 27u8, 237u8, - 20u8, 202u8, 33u8, 85u8, 189u8, 0u8, 28u8, 52u8, 198u8, 40u8, 219u8, - 54u8, - ], - ) - } - #[doc = " Total length (in bytes) for all extrinsics put together, for the current block."] - pub fn all_extrinsics_len( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "AllExtrinsicsLen", - vec![], - [ - 202u8, 145u8, 209u8, 225u8, 40u8, 220u8, 174u8, 74u8, 93u8, 164u8, - 254u8, 248u8, 254u8, 192u8, 32u8, 117u8, 96u8, 149u8, 53u8, 145u8, - 219u8, 64u8, 234u8, 18u8, 217u8, 200u8, 203u8, 141u8, 145u8, 28u8, - 134u8, 60u8, - ], - ) - } - #[doc = " Map of block numbers to block hashes."] - pub fn block_hash( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, > { - ::subxt::storage::address::Address::new_static( - "System", - "BlockHash", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_candidate_events", + types::CandidateEvents {}, [ - 50u8, 112u8, 176u8, 239u8, 175u8, 18u8, 205u8, 20u8, 241u8, 195u8, - 21u8, 228u8, 186u8, 57u8, 200u8, 25u8, 38u8, 44u8, 106u8, 20u8, 168u8, - 80u8, 76u8, 235u8, 12u8, 51u8, 137u8, 149u8, 200u8, 4u8, 220u8, 237u8, + 50u8, 177u8, 192u8, 138u8, 139u8, 179u8, 76u8, 167u8, 238u8, 92u8, + 255u8, 249u8, 223u8, 61u8, 112u8, 7u8, 0u8, 6u8, 43u8, 71u8, 209u8, + 21u8, 14u8, 184u8, 19u8, 68u8, 106u8, 193u8, 38u8, 251u8, 19u8, 208u8, ], ) } - #[doc = " Map of block numbers to block hashes."] - pub fn block_hash_root( + #[doc = " Get all the pending inbound messages in the downward message queue for a para."] + pub fn dmq_contents( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + recipient: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::runtime_api::Payload< + types::DmqContents, + ::std::vec::Vec< + runtime_types::polkadot_core_primitives::InboundDownwardMessage< + ::core::primitive::u32, + >, + >, > { - ::subxt::storage::address::Address::new_static( - "System", - "BlockHash", - Vec::new(), + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_dmq_contents", + types::DmqContents { recipient }, [ - 50u8, 112u8, 176u8, 239u8, 175u8, 18u8, 205u8, 20u8, 241u8, 195u8, - 21u8, 228u8, 186u8, 57u8, 200u8, 25u8, 38u8, 44u8, 106u8, 20u8, 168u8, - 80u8, 76u8, 235u8, 12u8, 51u8, 137u8, 149u8, 200u8, 4u8, 220u8, 237u8, + 34u8, 66u8, 1u8, 92u8, 223u8, 240u8, 222u8, 128u8, 190u8, 242u8, 160u8, + 140u8, 60u8, 57u8, 155u8, 105u8, 10u8, 162u8, 212u8, 72u8, 1u8, 192u8, + 36u8, 26u8, 127u8, 86u8, 8u8, 255u8, 57u8, 210u8, 148u8, 254u8, ], ) } - #[doc = " Extrinsics data for the current block (maps an extrinsic's index to its data)."] - pub fn extrinsic_data( + #[doc = " Get the contents of all channels addressed to the given recipient. Channels that have no"] + #[doc = " messages in them are also included."] + pub fn inbound_hrmp_channels_contents( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + recipient: runtime_types::polkadot_parachain::primitives::Id, + ) -> ::subxt::runtime_api::Payload< + types::InboundHrmpChannelsContents, + ::subxt::utils::KeyedVec< + runtime_types::polkadot_parachain::primitives::Id, + ::std::vec::Vec< + runtime_types::polkadot_core_primitives::InboundHrmpMessage< + ::core::primitive::u32, + >, + >, + >, > { - ::subxt::storage::address::Address::new_static( - "System", - "ExtrinsicData", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_inbound_hrmp_channels_contents", + types::InboundHrmpChannelsContents { recipient }, [ - 210u8, 224u8, 211u8, 186u8, 118u8, 210u8, 185u8, 194u8, 238u8, 211u8, - 254u8, 73u8, 67u8, 184u8, 31u8, 229u8, 168u8, 125u8, 98u8, 23u8, 241u8, - 59u8, 49u8, 86u8, 126u8, 9u8, 114u8, 163u8, 160u8, 62u8, 50u8, 67u8, + 209u8, 72u8, 244u8, 143u8, 167u8, 234u8, 8u8, 33u8, 80u8, 154u8, 132u8, + 22u8, 62u8, 174u8, 3u8, 89u8, 78u8, 115u8, 119u8, 77u8, 169u8, 80u8, + 98u8, 164u8, 8u8, 8u8, 50u8, 120u8, 58u8, 12u8, 114u8, 57u8, ], ) } - #[doc = " Extrinsics data for the current block (maps an extrinsic's index to its data)."] - pub fn extrinsic_data_root( + #[doc = " Get the validation code from its hash."] + pub fn validation_code_by_hash( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + hash: runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + ) -> ::subxt::runtime_api::Payload< + types::ValidationCodeByHash, + ::core::option::Option< + runtime_types::polkadot_parachain::primitives::ValidationCode, + >, > { - ::subxt::storage::address::Address::new_static( - "System", - "ExtrinsicData", - Vec::new(), + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_validation_code_by_hash", + types::ValidationCodeByHash { hash }, [ - 210u8, 224u8, 211u8, 186u8, 118u8, 210u8, 185u8, 194u8, 238u8, 211u8, - 254u8, 73u8, 67u8, 184u8, 31u8, 229u8, 168u8, 125u8, 98u8, 23u8, 241u8, - 59u8, 49u8, 86u8, 126u8, 9u8, 114u8, 163u8, 160u8, 62u8, 50u8, 67u8, + 143u8, 146u8, 97u8, 197u8, 138u8, 122u8, 186u8, 0u8, 86u8, 105u8, + 207u8, 55u8, 53u8, 47u8, 131u8, 101u8, 24u8, 71u8, 204u8, 71u8, 96u8, + 100u8, 252u8, 127u8, 21u8, 248u8, 70u8, 187u8, 111u8, 112u8, 77u8, + 208u8, ], ) } - #[doc = " The current block number being processed. Set by `execute_block`."] - pub fn number( + #[doc = " Scrape dispute relevant from on-chain, backing votes and resolved disputes."] + pub fn on_chain_votes( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), + ) -> ::subxt::runtime_api::Payload< + types::OnChainVotes, + ::core::option::Option< + runtime_types::polkadot_primitives::v4::ScrapedOnChainVotes< + ::subxt::utils::H256, + >, + >, > { - ::subxt::storage::address::Address::new_static( - "System", - "Number", - vec![], + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_on_chain_votes", + types::OnChainVotes {}, [ - 228u8, 96u8, 102u8, 190u8, 252u8, 130u8, 239u8, 172u8, 126u8, 235u8, - 246u8, 139u8, 208u8, 15u8, 88u8, 245u8, 141u8, 232u8, 43u8, 204u8, - 36u8, 87u8, 211u8, 141u8, 187u8, 68u8, 236u8, 70u8, 193u8, 235u8, - 164u8, 191u8, + 37u8, 2u8, 32u8, 215u8, 117u8, 137u8, 242u8, 168u8, 57u8, 175u8, 59u8, + 243u8, 132u8, 133u8, 246u8, 37u8, 154u8, 205u8, 191u8, 114u8, 114u8, + 167u8, 104u8, 27u8, 144u8, 56u8, 61u8, 159u8, 9u8, 79u8, 190u8, 239u8, ], ) } - #[doc = " Hash of the previous block."] - pub fn parent_hash( + #[doc = " Get the session info for the given session, if stored."] + #[doc = ""] + #[doc = " NOTE: This function is only available since parachain host version 2."] + pub fn session_info( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), + index: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload< + types::SessionInfo, + ::core::option::Option, > { - ::subxt::storage::address::Address::new_static( - "System", - "ParentHash", - vec![], + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_session_info", + types::SessionInfo { index }, [ - 232u8, 206u8, 177u8, 119u8, 38u8, 57u8, 233u8, 50u8, 225u8, 49u8, - 169u8, 176u8, 210u8, 51u8, 231u8, 176u8, 234u8, 186u8, 188u8, 112u8, - 15u8, 152u8, 195u8, 232u8, 201u8, 97u8, 208u8, 249u8, 9u8, 163u8, 69u8, - 36u8, + 107u8, 247u8, 186u8, 88u8, 134u8, 234u8, 251u8, 220u8, 134u8, 138u8, + 130u8, 168u8, 253u8, 101u8, 235u8, 126u8, 190u8, 37u8, 77u8, 182u8, + 195u8, 100u8, 63u8, 173u8, 147u8, 98u8, 217u8, 235u8, 220u8, 87u8, + 83u8, 198u8, ], ) } - #[doc = " Digest of the current block, also part of the block header."] - pub fn digest( + #[doc = " Submits a PVF pre-checking statement into the transaction pool."] + #[doc = ""] + #[doc = " NOTE: This function is only available since parachain host version 2."] + pub fn submit_pvf_check_statement( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_runtime::generic::digest::Digest, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "Digest", - vec![], + stmt: runtime_types::polkadot_primitives::v4::PvfCheckStatement, + signature: runtime_types::polkadot_primitives::v4::validator_app::Signature, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_submit_pvf_check_statement", + types::SubmitPvfCheckStatement { stmt, signature }, [ - 83u8, 141u8, 200u8, 132u8, 182u8, 55u8, 197u8, 122u8, 13u8, 159u8, - 31u8, 42u8, 60u8, 191u8, 89u8, 221u8, 242u8, 47u8, 199u8, 213u8, 48u8, - 216u8, 131u8, 168u8, 245u8, 82u8, 56u8, 190u8, 62u8, 69u8, 96u8, 37u8, + 228u8, 45u8, 8u8, 229u8, 69u8, 35u8, 3u8, 231u8, 235u8, 184u8, 19u8, + 96u8, 72u8, 62u8, 15u8, 218u8, 27u8, 134u8, 19u8, 179u8, 239u8, 1u8, + 207u8, 39u8, 50u8, 171u8, 59u8, 204u8, 143u8, 247u8, 27u8, 179u8, ], ) } - #[doc = " Events deposited for the current block."] - #[doc = ""] - #[doc = " NOTE: The item is unbound and should therefore never be read on chain."] - #[doc = " It could otherwise inflate the PoV size of a block."] + #[doc = " Returns code hashes of PVFs that require pre-checking by validators in the active set."] #[doc = ""] - #[doc = " Events have a large in-memory size. Box the events to not go out-of-memory"] - #[doc = " just in case someone still reads them from within the runtime."] - pub fn events( + #[doc = " NOTE: This function is only available since parachain host version 2."] + pub fn pvfs_require_precheck( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, + ) -> ::subxt::runtime_api::Payload< + types::PvfsRequirePrecheck, ::std::vec::Vec< - runtime_types::frame_system::EventRecord< - runtime_types::polkadot_runtime::RuntimeEvent, - ::subxt::utils::H256, - >, + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "Events", - vec![], - [ - 78u8, 158u8, 91u8, 165u8, 29u8, 179u8, 204u8, 195u8, 39u8, 3u8, 127u8, - 199u8, 132u8, 93u8, 252u8, 17u8, 84u8, 58u8, 51u8, 56u8, 159u8, 51u8, - 188u8, 138u8, 75u8, 109u8, 148u8, 73u8, 227u8, 56u8, 162u8, 246u8, - ], - ) - } - #[doc = " The number of events in the `Events` list."] - pub fn event_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), > { - ::subxt::storage::address::Address::new_static( - "System", - "EventCount", - vec![], + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_pvfs_require_precheck", + types::PvfsRequirePrecheck {}, [ - 236u8, 93u8, 90u8, 177u8, 250u8, 211u8, 138u8, 187u8, 26u8, 208u8, - 203u8, 113u8, 221u8, 233u8, 227u8, 9u8, 249u8, 25u8, 202u8, 185u8, - 161u8, 144u8, 167u8, 104u8, 127u8, 187u8, 38u8, 18u8, 52u8, 61u8, 66u8, - 112u8, + 58u8, 208u8, 110u8, 249u8, 77u8, 56u8, 39u8, 46u8, 196u8, 209u8, 189u8, + 200u8, 147u8, 235u8, 247u8, 235u8, 125u8, 230u8, 11u8, 151u8, 137u8, + 118u8, 110u8, 179u8, 72u8, 53u8, 127u8, 149u8, 252u8, 20u8, 165u8, + 239u8, ], ) } - #[doc = " Mapping between a topic (represented by T::Hash) and a vector of indexes"] - #[doc = " of events in the `>` list."] - #[doc = ""] - #[doc = " All topic vectors have deterministic storage locations depending on the topic. This"] - #[doc = " allows light-clients to leverage the changes trie storage tracking mechanism and"] - #[doc = " in case of changes fetch the list of events of interest."] + #[doc = " Fetch the hash of the validation code used by a para, making the given `OccupiedCoreAssumption`."] #[doc = ""] - #[doc = " The value has the type `(T::BlockNumber, EventIndex)` because if we used only just"] - #[doc = " the `EventIndex` then in case if the topic has the same contents on the next block"] - #[doc = " no notification will be triggered thus the event might be lost."] - pub fn event_topics( + #[doc = " NOTE: This function is only available since parachain host version 2."] + pub fn validation_code_hash( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::u32)>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + para_id: runtime_types::polkadot_parachain::primitives::Id, + assumption: runtime_types::polkadot_primitives::v4::OccupiedCoreAssumption, + ) -> ::subxt::runtime_api::Payload< + types::ValidationCodeHash, + ::core::option::Option< + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + >, > { - ::subxt::storage::address::Address::new_static( - "System", - "EventTopics", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_validation_code_hash", + types::ValidationCodeHash { + para_id, + assumption, + }, [ - 205u8, 90u8, 142u8, 190u8, 176u8, 37u8, 94u8, 82u8, 98u8, 1u8, 129u8, - 63u8, 246u8, 101u8, 130u8, 58u8, 216u8, 16u8, 139u8, 196u8, 154u8, - 111u8, 110u8, 178u8, 24u8, 44u8, 183u8, 176u8, 232u8, 82u8, 223u8, - 38u8, + 232u8, 173u8, 117u8, 125u8, 245u8, 188u8, 20u8, 124u8, 255u8, 219u8, + 2u8, 95u8, 131u8, 3u8, 122u8, 190u8, 240u8, 184u8, 8u8, 239u8, 85u8, + 107u8, 59u8, 105u8, 206u8, 130u8, 65u8, 142u8, 130u8, 193u8, 143u8, + 199u8, ], ) } - #[doc = " Mapping between a topic (represented by T::Hash) and a vector of indexes"] - #[doc = " of events in the `>` list."] - #[doc = ""] - #[doc = " All topic vectors have deterministic storage locations depending on the topic. This"] - #[doc = " allows light-clients to leverage the changes trie storage tracking mechanism and"] - #[doc = " in case of changes fetch the list of events of interest."] - #[doc = ""] - #[doc = " The value has the type `(T::BlockNumber, EventIndex)` because if we used only just"] - #[doc = " the `EventIndex` then in case if the topic has the same contents on the next block"] - #[doc = " no notification will be triggered thus the event might be lost."] - pub fn event_topics_root( + #[doc = " Returns all onchain disputes."] + pub fn disputes( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::u32)>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + ) -> ::subxt::runtime_api::Payload< + types::Disputes, + ::std::vec::Vec<( + ::core::primitive::u32, + runtime_types::polkadot_core_primitives::CandidateHash, + runtime_types::polkadot_primitives::v4::DisputeState< + ::core::primitive::u32, + >, + )>, > { - ::subxt::storage::address::Address::new_static( - "System", - "EventTopics", - Vec::new(), + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_disputes", + types::Disputes {}, [ - 205u8, 90u8, 142u8, 190u8, 176u8, 37u8, 94u8, 82u8, 98u8, 1u8, 129u8, - 63u8, 246u8, 101u8, 130u8, 58u8, 216u8, 16u8, 139u8, 196u8, 154u8, - 111u8, 110u8, 178u8, 24u8, 44u8, 183u8, 176u8, 232u8, 82u8, 223u8, - 38u8, + 90u8, 171u8, 12u8, 104u8, 109u8, 92u8, 149u8, 72u8, 109u8, 39u8, 75u8, + 241u8, 239u8, 78u8, 46u8, 134u8, 139u8, 200u8, 144u8, 213u8, 218u8, + 64u8, 98u8, 102u8, 159u8, 211u8, 154u8, 178u8, 187u8, 146u8, 193u8, + 34u8, ], ) } - #[doc = " Stores the `spec_version` and `spec_name` of when the last runtime upgrade happened."] - pub fn last_runtime_upgrade( + #[doc = " Returns execution parameters for the session."] + pub fn session_executor_params( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::LastRuntimeUpgradeInfo, - ::subxt::storage::address::Yes, - (), - (), + session_index: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload< + types::SessionExecutorParams, + ::core::option::Option< + runtime_types::polkadot_primitives::v4::executor_params::ExecutorParams, + >, > { - ::subxt::storage::address::Address::new_static( - "System", - "LastRuntimeUpgrade", - vec![], + ::subxt::runtime_api::Payload::new_static( + "ParachainHost_session_executor_params", + types::SessionExecutorParams { session_index }, [ - 52u8, 37u8, 117u8, 111u8, 57u8, 130u8, 196u8, 14u8, 99u8, 77u8, 91u8, - 126u8, 178u8, 249u8, 78u8, 34u8, 9u8, 194u8, 92u8, 105u8, 113u8, 81u8, - 185u8, 127u8, 245u8, 184u8, 60u8, 29u8, 234u8, 182u8, 96u8, 196u8, + 129u8, 198u8, 157u8, 37u8, 138u8, 132u8, 5u8, 183u8, 233u8, 119u8, + 99u8, 173u8, 22u8, 240u8, 182u8, 246u8, 101u8, 3u8, 149u8, 130u8, + 107u8, 60u8, 152u8, 217u8, 86u8, 150u8, 253u8, 170u8, 10u8, 86u8, + 183u8, 33u8, ], ) } - #[doc = " True if we have upgraded so that `type RefCount` is `u32`. False (default) if not."] - pub fn upgraded_to_u32_ref_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Validators {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ValidatorGroups {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AvailabilityCores {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PersistedValidationData { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub assumption: runtime_types::polkadot_primitives::v4::OccupiedCoreAssumption, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AssumedValidationData { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub expected_persisted_validation_data_hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckValidationOutputs { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub outputs: runtime_types::polkadot_primitives::v4::CandidateCommitments< + ::core::primitive::u32, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SessionIndexForChild {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ValidationCode { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub assumption: runtime_types::polkadot_primitives::v4::OccupiedCoreAssumption, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CandidatePendingAvailability { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CandidateEvents {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DmqContents { + pub recipient: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct InboundHrmpChannelsContents { + pub recipient: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ValidationCodeByHash { + pub hash: runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OnChainVotes {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SessionInfo { + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SubmitPvfCheckStatement { + pub stmt: runtime_types::polkadot_primitives::v4::PvfCheckStatement, + pub signature: runtime_types::polkadot_primitives::v4::validator_app::Signature, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PvfsRequirePrecheck {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ValidationCodeHash { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub assumption: runtime_types::polkadot_primitives::v4::OccupiedCoreAssumption, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Disputes {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SessionExecutorParams { + pub session_index: ::core::primitive::u32, + } + } + } + pub mod beefy_api { + use super::root_mod; + use super::runtime_types; + #[doc = " API necessary for BEEFY voters."] + pub struct BeefyApi; + impl BeefyApi { + #[doc = " Return the block number where BEEFY consensus is enabled/started"] + pub fn beefy_genesis( + &self, + ) -> ::subxt::runtime_api::Payload< + types::BeefyGenesis, + ::core::option::Option<::core::primitive::u32>, > { - ::subxt::storage::address::Address::new_static( - "System", - "UpgradedToU32RefCount", - vec![], + ::subxt::runtime_api::Payload::new_static( + "BeefyApi_beefy_genesis", + types::BeefyGenesis {}, [ - 171u8, 88u8, 244u8, 92u8, 122u8, 67u8, 27u8, 18u8, 59u8, 175u8, 175u8, - 178u8, 20u8, 150u8, 213u8, 59u8, 222u8, 141u8, 32u8, 107u8, 3u8, 114u8, - 83u8, 250u8, 180u8, 233u8, 152u8, 54u8, 187u8, 99u8, 131u8, 204u8, + 80u8, 47u8, 5u8, 126u8, 16u8, 213u8, 203u8, 179u8, 124u8, 14u8, 227u8, + 61u8, 164u8, 158u8, 115u8, 127u8, 132u8, 90u8, 222u8, 87u8, 249u8, + 214u8, 100u8, 13u8, 201u8, 186u8, 229u8, 217u8, 21u8, 152u8, 197u8, + 60u8, ], ) } - #[doc = " True if we have upgraded so that AccountInfo contains three types of `RefCount`. False"] - #[doc = " (default) if not."] - pub fn upgraded_to_triple_ref_count( + #[doc = " Return the current active BEEFY validator set"] + pub fn validator_set( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), + ) -> ::subxt::runtime_api::Payload< + types::ValidatorSet, + ::core::option::Option< + runtime_types::sp_consensus_beefy::ValidatorSet< + runtime_types::sp_consensus_beefy::crypto::Public, + >, + >, > { - ::subxt::storage::address::Address::new_static( - "System", - "UpgradedToTripleRefCount", - vec![], + ::subxt::runtime_api::Payload::new_static( + "BeefyApi_validator_set", + types::ValidatorSet {}, [ - 90u8, 33u8, 56u8, 86u8, 90u8, 101u8, 89u8, 133u8, 203u8, 56u8, 201u8, - 210u8, 244u8, 232u8, 150u8, 18u8, 51u8, 105u8, 14u8, 230u8, 103u8, - 155u8, 246u8, 99u8, 53u8, 207u8, 225u8, 128u8, 186u8, 76u8, 40u8, - 185u8, + 49u8, 44u8, 188u8, 42u8, 35u8, 233u8, 181u8, 44u8, 232u8, 88u8, 1u8, + 100u8, 90u8, 42u8, 139u8, 239u8, 25u8, 44u8, 183u8, 164u8, 161u8, + 129u8, 12u8, 158u8, 41u8, 39u8, 218u8, 43u8, 78u8, 70u8, 156u8, 159u8, ], ) } - #[doc = " The execution phase of the block."] - pub fn execution_phase( + #[doc = " Submits an unsigned extrinsic to report an equivocation. The caller"] + #[doc = " must provide the equivocation proof and a key ownership proof"] + #[doc = " (should be obtained using `generate_key_ownership_proof`). The"] + #[doc = " extrinsic will be unsigned and should only be accepted for local"] + #[doc = " authorship (not to be broadcast to the network). This method returns"] + #[doc = " `None` when creation of the extrinsic fails, e.g. if equivocation"] + #[doc = " reporting is disabled for the given runtime (i.e. this method is"] + #[doc = " hardcoded to return `None`). Only useful in an offchain context."] + pub fn submit_report_equivocation_unsigned_extrinsic( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::Phase, - ::subxt::storage::address::Yes, - (), - (), + equivocation_proof: runtime_types::sp_consensus_beefy::EquivocationProof< + ::core::primitive::u32, + runtime_types::sp_consensus_beefy::crypto::Public, + runtime_types::sp_consensus_beefy::crypto::Signature, + >, + key_owner_proof: runtime_types::sp_consensus_beefy::OpaqueKeyOwnershipProof, + ) -> ::subxt::runtime_api::Payload< + types::SubmitReportEquivocationUnsignedExtrinsic, + ::core::option::Option<()>, + > { + ::subxt::runtime_api::Payload::new_static( + "BeefyApi_submit_report_equivocation_unsigned_extrinsic", + types::SubmitReportEquivocationUnsignedExtrinsic { + equivocation_proof, + key_owner_proof, + }, + [ + 232u8, 114u8, 155u8, 57u8, 178u8, 76u8, 154u8, 140u8, 49u8, 60u8, 71u8, + 98u8, 167u8, 4u8, 248u8, 159u8, 0u8, 36u8, 119u8, 102u8, 188u8, 10u8, + 137u8, 252u8, 249u8, 124u8, 208u8, 173u8, 252u8, 185u8, 117u8, 35u8, + ], + ) + } + #[doc = " Generates a proof of key ownership for the given authority in the"] + #[doc = " given set. An example usage of this module is coupled with the"] + #[doc = " session historical module to prove that a given authority key is"] + #[doc = " tied to a given staking identity during a specific session. Proofs"] + #[doc = " of key ownership are necessary for submitting equivocation reports."] + #[doc = " NOTE: even though the API takes a `set_id` as parameter the current"] + #[doc = " implementations ignores this parameter and instead relies on this"] + #[doc = " method being called at the correct block height, i.e. any point at"] + #[doc = " which the given set id is live on-chain. Future implementations will"] + #[doc = " instead use indexed data through an offchain worker, not requiring"] + #[doc = " older states to be available."] + pub fn generate_key_ownership_proof( + &self, + set_id: ::core::primitive::u64, + authority_id: runtime_types::sp_consensus_beefy::crypto::Public, + ) -> ::subxt::runtime_api::Payload< + types::GenerateKeyOwnershipProof, + ::core::option::Option< + runtime_types::sp_consensus_beefy::OpaqueKeyOwnershipProof, + >, > { - ::subxt::storage::address::Address::new_static( - "System", - "ExecutionPhase", - vec![], + ::subxt::runtime_api::Payload::new_static( + "BeefyApi_generate_key_ownership_proof", + types::GenerateKeyOwnershipProof { + set_id, + authority_id, + }, [ - 230u8, 183u8, 221u8, 135u8, 226u8, 223u8, 55u8, 104u8, 138u8, 224u8, - 103u8, 156u8, 222u8, 99u8, 203u8, 199u8, 164u8, 168u8, 193u8, 133u8, - 201u8, 155u8, 63u8, 95u8, 17u8, 206u8, 165u8, 123u8, 161u8, 33u8, - 172u8, 93u8, + 219u8, 146u8, 168u8, 108u8, 180u8, 133u8, 182u8, 104u8, 153u8, 14u8, + 209u8, 207u8, 32u8, 226u8, 81u8, 196u8, 243u8, 208u8, 0u8, 94u8, 197u8, + 232u8, 181u8, 251u8, 182u8, 12u8, 245u8, 231u8, 198u8, 76u8, 59u8, + 53u8, ], ) } } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BeefyGenesis {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ValidatorSet {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SubmitReportEquivocationUnsignedExtrinsic { + pub equivocation_proof: runtime_types::sp_consensus_beefy::EquivocationProof< + ::core::primitive::u32, + runtime_types::sp_consensus_beefy::crypto::Public, + runtime_types::sp_consensus_beefy::crypto::Signature, + >, + pub key_owner_proof: runtime_types::sp_consensus_beefy::OpaqueKeyOwnershipProof, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct GenerateKeyOwnershipProof { + pub set_id: ::core::primitive::u64, + pub authority_id: runtime_types::sp_consensus_beefy::crypto::Public, + } + } } - pub mod constants { + pub mod mmr_api { + use super::root_mod; use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Block & extrinsics weights: base values and limits."] - pub fn block_weights( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "System", - "BlockWeights", - [ - 118u8, 253u8, 239u8, 217u8, 145u8, 115u8, 85u8, 86u8, 172u8, 248u8, - 139u8, 32u8, 158u8, 126u8, 172u8, 188u8, 197u8, 105u8, 145u8, 235u8, - 171u8, 50u8, 31u8, 225u8, 167u8, 187u8, 241u8, 87u8, 6u8, 17u8, 234u8, - 185u8, - ], - ) - } - #[doc = " The maximum length of a block (in bytes)."] - pub fn block_length( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "System", - "BlockLength", + #[doc = " API to interact with MMR pallet."] + pub struct MmrApi; + impl MmrApi { + #[doc = " Return the on-chain MMR root hash."] + pub fn mmr_root( + &self, + ) -> ::subxt::runtime_api::Payload< + types::MmrRoot, + ::core::result::Result< + ::subxt::utils::H256, + runtime_types::sp_mmr_primitives::Error, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "MmrApi_mmr_root", + types::MmrRoot {}, [ - 116u8, 184u8, 225u8, 228u8, 207u8, 203u8, 4u8, 220u8, 234u8, 198u8, - 150u8, 108u8, 205u8, 87u8, 194u8, 131u8, 229u8, 51u8, 140u8, 4u8, 47u8, - 12u8, 200u8, 144u8, 153u8, 62u8, 51u8, 39u8, 138u8, 205u8, 203u8, - 236u8, + 83u8, 202u8, 15u8, 77u8, 255u8, 136u8, 129u8, 210u8, 154u8, 178u8, + 197u8, 94u8, 231u8, 151u8, 68u8, 172u8, 112u8, 116u8, 30u8, 138u8, + 142u8, 166u8, 16u8, 4u8, 24u8, 204u8, 18u8, 48u8, 43u8, 103u8, 30u8, + 96u8, ], ) } - #[doc = " Maximum number of block number to block hash mappings to keep (oldest pruned first)."] - pub fn block_hash_count( + #[doc = " Return the number of MMR blocks in the chain."] + pub fn mmr_leaf_count( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "System", - "BlockHashCount", + ) -> ::subxt::runtime_api::Payload< + types::MmrLeafCount, + ::core::result::Result< + ::core::primitive::u64, + runtime_types::sp_mmr_primitives::Error, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "MmrApi_mmr_leaf_count", + types::MmrLeafCount {}, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 81u8, 145u8, 75u8, 170u8, 197u8, 235u8, 92u8, 81u8, 54u8, 16u8, 239u8, + 136u8, 174u8, 255u8, 90u8, 27u8, 24u8, 51u8, 152u8, 130u8, 249u8, + 247u8, 44u8, 173u8, 4u8, 21u8, 72u8, 44u8, 198u8, 145u8, 94u8, 77u8, ], ) } - #[doc = " The weight of runtime database operations the runtime can invoke."] - pub fn db_weight( + #[doc = " Generate MMR proof for a series of block numbers. If `best_known_block_number = Some(n)`,"] + #[doc = " use historical MMR state at given block height `n`. Else, use current MMR state."] + pub fn generate_proof( &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "System", - "DbWeight", + block_numbers: ::std::vec::Vec<::core::primitive::u32>, + best_known_block_number: ::core::option::Option<::core::primitive::u32>, + ) -> ::subxt::runtime_api::Payload< + types::GenerateProof, + ::core::result::Result< + ( + ::std::vec::Vec, + runtime_types::sp_mmr_primitives::Proof<::subxt::utils::H256>, + ), + runtime_types::sp_mmr_primitives::Error, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "MmrApi_generate_proof", + types::GenerateProof { + block_numbers, + best_known_block_number, + }, [ - 124u8, 162u8, 190u8, 149u8, 49u8, 177u8, 162u8, 231u8, 62u8, 167u8, - 199u8, 181u8, 43u8, 232u8, 185u8, 116u8, 195u8, 51u8, 233u8, 223u8, - 20u8, 129u8, 246u8, 13u8, 65u8, 180u8, 64u8, 9u8, 157u8, 59u8, 245u8, - 118u8, + 180u8, 123u8, 115u8, 227u8, 101u8, 119u8, 103u8, 230u8, 66u8, 255u8, + 15u8, 197u8, 60u8, 180u8, 27u8, 47u8, 73u8, 121u8, 179u8, 219u8, 161u8, + 37u8, 57u8, 131u8, 104u8, 106u8, 206u8, 230u8, 168u8, 185u8, 206u8, + 32u8, ], ) } - #[doc = " Get the chain's current version."] - pub fn version( + #[doc = " Verify MMR proof against on-chain MMR for a batch of leaves."] + #[doc = ""] + #[doc = " Note this function will use on-chain MMR root hash and check if the proof matches the hash."] + #[doc = " Note, the leaves should be sorted such that corresponding leaves and leaf indices have the"] + #[doc = " same position in both the `leaves` vector and the `leaf_indices` vector contained in the [Proof]"] + pub fn verify_proof( &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "System", - "Version", + leaves: ::std::vec::Vec, + proof: runtime_types::sp_mmr_primitives::Proof<::subxt::utils::H256>, + ) -> ::subxt::runtime_api::Payload< + types::VerifyProof, + ::core::result::Result<(), runtime_types::sp_mmr_primitives::Error>, + > { + ::subxt::runtime_api::Payload::new_static( + "MmrApi_verify_proof", + types::VerifyProof { leaves, proof }, [ - 93u8, 98u8, 57u8, 243u8, 229u8, 8u8, 234u8, 231u8, 72u8, 230u8, 139u8, - 47u8, 63u8, 181u8, 17u8, 2u8, 220u8, 231u8, 104u8, 237u8, 185u8, 143u8, - 165u8, 253u8, 188u8, 76u8, 147u8, 12u8, 170u8, 26u8, 74u8, 200u8, + 118u8, 13u8, 68u8, 159u8, 27u8, 144u8, 229u8, 72u8, 88u8, 106u8, 193u8, + 86u8, 228u8, 243u8, 28u8, 243u8, 99u8, 241u8, 153u8, 169u8, 121u8, + 139u8, 60u8, 244u8, 153u8, 110u8, 239u8, 149u8, 122u8, 164u8, 53u8, + 9u8, ], ) } - #[doc = " The designated SS58 prefix of this chain."] + #[doc = " Verify MMR proof against given root hash for a batch of leaves."] #[doc = ""] - #[doc = " This replaces the \"ss58Format\" property declared in the chain spec. Reason is"] - #[doc = " that the runtime should know about the prefix in order to make use of it as"] - #[doc = " an identifier of the chain."] - pub fn ss58_prefix(&self) -> ::subxt::constants::Address<::core::primitive::u16> { - ::subxt::constants::Address::new_static( - "System", - "SS58Prefix", + #[doc = " Note this function does not require any on-chain storage - the"] + #[doc = " proof is verified against given MMR root hash."] + #[doc = ""] + #[doc = " Note, the leaves should be sorted such that corresponding leaves and leaf indices have the"] + #[doc = " same position in both the `leaves` vector and the `leaf_indices` vector contained in the [Proof]"] + pub fn verify_proof_stateless( + &self, + root: ::subxt::utils::H256, + leaves: ::std::vec::Vec, + proof: runtime_types::sp_mmr_primitives::Proof<::subxt::utils::H256>, + ) -> ::subxt::runtime_api::Payload< + types::VerifyProofStateless, + ::core::result::Result<(), runtime_types::sp_mmr_primitives::Error>, + > { + ::subxt::runtime_api::Payload::new_static( + "MmrApi_verify_proof_stateless", + types::VerifyProofStateless { + root, + leaves, + proof, + }, [ - 116u8, 33u8, 2u8, 170u8, 181u8, 147u8, 171u8, 169u8, 167u8, 227u8, - 41u8, 144u8, 11u8, 236u8, 82u8, 100u8, 74u8, 60u8, 184u8, 72u8, 169u8, - 90u8, 208u8, 135u8, 15u8, 117u8, 10u8, 123u8, 128u8, 193u8, 29u8, 70u8, + 152u8, 237u8, 225u8, 199u8, 238u8, 151u8, 87u8, 236u8, 210u8, 38u8, + 168u8, 160u8, 166u8, 27u8, 186u8, 227u8, 160u8, 154u8, 120u8, 127u8, + 98u8, 247u8, 111u8, 99u8, 211u8, 236u8, 39u8, 221u8, 250u8, 110u8, + 232u8, 0u8, ], ) } } - } - } - pub mod scheduler { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_scheduler::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; pub mod types { use super::runtime_types; #[derive( @@ -2282,13 +2539,7 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Schedule { - pub when: ::core::primitive::u32, - pub maybe_periodic: - ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, - pub priority: ::core::primitive::u8, - pub call: ::std::boxed::Box, - } + pub struct MmrRoot {} #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -2299,10 +2550,7 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Cancel { - pub when: ::core::primitive::u32, - pub index: ::core::primitive::u32, - } + pub struct MmrLeafCount {} #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -2313,13 +2561,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduleNamed { - pub id: [::core::primitive::u8; 32usize], - pub when: ::core::primitive::u32, - pub maybe_periodic: - ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, - pub priority: ::core::primitive::u8, - pub call: ::std::boxed::Box, + pub struct GenerateProof { + pub block_numbers: ::std::vec::Vec<::core::primitive::u32>, + pub best_known_block_number: ::core::option::Option<::core::primitive::u32>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -2331,8 +2575,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelNamed { - pub id: [::core::primitive::u8; 32usize], + pub struct VerifyProof { + pub leaves: + ::std::vec::Vec, + pub proof: runtime_types::sp_mmr_primitives::Proof<::subxt::utils::H256>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -2344,13 +2590,140 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduleAfter { - pub after: ::core::primitive::u32, - pub maybe_periodic: - ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, - pub priority: ::core::primitive::u8, - pub call: ::std::boxed::Box, + pub struct VerifyProofStateless { + pub root: ::subxt::utils::H256, + pub leaves: + ::std::vec::Vec, + pub proof: runtime_types::sp_mmr_primitives::Proof<::subxt::utils::H256>, + } + } + } + pub mod grandpa_api { + use super::root_mod; + use super::runtime_types; + #[doc = " APIs for integrating the GRANDPA finality gadget into runtimes."] + #[doc = " This should be implemented on the runtime side."] + #[doc = ""] + #[doc = " This is primarily used for negotiating authority-set changes for the"] + #[doc = " gadget. GRANDPA uses a signaling model of changing authority sets:"] + #[doc = " changes should be signaled with a delay of N blocks, and then automatically"] + #[doc = " applied in the runtime after those N blocks have passed."] + #[doc = ""] + #[doc = " The consensus protocol will coordinate the handoff externally."] + pub struct GrandpaApi; + impl GrandpaApi { + #[doc = " Get the current GRANDPA authorities and weights. This should not change except"] + #[doc = " for when changes are scheduled and the corresponding delay has passed."] + #[doc = ""] + #[doc = " When called at block B, it will return the set of authorities that should be"] + #[doc = " used to finalize descendants of this block (B+1, B+2, ...). The block B itself"] + #[doc = " is finalized by the authorities from block B-1."] + pub fn grandpa_authorities( + &self, + ) -> ::subxt::runtime_api::Payload< + types::GrandpaAuthorities, + ::std::vec::Vec<( + runtime_types::sp_consensus_grandpa::app::Public, + ::core::primitive::u64, + )>, + > { + ::subxt::runtime_api::Payload::new_static( + "GrandpaApi_grandpa_authorities", + types::GrandpaAuthorities {}, + [ + 78u8, 213u8, 85u8, 178u8, 49u8, 70u8, 10u8, 221u8, 93u8, 91u8, 250u8, + 59u8, 80u8, 141u8, 62u8, 126u8, 55u8, 235u8, 163u8, 12u8, 21u8, 199u8, + 240u8, 209u8, 95u8, 63u8, 65u8, 73u8, 141u8, 42u8, 78u8, 154u8, + ], + ) + } + #[doc = " Submits an unsigned extrinsic to report an equivocation. The caller"] + #[doc = " must provide the equivocation proof and a key ownership proof"] + #[doc = " (should be obtained using `generate_key_ownership_proof`). The"] + #[doc = " extrinsic will be unsigned and should only be accepted for local"] + #[doc = " authorship (not to be broadcast to the network). This method returns"] + #[doc = " `None` when creation of the extrinsic fails, e.g. if equivocation"] + #[doc = " reporting is disabled for the given runtime (i.e. this method is"] + #[doc = " hardcoded to return `None`). Only useful in an offchain context."] + pub fn submit_report_equivocation_unsigned_extrinsic( + &self, + equivocation_proof: runtime_types::sp_consensus_grandpa::EquivocationProof< + ::subxt::utils::H256, + ::core::primitive::u32, + >, + key_owner_proof: runtime_types::sp_consensus_grandpa::OpaqueKeyOwnershipProof, + ) -> ::subxt::runtime_api::Payload< + types::SubmitReportEquivocationUnsignedExtrinsic, + ::core::option::Option<()>, + > { + ::subxt::runtime_api::Payload::new_static( + "GrandpaApi_submit_report_equivocation_unsigned_extrinsic", + types::SubmitReportEquivocationUnsignedExtrinsic { + equivocation_proof, + key_owner_proof, + }, + [ + 226u8, 83u8, 137u8, 173u8, 45u8, 138u8, 210u8, 202u8, 113u8, 196u8, + 110u8, 68u8, 31u8, 192u8, 127u8, 100u8, 125u8, 225u8, 30u8, 252u8, + 160u8, 109u8, 251u8, 96u8, 52u8, 214u8, 38u8, 91u8, 158u8, 71u8, 125u8, + 220u8, + ], + ) + } + #[doc = " Generates a proof of key ownership for the given authority in the"] + #[doc = " given set. An example usage of this module is coupled with the"] + #[doc = " session historical module to prove that a given authority key is"] + #[doc = " tied to a given staking identity during a specific session. Proofs"] + #[doc = " of key ownership are necessary for submitting equivocation reports."] + #[doc = " NOTE: even though the API takes a `set_id` as parameter the current"] + #[doc = " implementations ignore this parameter and instead rely on this"] + #[doc = " method being called at the correct block height, i.e. any point at"] + #[doc = " which the given set id is live on-chain. Future implementations will"] + #[doc = " instead use indexed data through an offchain worker, not requiring"] + #[doc = " older states to be available."] + pub fn generate_key_ownership_proof( + &self, + set_id: ::core::primitive::u64, + authority_id: runtime_types::sp_consensus_grandpa::app::Public, + ) -> ::subxt::runtime_api::Payload< + types::GenerateKeyOwnershipProof, + ::core::option::Option< + runtime_types::sp_consensus_grandpa::OpaqueKeyOwnershipProof, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "GrandpaApi_generate_key_ownership_proof", + types::GenerateKeyOwnershipProof { + set_id, + authority_id, + }, + [ + 149u8, 80u8, 146u8, 102u8, 63u8, 184u8, 111u8, 153u8, 143u8, 71u8, + 109u8, 162u8, 117u8, 45u8, 139u8, 245u8, 154u8, 252u8, 117u8, 224u8, + 10u8, 6u8, 143u8, 137u8, 58u8, 213u8, 215u8, 110u8, 180u8, 142u8, + 234u8, 182u8, + ], + ) + } + #[doc = " Get current GRANDPA authority set id."] + pub fn current_set_id( + &self, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "GrandpaApi_current_set_id", + types::CurrentSetId {}, + [ + 39u8, 245u8, 166u8, 229u8, 239u8, 200u8, 179u8, 64u8, 193u8, 93u8, + 41u8, 40u8, 208u8, 231u8, 75u8, 197u8, 45u8, 119u8, 131u8, 245u8, 84u8, + 249u8, 60u8, 7u8, 180u8, 176u8, 119u8, 130u8, 247u8, 134u8, 211u8, + 240u8, + ], + ) } + } + pub mod types { + use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -2361,491 +2734,197 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduleNamedAfter { - pub id: [::core::primitive::u8; 32usize], - pub after: ::core::primitive::u32, - pub maybe_periodic: - ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, - pub priority: ::core::primitive::u8, - pub call: ::std::boxed::Box, - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Anonymously schedule a task."] - pub fn schedule( - &self, - when: ::core::primitive::u32, - maybe_periodic: ::core::option::Option<( - ::core::primitive::u32, - ::core::primitive::u32, - )>, - priority: ::core::primitive::u8, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Scheduler", - "schedule", - types::Schedule { - when, - maybe_periodic, - priority, - call: ::std::boxed::Box::new(call), - }, - [ - 225u8, 142u8, 54u8, 240u8, 129u8, 69u8, 56u8, 230u8, 207u8, 110u8, - 78u8, 150u8, 87u8, 254u8, 95u8, 73u8, 74u8, 204u8, 165u8, 239u8, 246u8, - 132u8, 251u8, 183u8, 36u8, 102u8, 236u8, 244u8, 201u8, 2u8, 233u8, - 255u8, - ], - ) - } - #[doc = "Cancel an anonymously scheduled task."] - pub fn cancel( - &self, - when: ::core::primitive::u32, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Scheduler", - "cancel", - types::Cancel { when, index }, - [ - 81u8, 251u8, 234u8, 17u8, 214u8, 75u8, 19u8, 59u8, 19u8, 30u8, 89u8, - 74u8, 6u8, 216u8, 238u8, 165u8, 7u8, 19u8, 153u8, 253u8, 161u8, 103u8, - 178u8, 227u8, 152u8, 180u8, 80u8, 156u8, 82u8, 126u8, 132u8, 120u8, - ], - ) - } - #[doc = "Schedule a named task."] - pub fn schedule_named( - &self, - id: [::core::primitive::u8; 32usize], - when: ::core::primitive::u32, - maybe_periodic: ::core::option::Option<( - ::core::primitive::u32, - ::core::primitive::u32, - )>, - priority: ::core::primitive::u8, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Scheduler", - "schedule_named", - types::ScheduleNamed { - id, - when, - maybe_periodic, - priority, - call: ::std::boxed::Box::new(call), - }, - [ - 158u8, 202u8, 183u8, 44u8, 48u8, 102u8, 44u8, 53u8, 74u8, 193u8, 176u8, - 21u8, 240u8, 144u8, 135u8, 240u8, 87u8, 70u8, 132u8, 36u8, 229u8, - 233u8, 249u8, 55u8, 129u8, 81u8, 37u8, 193u8, 207u8, 252u8, 49u8, - 165u8, - ], - ) - } - #[doc = "Cancel a named scheduled task."] - pub fn cancel_named( - &self, - id: [::core::primitive::u8; 32usize], - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Scheduler", - "cancel_named", - types::CancelNamed { id }, - [ - 51u8, 3u8, 140u8, 50u8, 214u8, 211u8, 50u8, 4u8, 19u8, 43u8, 230u8, - 114u8, 18u8, 108u8, 138u8, 67u8, 99u8, 24u8, 255u8, 11u8, 246u8, 37u8, - 192u8, 207u8, 90u8, 157u8, 171u8, 93u8, 233u8, 189u8, 64u8, 180u8, - ], - ) - } - #[doc = "Anonymously schedule a task after a delay."] - pub fn schedule_after( - &self, - after: ::core::primitive::u32, - maybe_periodic: ::core::option::Option<( - ::core::primitive::u32, + pub struct GrandpaAuthorities {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SubmitReportEquivocationUnsignedExtrinsic { + pub equivocation_proof: runtime_types::sp_consensus_grandpa::EquivocationProof< + ::subxt::utils::H256, ::core::primitive::u32, - )>, - priority: ::core::primitive::u8, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Scheduler", - "schedule_after", - types::ScheduleAfter { - after, - maybe_periodic, - priority, - call: ::std::boxed::Box::new(call), - }, - [ - 73u8, 79u8, 70u8, 138u8, 189u8, 239u8, 243u8, 180u8, 250u8, 183u8, - 246u8, 40u8, 204u8, 164u8, 154u8, 219u8, 87u8, 144u8, 44u8, 185u8, - 181u8, 130u8, 147u8, 11u8, 156u8, 54u8, 201u8, 207u8, 238u8, 76u8, - 61u8, 179u8, - ], - ) + >, + pub key_owner_proof: + runtime_types::sp_consensus_grandpa::OpaqueKeyOwnershipProof, } - #[doc = "Schedule a named task after a delay."] - pub fn schedule_named_after( - &self, - id: [::core::primitive::u8; 32usize], - after: ::core::primitive::u32, - maybe_periodic: ::core::option::Option<( - ::core::primitive::u32, - ::core::primitive::u32, - )>, - priority: ::core::primitive::u8, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Scheduler", - "schedule_named_after", - types::ScheduleNamedAfter { - id, - after, - maybe_periodic, - priority, - call: ::std::boxed::Box::new(call), - }, - [ - 158u8, 154u8, 219u8, 160u8, 184u8, 209u8, 41u8, 234u8, 126u8, 157u8, - 63u8, 92u8, 143u8, 2u8, 82u8, 145u8, 45u8, 145u8, 148u8, 27u8, 48u8, - 255u8, 95u8, 70u8, 182u8, 146u8, 199u8, 252u8, 87u8, 105u8, 12u8, - 187u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct GenerateKeyOwnershipProof { + pub set_id: ::core::primitive::u64, + pub authority_id: runtime_types::sp_consensus_grandpa::app::Public, } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CurrentSetId {} } } - #[doc = "Events type."] - pub type Event = runtime_types::pallet_scheduler::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Scheduled some task."] - pub struct Scheduled { - pub when: ::core::primitive::u32, - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Scheduled { - const PALLET: &'static str = "Scheduler"; - const EVENT: &'static str = "Scheduled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Canceled some task."] - pub struct Canceled { - pub when: ::core::primitive::u32, - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Canceled { - const PALLET: &'static str = "Scheduler"; - const EVENT: &'static str = "Canceled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Dispatched some task."] - pub struct Dispatched { - pub task: (::core::primitive::u32, ::core::primitive::u32), - pub id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for Dispatched { - const PALLET: &'static str = "Scheduler"; - const EVENT: &'static str = "Dispatched"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The call for the provided hash was not found so the task has been aborted."] - pub struct CallUnavailable { - pub task: (::core::primitive::u32, ::core::primitive::u32), - pub id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - } - impl ::subxt::events::StaticEvent for CallUnavailable { - const PALLET: &'static str = "Scheduler"; - const EVENT: &'static str = "CallUnavailable"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The given task was unable to be renewed since the agenda is full at that block."] - pub struct PeriodicFailed { - pub task: (::core::primitive::u32, ::core::primitive::u32), - pub id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - } - impl ::subxt::events::StaticEvent for PeriodicFailed { - const PALLET: &'static str = "Scheduler"; - const EVENT: &'static str = "PeriodicFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The given task can never be executed since it is overweight."] - pub struct PermanentlyOverweight { - pub task: (::core::primitive::u32, ::core::primitive::u32), - pub id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - } - impl ::subxt::events::StaticEvent for PermanentlyOverweight { - const PALLET: &'static str = "Scheduler"; - const EVENT: &'static str = "PermanentlyOverweight"; - } - } - pub mod storage { + pub mod babe_api { + use super::root_mod; use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - pub fn incomplete_since( + #[doc = " API necessary for block authorship with BABE."] + pub struct BabeApi; + impl BabeApi { + #[doc = " Return the configuration for BABE."] + pub fn configuration( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), + ) -> ::subxt::runtime_api::Payload< + types::Configuration, + runtime_types::sp_consensus_babe::BabeConfiguration, > { - ::subxt::storage::address::Address::new_static( - "Scheduler", - "IncompleteSince", - vec![], + ::subxt::runtime_api::Payload::new_static( + "BabeApi_configuration", + types::Configuration {}, [ - 149u8, 66u8, 239u8, 67u8, 235u8, 219u8, 101u8, 182u8, 145u8, 56u8, - 252u8, 150u8, 253u8, 221u8, 125u8, 57u8, 38u8, 152u8, 153u8, 31u8, - 92u8, 238u8, 66u8, 246u8, 104u8, 163u8, 94u8, 73u8, 222u8, 168u8, - 193u8, 227u8, + 101u8, 27u8, 68u8, 108u8, 36u8, 12u8, 205u8, 58u8, 238u8, 195u8, 171u8, + 167u8, 248u8, 76u8, 92u8, 226u8, 241u8, 192u8, 151u8, 31u8, 6u8, 200u8, + 69u8, 180u8, 107u8, 134u8, 221u8, 99u8, 237u8, 223u8, 50u8, 175u8, ], ) } - #[doc = " Items to be executed, indexed by the block number that they should be executed on."] - pub fn agenda( + #[doc = " Returns the slot that started the current epoch."] + pub fn current_epoch_start( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::option::Option< - runtime_types::pallet_scheduler::Scheduled< - [::core::primitive::u8; 32usize], - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - ::core::primitive::u32, - runtime_types::polkadot_runtime::OriginCaller, - ::subxt::utils::AccountId32, - >, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + ) -> ::subxt::runtime_api::Payload< + types::CurrentEpochStart, + runtime_types::sp_consensus_slots::Slot, > { - ::subxt::storage::address::Address::new_static( - "Scheduler", - "Agenda", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + ::subxt::runtime_api::Payload::new_static( + "BabeApi_current_epoch_start", + types::CurrentEpochStart {}, [ - 130u8, 206u8, 243u8, 81u8, 169u8, 223u8, 74u8, 102u8, 75u8, 207u8, - 232u8, 175u8, 233u8, 167u8, 109u8, 190u8, 242u8, 24u8, 203u8, 144u8, - 31u8, 68u8, 147u8, 110u8, 77u8, 175u8, 2u8, 129u8, 127u8, 198u8, 49u8, - 151u8, + 67u8, 178u8, 67u8, 242u8, 228u8, 74u8, 93u8, 166u8, 160u8, 9u8, 109u8, + 174u8, 12u8, 82u8, 239u8, 200u8, 96u8, 54u8, 235u8, 184u8, 159u8, + 221u8, 72u8, 244u8, 83u8, 24u8, 239u8, 24u8, 152u8, 177u8, 211u8, + 205u8, ], ) } - #[doc = " Items to be executed, indexed by the block number that they should be executed on."] - pub fn agenda_root( + #[doc = " Returns information regarding the current epoch."] + pub fn current_epoch( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::option::Option< - runtime_types::pallet_scheduler::Scheduled< - [::core::primitive::u8; 32usize], - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - ::core::primitive::u32, - runtime_types::polkadot_runtime::OriginCaller, - ::subxt::utils::AccountId32, - >, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + ) -> ::subxt::runtime_api::Payload< + types::CurrentEpoch, + runtime_types::sp_consensus_babe::Epoch, > { - ::subxt::storage::address::Address::new_static( - "Scheduler", - "Agenda", - Vec::new(), + ::subxt::runtime_api::Payload::new_static( + "BabeApi_current_epoch", + types::CurrentEpoch {}, [ - 130u8, 206u8, 243u8, 81u8, 169u8, 223u8, 74u8, 102u8, 75u8, 207u8, - 232u8, 175u8, 233u8, 167u8, 109u8, 190u8, 242u8, 24u8, 203u8, 144u8, - 31u8, 68u8, 147u8, 110u8, 77u8, 175u8, 2u8, 129u8, 127u8, 198u8, 49u8, - 151u8, + 166u8, 104u8, 201u8, 148u8, 149u8, 137u8, 223u8, 165u8, 82u8, 4u8, + 130u8, 58u8, 52u8, 193u8, 201u8, 80u8, 120u8, 212u8, 76u8, 221u8, 11u8, + 131u8, 115u8, 8u8, 9u8, 59u8, 191u8, 165u8, 148u8, 24u8, 194u8, 162u8, ], ) } - #[doc = " Lookup from a name to the block number and index of the task."] - #[doc = ""] - #[doc = " For v3 -> v4 the previously unbounded identities are Blake2-256 hashed to form the v4"] - #[doc = " identities."] - pub fn lookup( + #[doc = " Returns information regarding the next epoch (which was already"] + #[doc = " previously announced)."] + pub fn next_epoch( &self, - _0: impl ::std::borrow::Borrow<[::core::primitive::u8; 32usize]>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, + ) -> ::subxt::runtime_api::Payload< + types::NextEpoch, + runtime_types::sp_consensus_babe::Epoch, > { - ::subxt::storage::address::Address::new_static( - "Scheduler", - "Lookup", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + ::subxt::runtime_api::Payload::new_static( + "BabeApi_next_epoch", + types::NextEpoch {}, [ - 82u8, 20u8, 178u8, 101u8, 108u8, 198u8, 71u8, 99u8, 16u8, 175u8, 15u8, - 187u8, 229u8, 243u8, 140u8, 200u8, 99u8, 77u8, 248u8, 178u8, 45u8, - 121u8, 193u8, 67u8, 165u8, 43u8, 234u8, 211u8, 158u8, 250u8, 103u8, - 243u8, + 251u8, 29u8, 230u8, 254u8, 174u8, 38u8, 55u8, 30u8, 93u8, 42u8, 254u8, + 172u8, 183u8, 250u8, 104u8, 211u8, 79u8, 211u8, 55u8, 98u8, 253u8, + 73u8, 137u8, 185u8, 116u8, 94u8, 20u8, 232u8, 224u8, 136u8, 86u8, + 182u8, ], ) } - #[doc = " Lookup from a name to the block number and index of the task."] - #[doc = ""] - #[doc = " For v3 -> v4 the previously unbounded identities are Blake2-256 hashed to form the v4"] - #[doc = " identities."] - pub fn lookup_root( + #[doc = " Generates a proof of key ownership for the given authority in the"] + #[doc = " current epoch. An example usage of this module is coupled with the"] + #[doc = " session historical module to prove that a given authority key is"] + #[doc = " tied to a given staking identity during a specific session. Proofs"] + #[doc = " of key ownership are necessary for submitting equivocation reports."] + #[doc = " NOTE: even though the API takes a `slot` as parameter the current"] + #[doc = " implementations ignores this parameter and instead relies on this"] + #[doc = " method being called at the correct block height, i.e. any point at"] + #[doc = " which the epoch for the given slot is live on-chain. Future"] + #[doc = " implementations will instead use indexed data through an offchain"] + #[doc = " worker, not requiring older states to be available."] + pub fn generate_key_ownership_proof( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), - (), - (), - ::subxt::storage::address::Yes, + slot: runtime_types::sp_consensus_slots::Slot, + authority_id: runtime_types::sp_consensus_babe::app::Public, + ) -> ::subxt::runtime_api::Payload< + types::GenerateKeyOwnershipProof, + ::core::option::Option< + runtime_types::sp_consensus_babe::OpaqueKeyOwnershipProof, + >, > { - ::subxt::storage::address::Address::new_static( - "Scheduler", - "Lookup", - Vec::new(), - [ - 82u8, 20u8, 178u8, 101u8, 108u8, 198u8, 71u8, 99u8, 16u8, 175u8, 15u8, - 187u8, 229u8, 243u8, 140u8, 200u8, 99u8, 77u8, 248u8, 178u8, 45u8, - 121u8, 193u8, 67u8, 165u8, 43u8, 234u8, 211u8, 158u8, 250u8, 103u8, - 243u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The maximum weight that may be scheduled per block for any dispatchables."] - pub fn maximum_weight( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "Scheduler", - "MaximumWeight", + ::subxt::runtime_api::Payload::new_static( + "BabeApi_generate_key_ownership_proof", + types::GenerateKeyOwnershipProof { slot, authority_id }, [ - 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, - 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, - 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, - 106u8, 76u8, + 16u8, 78u8, 1u8, 172u8, 172u8, 253u8, 240u8, 175u8, 90u8, 130u8, 90u8, + 69u8, 249u8, 12u8, 192u8, 134u8, 131u8, 248u8, 186u8, 166u8, 240u8, + 182u8, 177u8, 0u8, 107u8, 151u8, 200u8, 41u8, 157u8, 150u8, 162u8, + 244u8, ], ) } - #[doc = " The maximum number of scheduled calls in the queue for a single block."] - #[doc = ""] - #[doc = " NOTE:"] - #[doc = " + Dependent pallets' benchmarks might require a higher limit for the setting. Set a"] - #[doc = " higher limit under `runtime-benchmarks` feature."] - pub fn max_scheduled_per_block( + #[doc = " Submits an unsigned extrinsic to report an equivocation. The caller"] + #[doc = " must provide the equivocation proof and a key ownership proof"] + #[doc = " (should be obtained using `generate_key_ownership_proof`). The"] + #[doc = " extrinsic will be unsigned and should only be accepted for local"] + #[doc = " authorship (not to be broadcast to the network). This method returns"] + #[doc = " `None` when creation of the extrinsic fails, e.g. if equivocation"] + #[doc = " reporting is disabled for the given runtime (i.e. this method is"] + #[doc = " hardcoded to return `None`). Only useful in an offchain context."] + pub fn submit_report_equivocation_unsigned_extrinsic( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Scheduler", - "MaxScheduledPerBlock", + equivocation_proof: runtime_types::sp_consensus_slots::EquivocationProof< + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + runtime_types::sp_consensus_babe::app::Public, + >, + key_owner_proof: runtime_types::sp_consensus_babe::OpaqueKeyOwnershipProof, + ) -> ::subxt::runtime_api::Payload< + types::SubmitReportEquivocationUnsignedExtrinsic, + ::core::option::Option<()>, + > { + ::subxt::runtime_api::Payload::new_static( + "BabeApi_submit_report_equivocation_unsigned_extrinsic", + types::SubmitReportEquivocationUnsignedExtrinsic { + equivocation_proof, + key_owner_proof, + }, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 255u8, 136u8, 248u8, 244u8, 155u8, 51u8, 20u8, 157u8, 93u8, 19u8, 24u8, + 170u8, 72u8, 199u8, 222u8, 111u8, 164u8, 126u8, 159u8, 209u8, 198u8, + 37u8, 113u8, 12u8, 36u8, 117u8, 131u8, 7u8, 130u8, 85u8, 177u8, 109u8, ], ) } } - } - } - pub mod preimage { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_preimage::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; pub mod types { use super::runtime_types; #[derive( @@ -2858,9 +2937,7 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NotePreimage { - pub bytes: ::std::vec::Vec<::core::primitive::u8>, - } + pub struct Configuration {} #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -2871,9 +2948,7 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnnotePreimage { - pub hash: ::subxt::utils::H256, - } + pub struct CurrentEpochStart {} #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -2884,9 +2959,7 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RequestPreimage { - pub hash: ::subxt::utils::H256, - } + pub struct CurrentEpoch {} #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -2897,267 +2970,292 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnrequestPreimage { - pub hash: ::subxt::utils::H256, + pub struct NextEpoch {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct GenerateKeyOwnershipProof { + pub slot: runtime_types::sp_consensus_slots::Slot, + pub authority_id: runtime_types::sp_consensus_babe::app::Public, } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Register a preimage on-chain."] - #[doc = ""] - #[doc = "If the preimage was previously requested, no fees or deposits are taken for providing"] - #[doc = "the preimage. Otherwise, a deposit is taken proportional to the size of the preimage."] - pub fn note_preimage( + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SubmitReportEquivocationUnsignedExtrinsic { + pub equivocation_proof: runtime_types::sp_consensus_slots::EquivocationProof< + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + runtime_types::sp_consensus_babe::app::Public, + >, + pub key_owner_proof: runtime_types::sp_consensus_babe::OpaqueKeyOwnershipProof, + } + } + } + pub mod authority_discovery_api { + use super::root_mod; + use super::runtime_types; + #[doc = " The authority discovery api."] + #[doc = ""] + #[doc = " This api is used by the `client/authority-discovery` module to retrieve identifiers"] + #[doc = " of the current and next authority set."] + pub struct AuthorityDiscoveryApi; + impl AuthorityDiscoveryApi { + #[doc = " Retrieve authority identifiers of the current and next authority set."] + pub fn authorities( &self, - bytes: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Preimage", - "note_preimage", - types::NotePreimage { bytes }, + ) -> ::subxt::runtime_api::Payload< + types::Authorities, + ::std::vec::Vec, + > { + ::subxt::runtime_api::Payload::new_static( + "AuthorityDiscoveryApi_authorities", + types::Authorities {}, [ - 77u8, 48u8, 104u8, 3u8, 254u8, 65u8, 106u8, 95u8, 204u8, 89u8, 149u8, - 29u8, 144u8, 188u8, 99u8, 23u8, 146u8, 142u8, 35u8, 17u8, 125u8, 130u8, - 31u8, 206u8, 106u8, 83u8, 163u8, 192u8, 81u8, 23u8, 232u8, 230u8, + 104u8, 50u8, 187u8, 116u8, 97u8, 112u8, 203u8, 212u8, 27u8, 108u8, + 253u8, 8u8, 103u8, 104u8, 63u8, 176u8, 178u8, 179u8, 154u8, 104u8, + 167u8, 241u8, 76u8, 136u8, 102u8, 130u8, 88u8, 115u8, 104u8, 64u8, + 224u8, 98u8, ], ) } - #[doc = "Clear an unrequested preimage from the runtime storage."] + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Authorities {} + } + } + pub mod session_keys { + use super::root_mod; + use super::runtime_types; + #[doc = " Session keys runtime api."] + pub struct SessionKeys; + impl SessionKeys { + #[doc = " Generate a set of session keys with optionally using the given seed."] + #[doc = " The keys should be stored within the keystore exposed via runtime"] + #[doc = " externalities."] #[doc = ""] - #[doc = "If `len` is provided, then it will be a much cheaper operation."] + #[doc = " The seed needs to be a valid `utf8` string."] #[doc = ""] - #[doc = "- `hash`: The hash of the preimage to be removed from the store."] - #[doc = "- `len`: The length of the preimage of `hash`."] - pub fn unnote_preimage( + #[doc = " Returns the concatenated SCALE encoded public keys."] + pub fn generate_session_keys( &self, - hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Preimage", - "unnote_preimage", - types::UnnotePreimage { hash }, + seed: ::core::option::Option<::std::vec::Vec<::core::primitive::u8>>, + ) -> ::subxt::runtime_api::Payload< + types::GenerateSessionKeys, + ::std::vec::Vec<::core::primitive::u8>, + > { + ::subxt::runtime_api::Payload::new_static( + "SessionKeys_generate_session_keys", + types::GenerateSessionKeys { seed }, [ - 211u8, 204u8, 205u8, 58u8, 33u8, 179u8, 68u8, 74u8, 149u8, 138u8, - 213u8, 45u8, 140u8, 27u8, 106u8, 81u8, 68u8, 212u8, 147u8, 116u8, 27u8, - 130u8, 84u8, 34u8, 231u8, 197u8, 135u8, 8u8, 19u8, 242u8, 207u8, 17u8, + 238u8, 35u8, 56u8, 56u8, 5u8, 183u8, 237u8, 233u8, 220u8, 77u8, 245u8, + 218u8, 120u8, 21u8, 3u8, 95u8, 106u8, 140u8, 212u8, 37u8, 14u8, 180u8, + 24u8, 11u8, 137u8, 193u8, 111u8, 91u8, 235u8, 127u8, 202u8, 230u8, ], ) } - #[doc = "Request a preimage be uploaded to the chain without paying any fees or deposits."] + #[doc = " Decode the given public session keys."] #[doc = ""] - #[doc = "If the preimage requests has already been provided on-chain, we unreserve any deposit"] - #[doc = "a user may have paid, and take the control of the preimage out of their hands."] - pub fn request_preimage( + #[doc = " Returns the list of public raw public keys + key type."] + pub fn decode_session_keys( &self, - hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Preimage", - "request_preimage", - types::RequestPreimage { hash }, + encoded: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::runtime_api::Payload< + types::DecodeSessionKeys, + ::core::option::Option< + ::std::vec::Vec<( + ::std::vec::Vec<::core::primitive::u8>, + runtime_types::sp_core::crypto::KeyTypeId, + )>, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "SessionKeys_decode_session_keys", + types::DecodeSessionKeys { encoded }, [ - 195u8, 26u8, 146u8, 255u8, 79u8, 43u8, 73u8, 60u8, 115u8, 78u8, 99u8, - 197u8, 137u8, 95u8, 139u8, 141u8, 79u8, 213u8, 170u8, 169u8, 127u8, - 30u8, 236u8, 65u8, 38u8, 16u8, 118u8, 228u8, 141u8, 83u8, 162u8, 233u8, + 134u8, 106u8, 224u8, 190u8, 133u8, 212u8, 253u8, 184u8, 222u8, 76u8, + 44u8, 75u8, 168u8, 18u8, 3u8, 169u8, 32u8, 8u8, 46u8, 5u8, 155u8, 45u8, + 149u8, 144u8, 41u8, 174u8, 130u8, 133u8, 22u8, 150u8, 89u8, 196u8, ], ) } - #[doc = "Clear a previously made request for a preimage."] - #[doc = ""] - #[doc = "NOTE: THIS MUST NOT BE CALLED ON `hash` MORE TIMES THAN `request_preimage`."] - pub fn unrequest_preimage( - &self, - hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Preimage", - "unrequest_preimage", - types::UnrequestPreimage { hash }, - [ - 143u8, 225u8, 239u8, 44u8, 237u8, 83u8, 18u8, 105u8, 101u8, 68u8, - 111u8, 116u8, 66u8, 212u8, 63u8, 190u8, 38u8, 32u8, 105u8, 152u8, 69u8, - 177u8, 193u8, 15u8, 60u8, 26u8, 95u8, 130u8, 11u8, 113u8, 187u8, 108u8, - ], - ) + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct GenerateSessionKeys { + pub seed: ::core::option::Option<::std::vec::Vec<::core::primitive::u8>>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DecodeSessionKeys { + pub encoded: ::std::vec::Vec<::core::primitive::u8>, } } } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_preimage::pallet::Event; - pub mod events { + pub mod account_nonce_api { + use super::root_mod; use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A preimage has been noted."] - pub struct Noted { - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Noted { - const PALLET: &'static str = "Preimage"; - const EVENT: &'static str = "Noted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A preimage has been requested."] - pub struct Requested { - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Requested { - const PALLET: &'static str = "Preimage"; - const EVENT: &'static str = "Requested"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A preimage has ben cleared."] - pub struct Cleared { - pub hash: ::subxt::utils::H256, + #[doc = " The API to query account nonce (aka transaction index)."] + pub struct AccountNonceApi; + impl AccountNonceApi { + #[doc = " Get current account nonce of given `AccountId`."] + pub fn account_nonce( + &self, + account: ::subxt::utils::AccountId32, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "AccountNonceApi_account_nonce", + types::AccountNonce { account }, + [ + 115u8, 50u8, 18u8, 201u8, 220u8, 171u8, 244u8, 16u8, 58u8, 183u8, + 173u8, 196u8, 253u8, 239u8, 241u8, 100u8, 246u8, 179u8, 50u8, 32u8, + 22u8, 245u8, 109u8, 191u8, 232u8, 76u8, 152u8, 87u8, 156u8, 187u8, + 175u8, 202u8, + ], + ) + } } - impl ::subxt::events::StaticEvent for Cleared { - const PALLET: &'static str = "Preimage"; - const EVENT: &'static str = "Cleared"; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AccountNonce { + pub account: ::subxt::utils::AccountId32, + } } } - pub mod storage { + pub mod transaction_payment_api { + use super::root_mod; use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The request status of a given hash."] - pub fn status_for( + pub struct TransactionPaymentApi; + impl TransactionPaymentApi { + pub fn query_info( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_preimage::RequestStatus< - ::subxt::utils::AccountId32, + uxt : runtime_types :: sp_runtime :: generic :: unchecked_extrinsic :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: polkadot_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment , runtime_types :: polkadot_runtime_common :: claims :: PrevalidateAttests ,) >, + len: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload< + types::QueryInfo, + runtime_types::pallet_transaction_payment::types::RuntimeDispatchInfo< ::core::primitive::u128, + runtime_types::sp_weights::weight_v2::Weight, >, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, > { - ::subxt::storage::address::Address::new_static( - "Preimage", - "StatusFor", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentApi_query_info", + types::QueryInfo { uxt, len }, [ - 103u8, 208u8, 88u8, 167u8, 244u8, 198u8, 129u8, 134u8, 182u8, 80u8, - 71u8, 192u8, 73u8, 92u8, 190u8, 15u8, 20u8, 132u8, 37u8, 108u8, 88u8, - 233u8, 18u8, 145u8, 9u8, 235u8, 5u8, 132u8, 42u8, 17u8, 227u8, 56u8, + 157u8, 139u8, 132u8, 17u8, 44u8, 153u8, 215u8, 139u8, 196u8, 107u8, + 225u8, 39u8, 78u8, 134u8, 147u8, 168u8, 134u8, 89u8, 51u8, 144u8, + 101u8, 117u8, 35u8, 131u8, 108u8, 17u8, 74u8, 1u8, 167u8, 7u8, 165u8, + 98u8, ], ) } - #[doc = " The request status of a given hash."] - pub fn status_for_root( + pub fn query_fee_details( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_preimage::RequestStatus< - ::subxt::utils::AccountId32, + uxt : runtime_types :: sp_runtime :: generic :: unchecked_extrinsic :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: polkadot_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment , runtime_types :: polkadot_runtime_common :: claims :: PrevalidateAttests ,) >, + len: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload< + types::QueryFeeDetails, + runtime_types::pallet_transaction_payment::types::FeeDetails< ::core::primitive::u128, >, - (), - (), - ::subxt::storage::address::Yes, > { - ::subxt::storage::address::Address::new_static( - "Preimage", - "StatusFor", - Vec::new(), + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentApi_query_fee_details", + types::QueryFeeDetails { uxt, len }, [ - 103u8, 208u8, 88u8, 167u8, 244u8, 198u8, 129u8, 134u8, 182u8, 80u8, - 71u8, 192u8, 73u8, 92u8, 190u8, 15u8, 20u8, 132u8, 37u8, 108u8, 88u8, - 233u8, 18u8, 145u8, 9u8, 235u8, 5u8, 132u8, 42u8, 17u8, 227u8, 56u8, + 113u8, 100u8, 16u8, 128u8, 108u8, 95u8, 91u8, 255u8, 46u8, 255u8, 52u8, + 225u8, 92u8, 186u8, 175u8, 126u8, 96u8, 25u8, 206u8, 207u8, 16u8, 94u8, + 204u8, 138u8, 227u8, 38u8, 125u8, 14u8, 38u8, 58u8, 84u8, 71u8, ], ) } - pub fn preimage_for( + pub fn query_weight_to_fee( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - _1: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Preimage", - "PreimageFor", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentApi_query_weight_to_fee", + types::QueryWeightToFee { weight }, [ - 96u8, 74u8, 30u8, 112u8, 120u8, 41u8, 52u8, 187u8, 252u8, 68u8, 42u8, - 5u8, 61u8, 228u8, 250u8, 192u8, 224u8, 61u8, 53u8, 222u8, 95u8, 148u8, - 6u8, 53u8, 43u8, 152u8, 88u8, 58u8, 185u8, 234u8, 131u8, 124u8, + 179u8, 108u8, 155u8, 39u8, 134u8, 220u8, 72u8, 45u8, 230u8, 232u8, + 150u8, 146u8, 61u8, 198u8, 145u8, 250u8, 19u8, 157u8, 204u8, 217u8, + 111u8, 171u8, 197u8, 21u8, 75u8, 6u8, 16u8, 26u8, 244u8, 101u8, 134u8, + 95u8, ], ) } - pub fn preimage_for_root( + pub fn query_length_to_fee( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Preimage", - "PreimageFor", - Vec::new(), + length: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentApi_query_length_to_fee", + types::QueryLengthToFee { length }, [ - 96u8, 74u8, 30u8, 112u8, 120u8, 41u8, 52u8, 187u8, 252u8, 68u8, 42u8, - 5u8, 61u8, 228u8, 250u8, 192u8, 224u8, 61u8, 53u8, 222u8, 95u8, 148u8, - 6u8, 53u8, 43u8, 152u8, 88u8, 58u8, 185u8, 234u8, 131u8, 124u8, + 228u8, 141u8, 164u8, 186u8, 169u8, 249u8, 75u8, 2u8, 160u8, 73u8, 73u8, + 214u8, 141u8, 76u8, 180u8, 222u8, 230u8, 161u8, 131u8, 88u8, 25u8, + 192u8, 77u8, 124u8, 158u8, 113u8, 72u8, 147u8, 13u8, 11u8, 42u8, 30u8, ], ) } } - } - } - pub mod babe { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_babe::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; pub mod types { use super::runtime_types; #[derive( @@ -3170,18 +3268,7 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportEquivocation { - pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - runtime_types::sp_consensus_babe::app::Public, - >, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, - } + pub struct QueryInfo { pub uxt : runtime_types :: sp_runtime :: generic :: unchecked_extrinsic :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: polkadot_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment , runtime_types :: polkadot_runtime_common :: claims :: PrevalidateAttests ,) > , pub len : :: core :: primitive :: u32 , } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -3192,18 +3279,7 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportEquivocationUnsigned { - pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - runtime_types::sp_consensus_babe::app::Public, - >, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, - } + pub struct QueryFeeDetails { pub uxt : runtime_types :: sp_runtime :: generic :: unchecked_extrinsic :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: polkadot_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment , runtime_types :: polkadot_runtime_common :: claims :: PrevalidateAttests ,) > , pub len : :: core :: primitive :: u32 , } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -3214,611 +3290,108 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PlanConfigChange { - pub config: runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Report authority equivocation/misbehavior. This method will verify"] - #[doc = "the equivocation proof and validate the given key ownership proof"] - #[doc = "against the extracted offender. If both are valid, the offence will"] - #[doc = "be reported."] - pub fn report_equivocation( - &self, - equivocation_proof: runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - runtime_types::sp_consensus_babe::app::Public, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Babe", - "report_equivocation", - types::ReportEquivocation { - equivocation_proof: ::std::boxed::Box::new(equivocation_proof), - key_owner_proof, - }, - [ - 177u8, 237u8, 107u8, 138u8, 237u8, 233u8, 30u8, 195u8, 112u8, 176u8, - 185u8, 113u8, 157u8, 221u8, 134u8, 151u8, 62u8, 151u8, 64u8, 164u8, - 254u8, 112u8, 2u8, 94u8, 175u8, 79u8, 160u8, 3u8, 72u8, 145u8, 244u8, - 137u8, - ], - ) - } - #[doc = "Report authority equivocation/misbehavior. This method will verify"] - #[doc = "the equivocation proof and validate the given key ownership proof"] - #[doc = "against the extracted offender. If both are valid, the offence will"] - #[doc = "be reported."] - #[doc = "This extrinsic must be called unsigned and it is expected that only"] - #[doc = "block authors will call it (validated in `ValidateUnsigned`), as such"] - #[doc = "if the block author is defined it will be defined as the equivocation"] - #[doc = "reporter."] - pub fn report_equivocation_unsigned( - &self, - equivocation_proof: runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - runtime_types::sp_consensus_babe::app::Public, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Babe", - "report_equivocation_unsigned", - types::ReportEquivocationUnsigned { - equivocation_proof: ::std::boxed::Box::new(equivocation_proof), - key_owner_proof, - }, - [ - 56u8, 103u8, 238u8, 118u8, 61u8, 192u8, 222u8, 87u8, 254u8, 24u8, - 138u8, 219u8, 210u8, 85u8, 201u8, 147u8, 128u8, 49u8, 199u8, 144u8, - 46u8, 158u8, 163u8, 31u8, 101u8, 224u8, 72u8, 98u8, 68u8, 120u8, 215u8, - 19u8, - ], - ) + pub struct QueryWeightToFee { + pub weight: runtime_types::sp_weights::weight_v2::Weight, } - #[doc = "Plan an epoch config change. The epoch config change is recorded and will be enacted on"] - #[doc = "the next call to `enact_epoch_change`. The config will be activated one epoch after."] - #[doc = "Multiple calls to this method will replace any existing planned config change that had"] - #[doc = "not been enacted yet."] - pub fn plan_config_change( - &self, - config: runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Babe", - "plan_config_change", - types::PlanConfigChange { config }, - [ - 229u8, 157u8, 41u8, 58u8, 56u8, 4u8, 52u8, 107u8, 104u8, 20u8, 42u8, - 110u8, 1u8, 17u8, 45u8, 196u8, 30u8, 135u8, 63u8, 46u8, 40u8, 137u8, - 209u8, 37u8, 24u8, 108u8, 251u8, 189u8, 77u8, 208u8, 74u8, 32u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryLengthToFee { + pub length: ::core::primitive::u32, } } } - pub mod storage { + pub mod transaction_payment_call_api { + use super::root_mod; use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Current epoch index."] - pub fn epoch_index( + pub struct TransactionPaymentCallApi; + impl TransactionPaymentCallApi { + #[doc = " Query information of a dispatch class, weight, and fee of a given encoded `Call`."] + pub fn query_call_info( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), + call: runtime_types::polkadot_runtime::RuntimeCall, + len: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload< + types::QueryCallInfo, + runtime_types::pallet_transaction_payment::types::RuntimeDispatchInfo< + ::core::primitive::u128, + runtime_types::sp_weights::weight_v2::Weight, + >, > { - ::subxt::storage::address::Address::new_static( - "Babe", - "EpochIndex", - vec![], + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentCallApi_query_call_info", + types::QueryCallInfo { call, len }, [ - 51u8, 27u8, 91u8, 156u8, 118u8, 99u8, 46u8, 219u8, 190u8, 147u8, 205u8, - 23u8, 106u8, 169u8, 121u8, 218u8, 208u8, 235u8, 135u8, 127u8, 243u8, - 41u8, 55u8, 243u8, 235u8, 122u8, 57u8, 86u8, 37u8, 90u8, 208u8, 71u8, + 218u8, 54u8, 230u8, 230u8, 47u8, 1u8, 213u8, 144u8, 43u8, 21u8, 63u8, + 245u8, 81u8, 157u8, 189u8, 79u8, 108u8, 173u8, 142u8, 208u8, 47u8, + 90u8, 208u8, 125u8, 214u8, 233u8, 78u8, 29u8, 213u8, 198u8, 237u8, + 54u8, ], ) } - #[doc = " Current epoch authorities."] - pub fn authorities( + #[doc = " Query fee details of a given encoded `Call`."] + pub fn query_call_fee_details( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec<( - runtime_types::sp_consensus_babe::app::Public, - ::core::primitive::u64, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), + call: runtime_types::polkadot_runtime::RuntimeCall, + len: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload< + types::QueryCallFeeDetails, + runtime_types::pallet_transaction_payment::types::FeeDetails< + ::core::primitive::u128, + >, > { - ::subxt::storage::address::Address::new_static( - "Babe", - "Authorities", - vec![], + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentCallApi_query_call_fee_details", + types::QueryCallFeeDetails { call, len }, [ - 61u8, 8u8, 133u8, 111u8, 169u8, 120u8, 0u8, 213u8, 31u8, 159u8, 204u8, - 212u8, 18u8, 205u8, 93u8, 84u8, 140u8, 108u8, 136u8, 209u8, 234u8, - 107u8, 145u8, 9u8, 204u8, 224u8, 105u8, 9u8, 238u8, 241u8, 65u8, 30u8, + 117u8, 194u8, 140u8, 175u8, 222u8, 226u8, 47u8, 206u8, 231u8, 61u8, + 90u8, 113u8, 66u8, 118u8, 129u8, 235u8, 145u8, 217u8, 255u8, 169u8, + 207u8, 24u8, 64u8, 140u8, 39u8, 42u8, 34u8, 179u8, 219u8, 33u8, 107u8, + 1u8, ], ) } - #[doc = " The slot at which the first epoch actually started. This is 0"] - #[doc = " until the first block of the chain."] - pub fn genesis_slot( + #[doc = " Query the output of the current `WeightToFee` given some input."] + pub fn query_weight_to_fee( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_consensus_slots::Slot, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "GenesisSlot", - vec![], + weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentCallApi_query_weight_to_fee", + types::QueryWeightToFee { weight }, [ - 234u8, 127u8, 243u8, 100u8, 124u8, 160u8, 66u8, 248u8, 48u8, 218u8, - 61u8, 52u8, 54u8, 142u8, 158u8, 77u8, 32u8, 63u8, 156u8, 39u8, 94u8, - 255u8, 192u8, 238u8, 170u8, 118u8, 58u8, 42u8, 199u8, 61u8, 199u8, - 77u8, + 235u8, 177u8, 255u8, 102u8, 0u8, 237u8, 63u8, 37u8, 144u8, 142u8, 86u8, + 43u8, 82u8, 41u8, 25u8, 149u8, 75u8, 238u8, 118u8, 216u8, 84u8, 241u8, + 54u8, 157u8, 81u8, 246u8, 140u8, 240u8, 210u8, 208u8, 235u8, 172u8, ], ) } - #[doc = " Current slot number."] - pub fn current_slot( + #[doc = " Query the output of the current `LengthToFee` given some input."] + pub fn query_length_to_fee( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_consensus_slots::Slot, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "CurrentSlot", - vec![], + length: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentCallApi_query_length_to_fee", + types::QueryLengthToFee { length }, [ - 139u8, 237u8, 185u8, 137u8, 251u8, 179u8, 69u8, 167u8, 133u8, 168u8, - 204u8, 64u8, 178u8, 123u8, 92u8, 250u8, 119u8, 190u8, 208u8, 178u8, - 208u8, 176u8, 124u8, 187u8, 74u8, 165u8, 33u8, 78u8, 161u8, 206u8, 8u8, - 108u8, - ], - ) - } - #[doc = " The epoch randomness for the *current* epoch."] - #[doc = ""] - #[doc = " # Security"] - #[doc = ""] - #[doc = " This MUST NOT be used for gambling, as it can be influenced by a"] - #[doc = " malicious validator in the short term. It MAY be used in many"] - #[doc = " cryptographic protocols, however, so long as one remembers that this"] - #[doc = " (like everything else on-chain) it is public. For example, it can be"] - #[doc = " used where a number is needed that cannot have been chosen by an"] - #[doc = " adversary, for purposes such as public-coin zero-knowledge proofs."] - pub fn randomness( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - [::core::primitive::u8; 32usize], - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "Randomness", - vec![], - [ - 191u8, 197u8, 25u8, 164u8, 104u8, 248u8, 247u8, 193u8, 244u8, 60u8, - 181u8, 195u8, 248u8, 90u8, 41u8, 199u8, 82u8, 123u8, 72u8, 126u8, 18u8, - 17u8, 128u8, 215u8, 34u8, 251u8, 227u8, 70u8, 166u8, 10u8, 104u8, - 140u8, - ], - ) - } - #[doc = " Pending epoch configuration change that will be applied when the next epoch is enacted."] - pub fn pending_epoch_config_change( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "PendingEpochConfigChange", - vec![], - [ - 4u8, 201u8, 0u8, 204u8, 47u8, 246u8, 4u8, 185u8, 163u8, 242u8, 242u8, - 152u8, 29u8, 222u8, 71u8, 127u8, 49u8, 203u8, 206u8, 180u8, 244u8, - 50u8, 80u8, 49u8, 199u8, 97u8, 3u8, 170u8, 156u8, 139u8, 106u8, 113u8, - ], - ) - } - #[doc = " Next epoch randomness."] - pub fn next_randomness( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - [::core::primitive::u8; 32usize], - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "NextRandomness", - vec![], - [ - 185u8, 98u8, 45u8, 109u8, 253u8, 38u8, 238u8, 221u8, 240u8, 29u8, 38u8, - 107u8, 118u8, 117u8, 131u8, 115u8, 21u8, 255u8, 203u8, 81u8, 243u8, - 251u8, 91u8, 60u8, 163u8, 202u8, 125u8, 193u8, 173u8, 234u8, 166u8, - 92u8, - ], - ) - } - #[doc = " Next epoch authorities."] - pub fn next_authorities( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec<( - runtime_types::sp_consensus_babe::app::Public, - ::core::primitive::u64, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "NextAuthorities", - vec![], - [ - 201u8, 193u8, 164u8, 18u8, 155u8, 253u8, 124u8, 163u8, 143u8, 73u8, - 212u8, 20u8, 241u8, 108u8, 110u8, 5u8, 171u8, 66u8, 224u8, 208u8, 10u8, - 65u8, 148u8, 164u8, 1u8, 12u8, 216u8, 83u8, 20u8, 226u8, 254u8, 183u8, - ], - ) - } - #[doc = " Randomness under construction."] - #[doc = ""] - #[doc = " We make a trade-off between storage accesses and list length."] - #[doc = " We store the under-construction randomness in segments of up to"] - #[doc = " `UNDER_CONSTRUCTION_SEGMENT_LENGTH`."] - #[doc = ""] - #[doc = " Once a segment reaches this length, we begin the next one."] - #[doc = " We reset all segments and return to `0` at the beginning of every"] - #[doc = " epoch."] - pub fn segment_index( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "SegmentIndex", - vec![], - [ - 128u8, 45u8, 87u8, 58u8, 174u8, 152u8, 241u8, 156u8, 56u8, 192u8, 19u8, - 45u8, 75u8, 160u8, 35u8, 253u8, 145u8, 11u8, 178u8, 81u8, 114u8, 117u8, - 112u8, 107u8, 163u8, 208u8, 240u8, 151u8, 102u8, 176u8, 246u8, 5u8, - ], - ) - } - #[doc = " TWOX-NOTE: `SegmentIndex` is an increasing integer, so this is okay."] - pub fn under_construction( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - [::core::primitive::u8; 32usize], - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "UnderConstruction", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 180u8, 4u8, 149u8, 245u8, 231u8, 92u8, 99u8, 170u8, 254u8, 172u8, - 182u8, 3u8, 152u8, 156u8, 132u8, 196u8, 140u8, 97u8, 7u8, 84u8, 220u8, - 89u8, 195u8, 177u8, 235u8, 51u8, 98u8, 144u8, 73u8, 238u8, 59u8, 164u8, - ], - ) - } - #[doc = " TWOX-NOTE: `SegmentIndex` is an increasing integer, so this is okay."] - pub fn under_construction_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - [::core::primitive::u8; 32usize], - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "UnderConstruction", - Vec::new(), - [ - 180u8, 4u8, 149u8, 245u8, 231u8, 92u8, 99u8, 170u8, 254u8, 172u8, - 182u8, 3u8, 152u8, 156u8, 132u8, 196u8, 140u8, 97u8, 7u8, 84u8, 220u8, - 89u8, 195u8, 177u8, 235u8, 51u8, 98u8, 144u8, 73u8, 238u8, 59u8, 164u8, - ], - ) - } - #[doc = " Temporary value (cleared at block finalization) which is `Some`"] - #[doc = " if per-block initialization has already been called for current block."] - pub fn initialized( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::option::Option, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "Initialized", - vec![], - [ - 40u8, 135u8, 28u8, 144u8, 247u8, 208u8, 48u8, 220u8, 46u8, 60u8, 131u8, - 190u8, 196u8, 235u8, 126u8, 66u8, 34u8, 14u8, 32u8, 131u8, 71u8, 46u8, - 62u8, 207u8, 177u8, 213u8, 167u8, 34u8, 199u8, 29u8, 16u8, 236u8, - ], - ) - } - #[doc = " This field should always be populated during block processing unless"] - #[doc = " secondary plain slots are enabled (which don't contain a VRF output)."] - #[doc = ""] - #[doc = " It is set in `on_finalize`, before it will contain the value from the last block."] - pub fn author_vrf_randomness( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::option::Option<[::core::primitive::u8; 32usize]>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "AuthorVrfRandomness", - vec![], - [ - 66u8, 235u8, 74u8, 252u8, 222u8, 135u8, 19u8, 28u8, 74u8, 191u8, 170u8, - 197u8, 207u8, 127u8, 77u8, 121u8, 138u8, 138u8, 110u8, 187u8, 34u8, - 14u8, 230u8, 43u8, 241u8, 241u8, 63u8, 163u8, 53u8, 179u8, 250u8, - 247u8, - ], - ) - } - #[doc = " The block numbers when the last and current epoch have started, respectively `N-1` and"] - #[doc = " `N`."] - #[doc = " NOTE: We track this is in order to annotate the block number when a given pool of"] - #[doc = " entropy was fixed (i.e. it was known to chain observers). Since epochs are defined in"] - #[doc = " slots, which may be skipped, the block numbers may not line up with the slot numbers."] - pub fn epoch_start( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "EpochStart", - vec![], - [ - 196u8, 39u8, 241u8, 20u8, 150u8, 180u8, 136u8, 4u8, 195u8, 205u8, - 218u8, 10u8, 130u8, 131u8, 168u8, 243u8, 207u8, 249u8, 58u8, 195u8, - 177u8, 119u8, 110u8, 243u8, 241u8, 3u8, 245u8, 56u8, 157u8, 5u8, 68u8, - 60u8, - ], - ) - } - #[doc = " How late the current block is compared to its parent."] - #[doc = ""] - #[doc = " This entry is populated as part of block execution and is cleaned up"] - #[doc = " on block finalization. Querying this storage entry outside of block"] - #[doc = " execution context should always yield zero."] - pub fn lateness( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "Lateness", - vec![], - [ - 229u8, 230u8, 224u8, 89u8, 49u8, 213u8, 198u8, 236u8, 144u8, 56u8, - 193u8, 234u8, 62u8, 242u8, 191u8, 199u8, 105u8, 131u8, 74u8, 63u8, - 75u8, 1u8, 210u8, 49u8, 3u8, 128u8, 18u8, 77u8, 219u8, 146u8, 60u8, - 88u8, - ], - ) - } - #[doc = " The configuration for the current epoch. Should never be `None` as it is initialized in"] - #[doc = " genesis."] - pub fn epoch_config( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_consensus_babe::BabeEpochConfiguration, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "EpochConfig", - vec![], - [ - 41u8, 118u8, 141u8, 244u8, 72u8, 17u8, 125u8, 203u8, 43u8, 153u8, - 203u8, 119u8, 117u8, 223u8, 123u8, 133u8, 73u8, 235u8, 130u8, 21u8, - 160u8, 167u8, 16u8, 173u8, 177u8, 35u8, 117u8, 97u8, 149u8, 49u8, - 220u8, 24u8, - ], - ) - } - #[doc = " The configuration for the next epoch, `None` if the config will not change"] - #[doc = " (you can fallback to `EpochConfig` instead in that case)."] - pub fn next_epoch_config( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_consensus_babe::BabeEpochConfiguration, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "NextEpochConfig", - vec![], - [ - 111u8, 182u8, 144u8, 180u8, 92u8, 146u8, 102u8, 249u8, 196u8, 229u8, - 226u8, 30u8, 25u8, 198u8, 133u8, 9u8, 136u8, 95u8, 11u8, 151u8, 139u8, - 156u8, 105u8, 228u8, 181u8, 12u8, 175u8, 148u8, 174u8, 33u8, 233u8, - 228u8, - ], - ) - } - #[doc = " A list of the last 100 skipped epochs and the corresponding session index"] - #[doc = " when the epoch was skipped."] - #[doc = ""] - #[doc = " This is only used for validating equivocation proofs. An equivocation proof"] - #[doc = " must contains a key-ownership proof for a given session, therefore we need a"] - #[doc = " way to tie together sessions and epoch indices, i.e. we need to validate that"] - #[doc = " a validator was the owner of a given key on a given session, and what the"] - #[doc = " active epoch index was during that session."] - pub fn skipped_epochs( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u64, - ::core::primitive::u32, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "SkippedEpochs", - vec![], - [ - 187u8, 66u8, 178u8, 110u8, 247u8, 41u8, 128u8, 194u8, 173u8, 197u8, - 28u8, 219u8, 112u8, 75u8, 9u8, 184u8, 51u8, 12u8, 121u8, 117u8, 176u8, - 213u8, 139u8, 144u8, 122u8, 72u8, 243u8, 105u8, 248u8, 63u8, 6u8, 87u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The amount of time, in slots, that each epoch should last."] - #[doc = " NOTE: Currently it is not possible to change the epoch duration after"] - #[doc = " the chain has started. Attempting to do so will brick block production."] - pub fn epoch_duration( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "Babe", - "EpochDuration", - [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, - ], - ) - } - #[doc = " The expected average block time at which BABE should be creating"] - #[doc = " blocks. Since BABE is probabilistic it is not trivial to figure out"] - #[doc = " what the expected average block time should be based on the slot"] - #[doc = " duration and the security parameter `c` (where `1 - c` represents"] - #[doc = " the probability of a slot being empty)."] - pub fn expected_block_time( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "Babe", - "ExpectedBlockTime", - [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, - ], - ) - } - #[doc = " Max number of authorities allowed"] - pub fn max_authorities( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Babe", - "MaxAuthorities", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 188u8, 80u8, 192u8, 251u8, 47u8, 200u8, 60u8, 10u8, 214u8, 47u8, 137u8, + 111u8, 226u8, 163u8, 60u8, 177u8, 190u8, 210u8, 57u8, 89u8, 34u8, + 154u8, 190u8, 244u8, 132u8, 129u8, 212u8, 121u8, 43u8, 190u8, 71u8, + 237u8, ], ) } } - } - } - pub mod timestamp { - use super::root_mod; - use super::runtime_types; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; pub mod types { use super::runtime_types; #[derive( @@ -3831,120 +3404,498 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Set { - #[codec(compact)] - pub now: ::core::primitive::u64, + pub struct QueryCallInfo { + pub call: runtime_types::polkadot_runtime::RuntimeCall, + pub len: ::core::primitive::u32, } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Set the current time."] - #[doc = ""] - #[doc = "This call should be invoked exactly once per block. It will panic at the finalization"] - #[doc = "phase, if this call hasn't been invoked by that time."] - #[doc = ""] - #[doc = "The timestamp should be greater than the previous one by the amount specified by"] - #[doc = "`MinimumPeriod`."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be `Inherent`."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(1)` (Note that implementations of `OnTimestampSet` must also be `O(1)`)"] - #[doc = "- 1 storage read and 1 storage mutation (codec `O(1)`). (because of `DidUpdate::take` in"] - #[doc = " `on_finalize`)"] - #[doc = "- 1 event handler `on_timestamp_set`. Must be `O(1)`."] - pub fn set(&self, now: ::core::primitive::u64) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Timestamp", - "set", - types::Set { now }, - [ - 6u8, 97u8, 172u8, 236u8, 118u8, 238u8, 228u8, 114u8, 15u8, 115u8, - 102u8, 85u8, 66u8, 151u8, 16u8, 33u8, 187u8, 17u8, 166u8, 88u8, 127u8, - 214u8, 182u8, 51u8, 168u8, 88u8, 43u8, 101u8, 185u8, 8u8, 1u8, 28u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryCallFeeDetails { + pub call: runtime_types::polkadot_runtime::RuntimeCall, + pub len: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryWeightToFee { + pub weight: runtime_types::sp_weights::weight_v2::Weight, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryLengthToFee { + pub length: ::core::primitive::u32, } } } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Current time for the current block."] - pub fn now( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Timestamp", - "Now", - vec![], - [ - 148u8, 53u8, 50u8, 54u8, 13u8, 161u8, 57u8, 150u8, 16u8, 83u8, 144u8, - 221u8, 59u8, 75u8, 158u8, 130u8, 39u8, 123u8, 106u8, 134u8, 202u8, - 185u8, 83u8, 85u8, 60u8, 41u8, 120u8, 96u8, 210u8, 34u8, 2u8, 250u8, - ], - ) - } - #[doc = " Did the timestamp get updated in this block?"] - pub fn did_update( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Timestamp", - "DidUpdate", - vec![], - [ - 70u8, 13u8, 92u8, 186u8, 80u8, 151u8, 167u8, 90u8, 158u8, 232u8, 175u8, - 13u8, 103u8, 135u8, 2u8, 78u8, 16u8, 6u8, 39u8, 158u8, 167u8, 85u8, - 27u8, 47u8, 122u8, 73u8, 127u8, 26u8, 35u8, 168u8, 72u8, 204u8, - ], - ) - } - } + } + pub struct ConstantsApi; + impl ConstantsApi { + pub fn system(&self) -> system::constants::ConstantsApi { + system::constants::ConstantsApi } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The minimum period between blocks. Beware that this is different to the *expected*"] - #[doc = " period that the block production apparatus provides. Your chosen consensus system will"] - #[doc = " generally work with this to determine a sensible block time. e.g. For Aura, it will be"] - #[doc = " double this period on default settings."] - pub fn minimum_period( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "Timestamp", - "MinimumPeriod", - [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, - ], - ) - } - } + pub fn scheduler(&self) -> scheduler::constants::ConstantsApi { + scheduler::constants::ConstantsApi + } + pub fn babe(&self) -> babe::constants::ConstantsApi { + babe::constants::ConstantsApi + } + pub fn timestamp(&self) -> timestamp::constants::ConstantsApi { + timestamp::constants::ConstantsApi + } + pub fn indices(&self) -> indices::constants::ConstantsApi { + indices::constants::ConstantsApi + } + pub fn balances(&self) -> balances::constants::ConstantsApi { + balances::constants::ConstantsApi + } + pub fn transaction_payment(&self) -> transaction_payment::constants::ConstantsApi { + transaction_payment::constants::ConstantsApi + } + pub fn staking(&self) -> staking::constants::ConstantsApi { + staking::constants::ConstantsApi + } + pub fn grandpa(&self) -> grandpa::constants::ConstantsApi { + grandpa::constants::ConstantsApi + } + pub fn im_online(&self) -> im_online::constants::ConstantsApi { + im_online::constants::ConstantsApi + } + pub fn democracy(&self) -> democracy::constants::ConstantsApi { + democracy::constants::ConstantsApi + } + pub fn council(&self) -> council::constants::ConstantsApi { + council::constants::ConstantsApi + } + pub fn technical_committee(&self) -> technical_committee::constants::ConstantsApi { + technical_committee::constants::ConstantsApi + } + pub fn phragmen_election(&self) -> phragmen_election::constants::ConstantsApi { + phragmen_election::constants::ConstantsApi + } + pub fn treasury(&self) -> treasury::constants::ConstantsApi { + treasury::constants::ConstantsApi + } + pub fn conviction_voting(&self) -> conviction_voting::constants::ConstantsApi { + conviction_voting::constants::ConstantsApi + } + pub fn referenda(&self) -> referenda::constants::ConstantsApi { + referenda::constants::ConstantsApi + } + pub fn claims(&self) -> claims::constants::ConstantsApi { + claims::constants::ConstantsApi + } + pub fn vesting(&self) -> vesting::constants::ConstantsApi { + vesting::constants::ConstantsApi + } + pub fn utility(&self) -> utility::constants::ConstantsApi { + utility::constants::ConstantsApi + } + pub fn identity(&self) -> identity::constants::ConstantsApi { + identity::constants::ConstantsApi + } + pub fn proxy(&self) -> proxy::constants::ConstantsApi { + proxy::constants::ConstantsApi + } + pub fn multisig(&self) -> multisig::constants::ConstantsApi { + multisig::constants::ConstantsApi + } + pub fn bounties(&self) -> bounties::constants::ConstantsApi { + bounties::constants::ConstantsApi + } + pub fn child_bounties(&self) -> child_bounties::constants::ConstantsApi { + child_bounties::constants::ConstantsApi + } + pub fn tips(&self) -> tips::constants::ConstantsApi { + tips::constants::ConstantsApi + } + pub fn election_provider_multi_phase( + &self, + ) -> election_provider_multi_phase::constants::ConstantsApi { + election_provider_multi_phase::constants::ConstantsApi + } + pub fn voter_list(&self) -> voter_list::constants::ConstantsApi { + voter_list::constants::ConstantsApi + } + pub fn nomination_pools(&self) -> nomination_pools::constants::ConstantsApi { + nomination_pools::constants::ConstantsApi + } + pub fn fast_unstake(&self) -> fast_unstake::constants::ConstantsApi { + fast_unstake::constants::ConstantsApi + } + pub fn paras(&self) -> paras::constants::ConstantsApi { + paras::constants::ConstantsApi + } + pub fn registrar(&self) -> registrar::constants::ConstantsApi { + registrar::constants::ConstantsApi + } + pub fn slots(&self) -> slots::constants::ConstantsApi { + slots::constants::ConstantsApi + } + pub fn auctions(&self) -> auctions::constants::ConstantsApi { + auctions::constants::ConstantsApi + } + pub fn crowdloan(&self) -> crowdloan::constants::ConstantsApi { + crowdloan::constants::ConstantsApi } } - pub mod indices { + pub struct StorageApi; + impl StorageApi { + pub fn system(&self) -> system::storage::StorageApi { + system::storage::StorageApi + } + pub fn scheduler(&self) -> scheduler::storage::StorageApi { + scheduler::storage::StorageApi + } + pub fn preimage(&self) -> preimage::storage::StorageApi { + preimage::storage::StorageApi + } + pub fn babe(&self) -> babe::storage::StorageApi { + babe::storage::StorageApi + } + pub fn timestamp(&self) -> timestamp::storage::StorageApi { + timestamp::storage::StorageApi + } + pub fn indices(&self) -> indices::storage::StorageApi { + indices::storage::StorageApi + } + pub fn balances(&self) -> balances::storage::StorageApi { + balances::storage::StorageApi + } + pub fn transaction_payment(&self) -> transaction_payment::storage::StorageApi { + transaction_payment::storage::StorageApi + } + pub fn authorship(&self) -> authorship::storage::StorageApi { + authorship::storage::StorageApi + } + pub fn staking(&self) -> staking::storage::StorageApi { + staking::storage::StorageApi + } + pub fn offences(&self) -> offences::storage::StorageApi { + offences::storage::StorageApi + } + pub fn session(&self) -> session::storage::StorageApi { + session::storage::StorageApi + } + pub fn grandpa(&self) -> grandpa::storage::StorageApi { + grandpa::storage::StorageApi + } + pub fn im_online(&self) -> im_online::storage::StorageApi { + im_online::storage::StorageApi + } + pub fn democracy(&self) -> democracy::storage::StorageApi { + democracy::storage::StorageApi + } + pub fn council(&self) -> council::storage::StorageApi { + council::storage::StorageApi + } + pub fn technical_committee(&self) -> technical_committee::storage::StorageApi { + technical_committee::storage::StorageApi + } + pub fn phragmen_election(&self) -> phragmen_election::storage::StorageApi { + phragmen_election::storage::StorageApi + } + pub fn technical_membership(&self) -> technical_membership::storage::StorageApi { + technical_membership::storage::StorageApi + } + pub fn treasury(&self) -> treasury::storage::StorageApi { + treasury::storage::StorageApi + } + pub fn conviction_voting(&self) -> conviction_voting::storage::StorageApi { + conviction_voting::storage::StorageApi + } + pub fn referenda(&self) -> referenda::storage::StorageApi { + referenda::storage::StorageApi + } + pub fn whitelist(&self) -> whitelist::storage::StorageApi { + whitelist::storage::StorageApi + } + pub fn claims(&self) -> claims::storage::StorageApi { + claims::storage::StorageApi + } + pub fn vesting(&self) -> vesting::storage::StorageApi { + vesting::storage::StorageApi + } + pub fn identity(&self) -> identity::storage::StorageApi { + identity::storage::StorageApi + } + pub fn proxy(&self) -> proxy::storage::StorageApi { + proxy::storage::StorageApi + } + pub fn multisig(&self) -> multisig::storage::StorageApi { + multisig::storage::StorageApi + } + pub fn bounties(&self) -> bounties::storage::StorageApi { + bounties::storage::StorageApi + } + pub fn child_bounties(&self) -> child_bounties::storage::StorageApi { + child_bounties::storage::StorageApi + } + pub fn tips(&self) -> tips::storage::StorageApi { + tips::storage::StorageApi + } + pub fn election_provider_multi_phase( + &self, + ) -> election_provider_multi_phase::storage::StorageApi { + election_provider_multi_phase::storage::StorageApi + } + pub fn voter_list(&self) -> voter_list::storage::StorageApi { + voter_list::storage::StorageApi + } + pub fn nomination_pools(&self) -> nomination_pools::storage::StorageApi { + nomination_pools::storage::StorageApi + } + pub fn fast_unstake(&self) -> fast_unstake::storage::StorageApi { + fast_unstake::storage::StorageApi + } + pub fn configuration(&self) -> configuration::storage::StorageApi { + configuration::storage::StorageApi + } + pub fn paras_shared(&self) -> paras_shared::storage::StorageApi { + paras_shared::storage::StorageApi + } + pub fn para_inclusion(&self) -> para_inclusion::storage::StorageApi { + para_inclusion::storage::StorageApi + } + pub fn para_inherent(&self) -> para_inherent::storage::StorageApi { + para_inherent::storage::StorageApi + } + pub fn para_scheduler(&self) -> para_scheduler::storage::StorageApi { + para_scheduler::storage::StorageApi + } + pub fn paras(&self) -> paras::storage::StorageApi { + paras::storage::StorageApi + } + pub fn initializer(&self) -> initializer::storage::StorageApi { + initializer::storage::StorageApi + } + pub fn dmp(&self) -> dmp::storage::StorageApi { + dmp::storage::StorageApi + } + pub fn ump(&self) -> ump::storage::StorageApi { + ump::storage::StorageApi + } + pub fn hrmp(&self) -> hrmp::storage::StorageApi { + hrmp::storage::StorageApi + } + pub fn para_session_info(&self) -> para_session_info::storage::StorageApi { + para_session_info::storage::StorageApi + } + pub fn paras_disputes(&self) -> paras_disputes::storage::StorageApi { + paras_disputes::storage::StorageApi + } + pub fn paras_slashing(&self) -> paras_slashing::storage::StorageApi { + paras_slashing::storage::StorageApi + } + pub fn registrar(&self) -> registrar::storage::StorageApi { + registrar::storage::StorageApi + } + pub fn slots(&self) -> slots::storage::StorageApi { + slots::storage::StorageApi + } + pub fn auctions(&self) -> auctions::storage::StorageApi { + auctions::storage::StorageApi + } + pub fn crowdloan(&self) -> crowdloan::storage::StorageApi { + crowdloan::storage::StorageApi + } + pub fn xcm_pallet(&self) -> xcm_pallet::storage::StorageApi { + xcm_pallet::storage::StorageApi + } + } + pub struct TransactionApi; + impl TransactionApi { + pub fn system(&self) -> system::calls::TransactionApi { + system::calls::TransactionApi + } + pub fn scheduler(&self) -> scheduler::calls::TransactionApi { + scheduler::calls::TransactionApi + } + pub fn preimage(&self) -> preimage::calls::TransactionApi { + preimage::calls::TransactionApi + } + pub fn babe(&self) -> babe::calls::TransactionApi { + babe::calls::TransactionApi + } + pub fn timestamp(&self) -> timestamp::calls::TransactionApi { + timestamp::calls::TransactionApi + } + pub fn indices(&self) -> indices::calls::TransactionApi { + indices::calls::TransactionApi + } + pub fn balances(&self) -> balances::calls::TransactionApi { + balances::calls::TransactionApi + } + pub fn staking(&self) -> staking::calls::TransactionApi { + staking::calls::TransactionApi + } + pub fn session(&self) -> session::calls::TransactionApi { + session::calls::TransactionApi + } + pub fn grandpa(&self) -> grandpa::calls::TransactionApi { + grandpa::calls::TransactionApi + } + pub fn im_online(&self) -> im_online::calls::TransactionApi { + im_online::calls::TransactionApi + } + pub fn democracy(&self) -> democracy::calls::TransactionApi { + democracy::calls::TransactionApi + } + pub fn council(&self) -> council::calls::TransactionApi { + council::calls::TransactionApi + } + pub fn technical_committee(&self) -> technical_committee::calls::TransactionApi { + technical_committee::calls::TransactionApi + } + pub fn phragmen_election(&self) -> phragmen_election::calls::TransactionApi { + phragmen_election::calls::TransactionApi + } + pub fn technical_membership(&self) -> technical_membership::calls::TransactionApi { + technical_membership::calls::TransactionApi + } + pub fn treasury(&self) -> treasury::calls::TransactionApi { + treasury::calls::TransactionApi + } + pub fn conviction_voting(&self) -> conviction_voting::calls::TransactionApi { + conviction_voting::calls::TransactionApi + } + pub fn referenda(&self) -> referenda::calls::TransactionApi { + referenda::calls::TransactionApi + } + pub fn whitelist(&self) -> whitelist::calls::TransactionApi { + whitelist::calls::TransactionApi + } + pub fn claims(&self) -> claims::calls::TransactionApi { + claims::calls::TransactionApi + } + pub fn vesting(&self) -> vesting::calls::TransactionApi { + vesting::calls::TransactionApi + } + pub fn utility(&self) -> utility::calls::TransactionApi { + utility::calls::TransactionApi + } + pub fn identity(&self) -> identity::calls::TransactionApi { + identity::calls::TransactionApi + } + pub fn proxy(&self) -> proxy::calls::TransactionApi { + proxy::calls::TransactionApi + } + pub fn multisig(&self) -> multisig::calls::TransactionApi { + multisig::calls::TransactionApi + } + pub fn bounties(&self) -> bounties::calls::TransactionApi { + bounties::calls::TransactionApi + } + pub fn child_bounties(&self) -> child_bounties::calls::TransactionApi { + child_bounties::calls::TransactionApi + } + pub fn tips(&self) -> tips::calls::TransactionApi { + tips::calls::TransactionApi + } + pub fn election_provider_multi_phase( + &self, + ) -> election_provider_multi_phase::calls::TransactionApi { + election_provider_multi_phase::calls::TransactionApi + } + pub fn voter_list(&self) -> voter_list::calls::TransactionApi { + voter_list::calls::TransactionApi + } + pub fn nomination_pools(&self) -> nomination_pools::calls::TransactionApi { + nomination_pools::calls::TransactionApi + } + pub fn fast_unstake(&self) -> fast_unstake::calls::TransactionApi { + fast_unstake::calls::TransactionApi + } + pub fn configuration(&self) -> configuration::calls::TransactionApi { + configuration::calls::TransactionApi + } + pub fn paras_shared(&self) -> paras_shared::calls::TransactionApi { + paras_shared::calls::TransactionApi + } + pub fn para_inclusion(&self) -> para_inclusion::calls::TransactionApi { + para_inclusion::calls::TransactionApi + } + pub fn para_inherent(&self) -> para_inherent::calls::TransactionApi { + para_inherent::calls::TransactionApi + } + pub fn paras(&self) -> paras::calls::TransactionApi { + paras::calls::TransactionApi + } + pub fn initializer(&self) -> initializer::calls::TransactionApi { + initializer::calls::TransactionApi + } + pub fn ump(&self) -> ump::calls::TransactionApi { + ump::calls::TransactionApi + } + pub fn hrmp(&self) -> hrmp::calls::TransactionApi { + hrmp::calls::TransactionApi + } + pub fn paras_disputes(&self) -> paras_disputes::calls::TransactionApi { + paras_disputes::calls::TransactionApi + } + pub fn paras_slashing(&self) -> paras_slashing::calls::TransactionApi { + paras_slashing::calls::TransactionApi + } + pub fn registrar(&self) -> registrar::calls::TransactionApi { + registrar::calls::TransactionApi + } + pub fn slots(&self) -> slots::calls::TransactionApi { + slots::calls::TransactionApi + } + pub fn auctions(&self) -> auctions::calls::TransactionApi { + auctions::calls::TransactionApi + } + pub fn crowdloan(&self) -> crowdloan::calls::TransactionApi { + crowdloan::calls::TransactionApi + } + pub fn xcm_pallet(&self) -> xcm_pallet::calls::TransactionApi { + xcm_pallet::calls::TransactionApi + } + } + #[doc = r" check whether the Client you are using is aligned with the statically generated codegen."] + pub fn validate_codegen>( + client: &C, + ) -> Result<(), ::subxt::error::MetadataError> { + let runtime_metadata_hash = client.metadata().metadata_hash(&PALLETS); + if runtime_metadata_hash + != [ + 193u8, 126u8, 5u8, 68u8, 158u8, 198u8, 107u8, 140u8, 166u8, 77u8, 81u8, 160u8, + 213u8, 179u8, 210u8, 41u8, 130u8, 34u8, 133u8, 228u8, 10u8, 134u8, 182u8, 62u8, + 72u8, 116u8, 209u8, 70u8, 115u8, 234u8, 227u8, 18u8, + ] + { + Err(::subxt::error::MetadataError::IncompatibleMetadata) + } else { + Ok(()) + } + } + pub mod system { use super::root_mod; use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_indices::pallet::Error; + #[doc = "Error for the System pallet"] + pub type Error = runtime_types::frame_system::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -3952,6 +3903,19 @@ pub mod api { type DispatchError = runtime_types::sp_runtime::DispatchError; pub mod types { use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Remark { + pub remark: ::std::vec::Vec<::core::primitive::u8>, + } #[derive( :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, @@ -3963,8 +3927,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Claim { - pub index: ::core::primitive::u32, + pub struct SetHeapPages { + pub pages: ::core::primitive::u64, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -3976,12 +3940,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Transfer { - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub index: ::core::primitive::u32, + pub struct SetCode { + pub code: ::std::vec::Vec<::core::primitive::u8>, } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -3991,8 +3953,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Free { - pub index: ::core::primitive::u32, + pub struct SetCodeWithoutChecks { + pub code: ::std::vec::Vec<::core::primitive::u8>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -4004,13 +3966,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceTransfer { - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub index: ::core::primitive::u32, - pub freeze: ::core::primitive::bool, + pub struct SetStorage { + pub items: ::std::vec::Vec<( + ::std::vec::Vec<::core::primitive::u8>, + ::std::vec::Vec<::core::primitive::u8>, + )>, } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -4020,316 +3982,193 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Freeze { - pub index: ::core::primitive::u32, + pub struct KillStorage { + pub keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, } - } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct KillPrefix { + pub prefix: ::std::vec::Vec<::core::primitive::u8>, + pub subkeys: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemarkWithEvent { + pub remark: ::std::vec::Vec<::core::primitive::u8>, + } + } pub struct TransactionApi; impl TransactionApi { - #[doc = "Assign an previously unassigned index."] - #[doc = ""] - #[doc = "Payment: `Deposit` is reserved from the sender account."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "- `index`: the index to be claimed. This must not be in use."] - #[doc = ""] - #[doc = "Emits `IndexAssigned` if successful."] + #[doc = "Make some on-chain remark."] #[doc = ""] #[doc = "## Complexity"] - #[doc = "- `O(1)`."] - pub fn claim(&self, index: ::core::primitive::u32) -> ::subxt::tx::Payload { + #[doc = "- `O(1)`"] + pub fn remark( + &self, + remark: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Indices", - "claim", - types::Claim { index }, + "System", + "remark", + types::Remark { remark }, [ - 5u8, 24u8, 11u8, 173u8, 226u8, 170u8, 0u8, 30u8, 193u8, 102u8, 214u8, - 59u8, 252u8, 32u8, 221u8, 88u8, 196u8, 189u8, 244u8, 18u8, 233u8, 37u8, - 228u8, 248u8, 76u8, 175u8, 212u8, 233u8, 238u8, 203u8, 162u8, 68u8, + 101u8, 80u8, 195u8, 226u8, 224u8, 247u8, 60u8, 128u8, 3u8, 101u8, 51u8, + 147u8, 96u8, 126u8, 76u8, 230u8, 194u8, 227u8, 191u8, 73u8, 160u8, + 146u8, 87u8, 147u8, 243u8, 28u8, 228u8, 116u8, 224u8, 181u8, 129u8, + 160u8, ], ) } - #[doc = "Assign an index already owned by the sender to another account. The balance reservation"] - #[doc = "is effectively transferred to the new account."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "- `index`: the index to be re-assigned. This must be owned by the sender."] - #[doc = "- `new`: the new owner of the index. This function is a no-op if it is equal to sender."] - #[doc = ""] - #[doc = "Emits `IndexAssigned` if successful."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(1)`."] - pub fn transfer( + #[doc = "Set the number of pages in the WebAssembly environment's heap."] + pub fn set_heap_pages( &self, - new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + pages: ::core::primitive::u64, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Indices", - "transfer", - types::Transfer { new, index }, + "System", + "set_heap_pages", + types::SetHeapPages { pages }, [ - 154u8, 191u8, 183u8, 50u8, 185u8, 69u8, 126u8, 132u8, 12u8, 77u8, - 146u8, 189u8, 254u8, 7u8, 72u8, 191u8, 118u8, 102u8, 180u8, 2u8, 161u8, - 151u8, 68u8, 93u8, 79u8, 45u8, 97u8, 202u8, 131u8, 103u8, 174u8, 189u8, + 43u8, 103u8, 128u8, 49u8, 156u8, 136u8, 11u8, 204u8, 80u8, 6u8, 244u8, + 86u8, 171u8, 44u8, 140u8, 225u8, 142u8, 198u8, 43u8, 87u8, 26u8, 45u8, + 125u8, 222u8, 165u8, 254u8, 172u8, 158u8, 39u8, 178u8, 86u8, 87u8, ], ) } - #[doc = "Free up an index owned by the sender."] - #[doc = ""] - #[doc = "Payment: Any previous deposit placed for the index is unreserved in the sender account."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must own the index."] - #[doc = ""] - #[doc = "- `index`: the index to be freed. This must be owned by the sender."] - #[doc = ""] - #[doc = "Emits `IndexFreed` if successful."] + #[doc = "Set the new runtime code."] #[doc = ""] #[doc = "## Complexity"] - #[doc = "- `O(1)`."] - pub fn free(&self, index: ::core::primitive::u32) -> ::subxt::tx::Payload { + #[doc = "- `O(C + S)` where `C` length of `code` and `S` complexity of `can_set_code`"] + pub fn set_code( + &self, + code: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Indices", - "free", - types::Free { index }, + "System", + "set_code", + types::SetCode { code }, [ - 133u8, 202u8, 225u8, 127u8, 69u8, 145u8, 43u8, 13u8, 160u8, 248u8, - 215u8, 243u8, 232u8, 166u8, 74u8, 203u8, 235u8, 138u8, 255u8, 27u8, - 163u8, 71u8, 254u8, 217u8, 6u8, 208u8, 202u8, 204u8, 238u8, 70u8, - 126u8, 252u8, + 27u8, 104u8, 244u8, 205u8, 188u8, 254u8, 121u8, 13u8, 106u8, 120u8, + 244u8, 108u8, 97u8, 84u8, 100u8, 68u8, 26u8, 69u8, 93u8, 128u8, 107u8, + 4u8, 3u8, 142u8, 13u8, 134u8, 196u8, 62u8, 113u8, 181u8, 14u8, 40u8, ], ) } - #[doc = "Force an index to an account. This doesn't require a deposit. If the index is already"] - #[doc = "held, then any deposit is reimbursed to its current owner."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Root_."] - #[doc = ""] - #[doc = "- `index`: the index to be (re-)assigned."] - #[doc = "- `new`: the new owner of the index. This function is a no-op if it is equal to sender."] - #[doc = "- `freeze`: if set to `true`, will freeze the index so it cannot be transferred."] - #[doc = ""] - #[doc = "Emits `IndexAssigned` if successful."] + #[doc = "Set the new runtime code without doing any checks of the given `code`."] #[doc = ""] #[doc = "## Complexity"] - #[doc = "- `O(1)`."] - pub fn force_transfer( + #[doc = "- `O(C)` where `C` length of `code`"] + pub fn set_code_without_checks( &self, - new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - index: ::core::primitive::u32, - freeze: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { + code: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Indices", - "force_transfer", - types::ForceTransfer { new, index, freeze }, + "System", + "set_code_without_checks", + types::SetCodeWithoutChecks { code }, [ - 37u8, 220u8, 91u8, 118u8, 222u8, 81u8, 225u8, 131u8, 101u8, 203u8, - 60u8, 149u8, 102u8, 92u8, 58u8, 91u8, 227u8, 64u8, 229u8, 62u8, 201u8, - 57u8, 168u8, 11u8, 51u8, 149u8, 146u8, 156u8, 209u8, 226u8, 11u8, - 181u8, + 102u8, 160u8, 125u8, 235u8, 30u8, 23u8, 45u8, 239u8, 112u8, 148u8, + 159u8, 158u8, 42u8, 93u8, 206u8, 94u8, 80u8, 250u8, 66u8, 195u8, 60u8, + 40u8, 142u8, 169u8, 183u8, 80u8, 80u8, 96u8, 3u8, 231u8, 99u8, 216u8, ], ) } - #[doc = "Freeze an index so it will always point to the sender account. This consumes the"] - #[doc = "deposit."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the signing account must have a"] - #[doc = "non-frozen account `index`."] - #[doc = ""] - #[doc = "- `index`: the index to be frozen in place."] - #[doc = ""] - #[doc = "Emits `IndexFrozen` if successful."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(1)`."] - pub fn freeze( + #[doc = "Set some items of storage."] + pub fn set_storage( &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + items: ::std::vec::Vec<( + ::std::vec::Vec<::core::primitive::u8>, + ::std::vec::Vec<::core::primitive::u8>, + )>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Indices", - "freeze", - types::Freeze { index }, + "System", + "set_storage", + types::SetStorage { items }, [ - 121u8, 45u8, 118u8, 2u8, 72u8, 48u8, 38u8, 7u8, 234u8, 204u8, 68u8, - 20u8, 76u8, 251u8, 205u8, 246u8, 149u8, 31u8, 168u8, 186u8, 208u8, - 90u8, 40u8, 47u8, 100u8, 228u8, 188u8, 33u8, 79u8, 220u8, 105u8, 209u8, + 74u8, 43u8, 106u8, 255u8, 50u8, 151u8, 192u8, 155u8, 14u8, 90u8, 19u8, + 45u8, 165u8, 16u8, 235u8, 242u8, 21u8, 131u8, 33u8, 172u8, 119u8, 78u8, + 140u8, 10u8, 107u8, 202u8, 122u8, 235u8, 181u8, 191u8, 22u8, 116u8, ], ) } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_indices::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A account index was assigned."] - pub struct IndexAssigned { - pub who: ::subxt::utils::AccountId32, - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for IndexAssigned { - const PALLET: &'static str = "Indices"; - const EVENT: &'static str = "IndexAssigned"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A account index has been freed up (unassigned)."] - pub struct IndexFreed { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for IndexFreed { - const PALLET: &'static str = "Indices"; - const EVENT: &'static str = "IndexFreed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A account index has been frozen to its current account ID."] - pub struct IndexFrozen { - pub index: ::core::primitive::u32, - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for IndexFrozen { - const PALLET: &'static str = "Indices"; - const EVENT: &'static str = "IndexFrozen"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The lookup from index to account."] - pub fn accounts( + #[doc = "Kill some items from storage."] + pub fn kill_storage( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::bool, - ), - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Indices", - "Accounts", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "kill_storage", + types::KillStorage { keys }, [ - 211u8, 169u8, 54u8, 254u8, 88u8, 57u8, 22u8, 223u8, 108u8, 27u8, 38u8, - 9u8, 202u8, 209u8, 111u8, 209u8, 144u8, 13u8, 211u8, 114u8, 239u8, - 127u8, 75u8, 166u8, 234u8, 222u8, 225u8, 35u8, 160u8, 163u8, 112u8, - 242u8, + 174u8, 174u8, 13u8, 174u8, 75u8, 138u8, 128u8, 235u8, 222u8, 216u8, + 85u8, 18u8, 198u8, 1u8, 138u8, 70u8, 19u8, 108u8, 209u8, 41u8, 228u8, + 67u8, 130u8, 230u8, 160u8, 207u8, 11u8, 180u8, 139u8, 242u8, 41u8, + 15u8, ], ) } - #[doc = " The lookup from index to account."] - pub fn accounts_root( + #[doc = "Kill all storage items with a key that starts with the given prefix."] + #[doc = ""] + #[doc = "**NOTE:** We rely on the Root origin to provide us the number of subkeys under"] + #[doc = "the prefix we are removing to accurately calculate the weight of this function."] + pub fn kill_prefix( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::bool, - ), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Indices", - "Accounts", - Vec::new(), + prefix: ::std::vec::Vec<::core::primitive::u8>, + subkeys: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "kill_prefix", + types::KillPrefix { prefix, subkeys }, [ - 211u8, 169u8, 54u8, 254u8, 88u8, 57u8, 22u8, 223u8, 108u8, 27u8, 38u8, - 9u8, 202u8, 209u8, 111u8, 209u8, 144u8, 13u8, 211u8, 114u8, 239u8, - 127u8, 75u8, 166u8, 234u8, 222u8, 225u8, 35u8, 160u8, 163u8, 112u8, - 242u8, + 203u8, 116u8, 217u8, 42u8, 154u8, 215u8, 77u8, 217u8, 13u8, 22u8, + 193u8, 2u8, 128u8, 115u8, 179u8, 115u8, 187u8, 218u8, 129u8, 34u8, + 80u8, 4u8, 173u8, 120u8, 92u8, 35u8, 237u8, 112u8, 201u8, 207u8, 200u8, + 48u8, ], ) } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The deposit needed for reserving an index."] - pub fn deposit(&self) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Indices", - "Deposit", + #[doc = "Make some on-chain remark and emit event."] + pub fn remark_with_event( + &self, + remark: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "remark_with_event", + types::RemarkWithEvent { remark }, [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 123u8, 225u8, 180u8, 179u8, 144u8, 74u8, 27u8, 85u8, 101u8, 75u8, + 134u8, 44u8, 181u8, 25u8, 183u8, 158u8, 14u8, 213u8, 56u8, 225u8, + 136u8, 88u8, 26u8, 114u8, 178u8, 43u8, 176u8, 43u8, 240u8, 84u8, 116u8, + 46u8, ], ) } } } - } - pub mod balances { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_balances::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; + #[doc = "Event for the System pallet."] + pub type Event = runtime_types::frame_system::pallet::Event; + pub mod events { use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferAllowDeath { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, - } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -4340,28 +4179,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetBalanceDeprecated { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub new_free: ::core::primitive::u128, - #[codec(compact)] - pub old_reserved: ::core::primitive::u128, + #[doc = "An extrinsic completed successfully."] + pub struct ExtrinsicSuccess { + pub dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceTransfer { - pub source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, + impl ::subxt::events::StaticEvent for ExtrinsicSuccess { + const PALLET: &'static str = "System"; + const EVENT: &'static str = "ExtrinsicSuccess"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -4373,24 +4197,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferKeepAlive { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, + #[doc = "An extrinsic failed."] + pub struct ExtrinsicFailed { + pub dispatch_error: runtime_types::sp_runtime::DispatchError, + pub dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferAll { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub keep_alive: ::core::primitive::bool, + impl ::subxt::events::StaticEvent for ExtrinsicFailed { + const PALLET: &'static str = "System"; + const EVENT: &'static str = "ExtrinsicFailed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -4402,9 +4216,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceUnreserve { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub amount: ::core::primitive::u128, + #[doc = "`:code` was updated."] + pub struct CodeUpdated; + impl ::subxt::events::StaticEvent for CodeUpdated { + const PALLET: &'static str = "System"; + const EVENT: &'static str = "CodeUpdated"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -4416,23 +4232,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UpgradeAccounts { - pub who: ::std::vec::Vec<::subxt::utils::AccountId32>, + #[doc = "A new account was created."] + pub struct NewAccount { + pub account: ::subxt::utils::AccountId32, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Transfer { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, + impl ::subxt::events::StaticEvent for NewAccount { + const PALLET: &'static str = "System"; + const EVENT: &'static str = "NewAccount"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -4444,23 +4250,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSetBalance { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub new_free: ::core::primitive::u128, + #[doc = "An account was reaped."] + pub struct KilledAccount { + pub account: ::subxt::utils::AccountId32, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UpgradeAccounts { - pub who: ::std::vec::Vec<::subxt::utils::AccountId32>, + impl ::subxt::events::StaticEvent for KilledAccount { + const PALLET: &'static str = "System"; + const EVENT: &'static str = "KilledAccount"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -4472,265 +4268,871 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Transfer { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, + #[doc = "On on-chain remark happened."] + pub struct Remarked { + pub sender: ::subxt::utils::AccountId32, + pub hash: ::subxt::utils::H256, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSetBalance { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub new_free: ::core::primitive::u128, + impl ::subxt::events::StaticEvent for Remarked { + const PALLET: &'static str = "System"; + const EVENT: &'static str = "Remarked"; } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Transfer some liquid free balance to another account."] - #[doc = ""] - #[doc = "`transfer_allow_death` will set the `FreeBalance` of the sender and receiver."] - #[doc = "If the sender's account is below the existential deposit as a result"] - #[doc = "of the transfer, the account will be reaped."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be `Signed` by the transactor."] - pub fn transfer_allow_death( + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The full account information for a particular account ID."] + pub fn account( &self, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "transfer_allow_death", - TransferAllowDeath { dest, value }, - [ - 234u8, 130u8, 149u8, 36u8, 235u8, 112u8, 159u8, 189u8, 104u8, 148u8, - 108u8, 230u8, 25u8, 198u8, 71u8, 158u8, 112u8, 3u8, 162u8, 25u8, 145u8, - 252u8, 44u8, 63u8, 47u8, 34u8, 47u8, 158u8, 61u8, 14u8, 120u8, 255u8, - ], - ) - } - #[doc = "Set the regular balance of a given account; it also takes a reserved balance but this"] - #[doc = "must be the same as the account's current reserved balance."] - #[doc = ""] - #[doc = "The dispatch origin for this call is `root`."] - #[doc = ""] - #[doc = "WARNING: This call is DEPRECATED! Use `force_set_balance` instead."] - pub fn set_balance_deprecated( + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::frame_system::AccountInfo< + ::core::primitive::u32, + runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "System", + "Account", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 248u8, 178u8, 160u8, 222u8, 45u8, 231u8, 115u8, 164u8, 98u8, 184u8, + 174u8, 206u8, 149u8, 190u8, 175u8, 34u8, 202u8, 230u8, 69u8, 218u8, + 83u8, 43u8, 170u8, 41u8, 106u8, 77u8, 233u8, 97u8, 114u8, 14u8, 155u8, + 131u8, + ], + ) + } + #[doc = " The full account information for a particular account ID."] + pub fn account_root( &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - new_free: ::core::primitive::u128, - old_reserved: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "set_balance_deprecated", - SetBalanceDeprecated { - who, - new_free, - old_reserved, - }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::frame_system::AccountInfo< + ::core::primitive::u32, + runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "System", + "Account", + Vec::new(), [ - 240u8, 107u8, 184u8, 206u8, 78u8, 106u8, 115u8, 152u8, 130u8, 56u8, - 156u8, 176u8, 105u8, 27u8, 176u8, 187u8, 49u8, 171u8, 229u8, 79u8, - 254u8, 248u8, 8u8, 162u8, 134u8, 12u8, 89u8, 100u8, 137u8, 102u8, - 132u8, 158u8, + 248u8, 178u8, 160u8, 222u8, 45u8, 231u8, 115u8, 164u8, 98u8, 184u8, + 174u8, 206u8, 149u8, 190u8, 175u8, 34u8, 202u8, 230u8, 69u8, 218u8, + 83u8, 43u8, 170u8, 41u8, 106u8, 77u8, 233u8, 97u8, 114u8, 14u8, 155u8, + 131u8, ], ) } - #[doc = "Exactly as `transfer_allow_death`, except the origin must be root and the source account"] - #[doc = "may be specified."] - pub fn force_transfer( + #[doc = " Total extrinsics count for the current block."] + pub fn extrinsic_count( &self, - source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "force_transfer", - types::ForceTransfer { - source, - dest, - value, - }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "ExtrinsicCount", + vec![], [ - 79u8, 174u8, 212u8, 108u8, 184u8, 33u8, 170u8, 29u8, 232u8, 254u8, - 195u8, 218u8, 221u8, 134u8, 57u8, 99u8, 6u8, 70u8, 181u8, 227u8, 56u8, - 239u8, 243u8, 158u8, 157u8, 245u8, 36u8, 162u8, 11u8, 237u8, 147u8, - 15u8, + 223u8, 60u8, 201u8, 120u8, 36u8, 44u8, 180u8, 210u8, 242u8, 53u8, + 222u8, 154u8, 123u8, 176u8, 249u8, 8u8, 225u8, 28u8, 232u8, 4u8, 136u8, + 41u8, 151u8, 82u8, 189u8, 149u8, 49u8, 166u8, 139u8, 9u8, 163u8, 231u8, ], ) } - #[doc = "Same as the [`transfer_allow_death`] call, but with a check that the transfer will not"] - #[doc = "kill the origin account."] - #[doc = ""] - #[doc = "99% of the time you want [`transfer_allow_death`] instead."] - #[doc = ""] - #[doc = "[`transfer_allow_death`]: struct.Pallet.html#method.transfer"] - pub fn transfer_keep_alive( + #[doc = " The current weight for the block."] + pub fn block_weight( &self, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "transfer_keep_alive", - types::TransferKeepAlive { dest, value }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::frame_support::dispatch::PerDispatchClass< + runtime_types::sp_weights::weight_v2::Weight, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "BlockWeight", + vec![], [ - 112u8, 179u8, 75u8, 168u8, 193u8, 221u8, 9u8, 82u8, 190u8, 113u8, - 253u8, 13u8, 130u8, 134u8, 170u8, 216u8, 136u8, 111u8, 242u8, 220u8, - 202u8, 112u8, 47u8, 79u8, 73u8, 244u8, 226u8, 59u8, 240u8, 188u8, - 210u8, 208u8, + 120u8, 67u8, 71u8, 163u8, 36u8, 202u8, 52u8, 106u8, 143u8, 155u8, + 144u8, 87u8, 142u8, 241u8, 232u8, 183u8, 56u8, 235u8, 27u8, 237u8, + 20u8, 202u8, 33u8, 85u8, 189u8, 0u8, 28u8, 52u8, 198u8, 40u8, 219u8, + 54u8, ], ) } - #[doc = "Transfer the entire transferable balance from the caller account."] - #[doc = ""] - #[doc = "NOTE: This function only attempts to transfer _transferable_ balances. This means that"] - #[doc = "any locked, reserved, or existential deposits (when `keep_alive` is `true`), will not be"] - #[doc = "transferred by this function. To ensure that this function results in a killed account,"] - #[doc = "you might need to prepare the account by removing any reference counters, storage"] - #[doc = "deposits, etc..."] + #[doc = " Total length (in bytes) for all extrinsics put together, for the current block."] + pub fn all_extrinsics_len( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "AllExtrinsicsLen", + vec![], + [ + 202u8, 145u8, 209u8, 225u8, 40u8, 220u8, 174u8, 74u8, 93u8, 164u8, + 254u8, 248u8, 254u8, 192u8, 32u8, 117u8, 96u8, 149u8, 53u8, 145u8, + 219u8, 64u8, 234u8, 18u8, 217u8, 200u8, 203u8, 141u8, 145u8, 28u8, + 134u8, 60u8, + ], + ) + } + #[doc = " Map of block numbers to block hashes."] + pub fn block_hash( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "System", + "BlockHash", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 50u8, 112u8, 176u8, 239u8, 175u8, 18u8, 205u8, 20u8, 241u8, 195u8, + 21u8, 228u8, 186u8, 57u8, 200u8, 25u8, 38u8, 44u8, 106u8, 20u8, 168u8, + 80u8, 76u8, 235u8, 12u8, 51u8, 137u8, 149u8, 200u8, 4u8, 220u8, 237u8, + ], + ) + } + #[doc = " Map of block numbers to block hashes."] + pub fn block_hash_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "System", + "BlockHash", + Vec::new(), + [ + 50u8, 112u8, 176u8, 239u8, 175u8, 18u8, 205u8, 20u8, 241u8, 195u8, + 21u8, 228u8, 186u8, 57u8, 200u8, 25u8, 38u8, 44u8, 106u8, 20u8, 168u8, + 80u8, 76u8, 235u8, 12u8, 51u8, 137u8, 149u8, 200u8, 4u8, 220u8, 237u8, + ], + ) + } + #[doc = " Extrinsics data for the current block (maps an extrinsic's index to its data)."] + pub fn extrinsic_data( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "System", + "ExtrinsicData", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 210u8, 224u8, 211u8, 186u8, 118u8, 210u8, 185u8, 194u8, 238u8, 211u8, + 254u8, 73u8, 67u8, 184u8, 31u8, 229u8, 168u8, 125u8, 98u8, 23u8, 241u8, + 59u8, 49u8, 86u8, 126u8, 9u8, 114u8, 163u8, 160u8, 62u8, 50u8, 67u8, + ], + ) + } + #[doc = " Extrinsics data for the current block (maps an extrinsic's index to its data)."] + pub fn extrinsic_data_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "System", + "ExtrinsicData", + Vec::new(), + [ + 210u8, 224u8, 211u8, 186u8, 118u8, 210u8, 185u8, 194u8, 238u8, 211u8, + 254u8, 73u8, 67u8, 184u8, 31u8, 229u8, 168u8, 125u8, 98u8, 23u8, 241u8, + 59u8, 49u8, 86u8, 126u8, 9u8, 114u8, 163u8, 160u8, 62u8, 50u8, 67u8, + ], + ) + } + #[doc = " The current block number being processed. Set by `execute_block`."] + pub fn number( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "Number", + vec![], + [ + 228u8, 96u8, 102u8, 190u8, 252u8, 130u8, 239u8, 172u8, 126u8, 235u8, + 246u8, 139u8, 208u8, 15u8, 88u8, 245u8, 141u8, 232u8, 43u8, 204u8, + 36u8, 87u8, 211u8, 141u8, 187u8, 68u8, 236u8, 70u8, 193u8, 235u8, + 164u8, 191u8, + ], + ) + } + #[doc = " Hash of the previous block."] + pub fn parent_hash( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "ParentHash", + vec![], + [ + 232u8, 206u8, 177u8, 119u8, 38u8, 57u8, 233u8, 50u8, 225u8, 49u8, + 169u8, 176u8, 210u8, 51u8, 231u8, 176u8, 234u8, 186u8, 188u8, 112u8, + 15u8, 152u8, 195u8, 232u8, 201u8, 97u8, 208u8, 249u8, 9u8, 163u8, 69u8, + 36u8, + ], + ) + } + #[doc = " Digest of the current block, also part of the block header."] + pub fn digest( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_runtime::generic::digest::Digest, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "Digest", + vec![], + [ + 83u8, 141u8, 200u8, 132u8, 182u8, 55u8, 197u8, 122u8, 13u8, 159u8, + 31u8, 42u8, 60u8, 191u8, 89u8, 221u8, 242u8, 47u8, 199u8, 213u8, 48u8, + 216u8, 131u8, 168u8, 245u8, 82u8, 56u8, 190u8, 62u8, 69u8, 96u8, 37u8, + ], + ) + } + #[doc = " Events deposited for the current block."] #[doc = ""] - #[doc = "The dispatch origin of this call must be Signed."] + #[doc = " NOTE: The item is unbound and should therefore never be read on chain."] + #[doc = " It could otherwise inflate the PoV size of a block."] #[doc = ""] - #[doc = "- `dest`: The recipient of the transfer."] - #[doc = "- `keep_alive`: A boolean to determine if the `transfer_all` operation should send all"] - #[doc = " of the funds the account has, causing the sender account to be killed (false), or"] - #[doc = " transfer everything except at least the existential deposit, which will guarantee to"] - #[doc = " keep the sender account alive (true)."] - pub fn transfer_all( + #[doc = " Events have a large in-memory size. Box the events to not go out-of-memory"] + #[doc = " just in case someone still reads them from within the runtime."] + pub fn events( &self, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - keep_alive: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "transfer_all", - types::TransferAll { dest, keep_alive }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec< + runtime_types::frame_system::EventRecord< + runtime_types::polkadot_runtime::RuntimeEvent, + ::subxt::utils::H256, + >, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "Events", + vec![], [ - 46u8, 129u8, 29u8, 177u8, 221u8, 107u8, 245u8, 69u8, 238u8, 126u8, - 145u8, 26u8, 219u8, 208u8, 14u8, 80u8, 149u8, 1u8, 214u8, 63u8, 67u8, - 201u8, 144u8, 45u8, 129u8, 145u8, 174u8, 71u8, 238u8, 113u8, 208u8, - 34u8, + 78u8, 158u8, 91u8, 165u8, 29u8, 179u8, 204u8, 195u8, 39u8, 3u8, 127u8, + 199u8, 132u8, 93u8, 252u8, 17u8, 84u8, 58u8, 51u8, 56u8, 159u8, 51u8, + 188u8, 138u8, 75u8, 109u8, 148u8, 73u8, 227u8, 56u8, 162u8, 246u8, ], ) } - #[doc = "Unreserve some balance from a user by force."] - #[doc = ""] - #[doc = "Can only be called by ROOT."] - pub fn force_unreserve( + #[doc = " The number of events in the `Events` list."] + pub fn event_count( &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - amount: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "force_unreserve", - types::ForceUnreserve { who, amount }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "EventCount", + vec![], [ - 160u8, 146u8, 137u8, 76u8, 157u8, 187u8, 66u8, 148u8, 207u8, 76u8, - 32u8, 254u8, 82u8, 215u8, 35u8, 161u8, 213u8, 52u8, 32u8, 98u8, 102u8, - 106u8, 234u8, 123u8, 6u8, 175u8, 184u8, 188u8, 174u8, 106u8, 176u8, - 78u8, + 236u8, 93u8, 90u8, 177u8, 250u8, 211u8, 138u8, 187u8, 26u8, 208u8, + 203u8, 113u8, 221u8, 233u8, 227u8, 9u8, 249u8, 25u8, 202u8, 185u8, + 161u8, 144u8, 167u8, 104u8, 127u8, 187u8, 38u8, 18u8, 52u8, 61u8, 66u8, + 112u8, ], ) } - #[doc = "Upgrade a specified account."] + #[doc = " Mapping between a topic (represented by T::Hash) and a vector of indexes"] + #[doc = " of events in the `>` list."] #[doc = ""] - #[doc = "- `origin`: Must be `Signed`."] - #[doc = "- `who`: The account to be upgraded."] + #[doc = " All topic vectors have deterministic storage locations depending on the topic. This"] + #[doc = " allows light-clients to leverage the changes trie storage tracking mechanism and"] + #[doc = " in case of changes fetch the list of events of interest."] #[doc = ""] - #[doc = "This will waive the transaction fee if at least all but 10% of the accounts needed to"] - #[doc = "be upgraded. (We let some not have to be upgraded just in order to allow for the"] - #[doc = "possibililty of churn)."] - pub fn upgrade_accounts( + #[doc = " The value has the type `(T::BlockNumber, EventIndex)` because if we used only just"] + #[doc = " the `EventIndex` then in case if the topic has the same contents on the next block"] + #[doc = " no notification will be triggered thus the event might be lost."] + pub fn event_topics( &self, - who: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "upgrade_accounts", - UpgradeAccounts { who }, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::u32)>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "System", + "EventTopics", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 164u8, 61u8, 119u8, 24u8, 165u8, 46u8, 197u8, 59u8, 39u8, 198u8, 228u8, - 96u8, 228u8, 45u8, 85u8, 51u8, 37u8, 5u8, 75u8, 40u8, 241u8, 163u8, - 86u8, 228u8, 151u8, 217u8, 47u8, 105u8, 203u8, 103u8, 207u8, 4u8, + 205u8, 90u8, 142u8, 190u8, 176u8, 37u8, 94u8, 82u8, 98u8, 1u8, 129u8, + 63u8, 246u8, 101u8, 130u8, 58u8, 216u8, 16u8, 139u8, 196u8, 154u8, + 111u8, 110u8, 178u8, 24u8, 44u8, 183u8, 176u8, 232u8, 82u8, 223u8, + 38u8, ], ) } - #[doc = "Alias for `transfer_allow_death`, provided only for name-wise compatibility."] + #[doc = " Mapping between a topic (represented by T::Hash) and a vector of indexes"] + #[doc = " of events in the `>` list."] #[doc = ""] - #[doc = "WARNING: DEPRECATED! Will be released in approximately 3 months."] - pub fn transfer( + #[doc = " All topic vectors have deterministic storage locations depending on the topic. This"] + #[doc = " allows light-clients to leverage the changes trie storage tracking mechanism and"] + #[doc = " in case of changes fetch the list of events of interest."] + #[doc = ""] + #[doc = " The value has the type `(T::BlockNumber, EventIndex)` because if we used only just"] + #[doc = " the `EventIndex` then in case if the topic has the same contents on the next block"] + #[doc = " no notification will be triggered thus the event might be lost."] + pub fn event_topics_root( &self, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "transfer", - Transfer { dest, value }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::u32)>, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "System", + "EventTopics", + Vec::new(), [ - 111u8, 222u8, 32u8, 56u8, 171u8, 77u8, 252u8, 29u8, 194u8, 155u8, - 200u8, 192u8, 198u8, 81u8, 23u8, 115u8, 236u8, 91u8, 218u8, 114u8, - 107u8, 141u8, 138u8, 100u8, 237u8, 21u8, 58u8, 172u8, 3u8, 20u8, 216u8, + 205u8, 90u8, 142u8, 190u8, 176u8, 37u8, 94u8, 82u8, 98u8, 1u8, 129u8, + 63u8, 246u8, 101u8, 130u8, 58u8, 216u8, 16u8, 139u8, 196u8, 154u8, + 111u8, 110u8, 178u8, 24u8, 44u8, 183u8, 176u8, 232u8, 82u8, 223u8, 38u8, ], ) } - #[doc = "Set the regular balance of a given account."] - #[doc = ""] - #[doc = "The dispatch origin for this call is `root`."] - pub fn force_set_balance( + #[doc = " Stores the `spec_version` and `spec_name` of when the last runtime upgrade happened."] + pub fn last_runtime_upgrade( &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - new_free: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "force_set_balance", - ForceSetBalance { who, new_free }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::frame_system::LastRuntimeUpgradeInfo, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "LastRuntimeUpgrade", + vec![], [ - 237u8, 4u8, 41u8, 58u8, 62u8, 179u8, 160u8, 4u8, 50u8, 71u8, 178u8, - 36u8, 130u8, 130u8, 92u8, 229u8, 16u8, 245u8, 169u8, 109u8, 165u8, - 72u8, 94u8, 70u8, 196u8, 136u8, 37u8, 94u8, 140u8, 215u8, 125u8, 125u8, + 52u8, 37u8, 117u8, 111u8, 57u8, 130u8, 196u8, 14u8, 99u8, 77u8, 91u8, + 126u8, 178u8, 249u8, 78u8, 34u8, 9u8, 194u8, 92u8, 105u8, 113u8, 81u8, + 185u8, 127u8, 245u8, 184u8, 60u8, 29u8, 234u8, 182u8, 96u8, 196u8, + ], + ) + } + #[doc = " True if we have upgraded so that `type RefCount` is `u32`. False (default) if not."] + pub fn upgraded_to_u32_ref_count( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "UpgradedToU32RefCount", + vec![], + [ + 171u8, 88u8, 244u8, 92u8, 122u8, 67u8, 27u8, 18u8, 59u8, 175u8, 175u8, + 178u8, 20u8, 150u8, 213u8, 59u8, 222u8, 141u8, 32u8, 107u8, 3u8, 114u8, + 83u8, 250u8, 180u8, 233u8, 152u8, 54u8, 187u8, 99u8, 131u8, 204u8, + ], + ) + } + #[doc = " True if we have upgraded so that AccountInfo contains three types of `RefCount`. False"] + #[doc = " (default) if not."] + pub fn upgraded_to_triple_ref_count( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "UpgradedToTripleRefCount", + vec![], + [ + 90u8, 33u8, 56u8, 86u8, 90u8, 101u8, 89u8, 133u8, 203u8, 56u8, 201u8, + 210u8, 244u8, 232u8, 150u8, 18u8, 51u8, 105u8, 14u8, 230u8, 103u8, + 155u8, 246u8, 99u8, 53u8, 207u8, 225u8, 128u8, 186u8, 76u8, 40u8, + 185u8, + ], + ) + } + #[doc = " The execution phase of the block."] + pub fn execution_phase( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::frame_system::Phase, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "ExecutionPhase", + vec![], + [ + 230u8, 183u8, 221u8, 135u8, 226u8, 223u8, 55u8, 104u8, 138u8, 224u8, + 103u8, 156u8, 222u8, 99u8, 203u8, 199u8, 164u8, 168u8, 193u8, 133u8, + 201u8, 155u8, 63u8, 95u8, 17u8, 206u8, 165u8, 123u8, 161u8, 33u8, + 172u8, 93u8, ], ) } } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_balances::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was created with some free balance."] - pub struct Endowed { - pub account: ::subxt::utils::AccountId32, - pub free_balance: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Endowed { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Endowed"; + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " Block & extrinsics weights: base values and limits."] + pub fn block_weights( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "System", + "BlockWeights", + [ + 118u8, 253u8, 239u8, 217u8, 145u8, 115u8, 85u8, 86u8, 172u8, 248u8, + 139u8, 32u8, 158u8, 126u8, 172u8, 188u8, 197u8, 105u8, 145u8, 235u8, + 171u8, 50u8, 31u8, 225u8, 167u8, 187u8, 241u8, 87u8, 6u8, 17u8, 234u8, + 185u8, + ], + ) + } + #[doc = " The maximum length of a block (in bytes)."] + pub fn block_length( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "System", + "BlockLength", + [ + 116u8, 184u8, 225u8, 228u8, 207u8, 203u8, 4u8, 220u8, 234u8, 198u8, + 150u8, 108u8, 205u8, 87u8, 194u8, 131u8, 229u8, 51u8, 140u8, 4u8, 47u8, + 12u8, 200u8, 144u8, 153u8, 62u8, 51u8, 39u8, 138u8, 205u8, 203u8, + 236u8, + ], + ) + } + #[doc = " Maximum number of block number to block hash mappings to keep (oldest pruned first)."] + pub fn block_hash_count( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "System", + "BlockHashCount", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The weight of runtime database operations the runtime can invoke."] + pub fn db_weight( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "System", + "DbWeight", + [ + 124u8, 162u8, 190u8, 149u8, 49u8, 177u8, 162u8, 231u8, 62u8, 167u8, + 199u8, 181u8, 43u8, 232u8, 185u8, 116u8, 195u8, 51u8, 233u8, 223u8, + 20u8, 129u8, 246u8, 13u8, 65u8, 180u8, 64u8, 9u8, 157u8, 59u8, 245u8, + 118u8, + ], + ) + } + #[doc = " Get the chain's current version."] + pub fn version( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "System", + "Version", + [ + 93u8, 98u8, 57u8, 243u8, 229u8, 8u8, 234u8, 231u8, 72u8, 230u8, 139u8, + 47u8, 63u8, 181u8, 17u8, 2u8, 220u8, 231u8, 104u8, 237u8, 185u8, 143u8, + 165u8, 253u8, 188u8, 76u8, 147u8, 12u8, 170u8, 26u8, 74u8, 200u8, + ], + ) + } + #[doc = " The designated SS58 prefix of this chain."] + #[doc = ""] + #[doc = " This replaces the \"ss58Format\" property declared in the chain spec. Reason is"] + #[doc = " that the runtime should know about the prefix in order to make use of it as"] + #[doc = " an identifier of the chain."] + pub fn ss58_prefix(&self) -> ::subxt::constants::Address<::core::primitive::u16> { + ::subxt::constants::Address::new_static( + "System", + "SS58Prefix", + [ + 116u8, 33u8, 2u8, 170u8, 181u8, 147u8, 171u8, 169u8, 167u8, 227u8, + 41u8, 144u8, 11u8, 236u8, 82u8, 100u8, 74u8, 60u8, 184u8, 72u8, 169u8, + 90u8, 208u8, 135u8, 15u8, 117u8, 10u8, 123u8, 128u8, 193u8, 29u8, 70u8, + ], + ) + } + } + } + } + pub mod scheduler { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_scheduler::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Schedule { + pub when: ::core::primitive::u32, + pub maybe_periodic: + ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, + pub priority: ::core::primitive::u8, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Cancel { + pub when: ::core::primitive::u32, + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ScheduleNamed { + pub id: [::core::primitive::u8; 32usize], + pub when: ::core::primitive::u32, + pub maybe_periodic: + ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, + pub priority: ::core::primitive::u8, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelNamed { + pub id: [::core::primitive::u8; 32usize], + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ScheduleAfter { + pub after: ::core::primitive::u32, + pub maybe_periodic: + ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, + pub priority: ::core::primitive::u8, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ScheduleNamedAfter { + pub id: [::core::primitive::u8; 32usize], + pub after: ::core::primitive::u32, + pub maybe_periodic: + ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, + pub priority: ::core::primitive::u8, + pub call: ::std::boxed::Box, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Anonymously schedule a task."] + pub fn schedule( + &self, + when: ::core::primitive::u32, + maybe_periodic: ::core::option::Option<( + ::core::primitive::u32, + ::core::primitive::u32, + )>, + priority: ::core::primitive::u8, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Scheduler", + "schedule", + types::Schedule { + when, + maybe_periodic, + priority, + call: ::std::boxed::Box::new(call), + }, + [ + 225u8, 142u8, 54u8, 240u8, 129u8, 69u8, 56u8, 230u8, 207u8, 110u8, + 78u8, 150u8, 87u8, 254u8, 95u8, 73u8, 74u8, 204u8, 165u8, 239u8, 246u8, + 132u8, 251u8, 183u8, 36u8, 102u8, 236u8, 244u8, 201u8, 2u8, 233u8, + 255u8, + ], + ) + } + #[doc = "Cancel an anonymously scheduled task."] + pub fn cancel( + &self, + when: ::core::primitive::u32, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Scheduler", + "cancel", + types::Cancel { when, index }, + [ + 81u8, 251u8, 234u8, 17u8, 214u8, 75u8, 19u8, 59u8, 19u8, 30u8, 89u8, + 74u8, 6u8, 216u8, 238u8, 165u8, 7u8, 19u8, 153u8, 253u8, 161u8, 103u8, + 178u8, 227u8, 152u8, 180u8, 80u8, 156u8, 82u8, 126u8, 132u8, 120u8, + ], + ) + } + #[doc = "Schedule a named task."] + pub fn schedule_named( + &self, + id: [::core::primitive::u8; 32usize], + when: ::core::primitive::u32, + maybe_periodic: ::core::option::Option<( + ::core::primitive::u32, + ::core::primitive::u32, + )>, + priority: ::core::primitive::u8, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Scheduler", + "schedule_named", + types::ScheduleNamed { + id, + when, + maybe_periodic, + priority, + call: ::std::boxed::Box::new(call), + }, + [ + 158u8, 202u8, 183u8, 44u8, 48u8, 102u8, 44u8, 53u8, 74u8, 193u8, 176u8, + 21u8, 240u8, 144u8, 135u8, 240u8, 87u8, 70u8, 132u8, 36u8, 229u8, + 233u8, 249u8, 55u8, 129u8, 81u8, 37u8, 193u8, 207u8, 252u8, 49u8, + 165u8, + ], + ) + } + #[doc = "Cancel a named scheduled task."] + pub fn cancel_named( + &self, + id: [::core::primitive::u8; 32usize], + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Scheduler", + "cancel_named", + types::CancelNamed { id }, + [ + 51u8, 3u8, 140u8, 50u8, 214u8, 211u8, 50u8, 4u8, 19u8, 43u8, 230u8, + 114u8, 18u8, 108u8, 138u8, 67u8, 99u8, 24u8, 255u8, 11u8, 246u8, 37u8, + 192u8, 207u8, 90u8, 157u8, 171u8, 93u8, 233u8, 189u8, 64u8, 180u8, + ], + ) + } + #[doc = "Anonymously schedule a task after a delay."] + pub fn schedule_after( + &self, + after: ::core::primitive::u32, + maybe_periodic: ::core::option::Option<( + ::core::primitive::u32, + ::core::primitive::u32, + )>, + priority: ::core::primitive::u8, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Scheduler", + "schedule_after", + types::ScheduleAfter { + after, + maybe_periodic, + priority, + call: ::std::boxed::Box::new(call), + }, + [ + 73u8, 79u8, 70u8, 138u8, 189u8, 239u8, 243u8, 180u8, 250u8, 183u8, + 246u8, 40u8, 204u8, 164u8, 154u8, 219u8, 87u8, 144u8, 44u8, 185u8, + 181u8, 130u8, 147u8, 11u8, 156u8, 54u8, 201u8, 207u8, 238u8, 76u8, + 61u8, 179u8, + ], + ) + } + #[doc = "Schedule a named task after a delay."] + pub fn schedule_named_after( + &self, + id: [::core::primitive::u8; 32usize], + after: ::core::primitive::u32, + maybe_periodic: ::core::option::Option<( + ::core::primitive::u32, + ::core::primitive::u32, + )>, + priority: ::core::primitive::u8, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Scheduler", + "schedule_named_after", + types::ScheduleNamedAfter { + id, + after, + maybe_periodic, + priority, + call: ::std::boxed::Box::new(call), + }, + [ + 158u8, 154u8, 219u8, 160u8, 184u8, 209u8, 41u8, 234u8, 126u8, 157u8, + 63u8, 92u8, 143u8, 2u8, 82u8, 145u8, 45u8, 145u8, 148u8, 27u8, 48u8, + 255u8, 95u8, 70u8, 182u8, 146u8, 199u8, 252u8, 87u8, 105u8, 12u8, + 187u8, + ], + ) + } } + } + #[doc = "Events type."] + pub type Event = runtime_types::pallet_scheduler::pallet::Event; + pub mod events { + use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -4741,15 +5143,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was removed whose balance was non-zero but below ExistentialDeposit,"] - #[doc = "resulting in an outright loss."] - pub struct DustLost { - pub account: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, + #[doc = "Scheduled some task."] + pub struct Scheduled { + pub when: ::core::primitive::u32, + pub index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for DustLost { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "DustLost"; + impl ::subxt::events::StaticEvent for Scheduled { + const PALLET: &'static str = "Scheduler"; + const EVENT: &'static str = "Scheduled"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -4761,15 +5162,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Transfer succeeded."] - pub struct Transfer { - pub from: ::subxt::utils::AccountId32, - pub to: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, + #[doc = "Canceled some task."] + pub struct Canceled { + pub when: ::core::primitive::u32, + pub index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for Transfer { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Transfer"; + impl ::subxt::events::StaticEvent for Canceled { + const PALLET: &'static str = "Scheduler"; + const EVENT: &'static str = "Canceled"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -4781,14 +5181,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A balance was set by root."] - pub struct BalanceSet { - pub who: ::subxt::utils::AccountId32, - pub free: ::core::primitive::u128, + #[doc = "Dispatched some task."] + pub struct Dispatched { + pub task: (::core::primitive::u32, ::core::primitive::u32), + pub id: ::core::option::Option<[::core::primitive::u8; 32usize]>, + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, } - impl ::subxt::events::StaticEvent for BalanceSet { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "BalanceSet"; + impl ::subxt::events::StaticEvent for Dispatched { + const PALLET: &'static str = "Scheduler"; + const EVENT: &'static str = "Dispatched"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -4800,14 +5201,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was reserved (moved from free to reserved)."] - pub struct Reserved { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, + #[doc = "The call for the provided hash was not found so the task has been aborted."] + pub struct CallUnavailable { + pub task: (::core::primitive::u32, ::core::primitive::u32), + pub id: ::core::option::Option<[::core::primitive::u8; 32usize]>, } - impl ::subxt::events::StaticEvent for Reserved { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Reserved"; + impl ::subxt::events::StaticEvent for CallUnavailable { + const PALLET: &'static str = "Scheduler"; + const EVENT: &'static str = "CallUnavailable"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -4819,283 +5220,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was unreserved (moved from reserved to free)."] - pub struct Unreserved { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Unreserved { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Unreserved"; + #[doc = "The given task was unable to be renewed since the agenda is full at that block."] + pub struct PeriodicFailed { + pub task: (::core::primitive::u32, ::core::primitive::u32), + pub id: ::core::option::Option<[::core::primitive::u8; 32usize]>, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was moved from the reserve of the first account to the second account."] - #[doc = "Final argument indicates the destination balance type."] - pub struct ReserveRepatriated { - pub from: ::subxt::utils::AccountId32, - pub to: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - pub destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - } - impl ::subxt::events::StaticEvent for ReserveRepatriated { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "ReserveRepatriated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was deposited (e.g. for transaction fees)."] - pub struct Deposit { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Deposit { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Deposit"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was withdrawn from the account (e.g. for transaction fees)."] - pub struct Withdraw { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Withdraw { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Withdraw"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was removed from the account (e.g. for misbehavior)."] - pub struct Slashed { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Slashed { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Slashed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was minted into an account."] - pub struct Minted { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Minted { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Minted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was burned from an account."] - pub struct Burned { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Burned { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Burned"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was suspended from an account (it can be restored later)."] - pub struct Suspended { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Suspended { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Suspended"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was restored into an account."] - pub struct Restored { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Restored { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Restored"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was upgraded."] - pub struct Upgraded { - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Upgraded { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Upgraded"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Total issuance was increased by `amount`, creating a credit to be balanced."] - pub struct Issued { - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Issued { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Issued"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Total issuance was decreased by `amount`, creating a debt to be balanced."] - pub struct Rescinded { - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Rescinded { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Rescinded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was locked."] - pub struct Locked { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Locked { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Locked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was unlocked."] - pub struct Unlocked { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Unlocked { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Unlocked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was frozen."] - pub struct Frozen { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Frozen { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Frozen"; + impl ::subxt::events::StaticEvent for PeriodicFailed { + const PALLET: &'static str = "Scheduler"; + const EVENT: &'static str = "PeriodicFailed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -5107,460 +5239,357 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was thawed."] - pub struct Thawed { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, + #[doc = "The given task can never be executed since it is overweight."] + pub struct PermanentlyOverweight { + pub task: (::core::primitive::u32, ::core::primitive::u32), + pub id: ::core::option::Option<[::core::primitive::u8; 32usize]>, } - impl ::subxt::events::StaticEvent for Thawed { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Thawed"; + impl ::subxt::events::StaticEvent for PermanentlyOverweight { + const PALLET: &'static str = "Scheduler"; + const EVENT: &'static str = "PermanentlyOverweight"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " The total units issued in the system."] - pub fn total_issuance( + pub fn incomplete_since( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, + ::core::primitive::u32, ::subxt::storage::address::Yes, (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "TotalIssuance", - vec![], - [ - 1u8, 206u8, 252u8, 237u8, 6u8, 30u8, 20u8, 232u8, 164u8, 115u8, 51u8, - 156u8, 156u8, 206u8, 241u8, 187u8, 44u8, 84u8, 25u8, 164u8, 235u8, - 20u8, 86u8, 242u8, 124u8, 23u8, 28u8, 140u8, 26u8, 73u8, 231u8, 51u8, - ], - ) - } - #[doc = " The total units of outstanding deactivated balance in the system."] - pub fn inactive_issuance( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "Balances", - "InactiveIssuance", + "Scheduler", + "IncompleteSince", vec![], [ - 74u8, 203u8, 111u8, 142u8, 225u8, 104u8, 173u8, 51u8, 226u8, 12u8, - 85u8, 135u8, 41u8, 206u8, 177u8, 238u8, 94u8, 246u8, 184u8, 250u8, - 140u8, 213u8, 91u8, 118u8, 163u8, 111u8, 211u8, 46u8, 204u8, 160u8, - 154u8, 21u8, + 149u8, 66u8, 239u8, 67u8, 235u8, 219u8, 101u8, 182u8, 145u8, 56u8, + 252u8, 150u8, 253u8, 221u8, 125u8, 57u8, 38u8, 152u8, 153u8, 31u8, + 92u8, 238u8, 66u8, 246u8, 104u8, 163u8, 94u8, 73u8, 222u8, 168u8, + 193u8, 227u8, ], ) } - #[doc = " The Balances pallet example of storing the balance of an account."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = StorageMapShim, frame_system::Provider, AccountId, Self::AccountData>"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " You can also store the balance of an account in the `System` pallet."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = System"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " But this comes with tradeoffs, storing account balances in the system pallet stores"] - #[doc = " `frame_system` data alongside the account data contrary to storing account balances in the"] - #[doc = " `Balances` pallet, which uses a `StorageMap` to store balances data only."] - #[doc = " NOTE: This is only used in the case that this pallet is used to store balances."] - pub fn account( + #[doc = " Items to be executed, indexed by the block number that they should be executed on."] + pub fn agenda( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::option::Option< + runtime_types::pallet_scheduler::Scheduled< + [::core::primitive::u8; 32usize], + runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + ::core::primitive::u32, + runtime_types::polkadot_runtime::OriginCaller, + ::subxt::utils::AccountId32, + >, + >, + >, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Balances", - "Account", + "Scheduler", + "Agenda", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 109u8, 250u8, 18u8, 96u8, 139u8, 232u8, 4u8, 139u8, 133u8, 239u8, 30u8, - 237u8, 73u8, 209u8, 143u8, 160u8, 94u8, 248u8, 124u8, 43u8, 224u8, - 165u8, 11u8, 6u8, 176u8, 144u8, 189u8, 161u8, 174u8, 210u8, 56u8, - 225u8, + 130u8, 206u8, 243u8, 81u8, 169u8, 223u8, 74u8, 102u8, 75u8, 207u8, + 232u8, 175u8, 233u8, 167u8, 109u8, 190u8, 242u8, 24u8, 203u8, 144u8, + 31u8, 68u8, 147u8, 110u8, 77u8, 175u8, 2u8, 129u8, 127u8, 198u8, 49u8, + 151u8, ], ) } - #[doc = " The Balances pallet example of storing the balance of an account."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = StorageMapShim, frame_system::Provider, AccountId, Self::AccountData>"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " You can also store the balance of an account in the `System` pallet."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = System"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " But this comes with tradeoffs, storing account balances in the system pallet stores"] - #[doc = " `frame_system` data alongside the account data contrary to storing account balances in the"] - #[doc = " `Balances` pallet, which uses a `StorageMap` to store balances data only."] - #[doc = " NOTE: This is only used in the case that this pallet is used to store balances."] - pub fn account_root( + #[doc = " Items to be executed, indexed by the block number that they should be executed on."] + pub fn agenda_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::option::Option< + runtime_types::pallet_scheduler::Scheduled< + [::core::primitive::u8; 32usize], + runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + ::core::primitive::u32, + runtime_types::polkadot_runtime::OriginCaller, + ::subxt::utils::AccountId32, + >, + >, + >, (), ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Balances", - "Account", + "Scheduler", + "Agenda", Vec::new(), [ - 109u8, 250u8, 18u8, 96u8, 139u8, 232u8, 4u8, 139u8, 133u8, 239u8, 30u8, - 237u8, 73u8, 209u8, 143u8, 160u8, 94u8, 248u8, 124u8, 43u8, 224u8, - 165u8, 11u8, 6u8, 176u8, 144u8, 189u8, 161u8, 174u8, 210u8, 56u8, - 225u8, + 130u8, 206u8, 243u8, 81u8, 169u8, 223u8, 74u8, 102u8, 75u8, 207u8, + 232u8, 175u8, 233u8, 167u8, 109u8, 190u8, 242u8, 24u8, 203u8, 144u8, + 31u8, 68u8, 147u8, 110u8, 77u8, 175u8, 2u8, 129u8, 127u8, 198u8, 49u8, + 151u8, ], ) } - #[doc = " Any liquidity locks on some account balances."] - #[doc = " NOTE: Should only be accessed when setting, changing and freeing a lock."] - pub fn locks( + #[doc = " Lookup from a name to the block number and index of the task."] + #[doc = ""] + #[doc = " For v3 -> v4 the previously unbounded identities are Blake2-256 hashed to form the v4"] + #[doc = " identities."] + pub fn lookup( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _0: impl ::std::borrow::Borrow<[::core::primitive::u8; 32usize]>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, - >, - ::subxt::storage::address::Yes, + (::core::primitive::u32, ::core::primitive::u32), ::subxt::storage::address::Yes, + (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Balances", - "Locks", + "Scheduler", + "Lookup", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 216u8, 253u8, 87u8, 73u8, 24u8, 218u8, 35u8, 0u8, 244u8, 134u8, 195u8, - 58u8, 255u8, 64u8, 153u8, 212u8, 210u8, 232u8, 4u8, 122u8, 90u8, 212u8, - 136u8, 14u8, 127u8, 232u8, 8u8, 192u8, 40u8, 233u8, 18u8, 250u8, + 82u8, 20u8, 178u8, 101u8, 108u8, 198u8, 71u8, 99u8, 16u8, 175u8, 15u8, + 187u8, 229u8, 243u8, 140u8, 200u8, 99u8, 77u8, 248u8, 178u8, 45u8, + 121u8, 193u8, 67u8, 165u8, 43u8, 234u8, 211u8, 158u8, 250u8, 103u8, + 243u8, ], ) } - #[doc = " Any liquidity locks on some account balances."] - #[doc = " NOTE: Should only be accessed when setting, changing and freeing a lock."] - pub fn locks_root( + #[doc = " Lookup from a name to the block number and index of the task."] + #[doc = ""] + #[doc = " For v3 -> v4 the previously unbounded identities are Blake2-256 hashed to form the v4"] + #[doc = " identities."] + pub fn lookup_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, - >, + (::core::primitive::u32, ::core::primitive::u32), + (), (), - ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Balances", - "Locks", + "Scheduler", + "Lookup", Vec::new(), [ - 216u8, 253u8, 87u8, 73u8, 24u8, 218u8, 35u8, 0u8, 244u8, 134u8, 195u8, - 58u8, 255u8, 64u8, 153u8, 212u8, 210u8, 232u8, 4u8, 122u8, 90u8, 212u8, - 136u8, 14u8, 127u8, 232u8, 8u8, 192u8, 40u8, 233u8, 18u8, 250u8, + 82u8, 20u8, 178u8, 101u8, 108u8, 198u8, 71u8, 99u8, 16u8, 175u8, 15u8, + 187u8, 229u8, 243u8, 140u8, 200u8, 99u8, 77u8, 248u8, 178u8, 45u8, + 121u8, 193u8, 67u8, 165u8, 43u8, 234u8, 211u8, 158u8, 250u8, 103u8, + 243u8, ], ) } - #[doc = " Named reserves on some account balances."] - pub fn reserves( + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The maximum weight that may be scheduled per block for any dispatchables."] + pub fn maximum_weight( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::ReserveData< - [::core::primitive::u8; 8usize], - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Reserves", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "Scheduler", + "MaximumWeight", [ - 17u8, 32u8, 191u8, 46u8, 76u8, 220u8, 101u8, 100u8, 42u8, 250u8, 128u8, - 167u8, 117u8, 44u8, 85u8, 96u8, 105u8, 216u8, 16u8, 147u8, 74u8, 55u8, - 183u8, 94u8, 160u8, 177u8, 26u8, 187u8, 71u8, 197u8, 187u8, 163u8, + 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, + 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, + 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, + 106u8, 76u8, ], ) } - #[doc = " Named reserves on some account balances."] - pub fn reserves_root( + #[doc = " The maximum number of scheduled calls in the queue for a single block."] + #[doc = ""] + #[doc = " NOTE:"] + #[doc = " + Dependent pallets' benchmarks might require a higher limit for the setting. Set a"] + #[doc = " higher limit under `runtime-benchmarks` feature."] + pub fn max_scheduled_per_block( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::ReserveData< - [::core::primitive::u8; 8usize], - ::core::primitive::u128, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Reserves", - Vec::new(), + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Scheduler", + "MaxScheduledPerBlock", [ - 17u8, 32u8, 191u8, 46u8, 76u8, 220u8, 101u8, 100u8, 42u8, 250u8, 128u8, - 167u8, 117u8, 44u8, 85u8, 96u8, 105u8, 216u8, 16u8, 147u8, 74u8, 55u8, - 183u8, 94u8, 160u8, 177u8, 26u8, 187u8, 71u8, 197u8, 187u8, 163u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = " Holds on account balances."] - pub fn holds( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - (), - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Holds", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 247u8, 81u8, 4u8, 220u8, 77u8, 205u8, 28u8, 131u8, 215u8, 74u8, 197u8, - 137u8, 113u8, 214u8, 249u8, 91u8, 81u8, 216u8, 8u8, 5u8, 233u8, 39u8, - 104u8, 250u8, 3u8, 228u8, 148u8, 78u8, 4u8, 34u8, 45u8, 143u8, - ], - ) + } + } + } + pub mod preimage { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_preimage::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct NotePreimage { + pub bytes: ::std::vec::Vec<::core::primitive::u8>, } - #[doc = " Holds on account balances."] - pub fn holds_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - (), - ::core::primitive::u128, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Holds", - Vec::new(), - [ - 247u8, 81u8, 4u8, 220u8, 77u8, 205u8, 28u8, 131u8, 215u8, 74u8, 197u8, - 137u8, 113u8, 214u8, 249u8, 91u8, 81u8, 216u8, 8u8, 5u8, 233u8, 39u8, - 104u8, 250u8, 3u8, 228u8, 148u8, 78u8, 4u8, 34u8, 45u8, 143u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UnnotePreimage { + pub hash: ::subxt::utils::H256, } - #[doc = " Freeze locks on account balances."] - pub fn freezes( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - (), - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Freezes", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 211u8, 24u8, 237u8, 217u8, 47u8, 230u8, 147u8, 39u8, 112u8, 209u8, - 193u8, 47u8, 242u8, 13u8, 241u8, 0u8, 100u8, 45u8, 116u8, 130u8, 246u8, - 196u8, 50u8, 134u8, 135u8, 112u8, 206u8, 1u8, 12u8, 53u8, 106u8, 131u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RequestPreimage { + pub hash: ::subxt::utils::H256, } - #[doc = " Freeze locks on account balances."] - pub fn freezes_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - (), - ::core::primitive::u128, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Freezes", - Vec::new(), - [ - 211u8, 24u8, 237u8, 217u8, 47u8, 230u8, 147u8, 39u8, 112u8, 209u8, - 193u8, 47u8, 242u8, 13u8, 241u8, 0u8, 100u8, 45u8, 116u8, 130u8, 246u8, - 196u8, 50u8, 134u8, 135u8, 112u8, 206u8, 1u8, 12u8, 53u8, 106u8, 131u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UnrequestPreimage { + pub hash: ::subxt::utils::H256, } } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The minimum amount required to keep an account open. MUST BE GREATER THAN ZERO!"] - #[doc = ""] - #[doc = " If you *really* need it to be zero, you can enable the feature `insecure_zero_ed` for"] - #[doc = " this pallet. However, you do so at your own risk: this will open up a major DoS vector."] - #[doc = " In case you have multiple sources of provider references, you may also get unexpected"] - #[doc = " behaviour if you set this to zero."] + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Register a preimage on-chain."] #[doc = ""] - #[doc = " Bottom line: Do yourself a favour and make it at least one!"] - pub fn existential_deposit( + #[doc = "If the preimage was previously requested, no fees or deposits are taken for providing"] + #[doc = "the preimage. Otherwise, a deposit is taken proportional to the size of the preimage."] + pub fn note_preimage( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Balances", - "ExistentialDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum number of locks that should exist on an account."] - #[doc = " Not strictly enforced, but used for weight estimation."] - pub fn max_locks(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Balances", - "MaxLocks", + bytes: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Preimage", + "note_preimage", + types::NotePreimage { bytes }, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 77u8, 48u8, 104u8, 3u8, 254u8, 65u8, 106u8, 95u8, 204u8, 89u8, 149u8, + 29u8, 144u8, 188u8, 99u8, 23u8, 146u8, 142u8, 35u8, 17u8, 125u8, 130u8, + 31u8, 206u8, 106u8, 83u8, 163u8, 192u8, 81u8, 23u8, 232u8, 230u8, ], ) } - #[doc = " The maximum number of named reserves that can exist on an account."] - pub fn max_reserves(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Balances", - "MaxReserves", + #[doc = "Clear an unrequested preimage from the runtime storage."] + #[doc = ""] + #[doc = "If `len` is provided, then it will be a much cheaper operation."] + #[doc = ""] + #[doc = "- `hash`: The hash of the preimage to be removed from the store."] + #[doc = "- `len`: The length of the preimage of `hash`."] + pub fn unnote_preimage( + &self, + hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Preimage", + "unnote_preimage", + types::UnnotePreimage { hash }, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 211u8, 204u8, 205u8, 58u8, 33u8, 179u8, 68u8, 74u8, 149u8, 138u8, + 213u8, 45u8, 140u8, 27u8, 106u8, 81u8, 68u8, 212u8, 147u8, 116u8, 27u8, + 130u8, 84u8, 34u8, 231u8, 197u8, 135u8, 8u8, 19u8, 242u8, 207u8, 17u8, ], ) } - #[doc = " The maximum number of holds that can exist on an account at any time."] - pub fn max_holds(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Balances", - "MaxHolds", + #[doc = "Request a preimage be uploaded to the chain without paying any fees or deposits."] + #[doc = ""] + #[doc = "If the preimage requests has already been provided on-chain, we unreserve any deposit"] + #[doc = "a user may have paid, and take the control of the preimage out of their hands."] + pub fn request_preimage( + &self, + hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Preimage", + "request_preimage", + types::RequestPreimage { hash }, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 195u8, 26u8, 146u8, 255u8, 79u8, 43u8, 73u8, 60u8, 115u8, 78u8, 99u8, + 197u8, 137u8, 95u8, 139u8, 141u8, 79u8, 213u8, 170u8, 169u8, 127u8, + 30u8, 236u8, 65u8, 38u8, 16u8, 118u8, 228u8, 141u8, 83u8, 162u8, 233u8, ], ) } - #[doc = " The maximum number of individual freeze locks that can exist on an account at any time."] - pub fn max_freezes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Balances", - "MaxFreezes", + #[doc = "Clear a previously made request for a preimage."] + #[doc = ""] + #[doc = "NOTE: THIS MUST NOT BE CALLED ON `hash` MORE TIMES THAN `request_preimage`."] + pub fn unrequest_preimage( + &self, + hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Preimage", + "unrequest_preimage", + types::UnrequestPreimage { hash }, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 143u8, 225u8, 239u8, 44u8, 237u8, 83u8, 18u8, 105u8, 101u8, 68u8, + 111u8, 116u8, 66u8, 212u8, 63u8, 190u8, 38u8, 32u8, 105u8, 152u8, 69u8, + 177u8, 193u8, 15u8, 60u8, 26u8, 95u8, 130u8, 11u8, 113u8, 187u8, 108u8, ], ) } } } - } - pub mod transaction_payment { - use super::root_mod; - use super::runtime_types; #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_transaction_payment::pallet::Event; + pub type Event = runtime_types::pallet_preimage::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -5573,144 +5602,163 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A transaction fee `actual_fee`, of which `tip` was added to the minimum inclusion fee,"] - #[doc = "has been paid by `who`."] - pub struct TransactionFeePaid { - pub who: ::subxt::utils::AccountId32, - pub actual_fee: ::core::primitive::u128, - pub tip: ::core::primitive::u128, + #[doc = "A preimage has been noted."] + pub struct Noted { + pub hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for TransactionFeePaid { - const PALLET: &'static str = "TransactionPayment"; - const EVENT: &'static str = "TransactionFeePaid"; + impl ::subxt::events::StaticEvent for Noted { + const PALLET: &'static str = "Preimage"; + const EVENT: &'static str = "Noted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A preimage has been requested."] + pub struct Requested { + pub hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for Requested { + const PALLET: &'static str = "Preimage"; + const EVENT: &'static str = "Requested"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A preimage has ben cleared."] + pub struct Cleared { + pub hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for Cleared { + const PALLET: &'static str = "Preimage"; + const EVENT: &'static str = "Cleared"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - pub fn next_fee_multiplier( + #[doc = " The request status of a given hash."] + pub fn status_for( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::fixed_point::FixedU128, - ::subxt::storage::address::Yes, + runtime_types::pallet_preimage::RequestStatus< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, ::subxt::storage::address::Yes, (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "TransactionPayment", - "NextFeeMultiplier", - vec![], + "Preimage", + "StatusFor", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 210u8, 0u8, 206u8, 165u8, 183u8, 10u8, 206u8, 52u8, 14u8, 90u8, 218u8, - 197u8, 189u8, 125u8, 113u8, 216u8, 52u8, 161u8, 45u8, 24u8, 245u8, - 237u8, 121u8, 41u8, 106u8, 29u8, 45u8, 129u8, 250u8, 203u8, 206u8, - 180u8, + 103u8, 208u8, 88u8, 167u8, 244u8, 198u8, 129u8, 134u8, 182u8, 80u8, + 71u8, 192u8, 73u8, 92u8, 190u8, 15u8, 20u8, 132u8, 37u8, 108u8, 88u8, + 233u8, 18u8, 145u8, 9u8, 235u8, 5u8, 132u8, 42u8, 17u8, 227u8, 56u8, ], ) } - pub fn storage_version( + #[doc = " The request status of a given hash."] + pub fn status_for_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_transaction_payment::Releases, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + runtime_types::pallet_preimage::RequestStatus< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + (), (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "TransactionPayment", - "StorageVersion", - vec![], - [ - 219u8, 243u8, 82u8, 176u8, 65u8, 5u8, 132u8, 114u8, 8u8, 82u8, 176u8, - 200u8, 97u8, 150u8, 177u8, 164u8, 166u8, 11u8, 34u8, 12u8, 12u8, 198u8, - 58u8, 191u8, 186u8, 221u8, 221u8, 119u8, 181u8, 253u8, 154u8, 228u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " A fee mulitplier for `Operational` extrinsics to compute \"virtual tip\" to boost their"] - #[doc = " `priority`"] - #[doc = ""] - #[doc = " This value is multipled by the `final_fee` to obtain a \"virtual tip\" that is later"] - #[doc = " added to a tip component in regular `priority` calculations."] - #[doc = " It means that a `Normal` transaction can front-run a similarly-sized `Operational`"] - #[doc = " extrinsic (with no tip), by including a tip value greater than the virtual tip."] - #[doc = ""] - #[doc = " ```rust,ignore"] - #[doc = " // For `Normal`"] - #[doc = " let priority = priority_calc(tip);"] - #[doc = ""] - #[doc = " // For `Operational`"] - #[doc = " let virtual_tip = (inclusion_fee + tip) * OperationalFeeMultiplier;"] - #[doc = " let priority = priority_calc(tip + virtual_tip);"] - #[doc = " ```"] - #[doc = ""] - #[doc = " Note that since we use `final_fee` the multiplier applies also to the regular `tip`"] - #[doc = " sent with the transaction. So, not only does the transaction get a priority bump based"] - #[doc = " on the `inclusion_fee`, but we also amplify the impact of tips applied to `Operational`"] - #[doc = " transactions."] - pub fn operational_fee_multiplier( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u8> { - ::subxt::constants::Address::new_static( - "TransactionPayment", - "OperationalFeeMultiplier", + "Preimage", + "StatusFor", + Vec::new(), [ - 141u8, 130u8, 11u8, 35u8, 226u8, 114u8, 92u8, 179u8, 168u8, 110u8, - 28u8, 91u8, 221u8, 64u8, 4u8, 148u8, 201u8, 193u8, 185u8, 66u8, 226u8, - 114u8, 97u8, 79u8, 62u8, 212u8, 202u8, 114u8, 237u8, 228u8, 183u8, - 165u8, + 103u8, 208u8, 88u8, 167u8, 244u8, 198u8, 129u8, 134u8, 182u8, 80u8, + 71u8, 192u8, 73u8, 92u8, 190u8, 15u8, 20u8, 132u8, 37u8, 108u8, 88u8, + 233u8, 18u8, 145u8, 9u8, 235u8, 5u8, 132u8, 42u8, 17u8, 227u8, 56u8, ], ) } - } - } - } - pub mod authorship { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Author of current block."] - pub fn author( + pub fn preimage_for( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + _1: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, ::subxt::storage::address::Yes, (), - (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Authorship", - "Author", - vec![], - [ - 149u8, 42u8, 33u8, 147u8, 190u8, 207u8, 174u8, 227u8, 190u8, 110u8, - 25u8, 131u8, 5u8, 167u8, 237u8, 188u8, 188u8, 33u8, 177u8, 126u8, - 181u8, 49u8, 126u8, 118u8, 46u8, 128u8, 154u8, 95u8, 15u8, 91u8, 103u8, - 113u8, + "Preimage", + "PreimageFor", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 96u8, 74u8, 30u8, 112u8, 120u8, 41u8, 52u8, 187u8, 252u8, 68u8, 42u8, + 5u8, 61u8, 228u8, 250u8, 192u8, 224u8, 61u8, 53u8, 222u8, 95u8, 148u8, + 6u8, 53u8, 43u8, 152u8, 88u8, 58u8, 185u8, 234u8, 131u8, 124u8, + ], + ) + } + pub fn preimage_for_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Preimage", + "PreimageFor", + Vec::new(), + [ + 96u8, 74u8, 30u8, 112u8, 120u8, 41u8, 52u8, 187u8, 252u8, 68u8, 42u8, + 5u8, 61u8, 228u8, 250u8, 192u8, 224u8, 61u8, 53u8, 222u8, 95u8, 148u8, + 6u8, 53u8, 43u8, 152u8, 88u8, 58u8, 185u8, 234u8, 131u8, 124u8, ], ) } } } } - pub mod staking { + pub mod babe { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_staking::pallet::pallet::Error; + pub type Error = runtime_types::pallet_babe::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -5728,294 +5776,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Bond { - pub controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, - pub payee: runtime_types::pallet_staking::RewardDestination< - ::subxt::utils::AccountId32, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BondExtra { - #[codec(compact)] - pub max_additional: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Unbond { - #[codec(compact)] - pub value: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WithdrawUnbonded { - pub num_slashing_spans: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Validate { - pub prefs: runtime_types::pallet_staking::ValidatorPrefs, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Nominate { - pub targets: ::std::vec::Vec< - ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Chill; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetPayee { - pub payee: runtime_types::pallet_staking::RewardDestination< - ::subxt::utils::AccountId32, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetController { - pub controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetValidatorCount { - #[codec(compact)] - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct IncreaseValidatorCount { - #[codec(compact)] - pub additional: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScaleValidatorCount { - pub factor: runtime_types::sp_arithmetic::per_things::Percent, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceNoEras; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceNewEra; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetInvulnerables { - pub invulnerables: ::std::vec::Vec<::subxt::utils::AccountId32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceUnstake { - pub stash: ::subxt::utils::AccountId32, - pub num_slashing_spans: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceNewEraAlways; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelDeferredSlash { - pub era: ::core::primitive::u32, - pub slash_indices: ::std::vec::Vec<::core::primitive::u32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PayoutStakers { - pub validator_stash: ::subxt::utils::AccountId32, - pub era: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Rebond { - #[codec(compact)] - pub value: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReapStash { - pub stash: ::subxt::utils::AccountId32, - pub num_slashing_spans: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Kick { - pub who: ::std::vec::Vec< - ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub struct ReportEquivocation { + pub equivocation_proof: ::std::boxed::Box< + runtime_types::sp_consensus_slots::EquivocationProof< + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + runtime_types::sp_consensus_babe::app::Public, + >, >, + pub key_owner_proof: runtime_types::sp_session::MembershipProof, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -6027,53 +5798,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetStakingConfigs { - pub min_nominator_bond: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - ::core::primitive::u128, - >, - pub min_validator_bond: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - ::core::primitive::u128, - >, - pub max_nominator_count: - runtime_types::pallet_staking::pallet::pallet::ConfigOp< - ::core::primitive::u32, - >, - pub max_validator_count: - runtime_types::pallet_staking::pallet::pallet::ConfigOp< - ::core::primitive::u32, + pub struct ReportEquivocationUnsigned { + pub equivocation_proof: ::std::boxed::Box< + runtime_types::sp_consensus_slots::EquivocationProof< + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + runtime_types::sp_consensus_babe::app::Public, >, - pub chill_threshold: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - runtime_types::sp_arithmetic::per_things::Percent, >, - pub min_commission: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - runtime_types::sp_arithmetic::per_things::Perbill, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ChillOther { - pub controller: ::subxt::utils::AccountId32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceApplyMinCommission { - pub validator_stash: ::subxt::utils::AccountId32, + pub key_owner_proof: runtime_types::sp_session::MembershipProof, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -6085,803 +5820,965 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMinCommission { - pub new: runtime_types::sp_arithmetic::per_things::Perbill, + pub struct PlanConfigChange { + pub config: runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, } } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMinCommission { - pub new: runtime_types::sp_arithmetic::per_things::Perbill, - } pub struct TransactionApi; impl TransactionApi { - #[doc = "Take the origin account as a stash and lock up `value` of its balance. `controller` will"] - #[doc = "be the account that controls it."] - #[doc = ""] - #[doc = "`value` must be more than the `minimum_balance` specified by `T::Currency`."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ by the stash account."] - #[doc = ""] - #[doc = "Emits `Bonded`."] - #[doc = "## Complexity"] - #[doc = "- Independent of the arguments. Moderate complexity."] - #[doc = "- O(1)."] - #[doc = "- Three extra DB entries."] - #[doc = ""] - #[doc = "NOTE: Two of the storage writes (`Self::bonded`, `Self::payee`) are _never_ cleaned"] - #[doc = "unless the `origin` falls below _existential deposit_ and gets removed as dust."] - pub fn bond( + #[doc = "Report authority equivocation/misbehavior. This method will verify"] + #[doc = "the equivocation proof and validate the given key ownership proof"] + #[doc = "against the extracted offender. If both are valid, the offence will"] + #[doc = "be reported."] + pub fn report_equivocation( &self, - controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - payee: runtime_types::pallet_staking::RewardDestination< - ::subxt::utils::AccountId32, + equivocation_proof: runtime_types::sp_consensus_slots::EquivocationProof< + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + runtime_types::sp_consensus_babe::app::Public, >, - ) -> ::subxt::tx::Payload { + key_owner_proof: runtime_types::sp_session::MembershipProof, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Staking", - "bond", - types::Bond { - controller, - value, - payee, + "Babe", + "report_equivocation", + types::ReportEquivocation { + equivocation_proof: ::std::boxed::Box::new(equivocation_proof), + key_owner_proof, }, [ - 215u8, 211u8, 69u8, 215u8, 33u8, 158u8, 62u8, 3u8, 31u8, 216u8, 213u8, - 188u8, 151u8, 43u8, 165u8, 154u8, 117u8, 163u8, 190u8, 227u8, 116u8, - 70u8, 155u8, 178u8, 64u8, 174u8, 203u8, 179u8, 214u8, 187u8, 176u8, - 10u8, + 177u8, 237u8, 107u8, 138u8, 237u8, 233u8, 30u8, 195u8, 112u8, 176u8, + 185u8, 113u8, 157u8, 221u8, 134u8, 151u8, 62u8, 151u8, 64u8, 164u8, + 254u8, 112u8, 2u8, 94u8, 175u8, 79u8, 160u8, 3u8, 72u8, 145u8, 244u8, + 137u8, ], ) } - #[doc = "Add some extra amount that have appeared in the stash `free_balance` into the balance up"] - #[doc = "for staking."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ by the stash, not the controller."] - #[doc = ""] - #[doc = "Use this if there are additional funds in your stash account that you wish to bond."] - #[doc = "Unlike [`bond`](Self::bond) or [`unbond`](Self::unbond) this function does not impose"] - #[doc = "any limitation on the amount that can be added."] - #[doc = ""] - #[doc = "Emits `Bonded`."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- Independent of the arguments. Insignificant complexity."] - #[doc = "- O(1)."] - pub fn bond_extra( + #[doc = "Report authority equivocation/misbehavior. This method will verify"] + #[doc = "the equivocation proof and validate the given key ownership proof"] + #[doc = "against the extracted offender. If both are valid, the offence will"] + #[doc = "be reported."] + #[doc = "This extrinsic must be called unsigned and it is expected that only"] + #[doc = "block authors will call it (validated in `ValidateUnsigned`), as such"] + #[doc = "if the block author is defined it will be defined as the equivocation"] + #[doc = "reporter."] + pub fn report_equivocation_unsigned( &self, - max_additional: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + equivocation_proof: runtime_types::sp_consensus_slots::EquivocationProof< + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, + runtime_types::sp_consensus_babe::app::Public, + >, + key_owner_proof: runtime_types::sp_session::MembershipProof, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Staking", - "bond_extra", - types::BondExtra { max_additional }, + "Babe", + "report_equivocation_unsigned", + types::ReportEquivocationUnsigned { + equivocation_proof: ::std::boxed::Box::new(equivocation_proof), + key_owner_proof, + }, [ - 60u8, 45u8, 82u8, 223u8, 113u8, 95u8, 0u8, 71u8, 59u8, 108u8, 228u8, - 9u8, 95u8, 210u8, 113u8, 106u8, 252u8, 15u8, 19u8, 128u8, 11u8, 187u8, - 4u8, 151u8, 103u8, 143u8, 24u8, 33u8, 149u8, 82u8, 35u8, 192u8, + 56u8, 103u8, 238u8, 118u8, 61u8, 192u8, 222u8, 87u8, 254u8, 24u8, + 138u8, 219u8, 210u8, 85u8, 201u8, 147u8, 128u8, 49u8, 199u8, 144u8, + 46u8, 158u8, 163u8, 31u8, 101u8, 224u8, 72u8, 98u8, 68u8, 120u8, 215u8, + 19u8, ], ) } - #[doc = "Schedule a portion of the stash to be unlocked ready for transfer out after the bond"] - #[doc = "period ends. If this leaves an amount actively bonded less than"] - #[doc = "T::Currency::minimum_balance(), then it is increased to the full amount."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] - #[doc = ""] - #[doc = "Once the unlock period is done, you can call `withdraw_unbonded` to actually move"] - #[doc = "the funds out of management ready for transfer."] - #[doc = ""] - #[doc = "No more than a limited number of unlocking chunks (see `MaxUnlockingChunks`)"] - #[doc = "can co-exists at the same time. If there are no unlocking chunks slots available"] - #[doc = "[`Call::withdraw_unbonded`] is called to remove some of the chunks (if possible)."] - #[doc = ""] - #[doc = "If a user encounters the `InsufficientBond` error when calling this extrinsic,"] - #[doc = "they should call `chill` first in order to free up their bonded funds."] - #[doc = ""] - #[doc = "Emits `Unbonded`."] - #[doc = ""] - #[doc = "See also [`Call::withdraw_unbonded`]."] - pub fn unbond( + #[doc = "Plan an epoch config change. The epoch config change is recorded and will be enacted on"] + #[doc = "the next call to `enact_epoch_change`. The config will be activated one epoch after."] + #[doc = "Multiple calls to this method will replace any existing planned config change that had"] + #[doc = "not been enacted yet."] + pub fn plan_config_change( &self, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + config: runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Staking", - "unbond", - types::Unbond { value }, + "Babe", + "plan_config_change", + types::PlanConfigChange { config }, [ - 85u8, 62u8, 34u8, 127u8, 60u8, 241u8, 134u8, 60u8, 125u8, 91u8, 31u8, - 193u8, 50u8, 230u8, 237u8, 42u8, 114u8, 230u8, 240u8, 146u8, 14u8, - 109u8, 185u8, 151u8, 148u8, 44u8, 147u8, 182u8, 192u8, 253u8, 51u8, - 87u8, + 229u8, 157u8, 41u8, 58u8, 56u8, 4u8, 52u8, 107u8, 104u8, 20u8, 42u8, + 110u8, 1u8, 17u8, 45u8, 196u8, 30u8, 135u8, 63u8, 46u8, 40u8, 137u8, + 209u8, 37u8, 24u8, 108u8, 251u8, 189u8, 77u8, 208u8, 74u8, 32u8, ], ) } - #[doc = "Remove any unlocked chunks from the `unlocking` queue from our management."] - #[doc = ""] - #[doc = "This essentially frees up that balance to be used by the stash account to do"] - #[doc = "whatever it wants."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ by the controller."] - #[doc = ""] - #[doc = "Emits `Withdrawn`."] - #[doc = ""] - #[doc = "See also [`Call::unbond`]."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "O(S) where S is the number of slashing spans to remove"] - #[doc = "NOTE: Weight annotation is the kill scenario, we refund otherwise."] - pub fn withdraw_unbonded( + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Current epoch index."] + pub fn epoch_index( &self, - num_slashing_spans: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "withdraw_unbonded", - types::WithdrawUnbonded { num_slashing_spans }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u64, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "EpochIndex", + vec![], [ - 95u8, 223u8, 122u8, 217u8, 76u8, 208u8, 86u8, 129u8, 31u8, 104u8, 70u8, - 154u8, 23u8, 250u8, 165u8, 192u8, 149u8, 249u8, 158u8, 159u8, 194u8, - 224u8, 118u8, 134u8, 204u8, 157u8, 72u8, 136u8, 19u8, 193u8, 183u8, - 84u8, + 51u8, 27u8, 91u8, 156u8, 118u8, 99u8, 46u8, 219u8, 190u8, 147u8, 205u8, + 23u8, 106u8, 169u8, 121u8, 218u8, 208u8, 235u8, 135u8, 127u8, 243u8, + 41u8, 55u8, 243u8, 235u8, 122u8, 57u8, 86u8, 37u8, 90u8, 208u8, 71u8, ], ) } - #[doc = "Declare the desire to validate for the origin controller."] - #[doc = ""] - #[doc = "Effects will be felt at the beginning of the next era."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] - pub fn validate( + #[doc = " Current epoch authorities."] + pub fn authorities( &self, - prefs: runtime_types::pallet_staking::ValidatorPrefs, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "validate", - types::Validate { prefs }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec<( + runtime_types::sp_consensus_babe::app::Public, + ::core::primitive::u64, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "Authorities", + vec![], [ - 191u8, 116u8, 139u8, 35u8, 250u8, 211u8, 86u8, 240u8, 35u8, 9u8, 19u8, - 44u8, 148u8, 35u8, 91u8, 106u8, 200u8, 172u8, 108u8, 145u8, 194u8, - 146u8, 61u8, 145u8, 233u8, 168u8, 2u8, 26u8, 145u8, 101u8, 114u8, - 157u8, + 61u8, 8u8, 133u8, 111u8, 169u8, 120u8, 0u8, 213u8, 31u8, 159u8, 204u8, + 212u8, 18u8, 205u8, 93u8, 84u8, 140u8, 108u8, 136u8, 209u8, 234u8, + 107u8, 145u8, 9u8, 204u8, 224u8, 105u8, 9u8, 238u8, 241u8, 65u8, 30u8, ], ) } - #[doc = "Declare the desire to nominate `targets` for the origin controller."] - #[doc = ""] - #[doc = "Effects will be felt at the beginning of the next era."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- The transaction's complexity is proportional to the size of `targets` (N)"] - #[doc = "which is capped at CompactAssignments::LIMIT (T::MaxNominations)."] - #[doc = "- Both the reads and writes follow a similar pattern."] - pub fn nominate( + #[doc = " The slot at which the first epoch actually started. This is 0"] + #[doc = " until the first block of the chain."] + pub fn genesis_slot( &self, - targets: ::std::vec::Vec< - ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "nominate", - types::Nominate { targets }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_consensus_slots::Slot, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "GenesisSlot", + vec![], [ - 112u8, 162u8, 70u8, 26u8, 74u8, 7u8, 188u8, 193u8, 210u8, 247u8, 27u8, - 189u8, 133u8, 137u8, 33u8, 155u8, 255u8, 171u8, 122u8, 68u8, 175u8, - 247u8, 139u8, 253u8, 97u8, 187u8, 254u8, 201u8, 66u8, 166u8, 226u8, - 90u8, + 234u8, 127u8, 243u8, 100u8, 124u8, 160u8, 66u8, 248u8, 48u8, 218u8, + 61u8, 52u8, 54u8, 142u8, 158u8, 77u8, 32u8, 63u8, 156u8, 39u8, 94u8, + 255u8, 192u8, 238u8, 170u8, 118u8, 58u8, 42u8, 199u8, 61u8, 199u8, + 77u8, ], ) } - #[doc = "Declare no desire to either validate or nominate."] - #[doc = ""] - #[doc = "Effects will be felt at the beginning of the next era."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- Independent of the arguments. Insignificant complexity."] - #[doc = "- Contains one read."] - #[doc = "- Writes are limited to the `origin` account key."] - pub fn chill(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "chill", - types::Chill {}, + #[doc = " Current slot number."] + pub fn current_slot( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_consensus_slots::Slot, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "CurrentSlot", + vec![], [ - 94u8, 20u8, 196u8, 31u8, 220u8, 125u8, 115u8, 167u8, 140u8, 3u8, 20u8, - 132u8, 81u8, 120u8, 215u8, 166u8, 230u8, 56u8, 16u8, 222u8, 31u8, - 153u8, 120u8, 62u8, 153u8, 67u8, 220u8, 239u8, 11u8, 234u8, 127u8, - 122u8, + 139u8, 237u8, 185u8, 137u8, 251u8, 179u8, 69u8, 167u8, 133u8, 168u8, + 204u8, 64u8, 178u8, 123u8, 92u8, 250u8, 119u8, 190u8, 208u8, 178u8, + 208u8, 176u8, 124u8, 187u8, 74u8, 165u8, 33u8, 78u8, 161u8, 206u8, 8u8, + 108u8, ], ) } - #[doc = "(Re-)set the payment target for a controller."] - #[doc = ""] - #[doc = "Effects will be felt instantly (as soon as this function is completed successfully)."] + #[doc = " The epoch randomness for the *current* epoch."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] + #[doc = " # Security"] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(1)"] - #[doc = "- Independent of the arguments. Insignificant complexity."] - #[doc = "- Contains a limited number of reads."] - #[doc = "- Writes are limited to the `origin` account key."] - #[doc = "---------"] - pub fn set_payee( + #[doc = " This MUST NOT be used for gambling, as it can be influenced by a"] + #[doc = " malicious validator in the short term. It MAY be used in many"] + #[doc = " cryptographic protocols, however, so long as one remembers that this"] + #[doc = " (like everything else on-chain) it is public. For example, it can be"] + #[doc = " used where a number is needed that cannot have been chosen by an"] + #[doc = " adversary, for purposes such as public-coin zero-knowledge proofs."] + pub fn randomness( &self, - payee: runtime_types::pallet_staking::RewardDestination< - ::subxt::utils::AccountId32, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "set_payee", - types::SetPayee { payee }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + [::core::primitive::u8; 32usize], + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "Randomness", + vec![], [ - 96u8, 8u8, 254u8, 164u8, 87u8, 46u8, 120u8, 11u8, 197u8, 63u8, 20u8, - 178u8, 167u8, 236u8, 149u8, 245u8, 14u8, 171u8, 108u8, 195u8, 250u8, - 133u8, 0u8, 75u8, 192u8, 159u8, 84u8, 220u8, 242u8, 133u8, 60u8, 62u8, + 191u8, 197u8, 25u8, 164u8, 104u8, 248u8, 247u8, 193u8, 244u8, 60u8, + 181u8, 195u8, 248u8, 90u8, 41u8, 199u8, 82u8, 123u8, 72u8, 126u8, 18u8, + 17u8, 128u8, 215u8, 34u8, 251u8, 227u8, 70u8, 166u8, 10u8, 104u8, + 140u8, ], ) } - #[doc = "(Re-)set the controller of a stash."] - #[doc = ""] - #[doc = "Effects will be felt instantly (as soon as this function is completed successfully)."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ by the stash, not the controller."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "O(1)"] - #[doc = "- Independent of the arguments. Insignificant complexity."] - #[doc = "- Contains a limited number of reads."] - #[doc = "- Writes are limited to the `origin` account key."] - pub fn set_controller( + #[doc = " Pending epoch configuration change that will be applied when the next epoch is enacted."] + pub fn pending_epoch_config_change( &self, - controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "set_controller", - types::SetController { controller }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "PendingEpochConfigChange", + vec![], [ - 165u8, 250u8, 213u8, 32u8, 179u8, 163u8, 15u8, 35u8, 14u8, 152u8, 56u8, - 171u8, 43u8, 101u8, 7u8, 167u8, 178u8, 60u8, 89u8, 186u8, 59u8, 28u8, - 82u8, 159u8, 13u8, 96u8, 168u8, 123u8, 194u8, 212u8, 205u8, 184u8, + 4u8, 201u8, 0u8, 204u8, 47u8, 246u8, 4u8, 185u8, 163u8, 242u8, 242u8, + 152u8, 29u8, 222u8, 71u8, 127u8, 49u8, 203u8, 206u8, 180u8, 244u8, + 50u8, 80u8, 49u8, 199u8, 97u8, 3u8, 170u8, 156u8, 139u8, 106u8, 113u8, ], ) } - #[doc = "Sets the ideal number of validators."] - #[doc = ""] - #[doc = "The dispatch origin must be Root."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "O(1)"] - pub fn set_validator_count( + #[doc = " Next epoch randomness."] + pub fn next_randomness( &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "set_validator_count", - types::SetValidatorCount { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + [::core::primitive::u8; 32usize], + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "NextRandomness", + vec![], [ - 55u8, 232u8, 95u8, 66u8, 228u8, 217u8, 11u8, 27u8, 3u8, 202u8, 199u8, - 242u8, 70u8, 160u8, 250u8, 187u8, 194u8, 91u8, 15u8, 36u8, 215u8, 36u8, - 160u8, 108u8, 251u8, 60u8, 240u8, 202u8, 249u8, 235u8, 28u8, 94u8, + 185u8, 98u8, 45u8, 109u8, 253u8, 38u8, 238u8, 221u8, 240u8, 29u8, 38u8, + 107u8, 118u8, 117u8, 131u8, 115u8, 21u8, 255u8, 203u8, 81u8, 243u8, + 251u8, 91u8, 60u8, 163u8, 202u8, 125u8, 193u8, 173u8, 234u8, 166u8, + 92u8, ], ) } - #[doc = "Increments the ideal number of validators upto maximum of"] - #[doc = "`ElectionProviderBase::MaxWinners`."] - #[doc = ""] - #[doc = "The dispatch origin must be Root."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "Same as [`Self::set_validator_count`]."] - pub fn increase_validator_count( + #[doc = " Next epoch authorities."] + pub fn next_authorities( &self, - additional: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "increase_validator_count", - types::IncreaseValidatorCount { additional }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec<( + runtime_types::sp_consensus_babe::app::Public, + ::core::primitive::u64, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "NextAuthorities", + vec![], [ - 239u8, 184u8, 155u8, 213u8, 25u8, 22u8, 193u8, 13u8, 102u8, 192u8, - 82u8, 153u8, 249u8, 192u8, 60u8, 158u8, 8u8, 78u8, 175u8, 219u8, 46u8, - 51u8, 222u8, 193u8, 193u8, 201u8, 78u8, 90u8, 58u8, 86u8, 196u8, 17u8, + 201u8, 193u8, 164u8, 18u8, 155u8, 253u8, 124u8, 163u8, 143u8, 73u8, + 212u8, 20u8, 241u8, 108u8, 110u8, 5u8, 171u8, 66u8, 224u8, 208u8, 10u8, + 65u8, 148u8, 164u8, 1u8, 12u8, 216u8, 83u8, 20u8, 226u8, 254u8, 183u8, ], ) } - #[doc = "Scale up the ideal number of validators by a factor upto maximum of"] - #[doc = "`ElectionProviderBase::MaxWinners`."] + #[doc = " Randomness under construction."] #[doc = ""] - #[doc = "The dispatch origin must be Root."] + #[doc = " We make a trade-off between storage accesses and list length."] + #[doc = " We store the under-construction randomness in segments of up to"] + #[doc = " `UNDER_CONSTRUCTION_SEGMENT_LENGTH`."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "Same as [`Self::set_validator_count`]."] - pub fn scale_validator_count( + #[doc = " Once a segment reaches this length, we begin the next one."] + #[doc = " We reset all segments and return to `0` at the beginning of every"] + #[doc = " epoch."] + pub fn segment_index( &self, - factor: runtime_types::sp_arithmetic::per_things::Percent, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "scale_validator_count", - types::ScaleValidatorCount { factor }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "SegmentIndex", + vec![], [ - 198u8, 68u8, 227u8, 94u8, 110u8, 157u8, 209u8, 217u8, 112u8, 37u8, - 78u8, 142u8, 12u8, 193u8, 219u8, 167u8, 149u8, 112u8, 49u8, 139u8, - 74u8, 81u8, 172u8, 72u8, 253u8, 224u8, 56u8, 194u8, 185u8, 90u8, 87u8, - 125u8, + 128u8, 45u8, 87u8, 58u8, 174u8, 152u8, 241u8, 156u8, 56u8, 192u8, 19u8, + 45u8, 75u8, 160u8, 35u8, 253u8, 145u8, 11u8, 178u8, 81u8, 114u8, 117u8, + 112u8, 107u8, 163u8, 208u8, 240u8, 151u8, 102u8, 176u8, 246u8, 5u8, ], ) } - #[doc = "Force there to be no new eras indefinitely."] - #[doc = ""] - #[doc = "The dispatch origin must be Root."] - #[doc = ""] - #[doc = "# Warning"] - #[doc = ""] - #[doc = "The election process starts multiple blocks before the end of the era."] - #[doc = "Thus the election process may be ongoing when this is called. In this case the"] - #[doc = "election will continue until the next era is triggered."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- No arguments."] - #[doc = "- Weight: O(1)"] - pub fn force_no_eras(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "force_no_eras", - types::ForceNoEras {}, + #[doc = " TWOX-NOTE: `SegmentIndex` is an increasing integer, so this is okay."] + pub fn under_construction( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + [::core::primitive::u8; 32usize], + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "UnderConstruction", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 16u8, 81u8, 207u8, 168u8, 23u8, 236u8, 11u8, 75u8, 141u8, 107u8, 92u8, - 2u8, 53u8, 111u8, 252u8, 116u8, 91u8, 120u8, 75u8, 24u8, 125u8, 53u8, - 9u8, 28u8, 242u8, 87u8, 245u8, 55u8, 40u8, 103u8, 151u8, 178u8, + 180u8, 4u8, 149u8, 245u8, 231u8, 92u8, 99u8, 170u8, 254u8, 172u8, + 182u8, 3u8, 152u8, 156u8, 132u8, 196u8, 140u8, 97u8, 7u8, 84u8, 220u8, + 89u8, 195u8, 177u8, 235u8, 51u8, 98u8, 144u8, 73u8, 238u8, 59u8, 164u8, ], ) } - #[doc = "Force there to be a new era at the end of the next session. After this, it will be"] - #[doc = "reset to normal (non-forced) behaviour."] - #[doc = ""] - #[doc = "The dispatch origin must be Root."] - #[doc = ""] - #[doc = "# Warning"] - #[doc = ""] - #[doc = "The election process starts multiple blocks before the end of the era."] - #[doc = "If this is called just before a new era is triggered, the election process may not"] - #[doc = "have enough blocks to get a result."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- No arguments."] - #[doc = "- Weight: O(1)"] - pub fn force_new_era(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "force_new_era", - types::ForceNewEra {}, + #[doc = " TWOX-NOTE: `SegmentIndex` is an increasing integer, so this is okay."] + pub fn under_construction_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + [::core::primitive::u8; 32usize], + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "UnderConstruction", + Vec::new(), [ - 230u8, 242u8, 169u8, 196u8, 78u8, 145u8, 24u8, 191u8, 113u8, 68u8, 5u8, - 138u8, 48u8, 51u8, 109u8, 126u8, 73u8, 136u8, 162u8, 158u8, 174u8, - 201u8, 213u8, 230u8, 215u8, 44u8, 200u8, 32u8, 75u8, 27u8, 23u8, 254u8, + 180u8, 4u8, 149u8, 245u8, 231u8, 92u8, 99u8, 170u8, 254u8, 172u8, + 182u8, 3u8, 152u8, 156u8, 132u8, 196u8, 140u8, 97u8, 7u8, 84u8, 220u8, + 89u8, 195u8, 177u8, 235u8, 51u8, 98u8, 144u8, 73u8, 238u8, 59u8, 164u8, ], ) } - #[doc = "Set the validators who cannot be slashed (if any)."] - #[doc = ""] - #[doc = "The dispatch origin must be Root."] - pub fn set_invulnerables( + #[doc = " Temporary value (cleared at block finalization) which is `Some`"] + #[doc = " if per-block initialization has already been called for current block."] + pub fn initialized( &self, - invulnerables: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "set_invulnerables", - types::SetInvulnerables { invulnerables }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::option::Option, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "Initialized", + vec![], [ - 2u8, 148u8, 221u8, 111u8, 153u8, 48u8, 222u8, 36u8, 228u8, 84u8, 18u8, - 35u8, 168u8, 239u8, 53u8, 245u8, 27u8, 76u8, 18u8, 203u8, 206u8, 9u8, - 8u8, 81u8, 35u8, 224u8, 22u8, 133u8, 58u8, 99u8, 103u8, 39u8, + 40u8, 135u8, 28u8, 144u8, 247u8, 208u8, 48u8, 220u8, 46u8, 60u8, 131u8, + 190u8, 196u8, 235u8, 126u8, 66u8, 34u8, 14u8, 32u8, 131u8, 71u8, 46u8, + 62u8, 207u8, 177u8, 213u8, 167u8, 34u8, 199u8, 29u8, 16u8, 236u8, ], ) } - #[doc = "Force a current staker to become completely unstaked, immediately."] + #[doc = " This field should always be populated during block processing unless"] + #[doc = " secondary plain slots are enabled (which don't contain a VRF output)."] #[doc = ""] - #[doc = "The dispatch origin must be Root."] - pub fn force_unstake( + #[doc = " It is set in `on_finalize`, before it will contain the value from the last block."] + pub fn author_vrf_randomness( &self, - stash: ::subxt::utils::AccountId32, - num_slashing_spans: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "force_unstake", - types::ForceUnstake { - stash, - num_slashing_spans, - }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::option::Option<[::core::primitive::u8; 32usize]>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "AuthorVrfRandomness", + vec![], [ - 94u8, 247u8, 238u8, 47u8, 250u8, 6u8, 96u8, 175u8, 173u8, 123u8, 161u8, - 187u8, 162u8, 214u8, 176u8, 233u8, 33u8, 33u8, 167u8, 239u8, 40u8, - 223u8, 19u8, 131u8, 230u8, 39u8, 175u8, 200u8, 36u8, 182u8, 76u8, - 207u8, + 66u8, 235u8, 74u8, 252u8, 222u8, 135u8, 19u8, 28u8, 74u8, 191u8, 170u8, + 197u8, 207u8, 127u8, 77u8, 121u8, 138u8, 138u8, 110u8, 187u8, 34u8, + 14u8, 230u8, 43u8, 241u8, 241u8, 63u8, 163u8, 53u8, 179u8, 250u8, + 247u8, ], ) } - #[doc = "Force there to be a new era at the end of sessions indefinitely."] - #[doc = ""] - #[doc = "The dispatch origin must be Root."] - #[doc = ""] - #[doc = "# Warning"] - #[doc = ""] - #[doc = "The election process starts multiple blocks before the end of the era."] - #[doc = "If this is called just before a new era is triggered, the election process may not"] - #[doc = "have enough blocks to get a result."] - pub fn force_new_era_always( + #[doc = " The block numbers when the last and current epoch have started, respectively `N-1` and"] + #[doc = " `N`."] + #[doc = " NOTE: We track this is in order to annotate the block number when a given pool of"] + #[doc = " entropy was fixed (i.e. it was known to chain observers). Since epochs are defined in"] + #[doc = " slots, which may be skipped, the block numbers may not line up with the slot numbers."] + pub fn epoch_start( &self, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "force_new_era_always", - types::ForceNewEraAlways {}, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + (::core::primitive::u32, ::core::primitive::u32), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "EpochStart", + vec![], [ - 179u8, 118u8, 189u8, 54u8, 248u8, 141u8, 207u8, 142u8, 80u8, 37u8, - 241u8, 185u8, 138u8, 254u8, 117u8, 147u8, 225u8, 118u8, 34u8, 177u8, - 197u8, 158u8, 8u8, 82u8, 202u8, 108u8, 208u8, 26u8, 64u8, 33u8, 74u8, - 43u8, + 196u8, 39u8, 241u8, 20u8, 150u8, 180u8, 136u8, 4u8, 195u8, 205u8, + 218u8, 10u8, 130u8, 131u8, 168u8, 243u8, 207u8, 249u8, 58u8, 195u8, + 177u8, 119u8, 110u8, 243u8, 241u8, 3u8, 245u8, 56u8, 157u8, 5u8, 68u8, + 60u8, ], ) } - #[doc = "Cancel enactment of a deferred slash."] - #[doc = ""] - #[doc = "Can be called by the `T::AdminOrigin`."] + #[doc = " How late the current block is compared to its parent."] #[doc = ""] - #[doc = "Parameters: era and indices of the slashes for that era to kill."] - pub fn cancel_deferred_slash( + #[doc = " This entry is populated as part of block execution and is cleaned up"] + #[doc = " on block finalization. Querying this storage entry outside of block"] + #[doc = " execution context should always yield zero."] + pub fn lateness( &self, - era: ::core::primitive::u32, - slash_indices: ::std::vec::Vec<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "cancel_deferred_slash", - types::CancelDeferredSlash { era, slash_indices }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "Lateness", + vec![], [ - 120u8, 57u8, 162u8, 105u8, 91u8, 250u8, 129u8, 240u8, 110u8, 234u8, - 170u8, 98u8, 164u8, 65u8, 106u8, 101u8, 19u8, 88u8, 146u8, 210u8, - 171u8, 44u8, 37u8, 50u8, 65u8, 178u8, 37u8, 223u8, 239u8, 197u8, 116u8, - 168u8, + 229u8, 230u8, 224u8, 89u8, 49u8, 213u8, 198u8, 236u8, 144u8, 56u8, + 193u8, 234u8, 62u8, 242u8, 191u8, 199u8, 105u8, 131u8, 74u8, 63u8, + 75u8, 1u8, 210u8, 49u8, 3u8, 128u8, 18u8, 77u8, 219u8, 146u8, 60u8, + 88u8, ], ) } - #[doc = "Pay out all the stakers behind a single validator for a single era."] - #[doc = ""] - #[doc = "- `validator_stash` is the stash account of the validator. Their nominators, up to"] - #[doc = " `T::MaxNominatorRewardedPerValidator`, will also receive their rewards."] - #[doc = "- `era` may be any era between `[current_era - history_depth; current_era]`."] - #[doc = ""] - #[doc = "The origin of this call must be _Signed_. Any account can call this function, even if"] - #[doc = "it is not one of the stakers."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- At most O(MaxNominatorRewardedPerValidator)."] - pub fn payout_stakers( + #[doc = " The configuration for the current epoch. Should never be `None` as it is initialized in"] + #[doc = " genesis."] + pub fn epoch_config( &self, - validator_stash: ::subxt::utils::AccountId32, - era: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "payout_stakers", - types::PayoutStakers { - validator_stash, - era, - }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_consensus_babe::BabeEpochConfiguration, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "EpochConfig", + vec![], [ - 184u8, 194u8, 33u8, 118u8, 7u8, 203u8, 89u8, 119u8, 214u8, 76u8, 178u8, - 20u8, 82u8, 111u8, 57u8, 132u8, 212u8, 43u8, 232u8, 91u8, 252u8, 49u8, - 42u8, 115u8, 1u8, 181u8, 154u8, 207u8, 144u8, 206u8, 205u8, 33u8, + 41u8, 118u8, 141u8, 244u8, 72u8, 17u8, 125u8, 203u8, 43u8, 153u8, + 203u8, 119u8, 117u8, 223u8, 123u8, 133u8, 73u8, 235u8, 130u8, 21u8, + 160u8, 167u8, 16u8, 173u8, 177u8, 35u8, 117u8, 97u8, 149u8, 49u8, + 220u8, 24u8, ], ) } - #[doc = "Rebond a portion of the stash scheduled to be unlocked."] - #[doc = ""] - #[doc = "The dispatch origin must be signed by the controller."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- Time complexity: O(L), where L is unlocking chunks"] - #[doc = "- Bounded by `MaxUnlockingChunks`."] - pub fn rebond( + #[doc = " The configuration for the next epoch, `None` if the config will not change"] + #[doc = " (you can fallback to `EpochConfig` instead in that case)."] + pub fn next_epoch_config( &self, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "rebond", - types::Rebond { value }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_consensus_babe::BabeEpochConfiguration, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "NextEpochConfig", + vec![], [ - 25u8, 22u8, 191u8, 172u8, 133u8, 101u8, 139u8, 102u8, 134u8, 16u8, - 136u8, 56u8, 137u8, 162u8, 4u8, 253u8, 196u8, 30u8, 234u8, 49u8, 102u8, - 68u8, 145u8, 96u8, 148u8, 219u8, 162u8, 17u8, 177u8, 184u8, 34u8, - 113u8, + 111u8, 182u8, 144u8, 180u8, 92u8, 146u8, 102u8, 249u8, 196u8, 229u8, + 226u8, 30u8, 25u8, 198u8, 133u8, 9u8, 136u8, 95u8, 11u8, 151u8, 139u8, + 156u8, 105u8, 228u8, 181u8, 12u8, 175u8, 148u8, 174u8, 33u8, 233u8, + 228u8, ], ) } - #[doc = "Remove all data structures concerning a staker/stash once it is at a state where it can"] - #[doc = "be considered `dust` in the staking system. The requirements are:"] - #[doc = ""] - #[doc = "1. the `total_balance` of the stash is below existential deposit."] - #[doc = "2. or, the `ledger.total` of the stash is below existential deposit."] - #[doc = ""] - #[doc = "The former can happen in cases like a slash; the latter when a fully unbonded account"] - #[doc = "is still receiving staking rewards in `RewardDestination::Staked`."] - #[doc = ""] - #[doc = "It can be called by anyone, as long as `stash` meets the above requirements."] + #[doc = " A list of the last 100 skipped epochs and the corresponding session index"] + #[doc = " when the epoch was skipped."] #[doc = ""] - #[doc = "Refunds the transaction fees upon successful execution."] - pub fn reap_stash( + #[doc = " This is only used for validating equivocation proofs. An equivocation proof"] + #[doc = " must contains a key-ownership proof for a given session, therefore we need a"] + #[doc = " way to tie together sessions and epoch indices, i.e. we need to validate that"] + #[doc = " a validator was the owner of a given key on a given session, and what the"] + #[doc = " active epoch index was during that session."] + pub fn skipped_epochs( &self, - stash: ::subxt::utils::AccountId32, - num_slashing_spans: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "reap_stash", - types::ReapStash { - stash, - num_slashing_spans, - }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u64, + ::core::primitive::u32, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Babe", + "SkippedEpochs", + vec![], [ - 34u8, 168u8, 120u8, 161u8, 95u8, 199u8, 106u8, 233u8, 61u8, 240u8, - 166u8, 31u8, 183u8, 165u8, 158u8, 179u8, 32u8, 130u8, 27u8, 164u8, - 112u8, 44u8, 14u8, 125u8, 227u8, 87u8, 70u8, 203u8, 194u8, 24u8, 212u8, - 177u8, + 187u8, 66u8, 178u8, 110u8, 247u8, 41u8, 128u8, 194u8, 173u8, 197u8, + 28u8, 219u8, 112u8, 75u8, 9u8, 184u8, 51u8, 12u8, 121u8, 117u8, 176u8, + 213u8, 139u8, 144u8, 122u8, 72u8, 243u8, 105u8, 248u8, 63u8, 6u8, 87u8, ], ) } - #[doc = "Remove the given nominations from the calling validator."] - #[doc = ""] - #[doc = "Effects will be felt at the beginning of the next era."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] - #[doc = ""] - #[doc = "- `who`: A list of nominator stash accounts who are nominating this validator which"] - #[doc = " should no longer be nominating this validator."] - #[doc = ""] - #[doc = "Note: Making this call only makes sense if you first set the validator preferences to"] - #[doc = "block any further nominations."] - pub fn kick( + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The amount of time, in slots, that each epoch should last."] + #[doc = " NOTE: Currently it is not possible to change the epoch duration after"] + #[doc = " the chain has started. Attempting to do so will brick block production."] + pub fn epoch_duration( &self, - who: ::std::vec::Vec< - ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "kick", - types::Kick { who }, + ) -> ::subxt::constants::Address<::core::primitive::u64> { + ::subxt::constants::Address::new_static( + "Babe", + "EpochDuration", [ - 32u8, 26u8, 202u8, 6u8, 186u8, 180u8, 58u8, 121u8, 185u8, 208u8, 123u8, - 10u8, 53u8, 179u8, 167u8, 203u8, 96u8, 229u8, 7u8, 144u8, 231u8, 172u8, - 145u8, 141u8, 162u8, 180u8, 212u8, 42u8, 34u8, 5u8, 199u8, 82u8, + 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, + 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, + 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, + 246u8, ], ) } - #[doc = "Update the various staking configurations ."] - #[doc = ""] - #[doc = "* `min_nominator_bond`: The minimum active bond needed to be a nominator."] - #[doc = "* `min_validator_bond`: The minimum active bond needed to be a validator."] - #[doc = "* `max_nominator_count`: The max number of users who can be a nominator at once. When"] - #[doc = " set to `None`, no limit is enforced."] - #[doc = "* `max_validator_count`: The max number of users who can be a validator at once. When"] - #[doc = " set to `None`, no limit is enforced."] - #[doc = "* `chill_threshold`: The ratio of `max_nominator_count` or `max_validator_count` which"] - #[doc = " should be filled in order for the `chill_other` transaction to work."] - #[doc = "* `min_commission`: The minimum amount of commission that each validators must maintain."] - #[doc = " This is checked only upon calling `validate`. Existing validators are not affected."] - #[doc = ""] - #[doc = "RuntimeOrigin must be Root to call this function."] - #[doc = ""] - #[doc = "NOTE: Existing nominators and validators will not be affected by this update."] - #[doc = "to kick people under the new limits, `chill_other` should be called."] - pub fn set_staking_configs( + #[doc = " The expected average block time at which BABE should be creating"] + #[doc = " blocks. Since BABE is probabilistic it is not trivial to figure out"] + #[doc = " what the expected average block time should be based on the slot"] + #[doc = " duration and the security parameter `c` (where `1 - c` represents"] + #[doc = " the probability of a slot being empty)."] + pub fn expected_block_time( &self, - min_nominator_bond: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - ::core::primitive::u128, - >, - min_validator_bond: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - ::core::primitive::u128, - >, - max_nominator_count: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - ::core::primitive::u32, - >, - max_validator_count: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - ::core::primitive::u32, - >, - chill_threshold: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - runtime_types::sp_arithmetic::per_things::Percent, - >, - min_commission: runtime_types::pallet_staking::pallet::pallet::ConfigOp< - runtime_types::sp_arithmetic::per_things::Perbill, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "set_staking_configs", - types::SetStakingConfigs { - min_nominator_bond, - min_validator_bond, - max_nominator_count, - max_validator_count, - chill_threshold, - min_commission, - }, + ) -> ::subxt::constants::Address<::core::primitive::u64> { + ::subxt::constants::Address::new_static( + "Babe", + "ExpectedBlockTime", [ - 176u8, 168u8, 155u8, 176u8, 27u8, 79u8, 223u8, 92u8, 88u8, 93u8, 223u8, - 69u8, 179u8, 250u8, 138u8, 138u8, 87u8, 220u8, 36u8, 3u8, 126u8, 213u8, - 16u8, 68u8, 3u8, 16u8, 218u8, 151u8, 98u8, 169u8, 217u8, 75u8, + 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, + 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, + 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, + 246u8, ], ) } - #[doc = "Declare a `controller` to stop participating as either a validator or nominator."] - #[doc = ""] - #[doc = "Effects will be felt at the beginning of the next era."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_, but can be called by anyone."] - #[doc = ""] - #[doc = "If the caller is the same as the controller being targeted, then no further checks are"] - #[doc = "enforced, and this function behaves just like `chill`."] - #[doc = ""] - #[doc = "If the caller is different than the controller being targeted, the following conditions"] - #[doc = "must be met:"] + #[doc = " Max number of authorities allowed"] + pub fn max_authorities( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Babe", + "MaxAuthorities", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod timestamp { + use super::root_mod; + use super::runtime_types; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Set { + #[codec(compact)] + pub now: ::core::primitive::u64, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Set the current time."] #[doc = ""] - #[doc = "* `controller` must belong to a nominator who has become non-decodable,"] + #[doc = "This call should be invoked exactly once per block. It will panic at the finalization"] + #[doc = "phase, if this call hasn't been invoked by that time."] #[doc = ""] - #[doc = "Or:"] + #[doc = "The timestamp should be greater than the previous one by the amount specified by"] + #[doc = "`MinimumPeriod`."] #[doc = ""] - #[doc = "* A `ChillThreshold` must be set and checked which defines how close to the max"] - #[doc = " nominators or validators we must reach before users can start chilling one-another."] - #[doc = "* A `MaxNominatorCount` and `MaxValidatorCount` must be set which is used to determine"] - #[doc = " how close we are to the threshold."] - #[doc = "* A `MinNominatorBond` and `MinValidatorBond` must be set and checked, which determines"] - #[doc = " if this is a person that should be chilled because they have not met the threshold"] - #[doc = " bond required."] + #[doc = "The dispatch origin for this call must be `Inherent`."] #[doc = ""] - #[doc = "This can be helpful if bond requirements are updated, and we need to remove old users"] - #[doc = "who do not satisfy these requirements."] - pub fn chill_other( - &self, - controller: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { + #[doc = "## Complexity"] + #[doc = "- `O(1)` (Note that implementations of `OnTimestampSet` must also be `O(1)`)"] + #[doc = "- 1 storage read and 1 storage mutation (codec `O(1)`). (because of `DidUpdate::take` in"] + #[doc = " `on_finalize`)"] + #[doc = "- 1 event handler `on_timestamp_set`. Must be `O(1)`."] + pub fn set(&self, now: ::core::primitive::u64) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Staking", - "chill_other", - types::ChillOther { controller }, + "Timestamp", + "set", + types::Set { now }, [ - 140u8, 98u8, 4u8, 203u8, 91u8, 131u8, 123u8, 119u8, 169u8, 47u8, 188u8, - 23u8, 205u8, 170u8, 82u8, 220u8, 166u8, 170u8, 135u8, 176u8, 68u8, - 228u8, 14u8, 67u8, 42u8, 52u8, 140u8, 231u8, 62u8, 167u8, 80u8, 173u8, + 6u8, 97u8, 172u8, 236u8, 118u8, 238u8, 228u8, 114u8, 15u8, 115u8, + 102u8, 85u8, 66u8, 151u8, 16u8, 33u8, 187u8, 17u8, 166u8, 88u8, 127u8, + 214u8, 182u8, 51u8, 168u8, 88u8, 43u8, 101u8, 185u8, 8u8, 1u8, 28u8, ], ) } - #[doc = "Force a validator to have at least the minimum commission. This will not affect a"] - #[doc = "validator who already has a commission greater than or equal to the minimum. Any account"] - #[doc = "can call this."] - pub fn force_apply_min_commission( + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Current time for the current block."] + pub fn now( &self, - validator_stash: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "force_apply_min_commission", - types::ForceApplyMinCommission { validator_stash }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u64, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Timestamp", + "Now", + vec![], [ - 136u8, 163u8, 85u8, 134u8, 240u8, 247u8, 183u8, 227u8, 226u8, 202u8, - 102u8, 186u8, 138u8, 119u8, 78u8, 123u8, 229u8, 135u8, 129u8, 241u8, - 119u8, 106u8, 41u8, 182u8, 121u8, 181u8, 242u8, 175u8, 74u8, 207u8, - 64u8, 106u8, + 148u8, 53u8, 50u8, 54u8, 13u8, 161u8, 57u8, 150u8, 16u8, 83u8, 144u8, + 221u8, 59u8, 75u8, 158u8, 130u8, 39u8, 123u8, 106u8, 134u8, 202u8, + 185u8, 83u8, 85u8, 60u8, 41u8, 120u8, 96u8, 210u8, 34u8, 2u8, 250u8, ], ) } - #[doc = "Sets the minimum amount of commission that each validators must maintain."] - #[doc = ""] - #[doc = "This call has lower privilege requirements than `set_staking_config` and can be called"] - #[doc = "by the `T::AdminOrigin`. Root can always call this."] - pub fn set_min_commission( + #[doc = " Did the timestamp get updated in this block?"] + pub fn did_update( &self, - new: runtime_types::sp_arithmetic::per_things::Perbill, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Staking", - "set_min_commission", - SetMinCommission { new }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Timestamp", + "DidUpdate", + vec![], [ - 62u8, 139u8, 175u8, 245u8, 212u8, 113u8, 117u8, 130u8, 191u8, 173u8, - 78u8, 97u8, 19u8, 104u8, 185u8, 207u8, 201u8, 14u8, 200u8, 208u8, - 184u8, 195u8, 242u8, 175u8, 158u8, 156u8, 51u8, 58u8, 118u8, 154u8, - 68u8, 221u8, + 70u8, 13u8, 92u8, 186u8, 80u8, 151u8, 167u8, 90u8, 158u8, 232u8, 175u8, + 13u8, 103u8, 135u8, 2u8, 78u8, 16u8, 6u8, 39u8, 158u8, 167u8, 85u8, + 27u8, 47u8, 122u8, 73u8, 127u8, 26u8, 35u8, 168u8, 72u8, 204u8, ], ) } } } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_staking::pallet::pallet::Event; - pub mod events { + pub mod constants { use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The era payout has been set; the first balance is the validator-payout; the second is"] - #[doc = "the remainder from the maximum amount of reward."] - pub struct EraPaid { - pub era_index: ::core::primitive::u32, - pub validator_payout: ::core::primitive::u128, - pub remainder: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for EraPaid { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "EraPaid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The nominator has been rewarded by this amount."] - pub struct Rewarded { - pub stash: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Rewarded { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "Rewarded"; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The minimum period between blocks. Beware that this is different to the *expected*"] + #[doc = " period that the block production apparatus provides. Your chosen consensus system will"] + #[doc = " generally work with this to determine a sensible block time. e.g. For Aura, it will be"] + #[doc = " double this period on default settings."] + pub fn minimum_period( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u64> { + ::subxt::constants::Address::new_static( + "Timestamp", + "MinimumPeriod", + [ + 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, + 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, + 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, + 246u8, + ], + ) + } } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A staker (validator or nominator) has been slashed by the given amount."] - pub struct Slashed { - pub staker: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, + } + } + pub mod indices { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_indices::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Claim { + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Transfer { + pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Free { + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceTransfer { + pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub index: ::core::primitive::u32, + pub freeze: ::core::primitive::bool, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Freeze { + pub index: ::core::primitive::u32, + } } - impl ::subxt::events::StaticEvent for Slashed { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "Slashed"; + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Assign an previously unassigned index."] + #[doc = ""] + #[doc = "Payment: `Deposit` is reserved from the sender account."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "- `index`: the index to be claimed. This must not be in use."] + #[doc = ""] + #[doc = "Emits `IndexAssigned` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(1)`."] + pub fn claim( + &self, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Indices", + "claim", + types::Claim { index }, + [ + 5u8, 24u8, 11u8, 173u8, 226u8, 170u8, 0u8, 30u8, 193u8, 102u8, 214u8, + 59u8, 252u8, 32u8, 221u8, 88u8, 196u8, 189u8, 244u8, 18u8, 233u8, 37u8, + 228u8, 248u8, 76u8, 175u8, 212u8, 233u8, 238u8, 203u8, 162u8, 68u8, + ], + ) + } + #[doc = "Assign an index already owned by the sender to another account. The balance reservation"] + #[doc = "is effectively transferred to the new account."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "- `index`: the index to be re-assigned. This must be owned by the sender."] + #[doc = "- `new`: the new owner of the index. This function is a no-op if it is equal to sender."] + #[doc = ""] + #[doc = "Emits `IndexAssigned` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(1)`."] + pub fn transfer( + &self, + new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Indices", + "transfer", + types::Transfer { new, index }, + [ + 154u8, 191u8, 183u8, 50u8, 185u8, 69u8, 126u8, 132u8, 12u8, 77u8, + 146u8, 189u8, 254u8, 7u8, 72u8, 191u8, 118u8, 102u8, 180u8, 2u8, 161u8, + 151u8, 68u8, 93u8, 79u8, 45u8, 97u8, 202u8, 131u8, 103u8, 174u8, 189u8, + ], + ) + } + #[doc = "Free up an index owned by the sender."] + #[doc = ""] + #[doc = "Payment: Any previous deposit placed for the index is unreserved in the sender account."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must own the index."] + #[doc = ""] + #[doc = "- `index`: the index to be freed. This must be owned by the sender."] + #[doc = ""] + #[doc = "Emits `IndexFreed` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(1)`."] + pub fn free( + &self, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Indices", + "free", + types::Free { index }, + [ + 133u8, 202u8, 225u8, 127u8, 69u8, 145u8, 43u8, 13u8, 160u8, 248u8, + 215u8, 243u8, 232u8, 166u8, 74u8, 203u8, 235u8, 138u8, 255u8, 27u8, + 163u8, 71u8, 254u8, 217u8, 6u8, 208u8, 202u8, 204u8, 238u8, 70u8, + 126u8, 252u8, + ], + ) + } + #[doc = "Force an index to an account. This doesn't require a deposit. If the index is already"] + #[doc = "held, then any deposit is reimbursed to its current owner."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Root_."] + #[doc = ""] + #[doc = "- `index`: the index to be (re-)assigned."] + #[doc = "- `new`: the new owner of the index. This function is a no-op if it is equal to sender."] + #[doc = "- `freeze`: if set to `true`, will freeze the index so it cannot be transferred."] + #[doc = ""] + #[doc = "Emits `IndexAssigned` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(1)`."] + pub fn force_transfer( + &self, + new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + index: ::core::primitive::u32, + freeze: ::core::primitive::bool, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Indices", + "force_transfer", + types::ForceTransfer { new, index, freeze }, + [ + 37u8, 220u8, 91u8, 118u8, 222u8, 81u8, 225u8, 131u8, 101u8, 203u8, + 60u8, 149u8, 102u8, 92u8, 58u8, 91u8, 227u8, 64u8, 229u8, 62u8, 201u8, + 57u8, 168u8, 11u8, 51u8, 149u8, 146u8, 156u8, 209u8, 226u8, 11u8, + 181u8, + ], + ) + } + #[doc = "Freeze an index so it will always point to the sender account. This consumes the"] + #[doc = "deposit."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the signing account must have a"] + #[doc = "non-frozen account `index`."] + #[doc = ""] + #[doc = "- `index`: the index to be frozen in place."] + #[doc = ""] + #[doc = "Emits `IndexFrozen` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(1)`."] + pub fn freeze( + &self, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Indices", + "freeze", + types::Freeze { index }, + [ + 121u8, 45u8, 118u8, 2u8, 72u8, 48u8, 38u8, 7u8, 234u8, 204u8, 68u8, + 20u8, 76u8, 251u8, 205u8, 246u8, 149u8, 31u8, 168u8, 186u8, 208u8, + 90u8, 40u8, 47u8, 100u8, 228u8, 188u8, 33u8, 79u8, 220u8, 105u8, 209u8, + ], + ) + } } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_indices::pallet::Event; + pub mod events { + use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -6892,16 +6789,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A slash for the given validator, for the given percentage of their stake, at the given"] - #[doc = "era as been reported."] - pub struct SlashReported { - pub validator: ::subxt::utils::AccountId32, - pub fraction: runtime_types::sp_arithmetic::per_things::Perbill, - pub slash_era: ::core::primitive::u32, + #[doc = "A account index was assigned."] + pub struct IndexAssigned { + pub who: ::subxt::utils::AccountId32, + pub index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for SlashReported { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "SlashReported"; + impl ::subxt::events::StaticEvent for IndexAssigned { + const PALLET: &'static str = "Indices"; + const EVENT: &'static str = "IndexAssigned"; } #[derive( :: subxt :: ext :: codec :: CompactAs, @@ -6914,182 +6809,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An old slashing report from a prior era was discarded because it could"] - #[doc = "not be processed."] - pub struct OldSlashingReportDiscarded { - pub session_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for OldSlashingReportDiscarded { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "OldSlashingReportDiscarded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new set of stakers was elected."] - pub struct StakersElected; - impl ::subxt::events::StaticEvent for StakersElected { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "StakersElected"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has bonded this amount. \\[stash, amount\\]"] - #[doc = ""] - #[doc = "NOTE: This event is only emitted when funds are bonded via a dispatchable. Notably,"] - #[doc = "it will not be emitted for staking rewards when they are added to stake."] - pub struct Bonded { - pub stash: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Bonded { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "Bonded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has unbonded this amount."] - pub struct Unbonded { - pub stash: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Unbonded { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "Unbonded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has called `withdraw_unbonded` and removed unbonding chunks worth `Balance`"] - #[doc = "from the unlocking queue."] - pub struct Withdrawn { - pub stash: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Withdrawn { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "Withdrawn"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A nominator has been kicked from a validator."] - pub struct Kicked { - pub nominator: ::subxt::utils::AccountId32, - pub stash: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Kicked { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "Kicked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The election failed. No new era is planned."] - pub struct StakingElectionFailed; - impl ::subxt::events::StaticEvent for StakingElectionFailed { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "StakingElectionFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has stopped participating as either a validator or nominator."] - pub struct Chilled { - pub stash: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Chilled { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "Chilled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The stakers' rewards are getting paid."] - pub struct PayoutStarted { - pub era_index: ::core::primitive::u32, - pub validator_stash: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for PayoutStarted { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "PayoutStarted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A validator has set their preferences."] - pub struct ValidatorPrefsSet { - pub stash: ::subxt::utils::AccountId32, - pub prefs: runtime_types::pallet_staking::ValidatorPrefs, + #[doc = "A account index has been freed up (unassigned)."] + pub struct IndexFreed { + pub index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for ValidatorPrefsSet { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "ValidatorPrefsSet"; + impl ::subxt::events::StaticEvent for IndexFreed { + const PALLET: &'static str = "Indices"; + const EVENT: &'static str = "IndexFreed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -7101,1790 +6827,2641 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new force era mode was set."] - pub struct ForceEra { - pub mode: runtime_types::pallet_staking::Forcing, + #[doc = "A account index has been frozen to its current account ID."] + pub struct IndexFrozen { + pub index: ::core::primitive::u32, + pub who: ::subxt::utils::AccountId32, } - impl ::subxt::events::StaticEvent for ForceEra { - const PALLET: &'static str = "Staking"; - const EVENT: &'static str = "ForceEra"; + impl ::subxt::events::StaticEvent for IndexFrozen { + const PALLET: &'static str = "Indices"; + const EVENT: &'static str = "IndexFrozen"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " The ideal number of active validators."] - pub fn validator_count( + #[doc = " The lookup from index to account."] + pub fn accounts( &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + ( + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::bool, + ), + ::subxt::storage::address::Yes, (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Staking", - "ValidatorCount", - vec![], + "Indices", + "Accounts", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 245u8, 75u8, 214u8, 110u8, 66u8, 164u8, 86u8, 206u8, 69u8, 89u8, 12u8, - 111u8, 117u8, 16u8, 228u8, 184u8, 207u8, 6u8, 0u8, 126u8, 221u8, 67u8, - 125u8, 218u8, 188u8, 245u8, 156u8, 188u8, 34u8, 85u8, 208u8, 197u8, + 211u8, 169u8, 54u8, 254u8, 88u8, 57u8, 22u8, 223u8, 108u8, 27u8, 38u8, + 9u8, 202u8, 209u8, 111u8, 209u8, 144u8, 13u8, 211u8, 114u8, 239u8, + 127u8, 75u8, 166u8, 234u8, 222u8, 225u8, 35u8, 160u8, 163u8, 112u8, + 242u8, ], ) } - #[doc = " Minimum number of staking participants before emergency conditions are imposed."] - pub fn minimum_validator_count( + #[doc = " The lookup from index to account."] + pub fn accounts_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + ( + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::bool, + ), (), + (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Staking", - "MinimumValidatorCount", - vec![], + "Indices", + "Accounts", + Vec::new(), [ - 82u8, 95u8, 128u8, 55u8, 136u8, 134u8, 71u8, 117u8, 135u8, 76u8, 44u8, - 46u8, 174u8, 34u8, 170u8, 228u8, 175u8, 1u8, 234u8, 162u8, 91u8, 252u8, - 127u8, 68u8, 243u8, 241u8, 13u8, 107u8, 214u8, 70u8, 87u8, 249u8, + 211u8, 169u8, 54u8, 254u8, 88u8, 57u8, 22u8, 223u8, 108u8, 27u8, 38u8, + 9u8, 202u8, 209u8, 111u8, 209u8, 144u8, 13u8, 211u8, 114u8, 239u8, + 127u8, 75u8, 166u8, 234u8, 222u8, 225u8, 35u8, 160u8, 163u8, 112u8, + 242u8, ], ) } - #[doc = " Any validators that may never be slashed or forcibly kicked. It's a Vec since they're"] - #[doc = " easy to initialize and the performance hit is minimal (we expect no more than four"] - #[doc = " invulnerables) and restricted to testnets."] - pub fn invulnerables( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::AccountId32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "Invulnerables", - vec![], + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The deposit needed for reserving an index."] + pub fn deposit(&self) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Indices", + "Deposit", [ - 77u8, 78u8, 63u8, 199u8, 150u8, 167u8, 135u8, 130u8, 192u8, 51u8, - 202u8, 119u8, 68u8, 49u8, 241u8, 68u8, 82u8, 90u8, 226u8, 201u8, 96u8, - 170u8, 21u8, 173u8, 236u8, 116u8, 148u8, 8u8, 174u8, 92u8, 7u8, 11u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = " Map from all locked \"stash\" accounts to the controller account."] + } + } + } + pub mod balances { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_balances::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TransferAllowDeath { + pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetBalanceDeprecated { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub new_free: ::core::primitive::u128, + #[codec(compact)] + pub old_reserved: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceTransfer { + pub source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TransferKeepAlive { + pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TransferAll { + pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub keep_alive: ::core::primitive::bool, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceUnreserve { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub amount: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UpgradeAccounts { + pub who: ::std::vec::Vec<::subxt::utils::AccountId32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Transfer { + pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceSetBalance { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub new_free: ::core::primitive::u128, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Transfer some liquid free balance to another account."] #[doc = ""] - #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] - pub fn bonded( + #[doc = "`transfer_allow_death` will set the `FreeBalance` of the sender and receiver."] + #[doc = "If the sender's account is below the existential deposit as a result"] + #[doc = "of the transfer, the account will be reaped."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be `Signed` by the transactor."] + pub fn transfer_allow_death( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "Bonded", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "transfer_allow_death", + types::TransferAllowDeath { dest, value }, [ - 35u8, 197u8, 156u8, 60u8, 22u8, 59u8, 103u8, 83u8, 77u8, 15u8, 118u8, - 193u8, 155u8, 97u8, 229u8, 36u8, 119u8, 128u8, 224u8, 162u8, 21u8, - 46u8, 199u8, 221u8, 15u8, 74u8, 59u8, 70u8, 77u8, 218u8, 73u8, 165u8, + 234u8, 130u8, 149u8, 36u8, 235u8, 112u8, 159u8, 189u8, 104u8, 148u8, + 108u8, 230u8, 25u8, 198u8, 71u8, 158u8, 112u8, 3u8, 162u8, 25u8, 145u8, + 252u8, 44u8, 63u8, 47u8, 34u8, 47u8, 158u8, 61u8, 14u8, 120u8, 255u8, ], ) } - #[doc = " Map from all locked \"stash\" accounts to the controller account."] + #[doc = "Set the regular balance of a given account; it also takes a reserved balance but this"] + #[doc = "must be the same as the account's current reserved balance."] #[doc = ""] - #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] - pub fn bonded_root( + #[doc = "The dispatch origin for this call is `root`."] + #[doc = ""] + #[doc = "WARNING: This call is DEPRECATED! Use `force_set_balance` instead."] + pub fn set_balance_deprecated( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "Bonded", - Vec::new(), + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + new_free: ::core::primitive::u128, + old_reserved: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "set_balance_deprecated", + types::SetBalanceDeprecated { + who, + new_free, + old_reserved, + }, [ - 35u8, 197u8, 156u8, 60u8, 22u8, 59u8, 103u8, 83u8, 77u8, 15u8, 118u8, - 193u8, 155u8, 97u8, 229u8, 36u8, 119u8, 128u8, 224u8, 162u8, 21u8, - 46u8, 199u8, 221u8, 15u8, 74u8, 59u8, 70u8, 77u8, 218u8, 73u8, 165u8, + 240u8, 107u8, 184u8, 206u8, 78u8, 106u8, 115u8, 152u8, 130u8, 56u8, + 156u8, 176u8, 105u8, 27u8, 176u8, 187u8, 49u8, 171u8, 229u8, 79u8, + 254u8, 248u8, 8u8, 162u8, 134u8, 12u8, 89u8, 100u8, 137u8, 102u8, + 132u8, 158u8, ], ) } - #[doc = " The minimum active bond to become and maintain the role of a nominator."] - pub fn min_nominator_bond( + #[doc = "Exactly as `transfer_allow_death`, except the origin must be root and the source account"] + #[doc = "may be specified."] + pub fn force_transfer( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "MinNominatorBond", - vec![], + source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "force_transfer", + types::ForceTransfer { + source, + dest, + value, + }, [ - 187u8, 66u8, 149u8, 226u8, 72u8, 219u8, 57u8, 246u8, 102u8, 47u8, 71u8, - 12u8, 219u8, 204u8, 127u8, 223u8, 58u8, 134u8, 81u8, 165u8, 200u8, - 142u8, 196u8, 158u8, 26u8, 38u8, 165u8, 19u8, 91u8, 251u8, 119u8, 84u8, + 79u8, 174u8, 212u8, 108u8, 184u8, 33u8, 170u8, 29u8, 232u8, 254u8, + 195u8, 218u8, 221u8, 134u8, 57u8, 99u8, 6u8, 70u8, 181u8, 227u8, 56u8, + 239u8, 243u8, 158u8, 157u8, 245u8, 36u8, 162u8, 11u8, 237u8, 147u8, + 15u8, ], ) } - #[doc = " The minimum active bond to become and maintain the role of a validator."] - pub fn min_validator_bond( + #[doc = "Same as the [`transfer_allow_death`] call, but with a check that the transfer will not"] + #[doc = "kill the origin account."] + #[doc = ""] + #[doc = "99% of the time you want [`transfer_allow_death`] instead."] + #[doc = ""] + #[doc = "[`transfer_allow_death`]: struct.Pallet.html#method.transfer"] + pub fn transfer_keep_alive( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "MinValidatorBond", - vec![], + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "transfer_keep_alive", + types::TransferKeepAlive { dest, value }, [ - 48u8, 105u8, 85u8, 178u8, 142u8, 208u8, 208u8, 19u8, 236u8, 130u8, - 129u8, 169u8, 35u8, 245u8, 66u8, 182u8, 92u8, 20u8, 22u8, 109u8, 155u8, - 174u8, 87u8, 118u8, 242u8, 216u8, 193u8, 154u8, 4u8, 5u8, 66u8, 56u8, + 112u8, 179u8, 75u8, 168u8, 193u8, 221u8, 9u8, 82u8, 190u8, 113u8, + 253u8, 13u8, 130u8, 134u8, 170u8, 216u8, 136u8, 111u8, 242u8, 220u8, + 202u8, 112u8, 47u8, 79u8, 73u8, 244u8, 226u8, 59u8, 240u8, 188u8, + 210u8, 208u8, ], ) } - #[doc = " The minimum active nominator stake of the last successful election."] - pub fn minimum_active_stake( + #[doc = "Transfer the entire transferable balance from the caller account."] + #[doc = ""] + #[doc = "NOTE: This function only attempts to transfer _transferable_ balances. This means that"] + #[doc = "any locked, reserved, or existential deposits (when `keep_alive` is `true`), will not be"] + #[doc = "transferred by this function. To ensure that this function results in a killed account,"] + #[doc = "you might need to prepare the account by removing any reference counters, storage"] + #[doc = "deposits, etc..."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be Signed."] + #[doc = ""] + #[doc = "- `dest`: The recipient of the transfer."] + #[doc = "- `keep_alive`: A boolean to determine if the `transfer_all` operation should send all"] + #[doc = " of the funds the account has, causing the sender account to be killed (false), or"] + #[doc = " transfer everything except at least the existential deposit, which will guarantee to"] + #[doc = " keep the sender account alive (true)."] + pub fn transfer_all( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "MinimumActiveStake", - vec![], + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + keep_alive: ::core::primitive::bool, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "transfer_all", + types::TransferAll { dest, keep_alive }, [ - 172u8, 190u8, 228u8, 47u8, 47u8, 192u8, 182u8, 59u8, 9u8, 18u8, 103u8, - 46u8, 175u8, 54u8, 17u8, 79u8, 89u8, 107u8, 255u8, 200u8, 182u8, 107u8, - 89u8, 157u8, 55u8, 16u8, 77u8, 46u8, 154u8, 169u8, 103u8, 151u8, + 46u8, 129u8, 29u8, 177u8, 221u8, 107u8, 245u8, 69u8, 238u8, 126u8, + 145u8, 26u8, 219u8, 208u8, 14u8, 80u8, 149u8, 1u8, 214u8, 63u8, 67u8, + 201u8, 144u8, 45u8, 129u8, 145u8, 174u8, 71u8, 238u8, 113u8, 208u8, + 34u8, ], ) } - #[doc = " The minimum amount of commission that validators can set."] + #[doc = "Unreserve some balance from a user by force."] #[doc = ""] - #[doc = " If set to `0`, no limit exists."] - pub fn min_commission( + #[doc = "Can only be called by ROOT."] + pub fn force_unreserve( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::per_things::Perbill, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "MinCommission", - vec![], + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + amount: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "force_unreserve", + types::ForceUnreserve { who, amount }, [ - 61u8, 101u8, 69u8, 27u8, 220u8, 179u8, 5u8, 71u8, 66u8, 227u8, 84u8, - 98u8, 18u8, 141u8, 183u8, 49u8, 98u8, 46u8, 123u8, 114u8, 198u8, 85u8, - 15u8, 175u8, 243u8, 239u8, 133u8, 129u8, 146u8, 174u8, 254u8, 158u8, + 160u8, 146u8, 137u8, 76u8, 157u8, 187u8, 66u8, 148u8, 207u8, 76u8, + 32u8, 254u8, 82u8, 215u8, 35u8, 161u8, 213u8, 52u8, 32u8, 98u8, 102u8, + 106u8, 234u8, 123u8, 6u8, 175u8, 184u8, 188u8, 174u8, 106u8, 176u8, + 78u8, ], ) } - #[doc = " Map from all (unlocked) \"controller\" accounts to the info regarding the staking."] - pub fn ledger( + #[doc = "Upgrade a specified account."] + #[doc = ""] + #[doc = "- `origin`: Must be `Signed`."] + #[doc = "- `who`: The account to be upgraded."] + #[doc = ""] + #[doc = "This will waive the transaction fee if at least all but 10% of the accounts needed to"] + #[doc = "be upgraded. (We let some not have to be upgraded just in order to allow for the"] + #[doc = "possibililty of churn)."] + pub fn upgrade_accounts( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::StakingLedger, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "Ledger", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + who: ::std::vec::Vec<::subxt::utils::AccountId32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "upgrade_accounts", + types::UpgradeAccounts { who }, [ - 31u8, 205u8, 3u8, 165u8, 22u8, 22u8, 62u8, 92u8, 33u8, 189u8, 124u8, - 120u8, 177u8, 70u8, 27u8, 242u8, 188u8, 184u8, 204u8, 188u8, 242u8, - 140u8, 128u8, 230u8, 85u8, 99u8, 181u8, 173u8, 67u8, 252u8, 37u8, - 236u8, + 164u8, 61u8, 119u8, 24u8, 165u8, 46u8, 197u8, 59u8, 39u8, 198u8, 228u8, + 96u8, 228u8, 45u8, 85u8, 51u8, 37u8, 5u8, 75u8, 40u8, 241u8, 163u8, + 86u8, 228u8, 151u8, 217u8, 47u8, 105u8, 203u8, 103u8, 207u8, 4u8, ], ) } - #[doc = " Map from all (unlocked) \"controller\" accounts to the info regarding the staking."] - pub fn ledger_root( + #[doc = "Alias for `transfer_allow_death`, provided only for name-wise compatibility."] + #[doc = ""] + #[doc = "WARNING: DEPRECATED! Will be released in approximately 3 months."] + pub fn transfer( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::StakingLedger, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "Ledger", - Vec::new(), + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "transfer", + types::Transfer { dest, value }, [ - 31u8, 205u8, 3u8, 165u8, 22u8, 22u8, 62u8, 92u8, 33u8, 189u8, 124u8, - 120u8, 177u8, 70u8, 27u8, 242u8, 188u8, 184u8, 204u8, 188u8, 242u8, - 140u8, 128u8, 230u8, 85u8, 99u8, 181u8, 173u8, 67u8, 252u8, 37u8, - 236u8, + 111u8, 222u8, 32u8, 56u8, 171u8, 77u8, 252u8, 29u8, 194u8, 155u8, + 200u8, 192u8, 198u8, 81u8, 23u8, 115u8, 236u8, 91u8, 218u8, 114u8, + 107u8, 141u8, 138u8, 100u8, 237u8, 21u8, 58u8, 172u8, 3u8, 20u8, 216u8, + 38u8, ], ) } - #[doc = " Where the reward payment should be made. Keyed by stash."] + #[doc = "Set the regular balance of a given account."] #[doc = ""] - #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] - pub fn payee( + #[doc = "The dispatch origin for this call is `root`."] + pub fn force_set_balance( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::RewardDestination<::subxt::utils::AccountId32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + new_free: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "force_set_balance", + types::ForceSetBalance { who, new_free }, + [ + 237u8, 4u8, 41u8, 58u8, 62u8, 179u8, 160u8, 4u8, 50u8, 71u8, 178u8, + 36u8, 130u8, 130u8, 92u8, 229u8, 16u8, 245u8, 169u8, 109u8, 165u8, + 72u8, 94u8, 70u8, 196u8, 136u8, 37u8, 94u8, 140u8, 215u8, 125u8, 125u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_balances::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account was created with some free balance."] + pub struct Endowed { + pub account: ::subxt::utils::AccountId32, + pub free_balance: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Endowed { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Endowed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account was removed whose balance was non-zero but below ExistentialDeposit,"] + #[doc = "resulting in an outright loss."] + pub struct DustLost { + pub account: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for DustLost { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "DustLost"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Transfer succeeded."] + pub struct Transfer { + pub from: ::subxt::utils::AccountId32, + pub to: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Transfer { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Transfer"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A balance was set by root."] + pub struct BalanceSet { + pub who: ::subxt::utils::AccountId32, + pub free: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for BalanceSet { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "BalanceSet"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was reserved (moved from free to reserved)."] + pub struct Reserved { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Reserved { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Reserved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was unreserved (moved from reserved to free)."] + pub struct Unreserved { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Unreserved { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Unreserved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was moved from the reserve of the first account to the second account."] + #[doc = "Final argument indicates the destination balance type."] + pub struct ReserveRepatriated { + pub from: ::subxt::utils::AccountId32, + pub to: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + pub destination_status: + runtime_types::frame_support::traits::tokens::misc::BalanceStatus, + } + impl ::subxt::events::StaticEvent for ReserveRepatriated { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "ReserveRepatriated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was deposited (e.g. for transaction fees)."] + pub struct Deposit { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Deposit { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Deposit"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was withdrawn from the account (e.g. for transaction fees)."] + pub struct Withdraw { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Withdraw { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Withdraw"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was removed from the account (e.g. for misbehavior)."] + pub struct Slashed { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Slashed { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Slashed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was minted into an account."] + pub struct Minted { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Minted { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Minted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was burned from an account."] + pub struct Burned { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Burned { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Burned"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was suspended from an account (it can be restored later)."] + pub struct Suspended { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Suspended { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Suspended"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was restored into an account."] + pub struct Restored { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Restored { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Restored"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account was upgraded."] + pub struct Upgraded { + pub who: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for Upgraded { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Upgraded"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Total issuance was increased by `amount`, creating a credit to be balanced."] + pub struct Issued { + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Issued { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Issued"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Total issuance was decreased by `amount`, creating a debt to be balanced."] + pub struct Rescinded { + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Rescinded { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Rescinded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was locked."] + pub struct Locked { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Locked { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Locked"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was unlocked."] + pub struct Unlocked { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Unlocked { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Unlocked"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was frozen."] + pub struct Frozen { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Frozen { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Frozen"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was thawed."] + pub struct Thawed { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Thawed { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Thawed"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The total units issued in the system."] + pub fn total_issuance( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Staking", - "Payee", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Balances", + "TotalIssuance", + vec![], [ - 195u8, 125u8, 82u8, 213u8, 216u8, 64u8, 76u8, 63u8, 187u8, 163u8, 20u8, - 230u8, 153u8, 13u8, 189u8, 232u8, 119u8, 118u8, 107u8, 17u8, 102u8, - 245u8, 36u8, 42u8, 232u8, 137u8, 177u8, 165u8, 169u8, 246u8, 199u8, - 57u8, + 1u8, 206u8, 252u8, 237u8, 6u8, 30u8, 20u8, 232u8, 164u8, 115u8, 51u8, + 156u8, 156u8, 206u8, 241u8, 187u8, 44u8, 84u8, 25u8, 164u8, 235u8, + 20u8, 86u8, 242u8, 124u8, 23u8, 28u8, 140u8, 26u8, 73u8, 231u8, 51u8, ], ) } - #[doc = " Where the reward payment should be made. Keyed by stash."] - #[doc = ""] - #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] - pub fn payee_root( + #[doc = " The total units of outstanding deactivated balance in the system."] + pub fn inactive_issuance( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::RewardDestination<::subxt::utils::AccountId32>, - (), + ::core::primitive::u128, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Staking", - "Payee", - Vec::new(), + "Balances", + "InactiveIssuance", + vec![], [ - 195u8, 125u8, 82u8, 213u8, 216u8, 64u8, 76u8, 63u8, 187u8, 163u8, 20u8, - 230u8, 153u8, 13u8, 189u8, 232u8, 119u8, 118u8, 107u8, 17u8, 102u8, - 245u8, 36u8, 42u8, 232u8, 137u8, 177u8, 165u8, 169u8, 246u8, 199u8, - 57u8, + 74u8, 203u8, 111u8, 142u8, 225u8, 104u8, 173u8, 51u8, 226u8, 12u8, + 85u8, 135u8, 41u8, 206u8, 177u8, 238u8, 94u8, 246u8, 184u8, 250u8, + 140u8, 213u8, 91u8, 118u8, 163u8, 111u8, 211u8, 46u8, 204u8, 160u8, + 154u8, 21u8, ], ) } - #[doc = " The map from (wannabe) validator stash key to the preferences of that validator."] + #[doc = " The Balances pallet example of storing the balance of an account."] #[doc = ""] - #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] - pub fn validators( + #[doc = " # Example"] + #[doc = ""] + #[doc = " ```nocompile"] + #[doc = " impl pallet_balances::Config for Runtime {"] + #[doc = " type AccountStore = StorageMapShim, frame_system::Provider, AccountId, Self::AccountData>"] + #[doc = " }"] + #[doc = " ```"] + #[doc = ""] + #[doc = " You can also store the balance of an account in the `System` pallet."] + #[doc = ""] + #[doc = " # Example"] + #[doc = ""] + #[doc = " ```nocompile"] + #[doc = " impl pallet_balances::Config for Runtime {"] + #[doc = " type AccountStore = System"] + #[doc = " }"] + #[doc = " ```"] + #[doc = ""] + #[doc = " But this comes with tradeoffs, storing account balances in the system pallet stores"] + #[doc = " `frame_system` data alongside the account data contrary to storing account balances in the"] + #[doc = " `Balances` pallet, which uses a `StorageMap` to store balances data only."] + #[doc = " NOTE: This is only used in the case that this pallet is used to store balances."] + pub fn account( &self, _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::ValidatorPrefs, + runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Staking", - "Validators", + "Balances", + "Account", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 80u8, 77u8, 66u8, 18u8, 197u8, 250u8, 41u8, 185u8, 43u8, 24u8, 149u8, - 164u8, 208u8, 60u8, 144u8, 29u8, 251u8, 195u8, 236u8, 196u8, 108u8, - 58u8, 80u8, 115u8, 246u8, 66u8, 226u8, 241u8, 201u8, 172u8, 229u8, - 152u8, + 109u8, 250u8, 18u8, 96u8, 139u8, 232u8, 4u8, 139u8, 133u8, 239u8, 30u8, + 237u8, 73u8, 209u8, 143u8, 160u8, 94u8, 248u8, 124u8, 43u8, 224u8, + 165u8, 11u8, 6u8, 176u8, 144u8, 189u8, 161u8, 174u8, 210u8, 56u8, + 225u8, ], ) } - #[doc = " The map from (wannabe) validator stash key to the preferences of that validator."] + #[doc = " The Balances pallet example of storing the balance of an account."] #[doc = ""] - #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] - pub fn validators_root( + #[doc = " # Example"] + #[doc = ""] + #[doc = " ```nocompile"] + #[doc = " impl pallet_balances::Config for Runtime {"] + #[doc = " type AccountStore = StorageMapShim, frame_system::Provider, AccountId, Self::AccountData>"] + #[doc = " }"] + #[doc = " ```"] + #[doc = ""] + #[doc = " You can also store the balance of an account in the `System` pallet."] + #[doc = ""] + #[doc = " # Example"] + #[doc = ""] + #[doc = " ```nocompile"] + #[doc = " impl pallet_balances::Config for Runtime {"] + #[doc = " type AccountStore = System"] + #[doc = " }"] + #[doc = " ```"] + #[doc = ""] + #[doc = " But this comes with tradeoffs, storing account balances in the system pallet stores"] + #[doc = " `frame_system` data alongside the account data contrary to storing account balances in the"] + #[doc = " `Balances` pallet, which uses a `StorageMap` to store balances data only."] + #[doc = " NOTE: This is only used in the case that this pallet is used to store balances."] + pub fn account_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::ValidatorPrefs, + runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, (), ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Staking", - "Validators", + "Balances", + "Account", Vec::new(), [ - 80u8, 77u8, 66u8, 18u8, 197u8, 250u8, 41u8, 185u8, 43u8, 24u8, 149u8, - 164u8, 208u8, 60u8, 144u8, 29u8, 251u8, 195u8, 236u8, 196u8, 108u8, - 58u8, 80u8, 115u8, 246u8, 66u8, 226u8, 241u8, 201u8, 172u8, 229u8, - 152u8, + 109u8, 250u8, 18u8, 96u8, 139u8, 232u8, 4u8, 139u8, 133u8, 239u8, 30u8, + 237u8, 73u8, 209u8, 143u8, 160u8, 94u8, 248u8, 124u8, 43u8, 224u8, + 165u8, 11u8, 6u8, 176u8, 144u8, 189u8, 161u8, 174u8, 210u8, 56u8, + 225u8, ], ) } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_validators( + #[doc = " Any liquidity locks on some account balances."] + #[doc = " NOTE: Should only be accessed when setting, changing and freeing a lock."] + pub fn locks( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, + >, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), > { ::subxt::storage::address::Address::new_static( - "Staking", - "CounterForValidators", - vec![], + "Balances", + "Locks", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 139u8, 25u8, 223u8, 6u8, 160u8, 239u8, 212u8, 85u8, 36u8, 185u8, 69u8, - 63u8, 21u8, 156u8, 144u8, 241u8, 112u8, 85u8, 49u8, 78u8, 88u8, 11u8, - 8u8, 48u8, 118u8, 34u8, 62u8, 159u8, 239u8, 122u8, 90u8, 45u8, + 216u8, 253u8, 87u8, 73u8, 24u8, 218u8, 35u8, 0u8, 244u8, 134u8, 195u8, + 58u8, 255u8, 64u8, 153u8, 212u8, 210u8, 232u8, 4u8, 122u8, 90u8, 212u8, + 136u8, 14u8, 127u8, 232u8, 8u8, 192u8, 40u8, 233u8, 18u8, 250u8, ], ) } - #[doc = " The maximum validator count before we stop allowing new validators to join."] - #[doc = ""] - #[doc = " When this value is not set, no limits are enforced."] - pub fn max_validators_count( + #[doc = " Any liquidity locks on some account balances."] + #[doc = " NOTE: Should only be accessed when setting, changing and freeing a lock."] + pub fn locks_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, + >, (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Staking", - "MaxValidatorsCount", - vec![], + "Balances", + "Locks", + Vec::new(), [ - 250u8, 62u8, 16u8, 68u8, 192u8, 216u8, 236u8, 211u8, 217u8, 9u8, 213u8, - 49u8, 41u8, 37u8, 58u8, 62u8, 131u8, 112u8, 64u8, 26u8, 133u8, 7u8, - 130u8, 1u8, 71u8, 158u8, 14u8, 55u8, 169u8, 239u8, 223u8, 245u8, + 216u8, 253u8, 87u8, 73u8, 24u8, 218u8, 35u8, 0u8, 244u8, 134u8, 195u8, + 58u8, 255u8, 64u8, 153u8, 212u8, 210u8, 232u8, 4u8, 122u8, 90u8, 212u8, + 136u8, 14u8, 127u8, 232u8, 8u8, 192u8, 40u8, 233u8, 18u8, 250u8, ], ) } - #[doc = " The map from nominator stash key to their nomination preferences, namely the validators that"] - #[doc = " they wish to support."] - #[doc = ""] - #[doc = " Note that the keys of this storage map might become non-decodable in case the"] - #[doc = " [`Config::MaxNominations`] configuration is decreased. In this rare case, these nominators"] - #[doc = " are still existent in storage, their key is correct and retrievable (i.e. `contains_key`"] - #[doc = " indicates that they exist), but their value cannot be decoded. Therefore, the non-decodable"] - #[doc = " nominators will effectively not-exist, until they re-submit their preferences such that it"] - #[doc = " is within the bounds of the newly set `Config::MaxNominations`."] - #[doc = ""] - #[doc = " This implies that `::iter_keys().count()` and `::iter().count()` might return different"] - #[doc = " values for this map. Moreover, the main `::count()` is aligned with the former, namely the"] - #[doc = " number of keys that exist."] - #[doc = ""] - #[doc = " Lastly, if any of the nominators become non-decodable, they can be chilled immediately via"] - #[doc = " [`Call::chill_other`] dispatchable by anyone."] - #[doc = ""] - #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] - pub fn nominators( + #[doc = " Named reserves on some account balances."] + pub fn reserves( &self, _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::Nominations, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::ReserveData< + [::core::primitive::u8; 8usize], + ::core::primitive::u128, + >, + >, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Staking", - "Nominators", + "Balances", + "Reserves", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 1u8, 154u8, 55u8, 170u8, 215u8, 64u8, 56u8, 83u8, 254u8, 19u8, 152u8, - 85u8, 164u8, 171u8, 206u8, 129u8, 184u8, 45u8, 221u8, 181u8, 229u8, - 133u8, 200u8, 231u8, 16u8, 146u8, 247u8, 21u8, 77u8, 122u8, 165u8, - 134u8, + 17u8, 32u8, 191u8, 46u8, 76u8, 220u8, 101u8, 100u8, 42u8, 250u8, 128u8, + 167u8, 117u8, 44u8, 85u8, 96u8, 105u8, 216u8, 16u8, 147u8, 74u8, 55u8, + 183u8, 94u8, 160u8, 177u8, 26u8, 187u8, 71u8, 197u8, 187u8, 163u8, ], ) } - #[doc = " The map from nominator stash key to their nomination preferences, namely the validators that"] - #[doc = " they wish to support."] - #[doc = ""] - #[doc = " Note that the keys of this storage map might become non-decodable in case the"] - #[doc = " [`Config::MaxNominations`] configuration is decreased. In this rare case, these nominators"] - #[doc = " are still existent in storage, their key is correct and retrievable (i.e. `contains_key`"] - #[doc = " indicates that they exist), but their value cannot be decoded. Therefore, the non-decodable"] - #[doc = " nominators will effectively not-exist, until they re-submit their preferences such that it"] - #[doc = " is within the bounds of the newly set `Config::MaxNominations`."] - #[doc = ""] - #[doc = " This implies that `::iter_keys().count()` and `::iter().count()` might return different"] - #[doc = " values for this map. Moreover, the main `::count()` is aligned with the former, namely the"] - #[doc = " number of keys that exist."] - #[doc = ""] - #[doc = " Lastly, if any of the nominators become non-decodable, they can be chilled immediately via"] - #[doc = " [`Call::chill_other`] dispatchable by anyone."] - #[doc = ""] - #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] - pub fn nominators_root( + #[doc = " Named reserves on some account balances."] + pub fn reserves_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::Nominations, - (), + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::ReserveData< + [::core::primitive::u8; 8usize], + ::core::primitive::u128, + >, + >, (), ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Staking", - "Nominators", + "Balances", + "Reserves", Vec::new(), [ - 1u8, 154u8, 55u8, 170u8, 215u8, 64u8, 56u8, 83u8, 254u8, 19u8, 152u8, - 85u8, 164u8, 171u8, 206u8, 129u8, 184u8, 45u8, 221u8, 181u8, 229u8, - 133u8, 200u8, 231u8, 16u8, 146u8, 247u8, 21u8, 77u8, 122u8, 165u8, - 134u8, + 17u8, 32u8, 191u8, 46u8, 76u8, 220u8, 101u8, 100u8, 42u8, 250u8, 128u8, + 167u8, 117u8, 44u8, 85u8, 96u8, 105u8, 216u8, 16u8, 147u8, 74u8, 55u8, + 183u8, 94u8, 160u8, 177u8, 26u8, 187u8, 71u8, 197u8, 187u8, 163u8, ], ) } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_nominators( + #[doc = " Holds on account balances."] + pub fn holds( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::IdAmount< + (), + ::core::primitive::u128, + >, + >, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "CounterForNominators", - vec![], - [ - 31u8, 94u8, 130u8, 138u8, 75u8, 8u8, 38u8, 162u8, 181u8, 5u8, 125u8, - 116u8, 9u8, 51u8, 22u8, 234u8, 40u8, 117u8, 215u8, 46u8, 82u8, 117u8, - 225u8, 1u8, 9u8, 208u8, 83u8, 63u8, 39u8, 187u8, 207u8, 191u8, - ], - ) - } - #[doc = " The maximum nominator count before we stop allowing new validators to join."] - #[doc = ""] - #[doc = " When this value is not set, no limits are enforced."] - pub fn max_nominators_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, ::subxt::storage::address::Yes, - (), - (), > { ::subxt::storage::address::Address::new_static( - "Staking", - "MaxNominatorsCount", - vec![], + "Balances", + "Holds", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 180u8, 190u8, 180u8, 66u8, 235u8, 173u8, 76u8, 160u8, 197u8, 92u8, - 96u8, 165u8, 220u8, 188u8, 32u8, 119u8, 3u8, 73u8, 86u8, 49u8, 104u8, - 17u8, 186u8, 98u8, 221u8, 175u8, 109u8, 254u8, 207u8, 245u8, 125u8, - 179u8, + 247u8, 81u8, 4u8, 220u8, 77u8, 205u8, 28u8, 131u8, 215u8, 74u8, 197u8, + 137u8, 113u8, 214u8, 249u8, 91u8, 81u8, 216u8, 8u8, 5u8, 233u8, 39u8, + 104u8, 250u8, 3u8, 228u8, 148u8, 78u8, 4u8, 34u8, 45u8, 143u8, ], ) } - #[doc = " The current era index."] - #[doc = ""] - #[doc = " This is the latest planned era, depending on how the Session pallet queues the validator"] - #[doc = " set, it might be active or not."] - pub fn current_era( + #[doc = " Holds on account balances."] + pub fn holds_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::IdAmount< + (), + ::core::primitive::u128, + >, + >, (), - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "CurrentEra", - vec![], - [ - 105u8, 150u8, 49u8, 122u8, 4u8, 78u8, 8u8, 121u8, 34u8, 136u8, 157u8, - 227u8, 59u8, 139u8, 7u8, 253u8, 7u8, 10u8, 117u8, 71u8, 240u8, 74u8, - 86u8, 36u8, 198u8, 37u8, 153u8, 93u8, 196u8, 22u8, 192u8, 243u8, - ], - ) - } - #[doc = " The active era information, it holds index and start."] - #[doc = ""] - #[doc = " The active era is the era being currently rewarded. Validator set of this era must be"] - #[doc = " equal to [`SessionInterface::validators`]."] - pub fn active_era( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::ActiveEraInfo, ::subxt::storage::address::Yes, - (), - (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Staking", - "ActiveEra", - vec![], + "Balances", + "Holds", + Vec::new(), [ - 15u8, 112u8, 251u8, 183u8, 108u8, 61u8, 28u8, 71u8, 44u8, 150u8, 162u8, - 4u8, 143u8, 121u8, 11u8, 37u8, 83u8, 29u8, 193u8, 21u8, 210u8, 116u8, - 190u8, 236u8, 213u8, 235u8, 49u8, 97u8, 189u8, 142u8, 251u8, 124u8, + 247u8, 81u8, 4u8, 220u8, 77u8, 205u8, 28u8, 131u8, 215u8, 74u8, 197u8, + 137u8, 113u8, 214u8, 249u8, 91u8, 81u8, 216u8, 8u8, 5u8, 233u8, 39u8, + 104u8, 250u8, 3u8, 228u8, 148u8, 78u8, 4u8, 34u8, 45u8, 143u8, ], ) } - #[doc = " The session index at which the era start for the last `HISTORY_DEPTH` eras."] - #[doc = ""] - #[doc = " Note: This tracks the starting session (i.e. session index when era start being active)"] - #[doc = " for the eras in `[CurrentEra - HISTORY_DEPTH, CurrentEra]`."] - pub fn eras_start_session_index( + #[doc = " Freeze locks on account balances."] + pub fn freezes( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::IdAmount< + (), + ::core::primitive::u128, + >, + >, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Staking", - "ErasStartSessionIndex", + "Balances", + "Freezes", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 92u8, 157u8, 168u8, 144u8, 132u8, 3u8, 212u8, 80u8, 230u8, 229u8, - 251u8, 218u8, 97u8, 55u8, 79u8, 100u8, 163u8, 91u8, 32u8, 246u8, 122u8, - 78u8, 149u8, 214u8, 103u8, 249u8, 119u8, 20u8, 101u8, 116u8, 110u8, - 185u8, + 211u8, 24u8, 237u8, 217u8, 47u8, 230u8, 147u8, 39u8, 112u8, 209u8, + 193u8, 47u8, 242u8, 13u8, 241u8, 0u8, 100u8, 45u8, 116u8, 130u8, 246u8, + 196u8, 50u8, 134u8, 135u8, 112u8, 206u8, 1u8, 12u8, 53u8, 106u8, 131u8, ], ) } - #[doc = " The session index at which the era start for the last `HISTORY_DEPTH` eras."] - #[doc = ""] - #[doc = " Note: This tracks the starting session (i.e. session index when era start being active)"] - #[doc = " for the eras in `[CurrentEra - HISTORY_DEPTH, CurrentEra]`."] - pub fn eras_start_session_index_root( + #[doc = " Freeze locks on account balances."] + pub fn freezes_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::IdAmount< + (), + ::core::primitive::u128, + >, + >, (), ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Staking", - "ErasStartSessionIndex", + "Balances", + "Freezes", Vec::new(), [ - 92u8, 157u8, 168u8, 144u8, 132u8, 3u8, 212u8, 80u8, 230u8, 229u8, - 251u8, 218u8, 97u8, 55u8, 79u8, 100u8, 163u8, 91u8, 32u8, 246u8, 122u8, - 78u8, 149u8, 214u8, 103u8, 249u8, 119u8, 20u8, 101u8, 116u8, 110u8, - 185u8, + 211u8, 24u8, 237u8, 217u8, 47u8, 230u8, 147u8, 39u8, 112u8, 209u8, + 193u8, 47u8, 242u8, 13u8, 241u8, 0u8, 100u8, 45u8, 116u8, 130u8, 246u8, + 196u8, 50u8, 134u8, 135u8, 112u8, 206u8, 1u8, 12u8, 53u8, 106u8, 131u8, ], ) } - #[doc = " Exposure of validator at era."] + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The minimum amount required to keep an account open. MUST BE GREATER THAN ZERO!"] #[doc = ""] - #[doc = " This is keyed first by the era index to allow bulk deletion and then the stash account."] + #[doc = " If you *really* need it to be zero, you can enable the feature `insecure_zero_ed` for"] + #[doc = " this pallet. However, you do so at your own risk: this will open up a major DoS vector."] + #[doc = " In case you have multiple sources of provider references, you may also get unexpected"] + #[doc = " behaviour if you set this to zero."] #[doc = ""] - #[doc = " Is it removed after `HISTORY_DEPTH` eras."] - #[doc = " If stakers hasn't been set or has been removed then empty exposure is returned."] - pub fn eras_stakers( + #[doc = " Bottom line: Do yourself a favour and make it at least one!"] + pub fn existential_deposit( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Balances", + "ExistentialDeposit", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The maximum number of locks that should exist on an account."] + #[doc = " Not strictly enforced, but used for weight estimation."] + pub fn max_locks(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Balances", + "MaxLocks", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The maximum number of named reserves that can exist on an account."] + pub fn max_reserves(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Balances", + "MaxReserves", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The maximum number of holds that can exist on an account at any time."] + pub fn max_holds(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Balances", + "MaxHolds", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The maximum number of individual freeze locks that can exist on an account at any time."] + pub fn max_freezes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Balances", + "MaxFreezes", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod transaction_payment { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_transaction_payment::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A transaction fee `actual_fee`, of which `tip` was added to the minimum inclusion fee,"] + #[doc = "has been paid by `who`."] + pub struct TransactionFeePaid { + pub who: ::subxt::utils::AccountId32, + pub actual_fee: ::core::primitive::u128, + pub tip: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for TransactionFeePaid { + const PALLET: &'static str = "TransactionPayment"; + const EVENT: &'static str = "TransactionFeePaid"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + pub fn next_fee_multiplier( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::Exposure< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, + runtime_types::sp_arithmetic::fixed_point::FixedU128, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Staking", - "ErasStakers", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + "TransactionPayment", + "NextFeeMultiplier", + vec![], [ - 192u8, 50u8, 152u8, 151u8, 92u8, 180u8, 206u8, 15u8, 139u8, 210u8, - 128u8, 65u8, 92u8, 253u8, 43u8, 35u8, 139u8, 171u8, 73u8, 185u8, 32u8, - 78u8, 20u8, 197u8, 154u8, 90u8, 233u8, 231u8, 23u8, 22u8, 187u8, 156u8, + 210u8, 0u8, 206u8, 165u8, 183u8, 10u8, 206u8, 52u8, 14u8, 90u8, 218u8, + 197u8, 189u8, 125u8, 113u8, 216u8, 52u8, 161u8, 45u8, 24u8, 245u8, + 237u8, 121u8, 41u8, 106u8, 29u8, 45u8, 129u8, 250u8, 203u8, 206u8, + 180u8, ], ) } - #[doc = " Exposure of validator at era."] - #[doc = ""] - #[doc = " This is keyed first by the era index to allow bulk deletion and then the stash account."] - #[doc = ""] - #[doc = " Is it removed after `HISTORY_DEPTH` eras."] - #[doc = " If stakers hasn't been set or has been removed then empty exposure is returned."] - pub fn eras_stakers_root( + pub fn storage_version( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::Exposure< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - (), + runtime_types::pallet_transaction_payment::Releases, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Staking", - "ErasStakers", - Vec::new(), + "TransactionPayment", + "StorageVersion", + vec![], [ - 192u8, 50u8, 152u8, 151u8, 92u8, 180u8, 206u8, 15u8, 139u8, 210u8, - 128u8, 65u8, 92u8, 253u8, 43u8, 35u8, 139u8, 171u8, 73u8, 185u8, 32u8, - 78u8, 20u8, 197u8, 154u8, 90u8, 233u8, 231u8, 23u8, 22u8, 187u8, 156u8, + 219u8, 243u8, 82u8, 176u8, 65u8, 5u8, 132u8, 114u8, 8u8, 82u8, 176u8, + 200u8, 97u8, 150u8, 177u8, 164u8, 166u8, 11u8, 34u8, 12u8, 12u8, 198u8, + 58u8, 191u8, 186u8, 221u8, 221u8, 119u8, 181u8, 253u8, 154u8, 228u8, ], ) } - #[doc = " Clipped Exposure of validator at era."] - #[doc = ""] - #[doc = " This is similar to [`ErasStakers`] but number of nominators exposed is reduced to the"] - #[doc = " `T::MaxNominatorRewardedPerValidator` biggest stakers."] - #[doc = " (Note: the field `total` and `own` of the exposure remains unchanged)."] - #[doc = " This is used to limit the i/o cost for the nominator payout."] - #[doc = ""] - #[doc = " This is keyed fist by the era index to allow bulk deletion and then the stash account."] + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " A fee mulitplier for `Operational` extrinsics to compute \"virtual tip\" to boost their"] + #[doc = " `priority`"] #[doc = ""] - #[doc = " Is it removed after `HISTORY_DEPTH` eras."] - #[doc = " If stakers hasn't been set or has been removed then empty exposure is returned."] - pub fn eras_stakers_clipped( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::Exposure< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "ErasStakersClipped", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 43u8, 159u8, 113u8, 223u8, 122u8, 169u8, 98u8, 153u8, 26u8, 55u8, 71u8, - 119u8, 174u8, 48u8, 158u8, 45u8, 214u8, 26u8, 136u8, 215u8, 46u8, - 161u8, 185u8, 17u8, 174u8, 204u8, 206u8, 246u8, 49u8, 87u8, 134u8, - 169u8, - ], - ) - } - #[doc = " Clipped Exposure of validator at era."] + #[doc = " This value is multipled by the `final_fee` to obtain a \"virtual tip\" that is later"] + #[doc = " added to a tip component in regular `priority` calculations."] + #[doc = " It means that a `Normal` transaction can front-run a similarly-sized `Operational`"] + #[doc = " extrinsic (with no tip), by including a tip value greater than the virtual tip."] #[doc = ""] - #[doc = " This is similar to [`ErasStakers`] but number of nominators exposed is reduced to the"] - #[doc = " `T::MaxNominatorRewardedPerValidator` biggest stakers."] - #[doc = " (Note: the field `total` and `own` of the exposure remains unchanged)."] - #[doc = " This is used to limit the i/o cost for the nominator payout."] + #[doc = " ```rust,ignore"] + #[doc = " // For `Normal`"] + #[doc = " let priority = priority_calc(tip);"] #[doc = ""] - #[doc = " This is keyed fist by the era index to allow bulk deletion and then the stash account."] + #[doc = " // For `Operational`"] + #[doc = " let virtual_tip = (inclusion_fee + tip) * OperationalFeeMultiplier;"] + #[doc = " let priority = priority_calc(tip + virtual_tip);"] + #[doc = " ```"] #[doc = ""] - #[doc = " Is it removed after `HISTORY_DEPTH` eras."] - #[doc = " If stakers hasn't been set or has been removed then empty exposure is returned."] - pub fn eras_stakers_clipped_root( + #[doc = " Note that since we use `final_fee` the multiplier applies also to the regular `tip`"] + #[doc = " sent with the transaction. So, not only does the transaction get a priority bump based"] + #[doc = " on the `inclusion_fee`, but we also amplify the impact of tips applied to `Operational`"] + #[doc = " transactions."] + pub fn operational_fee_multiplier( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::Exposure< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "ErasStakersClipped", - Vec::new(), + ) -> ::subxt::constants::Address<::core::primitive::u8> { + ::subxt::constants::Address::new_static( + "TransactionPayment", + "OperationalFeeMultiplier", [ - 43u8, 159u8, 113u8, 223u8, 122u8, 169u8, 98u8, 153u8, 26u8, 55u8, 71u8, - 119u8, 174u8, 48u8, 158u8, 45u8, 214u8, 26u8, 136u8, 215u8, 46u8, - 161u8, 185u8, 17u8, 174u8, 204u8, 206u8, 246u8, 49u8, 87u8, 134u8, - 169u8, + 141u8, 130u8, 11u8, 35u8, 226u8, 114u8, 92u8, 179u8, 168u8, 110u8, + 28u8, 91u8, 221u8, 64u8, 4u8, 148u8, 201u8, 193u8, 185u8, 66u8, 226u8, + 114u8, 97u8, 79u8, 62u8, 212u8, 202u8, 114u8, 237u8, 228u8, 183u8, + 165u8, ], ) } - #[doc = " Similar to `ErasStakers`, this holds the preferences of validators."] - #[doc = ""] - #[doc = " This is keyed first by the era index to allow bulk deletion and then the stash account."] - #[doc = ""] - #[doc = " Is it removed after `HISTORY_DEPTH` eras."] - pub fn eras_validator_prefs( + } + } + } + pub mod authorship { + use super::root_mod; + use super::runtime_types; + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Author of current block."] + pub fn author( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::ValidatorPrefs, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + ::subxt::utils::AccountId32, ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "ErasValidatorPrefs", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 6u8, 196u8, 209u8, 138u8, 252u8, 18u8, 203u8, 86u8, 129u8, 62u8, 4u8, - 56u8, 234u8, 114u8, 141u8, 136u8, 127u8, 224u8, 142u8, 89u8, 150u8, - 33u8, 31u8, 50u8, 140u8, 108u8, 124u8, 77u8, 188u8, 102u8, 230u8, - 174u8, - ], - ) - } - #[doc = " Similar to `ErasStakers`, this holds the preferences of validators."] - #[doc = ""] - #[doc = " This is keyed first by the era index to allow bulk deletion and then the stash account."] - #[doc = ""] - #[doc = " Is it removed after `HISTORY_DEPTH` eras."] - pub fn eras_validator_prefs_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::ValidatorPrefs, (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "ErasValidatorPrefs", - Vec::new(), - [ - 6u8, 196u8, 209u8, 138u8, 252u8, 18u8, 203u8, 86u8, 129u8, 62u8, 4u8, - 56u8, 234u8, 114u8, 141u8, 136u8, 127u8, 224u8, 142u8, 89u8, 150u8, - 33u8, 31u8, 50u8, 140u8, 108u8, 124u8, 77u8, 188u8, 102u8, 230u8, - 174u8, - ], - ) - } - #[doc = " The total validator era payout for the last `HISTORY_DEPTH` eras."] - #[doc = ""] - #[doc = " Eras that haven't finished yet or has been removed doesn't have reward."] - pub fn eras_validator_reward( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, (), - ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Staking", - "ErasValidatorReward", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Authorship", + "Author", + vec![], [ - 87u8, 80u8, 156u8, 123u8, 107u8, 77u8, 203u8, 37u8, 231u8, 84u8, 124u8, - 155u8, 227u8, 212u8, 212u8, 179u8, 84u8, 161u8, 223u8, 255u8, 254u8, - 107u8, 52u8, 89u8, 98u8, 169u8, 136u8, 241u8, 104u8, 3u8, 244u8, 161u8, + 149u8, 42u8, 33u8, 147u8, 190u8, 207u8, 174u8, 227u8, 190u8, 110u8, + 25u8, 131u8, 5u8, 167u8, 237u8, 188u8, 188u8, 33u8, 177u8, 126u8, + 181u8, 49u8, 126u8, 118u8, 46u8, 128u8, 154u8, 95u8, 15u8, 91u8, 103u8, + 113u8, ], ) } - #[doc = " The total validator era payout for the last `HISTORY_DEPTH` eras."] - #[doc = ""] - #[doc = " Eras that haven't finished yet or has been removed doesn't have reward."] - pub fn eras_validator_reward_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "ErasValidatorReward", - Vec::new(), - [ - 87u8, 80u8, 156u8, 123u8, 107u8, 77u8, 203u8, 37u8, 231u8, 84u8, 124u8, - 155u8, 227u8, 212u8, 212u8, 179u8, 84u8, 161u8, 223u8, 255u8, 254u8, - 107u8, 52u8, 89u8, 98u8, 169u8, 136u8, 241u8, 104u8, 3u8, 244u8, 161u8, - ], - ) + } + } + } + pub mod staking { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_staking::pallet::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Bond { + pub controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub value: ::core::primitive::u128, + pub payee: runtime_types::pallet_staking::RewardDestination< + ::subxt::utils::AccountId32, + >, } - #[doc = " Rewards for the last `HISTORY_DEPTH` eras."] - #[doc = " If reward hasn't been set or has been removed then 0 reward is returned."] - pub fn eras_reward_points( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::EraRewardPoints<::subxt::utils::AccountId32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "ErasRewardPoints", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 194u8, 29u8, 20u8, 83u8, 200u8, 47u8, 158u8, 102u8, 88u8, 65u8, 24u8, - 255u8, 120u8, 178u8, 23u8, 232u8, 15u8, 64u8, 206u8, 0u8, 170u8, 40u8, - 18u8, 149u8, 45u8, 90u8, 179u8, 127u8, 52u8, 59u8, 37u8, 192u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BondExtra { + #[codec(compact)] + pub max_additional: ::core::primitive::u128, } - #[doc = " Rewards for the last `HISTORY_DEPTH` eras."] - #[doc = " If reward hasn't been set or has been removed then 0 reward is returned."] - pub fn eras_reward_points_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::EraRewardPoints<::subxt::utils::AccountId32>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "ErasRewardPoints", - Vec::new(), - [ - 194u8, 29u8, 20u8, 83u8, 200u8, 47u8, 158u8, 102u8, 88u8, 65u8, 24u8, - 255u8, 120u8, 178u8, 23u8, 232u8, 15u8, 64u8, 206u8, 0u8, 170u8, 40u8, - 18u8, 149u8, 45u8, 90u8, 179u8, 127u8, 52u8, 59u8, 37u8, 192u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Unbond { + #[codec(compact)] + pub value: ::core::primitive::u128, } - #[doc = " The total amount staked for the last `HISTORY_DEPTH` eras."] - #[doc = " If total hasn't been set or has been removed then 0 stake is returned."] - pub fn eras_total_stake( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "ErasTotalStake", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 224u8, 240u8, 168u8, 69u8, 148u8, 140u8, 249u8, 240u8, 4u8, 46u8, 77u8, - 11u8, 224u8, 65u8, 26u8, 239u8, 1u8, 110u8, 53u8, 11u8, 247u8, 235u8, - 142u8, 234u8, 22u8, 43u8, 24u8, 36u8, 37u8, 43u8, 170u8, 40u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct WithdrawUnbonded { + pub num_slashing_spans: ::core::primitive::u32, } - #[doc = " The total amount staked for the last `HISTORY_DEPTH` eras."] - #[doc = " If total hasn't been set or has been removed then 0 stake is returned."] - pub fn eras_total_stake_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "ErasTotalStake", - Vec::new(), - [ - 224u8, 240u8, 168u8, 69u8, 148u8, 140u8, 249u8, 240u8, 4u8, 46u8, 77u8, - 11u8, 224u8, 65u8, 26u8, 239u8, 1u8, 110u8, 53u8, 11u8, 247u8, 235u8, - 142u8, 234u8, 22u8, 43u8, 24u8, 36u8, 37u8, 43u8, 170u8, 40u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Validate { + pub prefs: runtime_types::pallet_staking::ValidatorPrefs, } - #[doc = " Mode of era forcing."] - pub fn force_era( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::Forcing, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "ForceEra", - vec![], - [ - 221u8, 41u8, 71u8, 21u8, 28u8, 193u8, 65u8, 97u8, 103u8, 37u8, 145u8, - 146u8, 183u8, 194u8, 57u8, 131u8, 214u8, 136u8, 68u8, 156u8, 140u8, - 194u8, 69u8, 151u8, 115u8, 177u8, 92u8, 147u8, 29u8, 40u8, 41u8, 31u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Nominate { + pub targets: ::std::vec::Vec< + ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + >, } - #[doc = " The percentage of the slash that is distributed to reporters."] - #[doc = ""] - #[doc = " The rest of the slashed value is handled by the `Slash`."] - pub fn slash_reward_fraction( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::per_things::Perbill, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "SlashRewardFraction", - vec![], - [ - 167u8, 79u8, 143u8, 202u8, 199u8, 100u8, 129u8, 162u8, 23u8, 165u8, - 106u8, 170u8, 244u8, 86u8, 144u8, 242u8, 65u8, 207u8, 115u8, 224u8, - 231u8, 155u8, 55u8, 139u8, 101u8, 129u8, 242u8, 196u8, 130u8, 50u8, - 3u8, 117u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Chill; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetPayee { + pub payee: runtime_types::pallet_staking::RewardDestination< + ::subxt::utils::AccountId32, + >, } - #[doc = " The amount of currency given to reporters of a slash event which was"] - #[doc = " canceled by extraordinary circumstances (e.g. governance)."] - pub fn canceled_slash_payout( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "CanceledSlashPayout", - vec![], - [ - 126u8, 218u8, 66u8, 92u8, 82u8, 124u8, 145u8, 161u8, 40u8, 176u8, 14u8, - 211u8, 178u8, 216u8, 8u8, 156u8, 83u8, 14u8, 91u8, 15u8, 200u8, 170u8, - 3u8, 127u8, 141u8, 139u8, 151u8, 98u8, 74u8, 96u8, 238u8, 29u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetController { + pub controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } - #[doc = " All unapplied slashes that are queued for later."] - pub fn unapplied_slashes( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::pallet_staking::UnappliedSlash< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "UnappliedSlashes", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 130u8, 4u8, 163u8, 163u8, 28u8, 85u8, 34u8, 156u8, 47u8, 125u8, 57u8, - 0u8, 133u8, 176u8, 130u8, 2u8, 175u8, 180u8, 167u8, 203u8, 230u8, 82u8, - 198u8, 183u8, 55u8, 82u8, 221u8, 248u8, 100u8, 173u8, 206u8, 151u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetValidatorCount { + #[codec(compact)] + pub new: ::core::primitive::u32, } - #[doc = " All unapplied slashes that are queued for later."] - pub fn unapplied_slashes_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::pallet_staking::UnappliedSlash< - ::subxt::utils::AccountId32, - ::core::primitive::u128, + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct IncreaseValidatorCount { + #[codec(compact)] + pub additional: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ScaleValidatorCount { + pub factor: runtime_types::sp_arithmetic::per_things::Percent, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceNoEras; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceNewEra; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetInvulnerables { + pub invulnerables: ::std::vec::Vec<::subxt::utils::AccountId32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceUnstake { + pub stash: ::subxt::utils::AccountId32, + pub num_slashing_spans: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceNewEraAlways; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelDeferredSlash { + pub era: ::core::primitive::u32, + pub slash_indices: ::std::vec::Vec<::core::primitive::u32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PayoutStakers { + pub validator_stash: ::subxt::utils::AccountId32, + pub era: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Rebond { + #[codec(compact)] + pub value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReapStash { + pub stash: ::subxt::utils::AccountId32, + pub num_slashing_spans: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Kick { + pub who: ::std::vec::Vec< + ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetStakingConfigs { + pub min_nominator_bond: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + ::core::primitive::u128, + >, + pub min_validator_bond: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + ::core::primitive::u128, + >, + pub max_nominator_count: + runtime_types::pallet_staking::pallet::pallet::ConfigOp< + ::core::primitive::u32, + >, + pub max_validator_count: + runtime_types::pallet_staking::pallet::pallet::ConfigOp< + ::core::primitive::u32, >, + pub chill_threshold: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + runtime_types::sp_arithmetic::per_things::Percent, + >, + pub min_commission: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + runtime_types::sp_arithmetic::per_things::Perbill, >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Staking", - "UnappliedSlashes", - Vec::new(), - [ - 130u8, 4u8, 163u8, 163u8, 28u8, 85u8, 34u8, 156u8, 47u8, 125u8, 57u8, - 0u8, 133u8, 176u8, 130u8, 2u8, 175u8, 180u8, 167u8, 203u8, 230u8, 82u8, - 198u8, 183u8, 55u8, 82u8, 221u8, 248u8, 100u8, 173u8, 206u8, 151u8, - ], - ) } - #[doc = " A mapping from still-bonded eras to the first session index of that era."] + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ChillOther { + pub controller: ::subxt::utils::AccountId32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceApplyMinCommission { + pub validator_stash: ::subxt::utils::AccountId32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMinCommission { + pub new: runtime_types::sp_arithmetic::per_things::Perbill, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Take the origin account as a stash and lock up `value` of its balance. `controller` will"] + #[doc = "be the account that controls it."] #[doc = ""] - #[doc = " Must contains information for eras for the range:"] - #[doc = " `[active_era - bounding_duration; active_era]`"] - pub fn bonded_eras( + #[doc = "`value` must be more than the `minimum_balance` specified by `T::Currency`."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ by the stash account."] + #[doc = ""] + #[doc = "Emits `Bonded`."] + #[doc = "## Complexity"] + #[doc = "- Independent of the arguments. Moderate complexity."] + #[doc = "- O(1)."] + #[doc = "- Three extra DB entries."] + #[doc = ""] + #[doc = "NOTE: Two of the storage writes (`Self::bonded`, `Self::payee`) are _never_ cleaned"] + #[doc = "unless the `origin` falls below _existential deposit_ and gets removed as dust."] + pub fn bond( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::u32)>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( + controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + value: ::core::primitive::u128, + payee: runtime_types::pallet_staking::RewardDestination< + ::subxt::utils::AccountId32, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "BondedEras", - vec![], + "bond", + types::Bond { + controller, + value, + payee, + }, [ - 243u8, 162u8, 236u8, 198u8, 122u8, 182u8, 37u8, 55u8, 171u8, 156u8, - 235u8, 223u8, 226u8, 129u8, 89u8, 206u8, 2u8, 155u8, 222u8, 154u8, - 116u8, 124u8, 4u8, 119u8, 155u8, 94u8, 248u8, 30u8, 171u8, 51u8, 78u8, - 106u8, + 215u8, 211u8, 69u8, 215u8, 33u8, 158u8, 62u8, 3u8, 31u8, 216u8, 213u8, + 188u8, 151u8, 43u8, 165u8, 154u8, 117u8, 163u8, 190u8, 227u8, 116u8, + 70u8, 155u8, 178u8, 64u8, 174u8, 203u8, 179u8, 214u8, 187u8, 176u8, + 10u8, ], ) } - #[doc = " All slashing events on validators, mapped by era to the highest slash proportion"] - #[doc = " and slash value of the era."] - pub fn validator_slash_in_era( + #[doc = "Add some extra amount that have appeared in the stash `free_balance` into the balance up"] + #[doc = "for staking."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ by the stash, not the controller."] + #[doc = ""] + #[doc = "Use this if there are additional funds in your stash account that you wish to bond."] + #[doc = "Unlike [`bond`](Self::bond) or [`unbond`](Self::unbond) this function does not impose"] + #[doc = "any limitation on the amount that can be added."] + #[doc = ""] + #[doc = "Emits `Bonded`."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- Independent of the arguments. Insignificant complexity."] + #[doc = "- O(1)."] + pub fn bond_extra( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::sp_arithmetic::per_things::Perbill, - ::core::primitive::u128, - ), - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( + max_additional: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "ValidatorSlashInEra", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + "bond_extra", + types::BondExtra { max_additional }, [ - 237u8, 80u8, 3u8, 237u8, 9u8, 40u8, 212u8, 15u8, 251u8, 196u8, 85u8, - 29u8, 27u8, 151u8, 98u8, 122u8, 189u8, 147u8, 205u8, 40u8, 202u8, - 194u8, 158u8, 96u8, 138u8, 16u8, 116u8, 71u8, 140u8, 163u8, 121u8, - 197u8, + 60u8, 45u8, 82u8, 223u8, 113u8, 95u8, 0u8, 71u8, 59u8, 108u8, 228u8, + 9u8, 95u8, 210u8, 113u8, 106u8, 252u8, 15u8, 19u8, 128u8, 11u8, 187u8, + 4u8, 151u8, 103u8, 143u8, 24u8, 33u8, 149u8, 82u8, 35u8, 192u8, ], ) } - #[doc = " All slashing events on validators, mapped by era to the highest slash proportion"] - #[doc = " and slash value of the era."] - pub fn validator_slash_in_era_root( + #[doc = "Schedule a portion of the stash to be unlocked ready for transfer out after the bond"] + #[doc = "period ends. If this leaves an amount actively bonded less than"] + #[doc = "T::Currency::minimum_balance(), then it is increased to the full amount."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] + #[doc = ""] + #[doc = "Once the unlock period is done, you can call `withdraw_unbonded` to actually move"] + #[doc = "the funds out of management ready for transfer."] + #[doc = ""] + #[doc = "No more than a limited number of unlocking chunks (see `MaxUnlockingChunks`)"] + #[doc = "can co-exists at the same time. If there are no unlocking chunks slots available"] + #[doc = "[`Call::withdraw_unbonded`] is called to remove some of the chunks (if possible)."] + #[doc = ""] + #[doc = "If a user encounters the `InsufficientBond` error when calling this extrinsic,"] + #[doc = "they should call `chill` first in order to free up their bonded funds."] + #[doc = ""] + #[doc = "Emits `Unbonded`."] + #[doc = ""] + #[doc = "See also [`Call::withdraw_unbonded`]."] + pub fn unbond( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::sp_arithmetic::per_things::Perbill, - ::core::primitive::u128, - ), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( + value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "ValidatorSlashInEra", - Vec::new(), + "unbond", + types::Unbond { value }, [ - 237u8, 80u8, 3u8, 237u8, 9u8, 40u8, 212u8, 15u8, 251u8, 196u8, 85u8, - 29u8, 27u8, 151u8, 98u8, 122u8, 189u8, 147u8, 205u8, 40u8, 202u8, - 194u8, 158u8, 96u8, 138u8, 16u8, 116u8, 71u8, 140u8, 163u8, 121u8, - 197u8, + 85u8, 62u8, 34u8, 127u8, 60u8, 241u8, 134u8, 60u8, 125u8, 91u8, 31u8, + 193u8, 50u8, 230u8, 237u8, 42u8, 114u8, 230u8, 240u8, 146u8, 14u8, + 109u8, 185u8, 151u8, 148u8, 44u8, 147u8, 182u8, 192u8, 253u8, 51u8, + 87u8, ], ) } - #[doc = " All slashing events on nominators, mapped by era to the highest slash value of the era."] - pub fn nominator_slash_in_era( + #[doc = "Remove any unlocked chunks from the `unlocking` queue from our management."] + #[doc = ""] + #[doc = "This essentially frees up that balance to be used by the stash account to do"] + #[doc = "whatever it wants."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ by the controller."] + #[doc = ""] + #[doc = "Emits `Withdrawn`."] + #[doc = ""] + #[doc = "See also [`Call::unbond`]."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "O(S) where S is the number of slashing spans to remove"] + #[doc = "NOTE: Weight annotation is the kill scenario, we refund otherwise."] + pub fn withdraw_unbonded( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( + num_slashing_spans: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "NominatorSlashInEra", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + "withdraw_unbonded", + types::WithdrawUnbonded { num_slashing_spans }, [ - 249u8, 85u8, 170u8, 41u8, 179u8, 194u8, 180u8, 12u8, 53u8, 101u8, 80u8, - 96u8, 166u8, 71u8, 239u8, 23u8, 153u8, 19u8, 152u8, 38u8, 138u8, 136u8, - 221u8, 200u8, 18u8, 165u8, 26u8, 228u8, 195u8, 199u8, 62u8, 4u8, + 95u8, 223u8, 122u8, 217u8, 76u8, 208u8, 86u8, 129u8, 31u8, 104u8, 70u8, + 154u8, 23u8, 250u8, 165u8, 192u8, 149u8, 249u8, 158u8, 159u8, 194u8, + 224u8, 118u8, 134u8, 204u8, 157u8, 72u8, 136u8, 19u8, 193u8, 183u8, + 84u8, ], ) } - #[doc = " All slashing events on nominators, mapped by era to the highest slash value of the era."] - pub fn nominator_slash_in_era_root( + #[doc = "Declare the desire to validate for the origin controller."] + #[doc = ""] + #[doc = "Effects will be felt at the beginning of the next era."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] + pub fn validate( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( + prefs: runtime_types::pallet_staking::ValidatorPrefs, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "NominatorSlashInEra", - Vec::new(), + "validate", + types::Validate { prefs }, [ - 249u8, 85u8, 170u8, 41u8, 179u8, 194u8, 180u8, 12u8, 53u8, 101u8, 80u8, - 96u8, 166u8, 71u8, 239u8, 23u8, 153u8, 19u8, 152u8, 38u8, 138u8, 136u8, - 221u8, 200u8, 18u8, 165u8, 26u8, 228u8, 195u8, 199u8, 62u8, 4u8, + 191u8, 116u8, 139u8, 35u8, 250u8, 211u8, 86u8, 240u8, 35u8, 9u8, 19u8, + 44u8, 148u8, 35u8, 91u8, 106u8, 200u8, 172u8, 108u8, 145u8, 194u8, + 146u8, 61u8, 145u8, 233u8, 168u8, 2u8, 26u8, 145u8, 101u8, 114u8, + 157u8, ], ) } - #[doc = " Slashing spans for stash accounts."] - pub fn slashing_spans( + #[doc = "Declare the desire to nominate `targets` for the origin controller."] + #[doc = ""] + #[doc = "Effects will be felt at the beginning of the next era."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- The transaction's complexity is proportional to the size of `targets` (N)"] + #[doc = "which is capped at CompactAssignments::LIMIT (T::MaxNominations)."] + #[doc = "- Both the reads and writes follow a similar pattern."] + pub fn nominate( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::slashing::SlashingSpans, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( + targets: ::std::vec::Vec< + ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "SlashingSpans", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "nominate", + types::Nominate { targets }, [ - 106u8, 115u8, 118u8, 52u8, 89u8, 77u8, 246u8, 5u8, 255u8, 204u8, 44u8, - 5u8, 66u8, 36u8, 227u8, 252u8, 86u8, 159u8, 186u8, 152u8, 196u8, 21u8, - 74u8, 201u8, 133u8, 93u8, 142u8, 191u8, 20u8, 27u8, 218u8, 157u8, + 112u8, 162u8, 70u8, 26u8, 74u8, 7u8, 188u8, 193u8, 210u8, 247u8, 27u8, + 189u8, 133u8, 137u8, 33u8, 155u8, 255u8, 171u8, 122u8, 68u8, 175u8, + 247u8, 139u8, 253u8, 97u8, 187u8, 254u8, 201u8, 66u8, 166u8, 226u8, + 90u8, ], ) } - #[doc = " Slashing spans for stash accounts."] - pub fn slashing_spans_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::slashing::SlashingSpans, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( + #[doc = "Declare no desire to either validate or nominate."] + #[doc = ""] + #[doc = "Effects will be felt at the beginning of the next era."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- Independent of the arguments. Insignificant complexity."] + #[doc = "- Contains one read."] + #[doc = "- Writes are limited to the `origin` account key."] + pub fn chill(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "SlashingSpans", - Vec::new(), + "chill", + types::Chill {}, [ - 106u8, 115u8, 118u8, 52u8, 89u8, 77u8, 246u8, 5u8, 255u8, 204u8, 44u8, - 5u8, 66u8, 36u8, 227u8, 252u8, 86u8, 159u8, 186u8, 152u8, 196u8, 21u8, - 74u8, 201u8, 133u8, 93u8, 142u8, 191u8, 20u8, 27u8, 218u8, 157u8, + 94u8, 20u8, 196u8, 31u8, 220u8, 125u8, 115u8, 167u8, 140u8, 3u8, 20u8, + 132u8, 81u8, 120u8, 215u8, 166u8, 230u8, 56u8, 16u8, 222u8, 31u8, + 153u8, 120u8, 62u8, 153u8, 67u8, 220u8, 239u8, 11u8, 234u8, 127u8, + 122u8, ], ) } - #[doc = " Records information about the maximum slash of a stash within a slashing span,"] - #[doc = " as well as how much reward has been paid out."] - pub fn span_slash( + #[doc = "(Re-)set the payment target for a controller."] + #[doc = ""] + #[doc = "Effects will be felt instantly (as soon as this function is completed successfully)."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)"] + #[doc = "- Independent of the arguments. Insignificant complexity."] + #[doc = "- Contains a limited number of reads."] + #[doc = "- Writes are limited to the `origin` account key."] + #[doc = "---------"] + pub fn set_payee( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - _1: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::slashing::SpanRecord<::core::primitive::u128>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( + payee: runtime_types::pallet_staking::RewardDestination< + ::subxt::utils::AccountId32, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "SpanSlash", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + "set_payee", + types::SetPayee { payee }, [ - 160u8, 63u8, 115u8, 190u8, 233u8, 148u8, 75u8, 3u8, 11u8, 59u8, 184u8, - 220u8, 205u8, 64u8, 28u8, 190u8, 116u8, 210u8, 225u8, 230u8, 224u8, - 163u8, 103u8, 157u8, 100u8, 29u8, 86u8, 167u8, 84u8, 217u8, 109u8, - 200u8, + 96u8, 8u8, 254u8, 164u8, 87u8, 46u8, 120u8, 11u8, 197u8, 63u8, 20u8, + 178u8, 167u8, 236u8, 149u8, 245u8, 14u8, 171u8, 108u8, 195u8, 250u8, + 133u8, 0u8, 75u8, 192u8, 159u8, 84u8, 220u8, 242u8, 133u8, 60u8, 62u8, ], ) } - #[doc = " Records information about the maximum slash of a stash within a slashing span,"] - #[doc = " as well as how much reward has been paid out."] - pub fn span_slash_root( + #[doc = "(Re-)set the controller of a stash."] + #[doc = ""] + #[doc = "Effects will be felt instantly (as soon as this function is completed successfully)."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ by the stash, not the controller."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "O(1)"] + #[doc = "- Independent of the arguments. Insignificant complexity."] + #[doc = "- Contains a limited number of reads."] + #[doc = "- Writes are limited to the `origin` account key."] + pub fn set_controller( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_staking::slashing::SpanRecord<::core::primitive::u128>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( + controller: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "SpanSlash", - Vec::new(), + "set_controller", + types::SetController { controller }, [ - 160u8, 63u8, 115u8, 190u8, 233u8, 148u8, 75u8, 3u8, 11u8, 59u8, 184u8, - 220u8, 205u8, 64u8, 28u8, 190u8, 116u8, 210u8, 225u8, 230u8, 224u8, - 163u8, 103u8, 157u8, 100u8, 29u8, 86u8, 167u8, 84u8, 217u8, 109u8, - 200u8, + 165u8, 250u8, 213u8, 32u8, 179u8, 163u8, 15u8, 35u8, 14u8, 152u8, 56u8, + 171u8, 43u8, 101u8, 7u8, 167u8, 178u8, 60u8, 89u8, 186u8, 59u8, 28u8, + 82u8, 159u8, 13u8, 96u8, 168u8, 123u8, 194u8, 212u8, 205u8, 184u8, ], ) } - #[doc = " The last planned session scheduled by the session pallet."] + #[doc = "Sets the ideal number of validators."] #[doc = ""] - #[doc = " This is basically in sync with the call to [`pallet_session::SessionManager::new_session`]."] - pub fn current_planned_session( + #[doc = "The dispatch origin must be Root."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "O(1)"] + pub fn set_validator_count( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "CurrentPlannedSession", - vec![], + "set_validator_count", + types::SetValidatorCount { new }, [ - 38u8, 22u8, 56u8, 250u8, 17u8, 154u8, 99u8, 37u8, 155u8, 253u8, 100u8, - 117u8, 5u8, 239u8, 31u8, 190u8, 53u8, 241u8, 11u8, 185u8, 163u8, 227u8, - 10u8, 77u8, 210u8, 64u8, 156u8, 218u8, 105u8, 16u8, 1u8, 57u8, + 55u8, 232u8, 95u8, 66u8, 228u8, 217u8, 11u8, 27u8, 3u8, 202u8, 199u8, + 242u8, 70u8, 160u8, 250u8, 187u8, 194u8, 91u8, 15u8, 36u8, 215u8, 36u8, + 160u8, 108u8, 251u8, 60u8, 240u8, 202u8, 249u8, 235u8, 28u8, 94u8, ], ) } - #[doc = " Indices of validators that have offended in the active era and whether they are currently"] - #[doc = " disabled."] + #[doc = "Increments the ideal number of validators upto maximum of"] + #[doc = "`ElectionProviderBase::MaxWinners`."] #[doc = ""] - #[doc = " This value should be a superset of disabled validators since not all offences lead to the"] - #[doc = " validator being disabled (if there was no slash). This is needed to track the percentage of"] - #[doc = " validators that have offended in the current era, ensuring a new era is forced if"] - #[doc = " `OffendingValidatorsThreshold` is reached. The vec is always kept sorted so that we can find"] - #[doc = " whether a given validator has previously offended using binary search. It gets cleared when"] - #[doc = " the era ends."] - pub fn offending_validators( + #[doc = "The dispatch origin must be Root."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "Same as [`Self::set_validator_count`]."] + pub fn increase_validator_count( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::bool)>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( + additional: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "OffendingValidators", - vec![], + "increase_validator_count", + types::IncreaseValidatorCount { additional }, [ - 94u8, 254u8, 0u8, 50u8, 76u8, 232u8, 51u8, 153u8, 118u8, 14u8, 70u8, - 101u8, 112u8, 215u8, 173u8, 82u8, 182u8, 104u8, 167u8, 103u8, 187u8, - 168u8, 86u8, 16u8, 51u8, 235u8, 51u8, 119u8, 38u8, 154u8, 42u8, 113u8, + 239u8, 184u8, 155u8, 213u8, 25u8, 22u8, 193u8, 13u8, 102u8, 192u8, + 82u8, 153u8, 249u8, 192u8, 60u8, 158u8, 8u8, 78u8, 175u8, 219u8, 46u8, + 51u8, 222u8, 193u8, 193u8, 201u8, 78u8, 90u8, 58u8, 86u8, 196u8, 17u8, ], ) } - #[doc = " The threshold for when users can start calling `chill_other` for other validators /"] - #[doc = " nominators. The threshold is compared to the actual number of validators / nominators"] - #[doc = " (`CountFor*`) in the system compared to the configured max (`Max*Count`)."] - pub fn chill_threshold( + #[doc = "Scale up the ideal number of validators by a factor upto maximum of"] + #[doc = "`ElectionProviderBase::MaxWinners`."] + #[doc = ""] + #[doc = "The dispatch origin must be Root."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "Same as [`Self::set_validator_count`]."] + pub fn scale_validator_count( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::per_things::Percent, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( + factor: runtime_types::sp_arithmetic::per_things::Percent, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "ChillThreshold", - vec![], + "scale_validator_count", + types::ScaleValidatorCount { factor }, [ - 174u8, 165u8, 249u8, 105u8, 24u8, 151u8, 115u8, 166u8, 199u8, 251u8, - 28u8, 5u8, 50u8, 95u8, 144u8, 110u8, 220u8, 76u8, 14u8, 23u8, 179u8, - 41u8, 11u8, 248u8, 28u8, 154u8, 159u8, 255u8, 156u8, 109u8, 98u8, 92u8, + 198u8, 68u8, 227u8, 94u8, 110u8, 157u8, 209u8, 217u8, 112u8, 37u8, + 78u8, 142u8, 12u8, 193u8, 219u8, 167u8, 149u8, 112u8, 49u8, 139u8, + 74u8, 81u8, 172u8, 72u8, 253u8, 224u8, 56u8, 194u8, 185u8, 90u8, 87u8, + 125u8, ], ) } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Maximum number of nominations per nominator."] - pub fn max_nominations( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( + #[doc = "Force there to be no new eras indefinitely."] + #[doc = ""] + #[doc = "The dispatch origin must be Root."] + #[doc = ""] + #[doc = "# Warning"] + #[doc = ""] + #[doc = "The election process starts multiple blocks before the end of the era."] + #[doc = "Thus the election process may be ongoing when this is called. In this case the"] + #[doc = "election will continue until the next era is triggered."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- No arguments."] + #[doc = "- Weight: O(1)"] + pub fn force_no_eras(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "MaxNominations", + "force_no_eras", + types::ForceNoEras {}, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 16u8, 81u8, 207u8, 168u8, 23u8, 236u8, 11u8, 75u8, 141u8, 107u8, 92u8, + 2u8, 53u8, 111u8, 252u8, 116u8, 91u8, 120u8, 75u8, 24u8, 125u8, 53u8, + 9u8, 28u8, 242u8, 87u8, 245u8, 55u8, 40u8, 103u8, 151u8, 178u8, ], ) } - #[doc = " Number of eras to keep in history."] + #[doc = "Force there to be a new era at the end of the next session. After this, it will be"] + #[doc = "reset to normal (non-forced) behaviour."] #[doc = ""] - #[doc = " Following information is kept for eras in `[current_era -"] - #[doc = " HistoryDepth, current_era]`: `ErasStakers`, `ErasStakersClipped`,"] - #[doc = " `ErasValidatorPrefs`, `ErasValidatorReward`, `ErasRewardPoints`,"] - #[doc = " `ErasTotalStake`, `ErasStartSessionIndex`,"] - #[doc = " `StakingLedger.claimed_rewards`."] + #[doc = "The dispatch origin must be Root."] #[doc = ""] - #[doc = " Must be more than the number of eras delayed by session."] - #[doc = " I.e. active era must always be in history. I.e. `active_era >"] - #[doc = " current_era - history_depth` must be guaranteed."] + #[doc = "# Warning"] #[doc = ""] - #[doc = " If migrating an existing pallet from storage value to config value,"] - #[doc = " this should be set to same value or greater as in storage."] + #[doc = "The election process starts multiple blocks before the end of the era."] + #[doc = "If this is called just before a new era is triggered, the election process may not"] + #[doc = "have enough blocks to get a result."] #[doc = ""] - #[doc = " Note: `HistoryDepth` is used as the upper bound for the `BoundedVec`"] - #[doc = " item `StakingLedger.claimed_rewards`. Setting this value lower than"] - #[doc = " the existing value can lead to inconsistencies in the"] - #[doc = " `StakingLedger` and will need to be handled properly in a migration."] - #[doc = " The test `reducing_history_depth_abrupt` shows this effect."] - pub fn history_depth(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( + #[doc = "## Complexity"] + #[doc = "- No arguments."] + #[doc = "- Weight: O(1)"] + pub fn force_new_era(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "HistoryDepth", + "force_new_era", + types::ForceNewEra {}, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 230u8, 242u8, 169u8, 196u8, 78u8, 145u8, 24u8, 191u8, 113u8, 68u8, 5u8, + 138u8, 48u8, 51u8, 109u8, 126u8, 73u8, 136u8, 162u8, 158u8, 174u8, + 201u8, 213u8, 230u8, 215u8, 44u8, 200u8, 32u8, 75u8, 27u8, 23u8, 254u8, ], ) } - #[doc = " Number of sessions per era."] - pub fn sessions_per_era( + #[doc = "Set the validators who cannot be slashed (if any)."] + #[doc = ""] + #[doc = "The dispatch origin must be Root."] + pub fn set_invulnerables( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( + invulnerables: ::std::vec::Vec<::subxt::utils::AccountId32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "SessionsPerEra", + "set_invulnerables", + types::SetInvulnerables { invulnerables }, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 2u8, 148u8, 221u8, 111u8, 153u8, 48u8, 222u8, 36u8, 228u8, 84u8, 18u8, + 35u8, 168u8, 239u8, 53u8, 245u8, 27u8, 76u8, 18u8, 203u8, 206u8, 9u8, + 8u8, 81u8, 35u8, 224u8, 22u8, 133u8, 58u8, 99u8, 103u8, 39u8, ], ) } - #[doc = " Number of eras that staked funds must remain bonded for."] - pub fn bonding_duration( + #[doc = "Force a current staker to become completely unstaked, immediately."] + #[doc = ""] + #[doc = "The dispatch origin must be Root."] + pub fn force_unstake( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( + stash: ::subxt::utils::AccountId32, + num_slashing_spans: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "BondingDuration", + "force_unstake", + types::ForceUnstake { + stash, + num_slashing_spans, + }, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 94u8, 247u8, 238u8, 47u8, 250u8, 6u8, 96u8, 175u8, 173u8, 123u8, 161u8, + 187u8, 162u8, 214u8, 176u8, 233u8, 33u8, 33u8, 167u8, 239u8, 40u8, + 223u8, 19u8, 131u8, 230u8, 39u8, 175u8, 200u8, 36u8, 182u8, 76u8, + 207u8, ], ) } - #[doc = " Number of eras that slashes are deferred by, after computation."] + #[doc = "Force there to be a new era at the end of sessions indefinitely."] #[doc = ""] - #[doc = " This should be less than the bonding duration. Set to 0 if slashes"] - #[doc = " should be applied immediately, without opportunity for intervention."] - pub fn slash_defer_duration( + #[doc = "The dispatch origin must be Root."] + #[doc = ""] + #[doc = "# Warning"] + #[doc = ""] + #[doc = "The election process starts multiple blocks before the end of the era."] + #[doc = "If this is called just before a new era is triggered, the election process may not"] + #[doc = "have enough blocks to get a result."] + pub fn force_new_era_always( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "SlashDeferDuration", + "force_new_era_always", + types::ForceNewEraAlways {}, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 179u8, 118u8, 189u8, 54u8, 248u8, 141u8, 207u8, 142u8, 80u8, 37u8, + 241u8, 185u8, 138u8, 254u8, 117u8, 147u8, 225u8, 118u8, 34u8, 177u8, + 197u8, 158u8, 8u8, 82u8, 202u8, 108u8, 208u8, 26u8, 64u8, 33u8, 74u8, + 43u8, ], ) } - #[doc = " The maximum number of nominators rewarded for each validator."] + #[doc = "Cancel enactment of a deferred slash."] #[doc = ""] - #[doc = " For each validator only the `$MaxNominatorRewardedPerValidator` biggest stakers can"] - #[doc = " claim their reward. This used to limit the i/o cost for the nominator payout."] - pub fn max_nominator_rewarded_per_validator( + #[doc = "Can be called by the `T::AdminOrigin`."] + #[doc = ""] + #[doc = "Parameters: era and indices of the slashes for that era to kill."] + pub fn cancel_deferred_slash( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( + era: ::core::primitive::u32, + slash_indices: ::std::vec::Vec<::core::primitive::u32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "MaxNominatorRewardedPerValidator", + "cancel_deferred_slash", + types::CancelDeferredSlash { era, slash_indices }, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 120u8, 57u8, 162u8, 105u8, 91u8, 250u8, 129u8, 240u8, 110u8, 234u8, + 170u8, 98u8, 164u8, 65u8, 106u8, 101u8, 19u8, 88u8, 146u8, 210u8, + 171u8, 44u8, 37u8, 50u8, 65u8, 178u8, 37u8, 223u8, 239u8, 197u8, 116u8, + 168u8, ], ) } - #[doc = " The maximum number of `unlocking` chunks a [`StakingLedger`] can"] - #[doc = " have. Effectively determines how many unique eras a staker may be"] - #[doc = " unbonding in."] + #[doc = "Pay out all the stakers behind a single validator for a single era."] #[doc = ""] - #[doc = " Note: `MaxUnlockingChunks` is used as the upper bound for the"] - #[doc = " `BoundedVec` item `StakingLedger.unlocking`. Setting this value"] - #[doc = " lower than the existing value can lead to inconsistencies in the"] - #[doc = " `StakingLedger` and will need to be handled properly in a runtime"] - #[doc = " migration. The test `reducing_max_unlocking_chunks_abrupt` shows"] - #[doc = " this effect."] - pub fn max_unlocking_chunks( + #[doc = "- `validator_stash` is the stash account of the validator. Their nominators, up to"] + #[doc = " `T::MaxNominatorRewardedPerValidator`, will also receive their rewards."] + #[doc = "- `era` may be any era between `[current_era - history_depth; current_era]`."] + #[doc = ""] + #[doc = "The origin of this call must be _Signed_. Any account can call this function, even if"] + #[doc = "it is not one of the stakers."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- At most O(MaxNominatorRewardedPerValidator)."] + pub fn payout_stakers( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( + validator_stash: ::subxt::utils::AccountId32, + era: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "Staking", - "MaxUnlockingChunks", + "payout_stakers", + types::PayoutStakers { + validator_stash, + era, + }, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 184u8, 194u8, 33u8, 118u8, 7u8, 203u8, 89u8, 119u8, 214u8, 76u8, 178u8, + 20u8, 82u8, 111u8, 57u8, 132u8, 212u8, 43u8, 232u8, 91u8, 252u8, 49u8, + 42u8, 115u8, 1u8, 181u8, 154u8, 207u8, 144u8, 206u8, 205u8, 33u8, ], ) } - } - } - } - pub mod offences { - use super::root_mod; - use super::runtime_types; - #[doc = "Events type."] - pub type Event = runtime_types::pallet_offences::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "There is an offence reported of the given `kind` happened at the `session_index` and"] - #[doc = "(kind-specific) time slot. This event is not deposited for duplicate slashes."] - #[doc = "\\[kind, timeslot\\]."] - pub struct Offence { - pub kind: [::core::primitive::u8; 16usize], - pub timeslot: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::events::StaticEvent for Offence { - const PALLET: &'static str = "Offences"; - const EVENT: &'static str = "Offence"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The primary structure that holds all offence records keyed by report identifiers."] - pub fn reports( + #[doc = "Rebond a portion of the stash scheduled to be unlocked."] + #[doc = ""] + #[doc = "The dispatch origin must be signed by the controller."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- Time complexity: O(L), where L is unlocking chunks"] + #[doc = "- Bounded by `MaxUnlockingChunks`."] + pub fn rebond( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_staking::offence::OffenceDetails< - ::subxt::utils::AccountId32, - ( - ::subxt::utils::AccountId32, - runtime_types::pallet_staking::Exposure< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - ), - >, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Offences", - "Reports", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Staking", + "rebond", + types::Rebond { value }, [ - 144u8, 30u8, 66u8, 199u8, 102u8, 236u8, 175u8, 201u8, 206u8, 170u8, - 55u8, 162u8, 137u8, 120u8, 220u8, 213u8, 57u8, 252u8, 0u8, 88u8, 210u8, - 68u8, 5u8, 25u8, 77u8, 114u8, 204u8, 23u8, 190u8, 32u8, 211u8, 30u8, + 25u8, 22u8, 191u8, 172u8, 133u8, 101u8, 139u8, 102u8, 134u8, 16u8, + 136u8, 56u8, 137u8, 162u8, 4u8, 253u8, 196u8, 30u8, 234u8, 49u8, 102u8, + 68u8, 145u8, 96u8, 148u8, 219u8, 162u8, 17u8, 177u8, 184u8, 34u8, + 113u8, ], ) } - #[doc = " The primary structure that holds all offence records keyed by report identifiers."] - pub fn reports_root( + #[doc = "Remove all data structures concerning a staker/stash once it is at a state where it can"] + #[doc = "be considered `dust` in the staking system. The requirements are:"] + #[doc = ""] + #[doc = "1. the `total_balance` of the stash is below existential deposit."] + #[doc = "2. or, the `ledger.total` of the stash is below existential deposit."] + #[doc = ""] + #[doc = "The former can happen in cases like a slash; the latter when a fully unbonded account"] + #[doc = "is still receiving staking rewards in `RewardDestination::Staked`."] + #[doc = ""] + #[doc = "It can be called by anyone, as long as `stash` meets the above requirements."] + #[doc = ""] + #[doc = "Refunds the transaction fees upon successful execution."] + pub fn reap_stash( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_staking::offence::OffenceDetails< - ::subxt::utils::AccountId32, - ( - ::subxt::utils::AccountId32, - runtime_types::pallet_staking::Exposure< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - ), - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Offences", - "Reports", - Vec::new(), + stash: ::subxt::utils::AccountId32, + num_slashing_spans: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Staking", + "reap_stash", + types::ReapStash { + stash, + num_slashing_spans, + }, [ - 144u8, 30u8, 66u8, 199u8, 102u8, 236u8, 175u8, 201u8, 206u8, 170u8, - 55u8, 162u8, 137u8, 120u8, 220u8, 213u8, 57u8, 252u8, 0u8, 88u8, 210u8, - 68u8, 5u8, 25u8, 77u8, 114u8, 204u8, 23u8, 190u8, 32u8, 211u8, 30u8, + 34u8, 168u8, 120u8, 161u8, 95u8, 199u8, 106u8, 233u8, 61u8, 240u8, + 166u8, 31u8, 183u8, 165u8, 158u8, 179u8, 32u8, 130u8, 27u8, 164u8, + 112u8, 44u8, 14u8, 125u8, 227u8, 87u8, 70u8, 203u8, 194u8, 24u8, 212u8, + 177u8, ], ) } - #[doc = " A vector of reports of the same kind that happened at the same time slot."] - pub fn concurrent_reports_index( + #[doc = "Remove the given nominations from the calling validator."] + #[doc = ""] + #[doc = "Effects will be felt at the beginning of the next era."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ by the controller, not the stash."] + #[doc = ""] + #[doc = "- `who`: A list of nominator stash accounts who are nominating this validator which"] + #[doc = " should no longer be nominating this validator."] + #[doc = ""] + #[doc = "Note: Making this call only makes sense if you first set the validator preferences to"] + #[doc = "block any further nominations."] + pub fn kick( &self, - _0: impl ::std::borrow::Borrow<[::core::primitive::u8; 16usize]>, - _1: impl ::std::borrow::Borrow<[::core::primitive::u8]>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::H256>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Offences", - "ConcurrentReportsIndex", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + who: ::std::vec::Vec< + ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Staking", + "kick", + types::Kick { who }, [ - 106u8, 21u8, 104u8, 5u8, 4u8, 66u8, 28u8, 70u8, 161u8, 195u8, 238u8, - 28u8, 69u8, 241u8, 221u8, 113u8, 140u8, 103u8, 181u8, 143u8, 60u8, - 177u8, 13u8, 129u8, 224u8, 149u8, 77u8, 32u8, 75u8, 74u8, 101u8, 65u8, + 32u8, 26u8, 202u8, 6u8, 186u8, 180u8, 58u8, 121u8, 185u8, 208u8, 123u8, + 10u8, 53u8, 179u8, 167u8, 203u8, 96u8, 229u8, 7u8, 144u8, 231u8, 172u8, + 145u8, 141u8, 162u8, 180u8, 212u8, 42u8, 34u8, 5u8, 199u8, 82u8, ], ) } - #[doc = " A vector of reports of the same kind that happened at the same time slot."] - pub fn concurrent_reports_index_root( + #[doc = "Update the various staking configurations ."] + #[doc = ""] + #[doc = "* `min_nominator_bond`: The minimum active bond needed to be a nominator."] + #[doc = "* `min_validator_bond`: The minimum active bond needed to be a validator."] + #[doc = "* `max_nominator_count`: The max number of users who can be a nominator at once. When"] + #[doc = " set to `None`, no limit is enforced."] + #[doc = "* `max_validator_count`: The max number of users who can be a validator at once. When"] + #[doc = " set to `None`, no limit is enforced."] + #[doc = "* `chill_threshold`: The ratio of `max_nominator_count` or `max_validator_count` which"] + #[doc = " should be filled in order for the `chill_other` transaction to work."] + #[doc = "* `min_commission`: The minimum amount of commission that each validators must maintain."] + #[doc = " This is checked only upon calling `validate`. Existing validators are not affected."] + #[doc = ""] + #[doc = "RuntimeOrigin must be Root to call this function."] + #[doc = ""] + #[doc = "NOTE: Existing nominators and validators will not be affected by this update."] + #[doc = "to kick people under the new limits, `chill_other` should be called."] + pub fn set_staking_configs( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::H256>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Offences", - "ConcurrentReportsIndex", - Vec::new(), + min_nominator_bond: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + ::core::primitive::u128, + >, + min_validator_bond: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + ::core::primitive::u128, + >, + max_nominator_count: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + ::core::primitive::u32, + >, + max_validator_count: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + ::core::primitive::u32, + >, + chill_threshold: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + runtime_types::sp_arithmetic::per_things::Percent, + >, + min_commission: runtime_types::pallet_staking::pallet::pallet::ConfigOp< + runtime_types::sp_arithmetic::per_things::Perbill, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Staking", + "set_staking_configs", + types::SetStakingConfigs { + min_nominator_bond, + min_validator_bond, + max_nominator_count, + max_validator_count, + chill_threshold, + min_commission, + }, [ - 106u8, 21u8, 104u8, 5u8, 4u8, 66u8, 28u8, 70u8, 161u8, 195u8, 238u8, - 28u8, 69u8, 241u8, 221u8, 113u8, 140u8, 103u8, 181u8, 143u8, 60u8, - 177u8, 13u8, 129u8, 224u8, 149u8, 77u8, 32u8, 75u8, 74u8, 101u8, 65u8, + 176u8, 168u8, 155u8, 176u8, 27u8, 79u8, 223u8, 92u8, 88u8, 93u8, 223u8, + 69u8, 179u8, 250u8, 138u8, 138u8, 87u8, 220u8, 36u8, 3u8, 126u8, 213u8, + 16u8, 68u8, 3u8, 16u8, 218u8, 151u8, 98u8, 169u8, 217u8, 75u8, ], ) } - } - } - } - pub mod historical { - use super::root_mod; - use super::runtime_types; - } - pub mod session { - use super::root_mod; - use super::runtime_types; - #[doc = "Error for the session pallet."] - pub type Error = runtime_types::pallet_session::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetKeys { - pub keys: runtime_types::polkadot_runtime::SessionKeys, - pub proof: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PurgeKeys; - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Sets the session key(s) of the function caller to `keys`."] - #[doc = "Allows an account to set its session key prior to becoming a validator."] - #[doc = "This doesn't take effect until the next session."] + #[doc = "Declare a `controller` to stop participating as either a validator or nominator."] #[doc = ""] - #[doc = "The dispatch origin of this function must be signed."] + #[doc = "Effects will be felt at the beginning of the next era."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(1)`. Actual cost depends on the number of length of `T::Keys::key_ids()` which is"] - #[doc = " fixed."] - pub fn set_keys( + #[doc = "The dispatch origin for this call must be _Signed_, but can be called by anyone."] + #[doc = ""] + #[doc = "If the caller is the same as the controller being targeted, then no further checks are"] + #[doc = "enforced, and this function behaves just like `chill`."] + #[doc = ""] + #[doc = "If the caller is different than the controller being targeted, the following conditions"] + #[doc = "must be met:"] + #[doc = ""] + #[doc = "* `controller` must belong to a nominator who has become non-decodable,"] + #[doc = ""] + #[doc = "Or:"] + #[doc = ""] + #[doc = "* A `ChillThreshold` must be set and checked which defines how close to the max"] + #[doc = " nominators or validators we must reach before users can start chilling one-another."] + #[doc = "* A `MaxNominatorCount` and `MaxValidatorCount` must be set which is used to determine"] + #[doc = " how close we are to the threshold."] + #[doc = "* A `MinNominatorBond` and `MinValidatorBond` must be set and checked, which determines"] + #[doc = " if this is a person that should be chilled because they have not met the threshold"] + #[doc = " bond required."] + #[doc = ""] + #[doc = "This can be helpful if bond requirements are updated, and we need to remove old users"] + #[doc = "who do not satisfy these requirements."] + pub fn chill_other( &self, - keys: runtime_types::polkadot_runtime::SessionKeys, - proof: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + controller: ::subxt::utils::AccountId32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Session", - "set_keys", - types::SetKeys { keys, proof }, + "Staking", + "chill_other", + types::ChillOther { controller }, [ - 17u8, 127u8, 23u8, 71u8, 118u8, 133u8, 89u8, 105u8, 93u8, 52u8, 46u8, - 201u8, 151u8, 19u8, 124u8, 195u8, 228u8, 229u8, 22u8, 216u8, 32u8, - 54u8, 67u8, 222u8, 91u8, 175u8, 206u8, 7u8, 238u8, 118u8, 81u8, 112u8, + 140u8, 98u8, 4u8, 203u8, 91u8, 131u8, 123u8, 119u8, 169u8, 47u8, 188u8, + 23u8, 205u8, 170u8, 82u8, 220u8, 166u8, 170u8, 135u8, 176u8, 68u8, + 228u8, 14u8, 67u8, 42u8, 52u8, 140u8, 231u8, 62u8, 167u8, 80u8, 173u8, ], ) } - #[doc = "Removes any session key(s) of the function caller."] - #[doc = ""] - #[doc = "This doesn't take effect until the next session."] - #[doc = ""] - #[doc = "The dispatch origin of this function must be Signed and the account must be either be"] - #[doc = "convertible to a validator ID using the chain's typical addressing system (this usually"] - #[doc = "means being a controller account) or directly convertible into a validator ID (which"] - #[doc = "usually means being a stash account)."] + #[doc = "Force a validator to have at least the minimum commission. This will not affect a"] + #[doc = "validator who already has a commission greater than or equal to the minimum. Any account"] + #[doc = "can call this."] + pub fn force_apply_min_commission( + &self, + validator_stash: ::subxt::utils::AccountId32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Staking", + "force_apply_min_commission", + types::ForceApplyMinCommission { validator_stash }, + [ + 136u8, 163u8, 85u8, 134u8, 240u8, 247u8, 183u8, 227u8, 226u8, 202u8, + 102u8, 186u8, 138u8, 119u8, 78u8, 123u8, 229u8, 135u8, 129u8, 241u8, + 119u8, 106u8, 41u8, 182u8, 121u8, 181u8, 242u8, 175u8, 74u8, 207u8, + 64u8, 106u8, + ], + ) + } + #[doc = "Sets the minimum amount of commission that each validators must maintain."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(1)` in number of key types. Actual cost depends on the number of length of"] - #[doc = " `T::Keys::key_ids()` which is fixed."] - pub fn purge_keys(&self) -> ::subxt::tx::Payload { + #[doc = "This call has lower privilege requirements than `set_staking_config` and can be called"] + #[doc = "by the `T::AdminOrigin`. Root can always call this."] + pub fn set_min_commission( + &self, + new: runtime_types::sp_arithmetic::per_things::Perbill, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Session", - "purge_keys", - types::PurgeKeys {}, + "Staking", + "set_min_commission", + types::SetMinCommission { new }, [ - 200u8, 255u8, 4u8, 213u8, 188u8, 92u8, 99u8, 116u8, 163u8, 152u8, 29u8, - 35u8, 133u8, 119u8, 246u8, 44u8, 91u8, 31u8, 145u8, 23u8, 213u8, 64u8, - 71u8, 242u8, 207u8, 239u8, 231u8, 37u8, 61u8, 63u8, 190u8, 35u8, + 62u8, 139u8, 175u8, 245u8, 212u8, 113u8, 117u8, 130u8, 191u8, 173u8, + 78u8, 97u8, 19u8, 104u8, 185u8, 207u8, 201u8, 14u8, 200u8, 208u8, + 184u8, 195u8, 242u8, 175u8, 158u8, 156u8, 51u8, 58u8, 118u8, 154u8, + 68u8, 221u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_session::pallet::Event; + pub type Event = runtime_types::pallet_staking::pallet::pallet::Event; pub mod events { use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The era payout has been set; the first balance is the validator-payout; the second is"] + #[doc = "the remainder from the maximum amount of reward."] + pub struct EraPaid { + pub era_index: ::core::primitive::u32, + pub validator_payout: ::core::primitive::u128, + pub remainder: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for EraPaid { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "EraPaid"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The nominator has been rewarded by this amount."] + pub struct Rewarded { + pub stash: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Rewarded { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "Rewarded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A staker (validator or nominator) has been slashed by the given amount."] + pub struct Slashed { + pub staker: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Slashed { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "Slashed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A slash for the given validator, for the given percentage of their stake, at the given"] + #[doc = "era as been reported."] + pub struct SlashReported { + pub validator: ::subxt::utils::AccountId32, + pub fraction: runtime_types::sp_arithmetic::per_things::Perbill, + pub slash_era: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for SlashReported { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "SlashReported"; + } #[derive( :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, @@ -8896,245 +9473,31 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "New session has happened. Note that the argument is the session index, not the"] - #[doc = "block number as the type might suggest."] - pub struct NewSession { + #[doc = "An old slashing report from a prior era was discarded because it could"] + #[doc = "not be processed."] + pub struct OldSlashingReportDiscarded { pub session_index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for NewSession { - const PALLET: &'static str = "Session"; - const EVENT: &'static str = "NewSession"; + impl ::subxt::events::StaticEvent for OldSlashingReportDiscarded { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "OldSlashingReportDiscarded"; } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The current set of validators."] - pub fn validators( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::AccountId32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "Validators", - vec![], - [ - 144u8, 235u8, 200u8, 43u8, 151u8, 57u8, 147u8, 172u8, 201u8, 202u8, - 242u8, 96u8, 57u8, 76u8, 124u8, 77u8, 42u8, 113u8, 218u8, 220u8, 230u8, - 32u8, 151u8, 152u8, 172u8, 106u8, 60u8, 227u8, 122u8, 118u8, 137u8, - 68u8, - ], - ) - } - #[doc = " Current index of the session."] - pub fn current_index( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "CurrentIndex", - vec![], - [ - 148u8, 179u8, 159u8, 15u8, 197u8, 95u8, 214u8, 30u8, 209u8, 251u8, - 183u8, 231u8, 91u8, 25u8, 181u8, 191u8, 143u8, 252u8, 227u8, 80u8, - 159u8, 66u8, 194u8, 67u8, 113u8, 74u8, 111u8, 91u8, 218u8, 187u8, - 130u8, 40u8, - ], - ) - } - #[doc = " True if the underlying economic identities or weighting behind the validators"] - #[doc = " has changed in the queued validator set."] - pub fn queued_changed( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "QueuedChanged", - vec![], - [ - 105u8, 140u8, 235u8, 218u8, 96u8, 100u8, 252u8, 10u8, 58u8, 221u8, - 244u8, 251u8, 67u8, 91u8, 80u8, 202u8, 152u8, 42u8, 50u8, 113u8, 200u8, - 247u8, 59u8, 213u8, 77u8, 195u8, 1u8, 150u8, 220u8, 18u8, 245u8, 46u8, - ], - ) - } - #[doc = " The queued keys for the next session. When the next session begins, these keys"] - #[doc = " will be used to determine the validator's session keys."] - pub fn queued_keys( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::polkadot_runtime::SessionKeys, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "QueuedKeys", - vec![], - [ - 197u8, 174u8, 245u8, 219u8, 36u8, 118u8, 73u8, 184u8, 156u8, 93u8, - 167u8, 107u8, 142u8, 7u8, 41u8, 51u8, 77u8, 191u8, 68u8, 95u8, 71u8, - 76u8, 253u8, 137u8, 73u8, 194u8, 169u8, 234u8, 217u8, 76u8, 157u8, - 223u8, - ], - ) - } - #[doc = " Indices of disabled validators."] - #[doc = ""] - #[doc = " The vec is always kept sorted so that we can find whether a given validator is"] - #[doc = " disabled using binary search. It gets cleared when `on_session_ending` returns"] - #[doc = " a new set of identities."] - pub fn disabled_validators( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "DisabledValidators", - vec![], - [ - 135u8, 22u8, 22u8, 97u8, 82u8, 217u8, 144u8, 141u8, 121u8, 240u8, - 189u8, 16u8, 176u8, 88u8, 177u8, 31u8, 20u8, 242u8, 73u8, 104u8, 11u8, - 110u8, 214u8, 34u8, 52u8, 217u8, 106u8, 33u8, 174u8, 174u8, 198u8, - 84u8, - ], - ) - } - #[doc = " The next session keys for a validator."] - pub fn next_keys( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime::SessionKeys, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Session", - "NextKeys", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 94u8, 197u8, 147u8, 245u8, 165u8, 97u8, 186u8, 57u8, 142u8, 66u8, - 132u8, 213u8, 126u8, 3u8, 77u8, 88u8, 191u8, 33u8, 82u8, 153u8, 11u8, - 109u8, 96u8, 252u8, 193u8, 171u8, 158u8, 131u8, 29u8, 192u8, 248u8, - 166u8, - ], - ) - } - #[doc = " The next session keys for a validator."] - pub fn next_keys_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime::SessionKeys, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Session", - "NextKeys", - Vec::new(), - [ - 94u8, 197u8, 147u8, 245u8, 165u8, 97u8, 186u8, 57u8, 142u8, 66u8, - 132u8, 213u8, 126u8, 3u8, 77u8, 88u8, 191u8, 33u8, 82u8, 153u8, 11u8, - 109u8, 96u8, 252u8, 193u8, 171u8, 158u8, 131u8, 29u8, 192u8, 248u8, - 166u8, - ], - ) - } - #[doc = " The owner of a key. The key is the `KeyTypeId` + the encoded key."] - pub fn key_owner( - &self, - _0: impl ::std::borrow::Borrow, - _1: impl ::std::borrow::Borrow<[::core::primitive::u8]>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Session", - "KeyOwner", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 4u8, 91u8, 25u8, 84u8, 250u8, 201u8, 174u8, 129u8, 201u8, 58u8, 197u8, - 199u8, 137u8, 240u8, 118u8, 33u8, 99u8, 2u8, 195u8, 57u8, 53u8, 172u8, - 0u8, 148u8, 203u8, 144u8, 149u8, 64u8, 135u8, 254u8, 242u8, 215u8, - ], - ) - } - #[doc = " The owner of a key. The key is the `KeyTypeId` + the encoded key."] - pub fn key_owner_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Session", - "KeyOwner", - Vec::new(), - [ - 4u8, 91u8, 25u8, 84u8, 250u8, 201u8, 174u8, 129u8, 201u8, 58u8, 197u8, - 199u8, 137u8, 240u8, 118u8, 33u8, 99u8, 2u8, 195u8, 57u8, 53u8, 172u8, - 0u8, 148u8, 203u8, 144u8, 149u8, 64u8, 135u8, 254u8, 242u8, 215u8, - ], - ) - } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new set of stakers was elected."] + pub struct StakersElected; + impl ::subxt::events::StaticEvent for StakersElected { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "StakersElected"; } - } - } - pub mod grandpa { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_grandpa::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -9145,14 +9508,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportEquivocation { - pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_grandpa::EquivocationProof< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, + #[doc = "An account has bonded this amount. \\[stash, amount\\]"] + #[doc = ""] + #[doc = "NOTE: This event is only emitted when funds are bonded via a dispatchable. Notably,"] + #[doc = "it will not be emitted for staking rewards when they are added to stake."] + pub struct Bonded { + pub stash: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Bonded { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "Bonded"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -9164,127 +9530,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportEquivocationUnsigned { - pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_grandpa::EquivocationProof< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NoteStalled { - pub delay: ::core::primitive::u32, - pub best_finalized_block_number: ::core::primitive::u32, - } + #[doc = "An account has unbonded this amount."] + pub struct Unbonded { + pub stash: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Report voter equivocation/misbehavior. This method will verify the"] - #[doc = "equivocation proof and validate the given key ownership proof"] - #[doc = "against the extracted offender. If both are valid, the offence"] - #[doc = "will be reported."] - pub fn report_equivocation( - &self, - equivocation_proof: runtime_types::sp_consensus_grandpa::EquivocationProof< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Grandpa", - "report_equivocation", - types::ReportEquivocation { - equivocation_proof: ::std::boxed::Box::new(equivocation_proof), - key_owner_proof, - }, - [ - 156u8, 162u8, 189u8, 89u8, 60u8, 156u8, 129u8, 176u8, 62u8, 35u8, - 214u8, 7u8, 68u8, 245u8, 130u8, 117u8, 30u8, 3u8, 73u8, 218u8, 142u8, - 82u8, 13u8, 141u8, 124u8, 19u8, 53u8, 138u8, 70u8, 4u8, 40u8, 32u8, - ], - ) - } - #[doc = "Report voter equivocation/misbehavior. This method will verify the"] - #[doc = "equivocation proof and validate the given key ownership proof"] - #[doc = "against the extracted offender. If both are valid, the offence"] - #[doc = "will be reported."] - #[doc = ""] - #[doc = "This extrinsic must be called unsigned and it is expected that only"] - #[doc = "block authors will call it (validated in `ValidateUnsigned`), as such"] - #[doc = "if the block author is defined it will be defined as the equivocation"] - #[doc = "reporter."] - pub fn report_equivocation_unsigned( - &self, - equivocation_proof: runtime_types::sp_consensus_grandpa::EquivocationProof< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Grandpa", - "report_equivocation_unsigned", - types::ReportEquivocationUnsigned { - equivocation_proof: ::std::boxed::Box::new(equivocation_proof), - key_owner_proof, - }, - [ - 166u8, 26u8, 217u8, 185u8, 215u8, 37u8, 174u8, 170u8, 137u8, 160u8, - 151u8, 43u8, 246u8, 86u8, 58u8, 18u8, 248u8, 73u8, 99u8, 161u8, 158u8, - 93u8, 212u8, 186u8, 224u8, 253u8, 234u8, 18u8, 151u8, 111u8, 227u8, - 249u8, - ], - ) - } - #[doc = "Note that the current authority set of the GRANDPA finality gadget has stalled."] - #[doc = ""] - #[doc = "This will trigger a forced authority set change at the beginning of the next session, to"] - #[doc = "be enacted `delay` blocks after that. The `delay` should be high enough to safely assume"] - #[doc = "that the block signalling the forced change will not be re-orged e.g. 1000 blocks."] - #[doc = "The block production rate (which may be slowed down because of finality lagging) should"] - #[doc = "be taken into account when choosing the `delay`. The GRANDPA voters based on the new"] - #[doc = "authority will start voting on top of `best_finalized_block_number` for new finalized"] - #[doc = "blocks. `best_finalized_block_number` should be the highest of the latest finalized"] - #[doc = "block of all validators of the new authority set."] - #[doc = ""] - #[doc = "Only callable by root."] - pub fn note_stalled( - &self, - delay: ::core::primitive::u32, - best_finalized_block_number: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Grandpa", - "note_stalled", - types::NoteStalled { - delay, - best_finalized_block_number, - }, - [ - 197u8, 236u8, 137u8, 32u8, 46u8, 200u8, 144u8, 13u8, 89u8, 181u8, - 235u8, 73u8, 167u8, 131u8, 174u8, 93u8, 42u8, 136u8, 238u8, 59u8, - 129u8, 60u8, 83u8, 100u8, 5u8, 182u8, 99u8, 250u8, 145u8, 180u8, 1u8, - 199u8, - ], - ) - } + impl ::subxt::events::StaticEvent for Unbonded { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "Unbonded"; } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_grandpa::pallet::Event; - pub mod events { - use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -9295,16 +9549,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "New authority set has been applied."] - pub struct NewAuthorities { - pub authority_set: ::std::vec::Vec<( - runtime_types::sp_consensus_grandpa::app::Public, - ::core::primitive::u64, - )>, + #[doc = "An account has called `withdraw_unbonded` and removed unbonding chunks worth `Balance`"] + #[doc = "from the unlocking queue."] + pub struct Withdrawn { + pub stash: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for NewAuthorities { - const PALLET: &'static str = "Grandpa"; - const EVENT: &'static str = "NewAuthorities"; + impl ::subxt::events::StaticEvent for Withdrawn { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "Withdrawn"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -9316,11 +9569,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Current authority set has been paused."] - pub struct Paused; - impl ::subxt::events::StaticEvent for Paused { - const PALLET: &'static str = "Grandpa"; - const EVENT: &'static str = "Paused"; + #[doc = "A nominator has been kicked from a validator."] + pub struct Kicked { + pub nominator: ::subxt::utils::AccountId32, + pub stash: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for Kicked { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "Kicked"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -9332,2205 +9588,1468 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Current authority set has been resumed."] - pub struct Resumed; - impl ::subxt::events::StaticEvent for Resumed { - const PALLET: &'static str = "Grandpa"; - const EVENT: &'static str = "Resumed"; + #[doc = "The election failed. No new era is planned."] + pub struct StakingElectionFailed; + impl ::subxt::events::StaticEvent for StakingElectionFailed { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "StakingElectionFailed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account has stopped participating as either a validator or nominator."] + pub struct Chilled { + pub stash: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for Chilled { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "Chilled"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The stakers' rewards are getting paid."] + pub struct PayoutStarted { + pub era_index: ::core::primitive::u32, + pub validator_stash: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for PayoutStarted { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "PayoutStarted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A validator has set their preferences."] + pub struct ValidatorPrefsSet { + pub stash: ::subxt::utils::AccountId32, + pub prefs: runtime_types::pallet_staking::ValidatorPrefs, + } + impl ::subxt::events::StaticEvent for ValidatorPrefsSet { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "ValidatorPrefsSet"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new force era mode was set."] + pub struct ForceEra { + pub mode: runtime_types::pallet_staking::Forcing, + } + impl ::subxt::events::StaticEvent for ForceEra { + const PALLET: &'static str = "Staking"; + const EVENT: &'static str = "ForceEra"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " State of the current authority set."] - pub fn state( + #[doc = " The ideal number of active validators."] + pub fn validator_count( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_grandpa::StoredState<::core::primitive::u32>, + ::core::primitive::u32, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "Grandpa", - "State", + "Staking", + "ValidatorCount", vec![], [ - 211u8, 149u8, 114u8, 217u8, 206u8, 194u8, 115u8, 67u8, 12u8, 218u8, - 246u8, 213u8, 208u8, 29u8, 216u8, 104u8, 2u8, 39u8, 123u8, 172u8, - 252u8, 210u8, 52u8, 129u8, 147u8, 237u8, 244u8, 68u8, 252u8, 169u8, - 97u8, 148u8, + 245u8, 75u8, 214u8, 110u8, 66u8, 164u8, 86u8, 206u8, 69u8, 89u8, 12u8, + 111u8, 117u8, 16u8, 228u8, 184u8, 207u8, 6u8, 0u8, 126u8, 221u8, 67u8, + 125u8, 218u8, 188u8, 245u8, 156u8, 188u8, 34u8, 85u8, 208u8, 197u8, ], ) } - #[doc = " Pending change: (signaled at, scheduled change)."] - pub fn pending_change( + #[doc = " Minimum number of staking participants before emergency conditions are imposed."] + pub fn minimum_validator_count( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_grandpa::StoredPendingChange<::core::primitive::u32>, + ::core::primitive::u32, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), (), > { ::subxt::storage::address::Address::new_static( - "Grandpa", - "PendingChange", + "Staking", + "MinimumValidatorCount", vec![], [ - 178u8, 24u8, 140u8, 7u8, 8u8, 196u8, 18u8, 58u8, 3u8, 226u8, 181u8, - 47u8, 155u8, 160u8, 70u8, 12u8, 75u8, 189u8, 38u8, 255u8, 104u8, 141u8, - 64u8, 34u8, 134u8, 201u8, 102u8, 21u8, 75u8, 81u8, 218u8, 60u8, + 82u8, 95u8, 128u8, 55u8, 136u8, 134u8, 71u8, 117u8, 135u8, 76u8, 44u8, + 46u8, 174u8, 34u8, 170u8, 228u8, 175u8, 1u8, 234u8, 162u8, 91u8, 252u8, + 127u8, 68u8, 243u8, 241u8, 13u8, 107u8, 214u8, 70u8, 87u8, 249u8, ], ) } - #[doc = " next block number where we can force a change."] - pub fn next_forced( + #[doc = " Any validators that may never be slashed or forcibly kicked. It's a Vec since they're"] + #[doc = " easy to initialize and the performance hit is minimal (we expect no more than four"] + #[doc = " invulnerables) and restricted to testnets."] + pub fn invulnerables( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + ::std::vec::Vec<::subxt::utils::AccountId32>, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), (), > { ::subxt::storage::address::Address::new_static( - "Grandpa", - "NextForced", + "Staking", + "Invulnerables", vec![], [ - 99u8, 43u8, 245u8, 201u8, 60u8, 9u8, 122u8, 99u8, 188u8, 29u8, 67u8, - 6u8, 193u8, 133u8, 179u8, 67u8, 202u8, 208u8, 62u8, 179u8, 19u8, 169u8, - 196u8, 119u8, 107u8, 75u8, 100u8, 3u8, 121u8, 18u8, 80u8, 156u8, + 77u8, 78u8, 63u8, 199u8, 150u8, 167u8, 135u8, 130u8, 192u8, 51u8, + 202u8, 119u8, 68u8, 49u8, 241u8, 68u8, 82u8, 90u8, 226u8, 201u8, 96u8, + 170u8, 21u8, 173u8, 236u8, 116u8, 148u8, 8u8, 174u8, 92u8, 7u8, 11u8, ], ) } - #[doc = " `true` if we are currently stalled."] - pub fn stalled( + #[doc = " Map from all locked \"stash\" accounts to the controller account."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn bonded( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), + ::subxt::utils::AccountId32, ::subxt::storage::address::Yes, (), - (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Grandpa", - "Stalled", - vec![], + "Staking", + "Bonded", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 219u8, 8u8, 37u8, 78u8, 150u8, 55u8, 0u8, 57u8, 201u8, 170u8, 186u8, - 189u8, 56u8, 161u8, 44u8, 15u8, 53u8, 178u8, 224u8, 208u8, 231u8, - 109u8, 14u8, 209u8, 57u8, 205u8, 237u8, 153u8, 231u8, 156u8, 24u8, - 185u8, + 35u8, 197u8, 156u8, 60u8, 22u8, 59u8, 103u8, 83u8, 77u8, 15u8, 118u8, + 193u8, 155u8, 97u8, 229u8, 36u8, 119u8, 128u8, 224u8, 162u8, 21u8, + 46u8, 199u8, 221u8, 15u8, 74u8, 59u8, 70u8, 77u8, 218u8, 73u8, 165u8, ], ) } - #[doc = " The number of changes (both in terms of keys and underlying economic responsibilities)"] - #[doc = " in the \"set\" of Grandpa validators from genesis."] - pub fn current_set_id( + #[doc = " Map from all locked \"stash\" accounts to the controller account."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn bonded_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + ::subxt::utils::AccountId32, (), + (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Grandpa", - "CurrentSetId", - vec![], - [ - 129u8, 7u8, 62u8, 101u8, 199u8, 60u8, 56u8, 33u8, 54u8, 158u8, 20u8, - 178u8, 244u8, 145u8, 189u8, 197u8, 157u8, 163u8, 116u8, 36u8, 105u8, - 52u8, 149u8, 244u8, 108u8, 94u8, 109u8, 111u8, 244u8, 137u8, 7u8, - 108u8, + "Staking", + "Bonded", + Vec::new(), + [ + 35u8, 197u8, 156u8, 60u8, 22u8, 59u8, 103u8, 83u8, 77u8, 15u8, 118u8, + 193u8, 155u8, 97u8, 229u8, 36u8, 119u8, 128u8, 224u8, 162u8, 21u8, + 46u8, 199u8, 221u8, 15u8, 74u8, 59u8, 70u8, 77u8, 218u8, 73u8, 165u8, ], ) } - #[doc = " A mapping from grandpa set ID to the index of the *most recent* session for which its"] - #[doc = " members were responsible."] - #[doc = ""] - #[doc = " This is only used for validating equivocation proofs. An equivocation proof must"] - #[doc = " contains a key-ownership proof for a given session, therefore we need a way to tie"] - #[doc = " together sessions and GRANDPA set ids, i.e. we need to validate that a validator"] - #[doc = " was the owner of a given key on a given session, and what the active set ID was"] - #[doc = " during that session."] - #[doc = ""] - #[doc = " TWOX-NOTE: `SetId` is not under user control."] - pub fn set_id_session( + #[doc = " The minimum active bond to become and maintain the role of a nominator."] + pub fn min_nominator_bond( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u64>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + ::core::primitive::u128, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Grandpa", - "SetIdSession", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Staking", + "MinNominatorBond", + vec![], [ - 91u8, 175u8, 145u8, 127u8, 242u8, 81u8, 13u8, 231u8, 110u8, 11u8, - 166u8, 169u8, 103u8, 146u8, 123u8, 133u8, 157u8, 15u8, 33u8, 234u8, - 108u8, 13u8, 88u8, 115u8, 254u8, 9u8, 145u8, 199u8, 102u8, 47u8, 53u8, - 134u8, + 187u8, 66u8, 149u8, 226u8, 72u8, 219u8, 57u8, 246u8, 102u8, 47u8, 71u8, + 12u8, 219u8, 204u8, 127u8, 223u8, 58u8, 134u8, 81u8, 165u8, 200u8, + 142u8, 196u8, 158u8, 26u8, 38u8, 165u8, 19u8, 91u8, 251u8, 119u8, 84u8, ], ) } - #[doc = " A mapping from grandpa set ID to the index of the *most recent* session for which its"] - #[doc = " members were responsible."] - #[doc = ""] - #[doc = " This is only used for validating equivocation proofs. An equivocation proof must"] - #[doc = " contains a key-ownership proof for a given session, therefore we need a way to tie"] - #[doc = " together sessions and GRANDPA set ids, i.e. we need to validate that a validator"] - #[doc = " was the owner of a given key on a given session, and what the active set ID was"] - #[doc = " during that session."] - #[doc = ""] - #[doc = " TWOX-NOTE: `SetId` is not under user control."] - pub fn set_id_session_root( + #[doc = " The minimum active bond to become and maintain the role of a validator."] + pub fn min_validator_bond( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), + ::core::primitive::u128, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Grandpa", - "SetIdSession", - Vec::new(), + "Staking", + "MinValidatorBond", + vec![], [ - 91u8, 175u8, 145u8, 127u8, 242u8, 81u8, 13u8, 231u8, 110u8, 11u8, - 166u8, 169u8, 103u8, 146u8, 123u8, 133u8, 157u8, 15u8, 33u8, 234u8, - 108u8, 13u8, 88u8, 115u8, 254u8, 9u8, 145u8, 199u8, 102u8, 47u8, 53u8, - 134u8, + 48u8, 105u8, 85u8, 178u8, 142u8, 208u8, 208u8, 19u8, 236u8, 130u8, + 129u8, 169u8, 35u8, 245u8, 66u8, 182u8, 92u8, 20u8, 22u8, 109u8, 155u8, + 174u8, 87u8, 118u8, 242u8, 216u8, 193u8, 154u8, 4u8, 5u8, 66u8, 56u8, ], ) } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Max Authorities in use"] - pub fn max_authorities( + #[doc = " The minimum active nominator stake of the last successful election."] + pub fn minimum_active_stake( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Grandpa", - "MaxAuthorities", + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "MinimumActiveStake", + vec![], [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 172u8, 190u8, 228u8, 47u8, 47u8, 192u8, 182u8, 59u8, 9u8, 18u8, 103u8, + 46u8, 175u8, 54u8, 17u8, 79u8, 89u8, 107u8, 255u8, 200u8, 182u8, 107u8, + 89u8, 157u8, 55u8, 16u8, 77u8, 46u8, 154u8, 169u8, 103u8, 151u8, ], ) } - #[doc = " The maximum number of entries to keep in the set id to session index mapping."] + #[doc = " The minimum amount of commission that validators can set."] #[doc = ""] - #[doc = " Since the `SetIdSession` map is only used for validating equivocations this"] - #[doc = " value should relate to the bonding duration of whatever staking system is"] - #[doc = " being used (if any). If equivocation handling is not enabled then this value"] - #[doc = " can be zero."] - pub fn max_set_id_session_entries( + #[doc = " If set to `0`, no limit exists."] + pub fn min_commission( &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "Grandpa", - "MaxSetIdSessionEntries", + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_arithmetic::per_things::Perbill, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "MinCommission", + vec![], [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, + 61u8, 101u8, 69u8, 27u8, 220u8, 179u8, 5u8, 71u8, 66u8, 227u8, 84u8, + 98u8, 18u8, 141u8, 183u8, 49u8, 98u8, 46u8, 123u8, 114u8, 198u8, 85u8, + 15u8, 175u8, 243u8, 239u8, 133u8, 129u8, 146u8, 174u8, 254u8, 158u8, ], ) } - } - } - } - pub mod im_online { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_im_online::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Heartbeat { - pub heartbeat: - runtime_types::pallet_im_online::Heartbeat<::core::primitive::u32>, - pub signature: runtime_types::pallet_im_online::sr25519::app_sr25519::Signature, + #[doc = " Map from all (unlocked) \"controller\" accounts to the info regarding the staking."] + pub fn ledger( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_staking::StakingLedger, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "Ledger", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 31u8, 205u8, 3u8, 165u8, 22u8, 22u8, 62u8, 92u8, 33u8, 189u8, 124u8, + 120u8, 177u8, 70u8, 27u8, 242u8, 188u8, 184u8, 204u8, 188u8, 242u8, + 140u8, 128u8, 230u8, 85u8, 99u8, 181u8, 173u8, 67u8, 252u8, 37u8, + 236u8, + ], + ) } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "## Complexity:"] - #[doc = "- `O(K + E)` where K is length of `Keys` (heartbeat.validators_len) and E is length of"] - #[doc = " `heartbeat.network_state.external_address`"] - #[doc = " - `O(K)`: decoding of length `K`"] - #[doc = " - `O(E)`: decoding/encoding of length `E`"] - pub fn heartbeat( + #[doc = " Map from all (unlocked) \"controller\" accounts to the info regarding the staking."] + pub fn ledger_root( &self, - heartbeat: runtime_types::pallet_im_online::Heartbeat<::core::primitive::u32>, - signature: runtime_types::pallet_im_online::sr25519::app_sr25519::Signature, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ImOnline", - "heartbeat", - types::Heartbeat { - heartbeat, - signature, - }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_staking::StakingLedger, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "Ledger", + Vec::new(), [ - 212u8, 23u8, 174u8, 246u8, 60u8, 220u8, 178u8, 137u8, 53u8, 146u8, - 165u8, 225u8, 179u8, 209u8, 233u8, 152u8, 129u8, 210u8, 126u8, 32u8, - 216u8, 22u8, 76u8, 196u8, 255u8, 128u8, 246u8, 161u8, 30u8, 186u8, - 249u8, 34u8, + 31u8, 205u8, 3u8, 165u8, 22u8, 22u8, 62u8, 92u8, 33u8, 189u8, 124u8, + 120u8, 177u8, 70u8, 27u8, 242u8, 188u8, 184u8, 204u8, 188u8, 242u8, + 140u8, 128u8, 230u8, 85u8, 99u8, 181u8, 173u8, 67u8, 252u8, 37u8, + 236u8, ], ) } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_im_online::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new heartbeat was received from `AuthorityId`."] - pub struct HeartbeatReceived { - pub authority_id: runtime_types::pallet_im_online::sr25519::app_sr25519::Public, - } - impl ::subxt::events::StaticEvent for HeartbeatReceived { - const PALLET: &'static str = "ImOnline"; - const EVENT: &'static str = "HeartbeatReceived"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "At the end of the session, no offence was committed."] - pub struct AllGood; - impl ::subxt::events::StaticEvent for AllGood { - const PALLET: &'static str = "ImOnline"; - const EVENT: &'static str = "AllGood"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "At the end of the session, at least one validator was found to be offline."] - pub struct SomeOffline { - pub offline: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::pallet_staking::Exposure< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - )>, - } - impl ::subxt::events::StaticEvent for SomeOffline { - const PALLET: &'static str = "ImOnline"; - const EVENT: &'static str = "SomeOffline"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The block number after which it's ok to send heartbeats in the current"] - #[doc = " session."] - #[doc = ""] - #[doc = " At the beginning of each session we set this to a value that should fall"] - #[doc = " roughly in the middle of the session duration. The idea is to first wait for"] - #[doc = " the validators to produce a block in the current session, so that the"] - #[doc = " heartbeat later on will not be necessary."] + #[doc = " Where the reward payment should be made. Keyed by stash."] #[doc = ""] - #[doc = " This value will only be used as a fallback if we fail to get a proper session"] - #[doc = " progress estimate from `NextSessionRotation`, as those estimates should be"] - #[doc = " more accurate then the value we calculate for `HeartbeatAfter`."] - pub fn heartbeat_after( + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn payee( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + runtime_types::pallet_staking::RewardDestination<::subxt::utils::AccountId32>, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), > { ::subxt::storage::address::Address::new_static( - "ImOnline", - "HeartbeatAfter", - vec![], + "Staking", + "Payee", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 108u8, 100u8, 85u8, 198u8, 226u8, 122u8, 94u8, 225u8, 97u8, 154u8, - 135u8, 95u8, 106u8, 28u8, 185u8, 78u8, 192u8, 196u8, 35u8, 191u8, 12u8, - 19u8, 163u8, 46u8, 232u8, 235u8, 193u8, 81u8, 126u8, 204u8, 25u8, - 228u8, + 195u8, 125u8, 82u8, 213u8, 216u8, 64u8, 76u8, 63u8, 187u8, 163u8, 20u8, + 230u8, 153u8, 13u8, 189u8, 232u8, 119u8, 118u8, 107u8, 17u8, 102u8, + 245u8, 36u8, 42u8, 232u8, 137u8, 177u8, 165u8, 169u8, 246u8, 199u8, + 57u8, ], ) } - #[doc = " The current set of keys that may issue a heartbeat."] - pub fn keys( + #[doc = " Where the reward payment should be made. Keyed by stash."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn payee_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - runtime_types::pallet_im_online::sr25519::app_sr25519::Public, - >, + runtime_types::pallet_staking::RewardDestination<::subxt::utils::AccountId32>, + (), ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), > { ::subxt::storage::address::Address::new_static( - "ImOnline", - "Keys", - vec![], + "Staking", + "Payee", + Vec::new(), [ - 6u8, 198u8, 221u8, 58u8, 14u8, 166u8, 245u8, 103u8, 191u8, 20u8, 69u8, - 233u8, 147u8, 245u8, 24u8, 64u8, 207u8, 180u8, 39u8, 208u8, 252u8, - 236u8, 247u8, 112u8, 187u8, 97u8, 70u8, 11u8, 248u8, 148u8, 208u8, - 106u8, + 195u8, 125u8, 82u8, 213u8, 216u8, 64u8, 76u8, 63u8, 187u8, 163u8, 20u8, + 230u8, 153u8, 13u8, 189u8, 232u8, 119u8, 118u8, 107u8, 17u8, 102u8, + 245u8, 36u8, 42u8, 232u8, 137u8, 177u8, 165u8, 169u8, 246u8, 199u8, + 57u8, ], ) } - #[doc = " For each session index, we keep a mapping of `SessionIndex` and `AuthIndex` to"] - #[doc = " `WrapperOpaque`."] - pub fn received_heartbeats( + #[doc = " The map from (wannabe) validator stash key to the preferences of that validator."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn validators( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::core::primitive::u32>, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_support::traits::misc::WrapperOpaque< - runtime_types::pallet_im_online::BoundedOpaqueNetworkState, - >, + runtime_types::pallet_staking::ValidatorPrefs, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ImOnline", - "ReceivedHeartbeats", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + "Staking", + "Validators", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 233u8, 128u8, 140u8, 233u8, 55u8, 146u8, 172u8, 54u8, 54u8, 57u8, - 141u8, 106u8, 168u8, 59u8, 147u8, 253u8, 119u8, 48u8, 50u8, 251u8, - 242u8, 109u8, 251u8, 2u8, 136u8, 80u8, 146u8, 121u8, 180u8, 219u8, - 245u8, 37u8, + 80u8, 77u8, 66u8, 18u8, 197u8, 250u8, 41u8, 185u8, 43u8, 24u8, 149u8, + 164u8, 208u8, 60u8, 144u8, 29u8, 251u8, 195u8, 236u8, 196u8, 108u8, + 58u8, 80u8, 115u8, 246u8, 66u8, 226u8, 241u8, 201u8, 172u8, 229u8, + 152u8, ], ) } - #[doc = " For each session index, we keep a mapping of `SessionIndex` and `AuthIndex` to"] - #[doc = " `WrapperOpaque`."] - pub fn received_heartbeats_root( + #[doc = " The map from (wannabe) validator stash key to the preferences of that validator."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn validators_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_support::traits::misc::WrapperOpaque< - runtime_types::pallet_im_online::BoundedOpaqueNetworkState, - >, - (), + runtime_types::pallet_staking::ValidatorPrefs, (), ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ImOnline", - "ReceivedHeartbeats", + "Staking", + "Validators", Vec::new(), [ - 233u8, 128u8, 140u8, 233u8, 55u8, 146u8, 172u8, 54u8, 54u8, 57u8, - 141u8, 106u8, 168u8, 59u8, 147u8, 253u8, 119u8, 48u8, 50u8, 251u8, - 242u8, 109u8, 251u8, 2u8, 136u8, 80u8, 146u8, 121u8, 180u8, 219u8, - 245u8, 37u8, + 80u8, 77u8, 66u8, 18u8, 197u8, 250u8, 41u8, 185u8, 43u8, 24u8, 149u8, + 164u8, 208u8, 60u8, 144u8, 29u8, 251u8, 195u8, 236u8, 196u8, 108u8, + 58u8, 80u8, 115u8, 246u8, 66u8, 226u8, 241u8, 201u8, 172u8, 229u8, + 152u8, ], ) } - #[doc = " For each session index, we keep a mapping of `ValidatorId` to the"] - #[doc = " number of blocks authored by the given authority."] - pub fn authored_blocks( + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_validators( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, ::core::primitive::u32, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "ImOnline", - "AuthoredBlocks", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + "Staking", + "CounterForValidators", + vec![], [ - 50u8, 4u8, 242u8, 240u8, 247u8, 184u8, 114u8, 245u8, 233u8, 170u8, - 24u8, 197u8, 18u8, 245u8, 8u8, 28u8, 33u8, 115u8, 166u8, 245u8, 221u8, - 223u8, 56u8, 144u8, 33u8, 139u8, 10u8, 227u8, 228u8, 223u8, 103u8, - 151u8, + 139u8, 25u8, 223u8, 6u8, 160u8, 239u8, 212u8, 85u8, 36u8, 185u8, 69u8, + 63u8, 21u8, 156u8, 144u8, 241u8, 112u8, 85u8, 49u8, 78u8, 88u8, 11u8, + 8u8, 48u8, 118u8, 34u8, 62u8, 159u8, 239u8, 122u8, 90u8, 45u8, ], ) } - #[doc = " For each session index, we keep a mapping of `ValidatorId` to the"] - #[doc = " number of blocks authored by the given authority."] - pub fn authored_blocks_root( + #[doc = " The maximum validator count before we stop allowing new validators to join."] + #[doc = ""] + #[doc = " When this value is not set, no limits are enforced."] + pub fn max_validators_count( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), + (), > { ::subxt::storage::address::Address::new_static( - "ImOnline", - "AuthoredBlocks", - Vec::new(), + "Staking", + "MaxValidatorsCount", + vec![], [ - 50u8, 4u8, 242u8, 240u8, 247u8, 184u8, 114u8, 245u8, 233u8, 170u8, - 24u8, 197u8, 18u8, 245u8, 8u8, 28u8, 33u8, 115u8, 166u8, 245u8, 221u8, - 223u8, 56u8, 144u8, 33u8, 139u8, 10u8, 227u8, 228u8, 223u8, 103u8, - 151u8, + 250u8, 62u8, 16u8, 68u8, 192u8, 216u8, 236u8, 211u8, 217u8, 9u8, 213u8, + 49u8, 41u8, 37u8, 58u8, 62u8, 131u8, 112u8, 64u8, 26u8, 133u8, 7u8, + 130u8, 1u8, 71u8, 158u8, 14u8, 55u8, 169u8, 239u8, 223u8, 245u8, ], ) } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " A configuration for base priority of unsigned transactions."] + #[doc = " The map from nominator stash key to their nomination preferences, namely the validators that"] + #[doc = " they wish to support."] #[doc = ""] - #[doc = " This is exposed so that it can be tuned for particular runtime, when"] - #[doc = " multiple pallets send unsigned transactions."] - pub fn unsigned_priority( + #[doc = " Note that the keys of this storage map might become non-decodable in case the"] + #[doc = " [`Config::MaxNominations`] configuration is decreased. In this rare case, these nominators"] + #[doc = " are still existent in storage, their key is correct and retrievable (i.e. `contains_key`"] + #[doc = " indicates that they exist), but their value cannot be decoded. Therefore, the non-decodable"] + #[doc = " nominators will effectively not-exist, until they re-submit their preferences such that it"] + #[doc = " is within the bounds of the newly set `Config::MaxNominations`."] + #[doc = ""] + #[doc = " This implies that `::iter_keys().count()` and `::iter().count()` might return different"] + #[doc = " values for this map. Moreover, the main `::count()` is aligned with the former, namely the"] + #[doc = " number of keys that exist."] + #[doc = ""] + #[doc = " Lastly, if any of the nominators become non-decodable, they can be chilled immediately via"] + #[doc = " [`Call::chill_other`] dispatchable by anyone."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn nominators( &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "ImOnline", - "UnsignedPriority", - [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, - ], - ) - } - } - } - } - pub mod authority_discovery { - use super::root_mod; - use super::runtime_types; - } - pub mod democracy { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_democracy::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Propose { - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - #[codec(compact)] - pub value: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Second { - #[codec(compact)] - pub proposal: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vote { - #[codec(compact)] - pub ref_index: ::core::primitive::u32, - pub vote: - runtime_types::pallet_democracy::vote::AccountVote<::core::primitive::u128>, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EmergencyCancel { - pub ref_index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExternalPropose { - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExternalProposeMajority { - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExternalProposeDefault { - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FastTrack { - pub proposal_hash: ::subxt::utils::H256, - pub voting_period: ::core::primitive::u32, - pub delay: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VetoExternal { - pub proposal_hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelReferendum { - #[codec(compact)] - pub ref_index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Delegate { - pub to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub conviction: runtime_types::pallet_democracy::conviction::Conviction, - pub balance: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Undelegate; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClearPublicProposals; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Unlock { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveVote { - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveOtherVote { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Blacklist { - pub proposal_hash: ::subxt::utils::H256, - pub maybe_ref_index: ::core::option::Option<::core::primitive::u32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelProposal { - #[codec(compact)] - pub prop_index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMetadata { - pub owner: runtime_types::pallet_democracy::types::MetadataOwner, - pub maybe_hash: ::core::option::Option<::subxt::utils::H256>, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_staking::Nominations, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "Nominators", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 1u8, 154u8, 55u8, 170u8, 215u8, 64u8, 56u8, 83u8, 254u8, 19u8, 152u8, + 85u8, 164u8, 171u8, 206u8, 129u8, 184u8, 45u8, 221u8, 181u8, 229u8, + 133u8, 200u8, 231u8, 16u8, 146u8, 247u8, 21u8, 77u8, 122u8, 165u8, + 134u8, + ], + ) } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMetadata { - pub owner: runtime_types::pallet_democracy::types::MetadataOwner, - pub maybe_hash: ::core::option::Option<::subxt::utils::H256>, - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Propose a sensitive action to be taken."] + #[doc = " The map from nominator stash key to their nomination preferences, namely the validators that"] + #[doc = " they wish to support."] #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_ and the sender must"] - #[doc = "have funds to cover the deposit."] + #[doc = " Note that the keys of this storage map might become non-decodable in case the"] + #[doc = " [`Config::MaxNominations`] configuration is decreased. In this rare case, these nominators"] + #[doc = " are still existent in storage, their key is correct and retrievable (i.e. `contains_key`"] + #[doc = " indicates that they exist), but their value cannot be decoded. Therefore, the non-decodable"] + #[doc = " nominators will effectively not-exist, until they re-submit their preferences such that it"] + #[doc = " is within the bounds of the newly set `Config::MaxNominations`."] #[doc = ""] - #[doc = "- `proposal_hash`: The hash of the proposal preimage."] - #[doc = "- `value`: The amount of deposit (must be at least `MinimumDeposit`)."] + #[doc = " This implies that `::iter_keys().count()` and `::iter().count()` might return different"] + #[doc = " values for this map. Moreover, the main `::count()` is aligned with the former, namely the"] + #[doc = " number of keys that exist."] #[doc = ""] - #[doc = "Emits `Proposed`."] - pub fn propose( + #[doc = " Lastly, if any of the nominators become non-decodable, they can be chilled immediately via"] + #[doc = " [`Call::chill_other`] dispatchable by anyone."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn nominators_root( &self, - proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "propose", - types::Propose { proposal, value }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_staking::Nominations, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "Nominators", + Vec::new(), [ - 123u8, 3u8, 204u8, 140u8, 194u8, 195u8, 214u8, 39u8, 167u8, 126u8, - 45u8, 4u8, 219u8, 17u8, 143u8, 185u8, 29u8, 224u8, 230u8, 68u8, 253u8, - 15u8, 170u8, 90u8, 232u8, 123u8, 46u8, 255u8, 168u8, 39u8, 204u8, 63u8, + 1u8, 154u8, 55u8, 170u8, 215u8, 64u8, 56u8, 83u8, 254u8, 19u8, 152u8, + 85u8, 164u8, 171u8, 206u8, 129u8, 184u8, 45u8, 221u8, 181u8, 229u8, + 133u8, 200u8, 231u8, 16u8, 146u8, 247u8, 21u8, 77u8, 122u8, 165u8, + 134u8, ], ) } - #[doc = "Signals agreement with a particular proposal."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_ and the sender"] - #[doc = "must have funds to cover the deposit, equal to the original deposit."] - #[doc = ""] - #[doc = "- `proposal`: The index of the proposal to second."] - pub fn second( + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_nominators( &self, - proposal: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "second", - types::Second { proposal }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "CounterForNominators", + vec![], [ - 59u8, 240u8, 183u8, 218u8, 61u8, 93u8, 184u8, 67u8, 10u8, 4u8, 138u8, - 196u8, 168u8, 49u8, 42u8, 69u8, 154u8, 42u8, 90u8, 112u8, 179u8, 69u8, - 51u8, 148u8, 159u8, 212u8, 221u8, 226u8, 132u8, 228u8, 51u8, 83u8, + 31u8, 94u8, 130u8, 138u8, 75u8, 8u8, 38u8, 162u8, 181u8, 5u8, 125u8, + 116u8, 9u8, 51u8, 22u8, 234u8, 40u8, 117u8, 215u8, 46u8, 82u8, 117u8, + 225u8, 1u8, 9u8, 208u8, 83u8, 63u8, 39u8, 187u8, 207u8, 191u8, ], ) } - #[doc = "Vote in a referendum. If `vote.is_aye()`, the vote is to enact the proposal;"] - #[doc = "otherwise it is a vote to keep the status quo."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_."] + #[doc = " The maximum nominator count before we stop allowing new validators to join."] #[doc = ""] - #[doc = "- `ref_index`: The index of the referendum to vote for."] - #[doc = "- `vote`: The vote configuration."] - pub fn vote( + #[doc = " When this value is not set, no limits are enforced."] + pub fn max_nominators_count( &self, - ref_index: ::core::primitive::u32, - vote: runtime_types::pallet_democracy::vote::AccountVote< - ::core::primitive::u128, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "vote", - types::Vote { ref_index, vote }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "MaxNominatorsCount", + vec![], [ - 138u8, 213u8, 229u8, 111u8, 1u8, 191u8, 73u8, 3u8, 145u8, 28u8, 44u8, - 88u8, 163u8, 188u8, 129u8, 188u8, 64u8, 15u8, 64u8, 103u8, 250u8, 97u8, - 234u8, 188u8, 29u8, 205u8, 51u8, 6u8, 116u8, 58u8, 156u8, 201u8, + 180u8, 190u8, 180u8, 66u8, 235u8, 173u8, 76u8, 160u8, 197u8, 92u8, + 96u8, 165u8, 220u8, 188u8, 32u8, 119u8, 3u8, 73u8, 86u8, 49u8, 104u8, + 17u8, 186u8, 98u8, 221u8, 175u8, 109u8, 254u8, 207u8, 245u8, 125u8, + 179u8, ], ) } - #[doc = "Schedule an emergency cancellation of a referendum. Cannot happen twice to the same"] - #[doc = "referendum."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be `CancellationOrigin`."] - #[doc = ""] - #[doc = "-`ref_index`: The index of the referendum to cancel."] + #[doc = " The current era index."] #[doc = ""] - #[doc = "Weight: `O(1)`."] - pub fn emergency_cancel( + #[doc = " This is the latest planned era, depending on how the Session pallet queues the validator"] + #[doc = " set, it might be active or not."] + pub fn current_era( &self, - ref_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "emergency_cancel", - types::EmergencyCancel { ref_index }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "CurrentEra", + vec![], [ - 139u8, 213u8, 133u8, 75u8, 34u8, 206u8, 124u8, 245u8, 35u8, 237u8, - 132u8, 92u8, 49u8, 167u8, 117u8, 80u8, 188u8, 93u8, 198u8, 237u8, - 132u8, 77u8, 195u8, 65u8, 29u8, 37u8, 86u8, 74u8, 214u8, 119u8, 71u8, - 204u8, + 105u8, 150u8, 49u8, 122u8, 4u8, 78u8, 8u8, 121u8, 34u8, 136u8, 157u8, + 227u8, 59u8, 139u8, 7u8, 253u8, 7u8, 10u8, 117u8, 71u8, 240u8, 74u8, + 86u8, 36u8, 198u8, 37u8, 153u8, 93u8, 196u8, 22u8, 192u8, 243u8, ], ) } - #[doc = "Schedule a referendum to be tabled once it is legal to schedule an external"] - #[doc = "referendum."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be `ExternalOrigin`."] + #[doc = " The active era information, it holds index and start."] #[doc = ""] - #[doc = "- `proposal_hash`: The preimage hash of the proposal."] - pub fn external_propose( + #[doc = " The active era is the era being currently rewarded. Validator set of this era must be"] + #[doc = " equal to [`SessionInterface::validators`]."] + pub fn active_era( &self, - proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "external_propose", - types::ExternalPropose { proposal }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_staking::ActiveEraInfo, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ActiveEra", + vec![], [ - 164u8, 193u8, 14u8, 122u8, 105u8, 232u8, 20u8, 194u8, 99u8, 227u8, - 36u8, 105u8, 218u8, 146u8, 16u8, 208u8, 56u8, 62u8, 100u8, 65u8, 35u8, - 33u8, 51u8, 208u8, 17u8, 43u8, 223u8, 198u8, 202u8, 16u8, 56u8, 75u8, + 15u8, 112u8, 251u8, 183u8, 108u8, 61u8, 28u8, 71u8, 44u8, 150u8, 162u8, + 4u8, 143u8, 121u8, 11u8, 37u8, 83u8, 29u8, 193u8, 21u8, 210u8, 116u8, + 190u8, 236u8, 213u8, 235u8, 49u8, 97u8, 189u8, 142u8, 251u8, 124u8, ], ) } - #[doc = "Schedule a majority-carries referendum to be tabled next once it is legal to schedule"] - #[doc = "an external referendum."] - #[doc = ""] - #[doc = "The dispatch of this call must be `ExternalMajorityOrigin`."] - #[doc = ""] - #[doc = "- `proposal_hash`: The preimage hash of the proposal."] - #[doc = ""] - #[doc = "Unlike `external_propose`, blacklisting has no effect on this and it may replace a"] - #[doc = "pre-scheduled `external_propose` call."] + #[doc = " The session index at which the era start for the last `HISTORY_DEPTH` eras."] #[doc = ""] - #[doc = "Weight: `O(1)`"] - pub fn external_propose_majority( + #[doc = " Note: This tracks the starting session (i.e. session index when era start being active)"] + #[doc = " for the eras in `[CurrentEra - HISTORY_DEPTH, CurrentEra]`."] + pub fn eras_start_session_index( &self, - proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "external_propose_majority", - types::ExternalProposeMajority { proposal }, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasStartSessionIndex", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 129u8, 124u8, 147u8, 253u8, 69u8, 115u8, 230u8, 186u8, 155u8, 4u8, - 220u8, 103u8, 28u8, 132u8, 115u8, 153u8, 196u8, 88u8, 9u8, 130u8, - 129u8, 234u8, 75u8, 96u8, 202u8, 216u8, 145u8, 189u8, 231u8, 101u8, - 127u8, 11u8, + 92u8, 157u8, 168u8, 144u8, 132u8, 3u8, 212u8, 80u8, 230u8, 229u8, + 251u8, 218u8, 97u8, 55u8, 79u8, 100u8, 163u8, 91u8, 32u8, 246u8, 122u8, + 78u8, 149u8, 214u8, 103u8, 249u8, 119u8, 20u8, 101u8, 116u8, 110u8, + 185u8, ], ) } - #[doc = "Schedule a negative-turnout-bias referendum to be tabled next once it is legal to"] - #[doc = "schedule an external referendum."] - #[doc = ""] - #[doc = "The dispatch of this call must be `ExternalDefaultOrigin`."] - #[doc = ""] - #[doc = "- `proposal_hash`: The preimage hash of the proposal."] - #[doc = ""] - #[doc = "Unlike `external_propose`, blacklisting has no effect on this and it may replace a"] - #[doc = "pre-scheduled `external_propose` call."] + #[doc = " The session index at which the era start for the last `HISTORY_DEPTH` eras."] #[doc = ""] - #[doc = "Weight: `O(1)`"] - pub fn external_propose_default( + #[doc = " Note: This tracks the starting session (i.e. session index when era start being active)"] + #[doc = " for the eras in `[CurrentEra - HISTORY_DEPTH, CurrentEra]`."] + pub fn eras_start_session_index_root( &self, - proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "external_propose_default", - types::ExternalProposeDefault { proposal }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasStartSessionIndex", + Vec::new(), [ - 96u8, 15u8, 108u8, 208u8, 141u8, 247u8, 4u8, 73u8, 2u8, 30u8, 231u8, - 40u8, 184u8, 250u8, 42u8, 161u8, 248u8, 45u8, 217u8, 50u8, 53u8, 13u8, - 181u8, 214u8, 136u8, 51u8, 93u8, 95u8, 165u8, 3u8, 83u8, 190u8, + 92u8, 157u8, 168u8, 144u8, 132u8, 3u8, 212u8, 80u8, 230u8, 229u8, + 251u8, 218u8, 97u8, 55u8, 79u8, 100u8, 163u8, 91u8, 32u8, 246u8, 122u8, + 78u8, 149u8, 214u8, 103u8, 249u8, 119u8, 20u8, 101u8, 116u8, 110u8, + 185u8, ], ) } - #[doc = "Schedule the currently externally-proposed majority-carries referendum to be tabled"] - #[doc = "immediately. If there is no externally-proposed referendum currently, or if there is one"] - #[doc = "but it is not a majority-carries referendum then it fails."] - #[doc = ""] - #[doc = "The dispatch of this call must be `FastTrackOrigin`."] - #[doc = ""] - #[doc = "- `proposal_hash`: The hash of the current external proposal."] - #[doc = "- `voting_period`: The period that is allowed for voting on this proposal. Increased to"] - #[doc = "\tMust be always greater than zero."] - #[doc = "\tFor `FastTrackOrigin` must be equal or greater than `FastTrackVotingPeriod`."] - #[doc = "- `delay`: The number of block after voting has ended in approval and this should be"] - #[doc = " enacted. This doesn't have a minimum amount."] + #[doc = " Exposure of validator at era."] #[doc = ""] - #[doc = "Emits `Started`."] + #[doc = " This is keyed first by the era index to allow bulk deletion and then the stash account."] #[doc = ""] - #[doc = "Weight: `O(1)`"] - pub fn fast_track( + #[doc = " Is it removed after `HISTORY_DEPTH` eras."] + #[doc = " If stakers hasn't been set or has been removed then empty exposure is returned."] + pub fn eras_stakers( &self, - proposal_hash: ::subxt::utils::H256, - voting_period: ::core::primitive::u32, - delay: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "fast_track", - types::FastTrack { - proposal_hash, - voting_period, - delay, - }, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_staking::Exposure< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasStakers", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], [ - 125u8, 209u8, 107u8, 120u8, 93u8, 205u8, 129u8, 147u8, 254u8, 126u8, - 45u8, 126u8, 39u8, 0u8, 56u8, 14u8, 233u8, 49u8, 245u8, 220u8, 156u8, - 10u8, 252u8, 31u8, 102u8, 90u8, 163u8, 236u8, 178u8, 85u8, 13u8, 24u8, + 192u8, 50u8, 152u8, 151u8, 92u8, 180u8, 206u8, 15u8, 139u8, 210u8, + 128u8, 65u8, 92u8, 253u8, 43u8, 35u8, 139u8, 171u8, 73u8, 185u8, 32u8, + 78u8, 20u8, 197u8, 154u8, 90u8, 233u8, 231u8, 23u8, 22u8, 187u8, 156u8, ], ) } - #[doc = "Veto and blacklist the external proposal hash."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be `VetoOrigin`."] - #[doc = ""] - #[doc = "- `proposal_hash`: The preimage hash of the proposal to veto and blacklist."] + #[doc = " Exposure of validator at era."] #[doc = ""] - #[doc = "Emits `Vetoed`."] + #[doc = " This is keyed first by the era index to allow bulk deletion and then the stash account."] #[doc = ""] - #[doc = "Weight: `O(V + log(V))` where V is number of `existing vetoers`"] - pub fn veto_external( + #[doc = " Is it removed after `HISTORY_DEPTH` eras."] + #[doc = " If stakers hasn't been set or has been removed then empty exposure is returned."] + pub fn eras_stakers_root( &self, - proposal_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "veto_external", - types::VetoExternal { proposal_hash }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_staking::Exposure< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasStakers", + Vec::new(), [ - 209u8, 18u8, 18u8, 103u8, 186u8, 160u8, 214u8, 124u8, 150u8, 207u8, - 112u8, 90u8, 84u8, 197u8, 95u8, 157u8, 165u8, 65u8, 109u8, 101u8, 75u8, - 201u8, 41u8, 149u8, 75u8, 154u8, 37u8, 178u8, 239u8, 121u8, 124u8, - 23u8, + 192u8, 50u8, 152u8, 151u8, 92u8, 180u8, 206u8, 15u8, 139u8, 210u8, + 128u8, 65u8, 92u8, 253u8, 43u8, 35u8, 139u8, 171u8, 73u8, 185u8, 32u8, + 78u8, 20u8, 197u8, 154u8, 90u8, 233u8, 231u8, 23u8, 22u8, 187u8, 156u8, ], ) } - #[doc = "Remove a referendum."] + #[doc = " Clipped Exposure of validator at era."] #[doc = ""] - #[doc = "The dispatch origin of this call must be _Root_."] + #[doc = " This is similar to [`ErasStakers`] but number of nominators exposed is reduced to the"] + #[doc = " `T::MaxNominatorRewardedPerValidator` biggest stakers."] + #[doc = " (Note: the field `total` and `own` of the exposure remains unchanged)."] + #[doc = " This is used to limit the i/o cost for the nominator payout."] #[doc = ""] - #[doc = "- `ref_index`: The index of the referendum to cancel."] + #[doc = " This is keyed fist by the era index to allow bulk deletion and then the stash account."] #[doc = ""] - #[doc = "# Weight: `O(1)`."] - pub fn cancel_referendum( + #[doc = " Is it removed after `HISTORY_DEPTH` eras."] + #[doc = " If stakers hasn't been set or has been removed then empty exposure is returned."] + pub fn eras_stakers_clipped( &self, - ref_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "cancel_referendum", - types::CancelReferendum { ref_index }, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_staking::Exposure< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasStakersClipped", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], [ - 51u8, 25u8, 25u8, 251u8, 236u8, 115u8, 130u8, 230u8, 72u8, 186u8, - 119u8, 71u8, 165u8, 137u8, 55u8, 167u8, 187u8, 128u8, 55u8, 8u8, 212u8, - 139u8, 245u8, 232u8, 103u8, 136u8, 229u8, 113u8, 125u8, 36u8, 1u8, - 149u8, + 43u8, 159u8, 113u8, 223u8, 122u8, 169u8, 98u8, 153u8, 26u8, 55u8, 71u8, + 119u8, 174u8, 48u8, 158u8, 45u8, 214u8, 26u8, 136u8, 215u8, 46u8, + 161u8, 185u8, 17u8, 174u8, 204u8, 206u8, 246u8, 49u8, 87u8, 134u8, + 169u8, ], ) } - #[doc = "Delegate the voting power (with some given conviction) of the sending account."] - #[doc = ""] - #[doc = "The balance delegated is locked for as long as it's delegated, and thereafter for the"] - #[doc = "time appropriate for the conviction's lock period."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_, and the signing account must either:"] - #[doc = " - be delegating already; or"] - #[doc = " - have no voting activity (if there is, then it will need to be removed/consolidated"] - #[doc = " through `reap_vote` or `unvote`)."] + #[doc = " Clipped Exposure of validator at era."] #[doc = ""] - #[doc = "- `to`: The account whose voting the `target` account's voting power will follow."] - #[doc = "- `conviction`: The conviction that will be attached to the delegated votes. When the"] - #[doc = " account is undelegated, the funds will be locked for the corresponding period."] - #[doc = "- `balance`: The amount of the account's balance to be used in delegating. This must not"] - #[doc = " be more than the account's current balance."] + #[doc = " This is similar to [`ErasStakers`] but number of nominators exposed is reduced to the"] + #[doc = " `T::MaxNominatorRewardedPerValidator` biggest stakers."] + #[doc = " (Note: the field `total` and `own` of the exposure remains unchanged)."] + #[doc = " This is used to limit the i/o cost for the nominator payout."] #[doc = ""] - #[doc = "Emits `Delegated`."] + #[doc = " This is keyed fist by the era index to allow bulk deletion and then the stash account."] #[doc = ""] - #[doc = "Weight: `O(R)` where R is the number of referendums the voter delegating to has"] - #[doc = " voted on. Weight is charged as if maximum votes."] - pub fn delegate( + #[doc = " Is it removed after `HISTORY_DEPTH` eras."] + #[doc = " If stakers hasn't been set or has been removed then empty exposure is returned."] + pub fn eras_stakers_clipped_root( &self, - to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - conviction: runtime_types::pallet_democracy::conviction::Conviction, - balance: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "delegate", - types::Delegate { - to, - conviction, - balance, - }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_staking::Exposure< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasStakersClipped", + Vec::new(), [ - 22u8, 205u8, 202u8, 196u8, 63u8, 1u8, 196u8, 109u8, 4u8, 190u8, 38u8, - 142u8, 248u8, 200u8, 136u8, 12u8, 194u8, 170u8, 237u8, 176u8, 70u8, - 21u8, 112u8, 154u8, 93u8, 169u8, 211u8, 120u8, 156u8, 68u8, 14u8, - 231u8, + 43u8, 159u8, 113u8, 223u8, 122u8, 169u8, 98u8, 153u8, 26u8, 55u8, 71u8, + 119u8, 174u8, 48u8, 158u8, 45u8, 214u8, 26u8, 136u8, 215u8, 46u8, + 161u8, 185u8, 17u8, 174u8, 204u8, 206u8, 246u8, 49u8, 87u8, 134u8, + 169u8, ], ) } - #[doc = "Undelegate the voting power of the sending account."] - #[doc = ""] - #[doc = "Tokens may be unlocked following once an amount of time consistent with the lock period"] - #[doc = "of the conviction with which the delegation was issued."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_ and the signing account must be"] - #[doc = "currently delegating."] + #[doc = " Similar to `ErasStakers`, this holds the preferences of validators."] #[doc = ""] - #[doc = "Emits `Undelegated`."] + #[doc = " This is keyed first by the era index to allow bulk deletion and then the stash account."] #[doc = ""] - #[doc = "Weight: `O(R)` where R is the number of referendums the voter delegating to has"] - #[doc = " voted on. Weight is charged as if maximum votes."] - pub fn undelegate(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "undelegate", - types::Undelegate {}, + #[doc = " Is it removed after `HISTORY_DEPTH` eras."] + pub fn eras_validator_prefs( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_staking::ValidatorPrefs, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasValidatorPrefs", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], [ - 165u8, 40u8, 183u8, 209u8, 57u8, 153u8, 111u8, 29u8, 114u8, 109u8, - 107u8, 235u8, 97u8, 61u8, 53u8, 155u8, 44u8, 245u8, 28u8, 220u8, 56u8, - 134u8, 43u8, 122u8, 248u8, 156u8, 191u8, 154u8, 4u8, 121u8, 152u8, - 153u8, + 6u8, 196u8, 209u8, 138u8, 252u8, 18u8, 203u8, 86u8, 129u8, 62u8, 4u8, + 56u8, 234u8, 114u8, 141u8, 136u8, 127u8, 224u8, 142u8, 89u8, 150u8, + 33u8, 31u8, 50u8, 140u8, 108u8, 124u8, 77u8, 188u8, 102u8, 230u8, + 174u8, ], ) } - #[doc = "Clears all public proposals."] + #[doc = " Similar to `ErasStakers`, this holds the preferences of validators."] #[doc = ""] - #[doc = "The dispatch origin of this call must be _Root_."] + #[doc = " This is keyed first by the era index to allow bulk deletion and then the stash account."] #[doc = ""] - #[doc = "Weight: `O(1)`."] - pub fn clear_public_proposals( + #[doc = " Is it removed after `HISTORY_DEPTH` eras."] + pub fn eras_validator_prefs_root( &self, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "clear_public_proposals", - types::ClearPublicProposals {}, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_staking::ValidatorPrefs, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasValidatorPrefs", + Vec::new(), [ - 59u8, 126u8, 254u8, 223u8, 252u8, 225u8, 75u8, 185u8, 188u8, 181u8, - 42u8, 179u8, 211u8, 73u8, 12u8, 141u8, 243u8, 197u8, 46u8, 130u8, - 215u8, 196u8, 225u8, 88u8, 48u8, 199u8, 231u8, 249u8, 195u8, 53u8, - 184u8, 204u8, + 6u8, 196u8, 209u8, 138u8, 252u8, 18u8, 203u8, 86u8, 129u8, 62u8, 4u8, + 56u8, 234u8, 114u8, 141u8, 136u8, 127u8, 224u8, 142u8, 89u8, 150u8, + 33u8, 31u8, 50u8, 140u8, 108u8, 124u8, 77u8, 188u8, 102u8, 230u8, + 174u8, ], ) } - #[doc = "Unlock tokens that have an expired lock."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_."] - #[doc = ""] - #[doc = "- `target`: The account to remove the lock on."] + #[doc = " The total validator era payout for the last `HISTORY_DEPTH` eras."] #[doc = ""] - #[doc = "Weight: `O(R)` with R number of vote of target."] - pub fn unlock( + #[doc = " Eras that haven't finished yet or has been removed doesn't have reward."] + pub fn eras_validator_reward( &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "unlock", - types::Unlock { target }, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasValidatorReward", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 126u8, 151u8, 230u8, 89u8, 49u8, 247u8, 242u8, 139u8, 190u8, 15u8, - 47u8, 2u8, 132u8, 165u8, 48u8, 205u8, 196u8, 66u8, 230u8, 222u8, 164u8, - 249u8, 152u8, 107u8, 0u8, 99u8, 238u8, 167u8, 72u8, 77u8, 145u8, 236u8, + 87u8, 80u8, 156u8, 123u8, 107u8, 77u8, 203u8, 37u8, 231u8, 84u8, 124u8, + 155u8, 227u8, 212u8, 212u8, 179u8, 84u8, 161u8, 223u8, 255u8, 254u8, + 107u8, 52u8, 89u8, 98u8, 169u8, 136u8, 241u8, 104u8, 3u8, 244u8, 161u8, ], ) } - #[doc = "Remove a vote for a referendum."] - #[doc = ""] - #[doc = "If:"] - #[doc = "- the referendum was cancelled, or"] - #[doc = "- the referendum is ongoing, or"] - #[doc = "- the referendum has ended such that"] - #[doc = " - the vote of the account was in opposition to the result; or"] - #[doc = " - there was no conviction to the account's vote; or"] - #[doc = " - the account made a split vote"] - #[doc = "...then the vote is removed cleanly and a following call to `unlock` may result in more"] - #[doc = "funds being available."] - #[doc = ""] - #[doc = "If, however, the referendum has ended and:"] - #[doc = "- it finished corresponding to the vote of the account, and"] - #[doc = "- the account made a standard vote with conviction, and"] - #[doc = "- the lock period of the conviction is not over"] - #[doc = "...then the lock will be aggregated into the overall account's lock, which may involve"] - #[doc = "*overlocking* (where the two locks are combined into a single lock that is the maximum"] - #[doc = "of both the amount locked and the time is it locked for)."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_, and the signer must have a vote"] - #[doc = "registered for referendum `index`."] - #[doc = ""] - #[doc = "- `index`: The index of referendum of the vote to be removed."] + #[doc = " The total validator era payout for the last `HISTORY_DEPTH` eras."] #[doc = ""] - #[doc = "Weight: `O(R + log R)` where R is the number of referenda that `target` has voted on."] - #[doc = " Weight is calculated for the maximum number of vote."] - pub fn remove_vote( + #[doc = " Eras that haven't finished yet or has been removed doesn't have reward."] + pub fn eras_validator_reward_root( &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "remove_vote", - types::RemoveVote { index }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasValidatorReward", + Vec::new(), [ - 148u8, 120u8, 14u8, 172u8, 81u8, 152u8, 159u8, 178u8, 106u8, 244u8, - 36u8, 98u8, 120u8, 189u8, 213u8, 93u8, 119u8, 156u8, 112u8, 34u8, - 241u8, 72u8, 206u8, 113u8, 212u8, 161u8, 164u8, 126u8, 122u8, 82u8, - 160u8, 74u8, + 87u8, 80u8, 156u8, 123u8, 107u8, 77u8, 203u8, 37u8, 231u8, 84u8, 124u8, + 155u8, 227u8, 212u8, 212u8, 179u8, 84u8, 161u8, 223u8, 255u8, 254u8, + 107u8, 52u8, 89u8, 98u8, 169u8, 136u8, 241u8, 104u8, 3u8, 244u8, 161u8, ], ) } - #[doc = "Remove a vote for a referendum."] - #[doc = ""] - #[doc = "If the `target` is equal to the signer, then this function is exactly equivalent to"] - #[doc = "`remove_vote`. If not equal to the signer, then the vote must have expired,"] - #[doc = "either because the referendum was cancelled, because the voter lost the referendum or"] - #[doc = "because the conviction period is over."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_."] - #[doc = ""] - #[doc = "- `target`: The account of the vote to be removed; this account must have voted for"] - #[doc = " referendum `index`."] - #[doc = "- `index`: The index of referendum of the vote to be removed."] - #[doc = ""] - #[doc = "Weight: `O(R + log R)` where R is the number of referenda that `target` has voted on."] - #[doc = " Weight is calculated for the maximum number of vote."] - pub fn remove_other_vote( + #[doc = " Rewards for the last `HISTORY_DEPTH` eras."] + #[doc = " If reward hasn't been set or has been removed then 0 reward is returned."] + pub fn eras_reward_points( &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "remove_other_vote", - types::RemoveOtherVote { target, index }, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_staking::EraRewardPoints<::subxt::utils::AccountId32>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasRewardPoints", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 151u8, 190u8, 115u8, 124u8, 185u8, 43u8, 70u8, 147u8, 98u8, 167u8, - 120u8, 25u8, 231u8, 143u8, 214u8, 25u8, 240u8, 74u8, 35u8, 58u8, 206u8, - 78u8, 121u8, 215u8, 190u8, 42u8, 2u8, 206u8, 241u8, 44u8, 92u8, 23u8, + 194u8, 29u8, 20u8, 83u8, 200u8, 47u8, 158u8, 102u8, 88u8, 65u8, 24u8, + 255u8, 120u8, 178u8, 23u8, 232u8, 15u8, 64u8, 206u8, 0u8, 170u8, 40u8, + 18u8, 149u8, 45u8, 90u8, 179u8, 127u8, 52u8, 59u8, 37u8, 192u8, ], ) } - #[doc = "Permanently place a proposal into the blacklist. This prevents it from ever being"] - #[doc = "proposed again."] - #[doc = ""] - #[doc = "If called on a queued public or external proposal, then this will result in it being"] - #[doc = "removed. If the `ref_index` supplied is an active referendum with the proposal hash,"] - #[doc = "then it will be cancelled."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be `BlacklistOrigin`."] - #[doc = ""] - #[doc = "- `proposal_hash`: The proposal hash to blacklist permanently."] - #[doc = "- `ref_index`: An ongoing referendum whose hash is `proposal_hash`, which will be"] - #[doc = "cancelled."] - #[doc = ""] - #[doc = "Weight: `O(p)` (though as this is an high-privilege dispatch, we assume it has a"] - #[doc = " reasonable value)."] - pub fn blacklist( + #[doc = " Rewards for the last `HISTORY_DEPTH` eras."] + #[doc = " If reward hasn't been set or has been removed then 0 reward is returned."] + pub fn eras_reward_points_root( &self, - proposal_hash: ::subxt::utils::H256, - maybe_ref_index: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "blacklist", - types::Blacklist { - proposal_hash, - maybe_ref_index, - }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_staking::EraRewardPoints<::subxt::utils::AccountId32>, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasRewardPoints", + Vec::new(), [ - 48u8, 144u8, 81u8, 164u8, 54u8, 111u8, 197u8, 134u8, 6u8, 98u8, 121u8, - 179u8, 254u8, 191u8, 204u8, 212u8, 84u8, 255u8, 86u8, 110u8, 225u8, - 130u8, 26u8, 65u8, 133u8, 56u8, 231u8, 15u8, 245u8, 137u8, 146u8, - 242u8, + 194u8, 29u8, 20u8, 83u8, 200u8, 47u8, 158u8, 102u8, 88u8, 65u8, 24u8, + 255u8, 120u8, 178u8, 23u8, 232u8, 15u8, 64u8, 206u8, 0u8, 170u8, 40u8, + 18u8, 149u8, 45u8, 90u8, 179u8, 127u8, 52u8, 59u8, 37u8, 192u8, ], ) } - #[doc = "Remove a proposal."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be `CancelProposalOrigin`."] - #[doc = ""] - #[doc = "- `prop_index`: The index of the proposal to cancel."] - #[doc = ""] - #[doc = "Weight: `O(p)` where `p = PublicProps::::decode_len()`"] - pub fn cancel_proposal( + #[doc = " The total amount staked for the last `HISTORY_DEPTH` eras."] + #[doc = " If total hasn't been set or has been removed then 0 stake is returned."] + pub fn eras_total_stake( &self, - prop_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "cancel_proposal", - types::CancelProposal { prop_index }, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasTotalStake", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 179u8, 3u8, 198u8, 244u8, 241u8, 124u8, 205u8, 58u8, 100u8, 80u8, - 177u8, 254u8, 98u8, 220u8, 189u8, 63u8, 229u8, 60u8, 157u8, 83u8, - 142u8, 6u8, 236u8, 183u8, 193u8, 235u8, 253u8, 126u8, 153u8, 185u8, - 74u8, 117u8, + 224u8, 240u8, 168u8, 69u8, 148u8, 140u8, 249u8, 240u8, 4u8, 46u8, 77u8, + 11u8, 224u8, 65u8, 26u8, 239u8, 1u8, 110u8, 53u8, 11u8, 247u8, 235u8, + 142u8, 234u8, 22u8, 43u8, 24u8, 36u8, 37u8, 43u8, 170u8, 40u8, ], ) } - #[doc = "Set or clear a metadata of a proposal or a referendum."] - #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `origin`: Must correspond to the `MetadataOwner`."] - #[doc = " - `ExternalOrigin` for an external proposal with the `SuperMajorityApprove`"] - #[doc = " threshold."] - #[doc = " - `ExternalDefaultOrigin` for an external proposal with the `SuperMajorityAgainst`"] - #[doc = " threshold."] - #[doc = " - `ExternalMajorityOrigin` for an external proposal with the `SimpleMajority`"] - #[doc = " threshold."] - #[doc = " - `Signed` by a creator for a public proposal."] - #[doc = " - `Signed` to clear a metadata for a finished referendum."] - #[doc = " - `Root` to set a metadata for an ongoing referendum."] - #[doc = "- `owner`: an identifier of a metadata owner."] - #[doc = "- `maybe_hash`: The hash of an on-chain stored preimage. `None` to clear a metadata."] - pub fn set_metadata( + #[doc = " The total amount staked for the last `HISTORY_DEPTH` eras."] + #[doc = " If total hasn't been set or has been removed then 0 stake is returned."] + pub fn eras_total_stake_root( &self, - owner: runtime_types::pallet_democracy::types::MetadataOwner, - maybe_hash: ::core::option::Option<::subxt::utils::H256>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Democracy", - "set_metadata", - SetMetadata { owner, maybe_hash }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Staking", + "ErasTotalStake", + Vec::new(), [ - 182u8, 2u8, 168u8, 244u8, 247u8, 35u8, 65u8, 9u8, 39u8, 164u8, 30u8, - 141u8, 69u8, 137u8, 75u8, 156u8, 158u8, 107u8, 67u8, 28u8, 145u8, 65u8, - 175u8, 30u8, 254u8, 231u8, 4u8, 77u8, 207u8, 166u8, 157u8, 73u8, + 224u8, 240u8, 168u8, 69u8, 148u8, 140u8, 249u8, 240u8, 4u8, 46u8, 77u8, + 11u8, 224u8, 65u8, 26u8, 239u8, 1u8, 110u8, 53u8, 11u8, 247u8, 235u8, + 142u8, 234u8, 22u8, 43u8, 24u8, 36u8, 37u8, 43u8, 170u8, 40u8, ], ) } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_democracy::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A motion has been proposed by a public account."] - pub struct Proposed { - pub proposal_index: ::core::primitive::u32, - pub deposit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Proposed { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "Proposed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A public proposal has been tabled for referendum vote."] - pub struct Tabled { - pub proposal_index: ::core::primitive::u32, - pub deposit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Tabled { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "Tabled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An external proposal has been tabled."] - pub struct ExternalTabled; - impl ::subxt::events::StaticEvent for ExternalTabled { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "ExternalTabled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has begun."] - pub struct Started { - pub ref_index: ::core::primitive::u32, - pub threshold: runtime_types::pallet_democracy::vote_threshold::VoteThreshold, - } - impl ::subxt::events::StaticEvent for Started { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "Started"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proposal has been approved by referendum."] - pub struct Passed { - pub ref_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Passed { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "Passed"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proposal has been rejected by referendum."] - pub struct NotPassed { - pub ref_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for NotPassed { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "NotPassed"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been cancelled."] - pub struct Cancelled { - pub ref_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Cancelled { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "Cancelled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has delegated their vote to another account."] - pub struct Delegated { - pub who: ::subxt::utils::AccountId32, - pub target: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Delegated { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "Delegated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has cancelled a previous delegation operation."] - pub struct Undelegated { - pub account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Undelegated { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "Undelegated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An external proposal has been vetoed."] - pub struct Vetoed { - pub who: ::subxt::utils::AccountId32, - pub proposal_hash: ::subxt::utils::H256, - pub until: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Vetoed { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "Vetoed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proposal_hash has been blacklisted permanently."] - pub struct Blacklisted { - pub proposal_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Blacklisted { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "Blacklisted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has voted in a referendum"] - pub struct Voted { - pub voter: ::subxt::utils::AccountId32, - pub ref_index: ::core::primitive::u32, - pub vote: - runtime_types::pallet_democracy::vote::AccountVote<::core::primitive::u128>, - } - impl ::subxt::events::StaticEvent for Voted { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "Voted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has secconded a proposal"] - pub struct Seconded { - pub seconder: ::subxt::utils::AccountId32, - pub prop_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Seconded { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "Seconded"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proposal got canceled."] - pub struct ProposalCanceled { - pub prop_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for ProposalCanceled { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "ProposalCanceled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Metadata for a proposal or a referendum has been set."] - pub struct MetadataSet { - pub owner: runtime_types::pallet_democracy::types::MetadataOwner, - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for MetadataSet { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "MetadataSet"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Metadata for a proposal or a referendum has been cleared."] - pub struct MetadataCleared { - pub owner: runtime_types::pallet_democracy::types::MetadataOwner, - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for MetadataCleared { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "MetadataCleared"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Metadata has been transferred to new owner."] - pub struct MetadataTransferred { - pub prev_owner: runtime_types::pallet_democracy::types::MetadataOwner, - pub owner: runtime_types::pallet_democracy::types::MetadataOwner, - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for MetadataTransferred { - const PALLET: &'static str = "Democracy"; - const EVENT: &'static str = "MetadataTransferred"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The number of (public) proposals that have been made so far."] - pub fn public_prop_count( + #[doc = " Mode of era forcing."] + pub fn force_era( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + runtime_types::pallet_staking::Forcing, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "Democracy", - "PublicPropCount", + "Staking", + "ForceEra", vec![], [ - 91u8, 14u8, 171u8, 94u8, 37u8, 157u8, 46u8, 157u8, 254u8, 13u8, 68u8, - 144u8, 23u8, 146u8, 128u8, 159u8, 9u8, 174u8, 74u8, 174u8, 218u8, - 197u8, 23u8, 235u8, 152u8, 226u8, 216u8, 4u8, 120u8, 121u8, 27u8, - 138u8, + 221u8, 41u8, 71u8, 21u8, 28u8, 193u8, 65u8, 97u8, 103u8, 37u8, 145u8, + 146u8, 183u8, 194u8, 57u8, 131u8, 214u8, 136u8, 68u8, 156u8, 140u8, + 194u8, 69u8, 151u8, 115u8, 177u8, 92u8, 147u8, 29u8, 40u8, 41u8, 31u8, ], ) } - #[doc = " The public proposals. Unsorted. The second item is the proposal."] - pub fn public_props( + #[doc = " The percentage of the slash that is distributed to reporters."] + #[doc = ""] + #[doc = " The rest of the slashed value is handled by the `Slash`."] + pub fn slash_reward_fraction( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u32, - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - ::subxt::utils::AccountId32, - )>, + runtime_types::sp_arithmetic::per_things::Perbill, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "Democracy", - "PublicProps", + "Staking", + "SlashRewardFraction", vec![], [ - 63u8, 172u8, 211u8, 85u8, 27u8, 14u8, 86u8, 49u8, 133u8, 5u8, 132u8, - 189u8, 138u8, 137u8, 219u8, 37u8, 209u8, 49u8, 172u8, 86u8, 240u8, - 235u8, 42u8, 201u8, 203u8, 12u8, 122u8, 225u8, 0u8, 109u8, 205u8, - 103u8, + 167u8, 79u8, 143u8, 202u8, 199u8, 100u8, 129u8, 162u8, 23u8, 165u8, + 106u8, 170u8, 244u8, 86u8, 144u8, 242u8, 65u8, 207u8, 115u8, 224u8, + 231u8, 155u8, 55u8, 139u8, 101u8, 129u8, 242u8, 196u8, 130u8, 50u8, + 3u8, 117u8, ], ) } - #[doc = " Those who have locked a deposit."] - #[doc = ""] - #[doc = " TWOX-NOTE: Safe, as increasing integer keys are safe."] - pub fn deposit_of( + #[doc = " The amount of currency given to reporters of a slash event which was"] + #[doc = " canceled by extraordinary circumstances (e.g. governance)."] + pub fn canceled_slash_payout( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - ::core::primitive::u128, - ), + ::core::primitive::u128, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Democracy", - "DepositOf", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Staking", + "CanceledSlashPayout", + vec![], [ - 9u8, 219u8, 11u8, 58u8, 17u8, 194u8, 248u8, 154u8, 135u8, 119u8, 123u8, - 235u8, 252u8, 176u8, 190u8, 162u8, 236u8, 45u8, 237u8, 125u8, 98u8, - 176u8, 184u8, 160u8, 8u8, 181u8, 213u8, 65u8, 14u8, 84u8, 200u8, 64u8, + 126u8, 218u8, 66u8, 92u8, 82u8, 124u8, 145u8, 161u8, 40u8, 176u8, 14u8, + 211u8, 178u8, 216u8, 8u8, 156u8, 83u8, 14u8, 91u8, 15u8, 200u8, 170u8, + 3u8, 127u8, 141u8, 139u8, 151u8, 98u8, 74u8, 96u8, 238u8, 29u8, ], ) } - #[doc = " Those who have locked a deposit."] - #[doc = ""] - #[doc = " TWOX-NOTE: Safe, as increasing integer keys are safe."] - pub fn deposit_of_root( + #[doc = " All unapplied slashes that are queued for later."] + pub fn unapplied_slashes( &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::std::vec::Vec< + runtime_types::pallet_staking::UnappliedSlash< ::subxt::utils::AccountId32, + ::core::primitive::u128, >, - ::core::primitive::u128, - ), - (), - (), + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Democracy", - "DepositOf", - Vec::new(), + "Staking", + "UnappliedSlashes", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 9u8, 219u8, 11u8, 58u8, 17u8, 194u8, 248u8, 154u8, 135u8, 119u8, 123u8, - 235u8, 252u8, 176u8, 190u8, 162u8, 236u8, 45u8, 237u8, 125u8, 98u8, - 176u8, 184u8, 160u8, 8u8, 181u8, 213u8, 65u8, 14u8, 84u8, 200u8, 64u8, + 130u8, 4u8, 163u8, 163u8, 28u8, 85u8, 34u8, 156u8, 47u8, 125u8, 57u8, + 0u8, 133u8, 176u8, 130u8, 2u8, 175u8, 180u8, 167u8, 203u8, 230u8, 82u8, + 198u8, 183u8, 55u8, 82u8, 221u8, 248u8, 100u8, 173u8, 206u8, 151u8, ], ) } - #[doc = " The next free referendum index, aka the number of referenda started so far."] - pub fn referendum_count( + #[doc = " All unapplied slashes that are queued for later."] + pub fn unapplied_slashes_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + ::std::vec::Vec< + runtime_types::pallet_staking::UnappliedSlash< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + >, + (), ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), > { ::subxt::storage::address::Address::new_static( - "Democracy", - "ReferendumCount", - vec![], + "Staking", + "UnappliedSlashes", + Vec::new(), [ - 153u8, 210u8, 106u8, 244u8, 156u8, 70u8, 124u8, 251u8, 123u8, 75u8, - 7u8, 189u8, 199u8, 145u8, 95u8, 119u8, 137u8, 11u8, 240u8, 160u8, - 151u8, 248u8, 229u8, 231u8, 89u8, 222u8, 18u8, 237u8, 144u8, 78u8, - 99u8, 58u8, + 130u8, 4u8, 163u8, 163u8, 28u8, 85u8, 34u8, 156u8, 47u8, 125u8, 57u8, + 0u8, 133u8, 176u8, 130u8, 2u8, 175u8, 180u8, 167u8, 203u8, 230u8, 82u8, + 198u8, 183u8, 55u8, 82u8, 221u8, 248u8, 100u8, 173u8, 206u8, 151u8, ], ) } - #[doc = " The lowest referendum index representing an unbaked referendum. Equal to"] - #[doc = " `ReferendumCount` if there isn't a unbaked referendum."] - pub fn lowest_unbaked( + #[doc = " A mapping from still-bonded eras to the first session index of that era."] + #[doc = ""] + #[doc = " Must contains information for eras for the range:"] + #[doc = " `[active_era - bounding_duration; active_era]`"] + pub fn bonded_eras( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::u32)>, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "Democracy", - "LowestUnbaked", + "Staking", + "BondedEras", vec![], [ - 4u8, 51u8, 108u8, 11u8, 48u8, 165u8, 19u8, 251u8, 182u8, 76u8, 163u8, - 73u8, 227u8, 2u8, 212u8, 74u8, 128u8, 27u8, 165u8, 164u8, 111u8, 22u8, - 209u8, 190u8, 103u8, 7u8, 116u8, 16u8, 160u8, 144u8, 123u8, 64u8, + 243u8, 162u8, 236u8, 198u8, 122u8, 182u8, 37u8, 55u8, 171u8, 156u8, + 235u8, 223u8, 226u8, 129u8, 89u8, 206u8, 2u8, 155u8, 222u8, 154u8, + 116u8, 124u8, 4u8, 119u8, 155u8, 94u8, 248u8, 30u8, 171u8, 51u8, 78u8, + 106u8, ], ) } - #[doc = " Information concerning any given referendum."] - #[doc = ""] - #[doc = " TWOX-NOTE: SAFE as indexes are not under an attacker’s control."] - pub fn referendum_info_of( + #[doc = " All slashing events on validators, mapped by era to the highest slash proportion"] + #[doc = " and slash value of the era."] + pub fn validator_slash_in_era( &self, _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_democracy::types::ReferendumInfo< - ::core::primitive::u32, - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, + ( + runtime_types::sp_arithmetic::per_things::Perbill, ::core::primitive::u128, - >, + ), ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Democracy", - "ReferendumInfoOf", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Staking", + "ValidatorSlashInEra", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], [ - 167u8, 58u8, 230u8, 197u8, 185u8, 56u8, 181u8, 32u8, 81u8, 150u8, 29u8, - 138u8, 142u8, 38u8, 255u8, 216u8, 139u8, 93u8, 56u8, 148u8, 196u8, - 169u8, 168u8, 144u8, 193u8, 200u8, 187u8, 5u8, 141u8, 201u8, 254u8, - 248u8, + 237u8, 80u8, 3u8, 237u8, 9u8, 40u8, 212u8, 15u8, 251u8, 196u8, 85u8, + 29u8, 27u8, 151u8, 98u8, 122u8, 189u8, 147u8, 205u8, 40u8, 202u8, + 194u8, 158u8, 96u8, 138u8, 16u8, 116u8, 71u8, 140u8, 163u8, 121u8, + 197u8, ], ) } - #[doc = " Information concerning any given referendum."] - #[doc = ""] - #[doc = " TWOX-NOTE: SAFE as indexes are not under an attacker’s control."] - pub fn referendum_info_of_root( + #[doc = " All slashing events on validators, mapped by era to the highest slash proportion"] + #[doc = " and slash value of the era."] + pub fn validator_slash_in_era_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_democracy::types::ReferendumInfo< - ::core::primitive::u32, - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, + ( + runtime_types::sp_arithmetic::per_things::Perbill, ::core::primitive::u128, - >, + ), (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Democracy", - "ReferendumInfoOf", + "Staking", + "ValidatorSlashInEra", Vec::new(), [ - 167u8, 58u8, 230u8, 197u8, 185u8, 56u8, 181u8, 32u8, 81u8, 150u8, 29u8, - 138u8, 142u8, 38u8, 255u8, 216u8, 139u8, 93u8, 56u8, 148u8, 196u8, - 169u8, 168u8, 144u8, 193u8, 200u8, 187u8, 5u8, 141u8, 201u8, 254u8, - 248u8, + 237u8, 80u8, 3u8, 237u8, 9u8, 40u8, 212u8, 15u8, 251u8, 196u8, 85u8, + 29u8, 27u8, 151u8, 98u8, 122u8, 189u8, 147u8, 205u8, 40u8, 202u8, + 194u8, 158u8, 96u8, 138u8, 16u8, 116u8, 71u8, 140u8, 163u8, 121u8, + 197u8, ], ) } - #[doc = " All votes for a particular voter. We store the balance for the number of votes that we"] - #[doc = " have recorded. The second item is the total amount of delegations, that will be added."] - #[doc = ""] - #[doc = " TWOX-NOTE: SAFE as `AccountId`s are crypto hashes anyway."] - pub fn voting_of( + #[doc = " All slashing events on nominators, mapped by era to the highest slash value of the era."] + pub fn nominator_slash_in_era( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_democracy::vote::Voting< - ::core::primitive::u128, - ::subxt::utils::AccountId32, - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, + ::core::primitive::u128, ::subxt::storage::address::Yes, + (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Democracy", - "VotingOf", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Staking", + "NominatorSlashInEra", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], [ - 125u8, 121u8, 167u8, 170u8, 18u8, 194u8, 183u8, 38u8, 176u8, 48u8, - 30u8, 88u8, 233u8, 196u8, 33u8, 119u8, 160u8, 201u8, 29u8, 183u8, 88u8, - 67u8, 219u8, 137u8, 6u8, 195u8, 11u8, 63u8, 162u8, 181u8, 82u8, 243u8, + 249u8, 85u8, 170u8, 41u8, 179u8, 194u8, 180u8, 12u8, 53u8, 101u8, 80u8, + 96u8, 166u8, 71u8, 239u8, 23u8, 153u8, 19u8, 152u8, 38u8, 138u8, 136u8, + 221u8, 200u8, 18u8, 165u8, 26u8, 228u8, 195u8, 199u8, 62u8, 4u8, ], ) } - #[doc = " All votes for a particular voter. We store the balance for the number of votes that we"] - #[doc = " have recorded. The second item is the total amount of delegations, that will be added."] - #[doc = ""] - #[doc = " TWOX-NOTE: SAFE as `AccountId`s are crypto hashes anyway."] - pub fn voting_of_root( + #[doc = " All slashing events on nominators, mapped by era to the highest slash value of the era."] + pub fn nominator_slash_in_era_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_democracy::vote::Voting< - ::core::primitive::u128, - ::subxt::utils::AccountId32, - ::core::primitive::u32, - >, + ::core::primitive::u128, + (), (), - ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Democracy", - "VotingOf", + "Staking", + "NominatorSlashInEra", Vec::new(), [ - 125u8, 121u8, 167u8, 170u8, 18u8, 194u8, 183u8, 38u8, 176u8, 48u8, - 30u8, 88u8, 233u8, 196u8, 33u8, 119u8, 160u8, 201u8, 29u8, 183u8, 88u8, - 67u8, 219u8, 137u8, 6u8, 195u8, 11u8, 63u8, 162u8, 181u8, 82u8, 243u8, + 249u8, 85u8, 170u8, 41u8, 179u8, 194u8, 180u8, 12u8, 53u8, 101u8, 80u8, + 96u8, 166u8, 71u8, 239u8, 23u8, 153u8, 19u8, 152u8, 38u8, 138u8, 136u8, + 221u8, 200u8, 18u8, 165u8, 26u8, 228u8, 195u8, 199u8, 62u8, 4u8, ], ) } - #[doc = " True if the last referendum tabled was submitted externally. False if it was a public"] - #[doc = " proposal."] - pub fn last_tabled_was_external( + #[doc = " Slashing spans for stash accounts."] + pub fn slashing_spans( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, + runtime_types::pallet_staking::slashing::SlashingSpans, ::subxt::storage::address::Yes, (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Democracy", - "LastTabledWasExternal", - vec![], + "Staking", + "SlashingSpans", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 3u8, 67u8, 106u8, 1u8, 89u8, 204u8, 4u8, 145u8, 121u8, 44u8, 34u8, - 76u8, 18u8, 206u8, 65u8, 214u8, 222u8, 82u8, 31u8, 223u8, 144u8, 169u8, - 17u8, 6u8, 138u8, 36u8, 113u8, 155u8, 241u8, 106u8, 189u8, 218u8, + 106u8, 115u8, 118u8, 52u8, 89u8, 77u8, 246u8, 5u8, 255u8, 204u8, 44u8, + 5u8, 66u8, 36u8, 227u8, 252u8, 86u8, 159u8, 186u8, 152u8, 196u8, 21u8, + 74u8, 201u8, 133u8, 93u8, 142u8, 191u8, 20u8, 27u8, 218u8, 157u8, ], ) } - #[doc = " The referendum to be tabled whenever it would be valid to table an external proposal."] - #[doc = " This happens when a referendum needs to be tabled and one of two conditions are met:"] - #[doc = " - `LastTabledWasExternal` is `false`; or"] - #[doc = " - `PublicProps` is empty."] - pub fn next_external( + #[doc = " Slashing spans for stash accounts."] + pub fn slashing_spans_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - runtime_types::pallet_democracy::vote_threshold::VoteThreshold, - ), - ::subxt::storage::address::Yes, + runtime_types::pallet_staking::slashing::SlashingSpans, (), (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Democracy", - "NextExternal", - vec![], + "Staking", + "SlashingSpans", + Vec::new(), [ - 213u8, 36u8, 235u8, 75u8, 153u8, 33u8, 140u8, 121u8, 191u8, 197u8, - 17u8, 57u8, 234u8, 67u8, 81u8, 55u8, 123u8, 179u8, 207u8, 124u8, 238u8, - 147u8, 243u8, 126u8, 200u8, 2u8, 16u8, 143u8, 165u8, 143u8, 159u8, - 93u8, + 106u8, 115u8, 118u8, 52u8, 89u8, 77u8, 246u8, 5u8, 255u8, 204u8, 44u8, + 5u8, 66u8, 36u8, 227u8, 252u8, 86u8, 159u8, 186u8, 152u8, 196u8, 21u8, + 74u8, 201u8, 133u8, 93u8, 142u8, 191u8, 20u8, 27u8, 218u8, 157u8, ], ) } - #[doc = " A record of who vetoed what. Maps proposal hash to a possible existent block number"] - #[doc = " (until when it may not be resubmitted) and who vetoed it."] - pub fn blacklist( + #[doc = " Records information about the maximum slash of a stash within a slashing span,"] + #[doc = " as well as how much reward has been paid out."] + pub fn span_slash( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _1: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u32, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - ), + runtime_types::pallet_staking::slashing::SpanRecord<::core::primitive::u128>, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Democracy", - "Blacklist", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Staking", + "SpanSlash", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], [ - 8u8, 227u8, 185u8, 179u8, 192u8, 92u8, 171u8, 125u8, 237u8, 224u8, - 109u8, 207u8, 44u8, 181u8, 78u8, 17u8, 254u8, 183u8, 199u8, 241u8, - 49u8, 90u8, 101u8, 168u8, 46u8, 89u8, 253u8, 155u8, 38u8, 183u8, 112u8, - 35u8, + 160u8, 63u8, 115u8, 190u8, 233u8, 148u8, 75u8, 3u8, 11u8, 59u8, 184u8, + 220u8, 205u8, 64u8, 28u8, 190u8, 116u8, 210u8, 225u8, 230u8, 224u8, + 163u8, 103u8, 157u8, 100u8, 29u8, 86u8, 167u8, 84u8, 217u8, 109u8, + 200u8, ], ) } - #[doc = " A record of who vetoed what. Maps proposal hash to a possible existent block number"] - #[doc = " (until when it may not be resubmitted) and who vetoed it."] - pub fn blacklist_root( + #[doc = " Records information about the maximum slash of a stash within a slashing span,"] + #[doc = " as well as how much reward has been paid out."] + pub fn span_slash_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u32, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - ), - (), + runtime_types::pallet_staking::slashing::SpanRecord<::core::primitive::u128>, (), ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Democracy", - "Blacklist", + "Staking", + "SpanSlash", Vec::new(), [ - 8u8, 227u8, 185u8, 179u8, 192u8, 92u8, 171u8, 125u8, 237u8, 224u8, - 109u8, 207u8, 44u8, 181u8, 78u8, 17u8, 254u8, 183u8, 199u8, 241u8, - 49u8, 90u8, 101u8, 168u8, 46u8, 89u8, 253u8, 155u8, 38u8, 183u8, 112u8, - 35u8, + 160u8, 63u8, 115u8, 190u8, 233u8, 148u8, 75u8, 3u8, 11u8, 59u8, 184u8, + 220u8, 205u8, 64u8, 28u8, 190u8, 116u8, 210u8, 225u8, 230u8, 224u8, + 163u8, 103u8, 157u8, 100u8, 29u8, 86u8, 167u8, 84u8, 217u8, 109u8, + 200u8, ], ) } - #[doc = " Record of all proposals that have been subject to emergency cancellation."] - pub fn cancellations( + #[doc = " The last planned session scheduled by the session pallet."] + #[doc = ""] + #[doc = " This is basically in sync with the call to [`pallet_session::SessionManager::new_session`]."] + pub fn current_planned_session( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, + ::core::primitive::u32, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Democracy", - "Cancellations", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 154u8, 36u8, 172u8, 46u8, 65u8, 218u8, 30u8, 151u8, 173u8, 186u8, - 166u8, 79u8, 35u8, 226u8, 94u8, 200u8, 67u8, 44u8, 47u8, 7u8, 17u8, - 89u8, 169u8, 166u8, 236u8, 101u8, 68u8, 54u8, 114u8, 141u8, 177u8, - 135u8, - ], - ) - } - #[doc = " Record of all proposals that have been subject to emergency cancellation."] - pub fn cancellations_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Democracy", - "Cancellations", - Vec::new(), + "Staking", + "CurrentPlannedSession", + vec![], [ - 154u8, 36u8, 172u8, 46u8, 65u8, 218u8, 30u8, 151u8, 173u8, 186u8, - 166u8, 79u8, 35u8, 226u8, 94u8, 200u8, 67u8, 44u8, 47u8, 7u8, 17u8, - 89u8, 169u8, 166u8, 236u8, 101u8, 68u8, 54u8, 114u8, 141u8, 177u8, - 135u8, + 38u8, 22u8, 56u8, 250u8, 17u8, 154u8, 99u8, 37u8, 155u8, 253u8, 100u8, + 117u8, 5u8, 239u8, 31u8, 190u8, 53u8, 241u8, 11u8, 185u8, 163u8, 227u8, + 10u8, 77u8, 210u8, 64u8, 156u8, 218u8, 105u8, 16u8, 1u8, 57u8, ], ) } - #[doc = " General information concerning any proposal or referendum."] - #[doc = " The `PreimageHash` refers to the preimage of the `Preimages` provider which can be a JSON"] - #[doc = " dump or IPFS hash of a JSON file."] + #[doc = " Indices of validators that have offended in the active era and whether they are currently"] + #[doc = " disabled."] #[doc = ""] - #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] - #[doc = " large preimages."] - pub fn metadata_of( + #[doc = " This value should be a superset of disabled validators since not all offences lead to the"] + #[doc = " validator being disabled (if there was no slash). This is needed to track the percentage of"] + #[doc = " validators that have offended in the current era, ensuring a new era is forced if"] + #[doc = " `OffendingValidatorsThreshold` is reached. The vec is always kept sorted so that we can find"] + #[doc = " whether a given validator has previously offended using binary search. It gets cleared when"] + #[doc = " the era ends."] + pub fn offending_validators( &self, - _0: impl ::std::borrow::Borrow< - runtime_types::pallet_democracy::types::MetadataOwner, - >, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, + ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::bool)>, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Democracy", - "MetadataOf", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Staking", + "OffendingValidators", + vec![], [ - 157u8, 252u8, 120u8, 151u8, 76u8, 82u8, 189u8, 77u8, 196u8, 65u8, - 113u8, 138u8, 138u8, 57u8, 199u8, 136u8, 22u8, 35u8, 114u8, 144u8, - 172u8, 42u8, 130u8, 19u8, 19u8, 245u8, 76u8, 177u8, 145u8, 146u8, - 107u8, 23u8, + 94u8, 254u8, 0u8, 50u8, 76u8, 232u8, 51u8, 153u8, 118u8, 14u8, 70u8, + 101u8, 112u8, 215u8, 173u8, 82u8, 182u8, 104u8, 167u8, 103u8, 187u8, + 168u8, 86u8, 16u8, 51u8, 235u8, 51u8, 119u8, 38u8, 154u8, 42u8, 113u8, ], ) } - #[doc = " General information concerning any proposal or referendum."] - #[doc = " The `PreimageHash` refers to the preimage of the `Preimages` provider which can be a JSON"] - #[doc = " dump or IPFS hash of a JSON file."] - #[doc = ""] - #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] - #[doc = " large preimages."] - pub fn metadata_of_root( + #[doc = " The threshold for when users can start calling `chill_other` for other validators /"] + #[doc = " nominators. The threshold is compared to the actual number of validators / nominators"] + #[doc = " (`CountFor*`) in the system compared to the configured max (`Max*Count`)."] + pub fn chill_threshold( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, + runtime_types::sp_arithmetic::per_things::Percent, + ::subxt::storage::address::Yes, (), (), - ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Democracy", - "MetadataOf", - Vec::new(), + "Staking", + "ChillThreshold", + vec![], [ - 157u8, 252u8, 120u8, 151u8, 76u8, 82u8, 189u8, 77u8, 196u8, 65u8, - 113u8, 138u8, 138u8, 57u8, 199u8, 136u8, 22u8, 35u8, 114u8, 144u8, - 172u8, 42u8, 130u8, 19u8, 19u8, 245u8, 76u8, 177u8, 145u8, 146u8, - 107u8, 23u8, + 174u8, 165u8, 249u8, 105u8, 24u8, 151u8, 115u8, 166u8, 199u8, 251u8, + 28u8, 5u8, 50u8, 95u8, 144u8, 110u8, 220u8, 76u8, 14u8, 23u8, 179u8, + 41u8, 11u8, 248u8, 28u8, 154u8, 159u8, 255u8, 156u8, 109u8, 98u8, 92u8, ], ) } @@ -11540,17 +11059,13 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " The period between a proposal being approved and enacted."] - #[doc = ""] - #[doc = " It should generally be a little more than the unstake period to ensure that"] - #[doc = " voting stakers have an opportunity to remove themselves from the system in the case"] - #[doc = " where they are on the losing side of a vote."] - pub fn enactment_period( + #[doc = " Maximum number of nominations per nominator."] + pub fn max_nominations( &self, ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Democracy", - "EnactmentPeriod", + "Staking", + "MaxNominations", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -11559,11 +11074,30 @@ pub mod api { ], ) } - #[doc = " How often (in blocks) new public referenda are launched."] - pub fn launch_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + #[doc = " Number of eras to keep in history."] + #[doc = ""] + #[doc = " Following information is kept for eras in `[current_era -"] + #[doc = " HistoryDepth, current_era]`: `ErasStakers`, `ErasStakersClipped`,"] + #[doc = " `ErasValidatorPrefs`, `ErasValidatorReward`, `ErasRewardPoints`,"] + #[doc = " `ErasTotalStake`, `ErasStartSessionIndex`,"] + #[doc = " `StakingLedger.claimed_rewards`."] + #[doc = ""] + #[doc = " Must be more than the number of eras delayed by session."] + #[doc = " I.e. active era must always be in history. I.e. `active_era >"] + #[doc = " current_era - history_depth` must be guaranteed."] + #[doc = ""] + #[doc = " If migrating an existing pallet from storage value to config value,"] + #[doc = " this should be set to same value or greater as in storage."] + #[doc = ""] + #[doc = " Note: `HistoryDepth` is used as the upper bound for the `BoundedVec`"] + #[doc = " item `StakingLedger.claimed_rewards`. Setting this value lower than"] + #[doc = " the existing value can lead to inconsistencies in the"] + #[doc = " `StakingLedger` and will need to be handled properly in a migration."] + #[doc = " The test `reducing_history_depth_abrupt` shows this effect."] + pub fn history_depth(&self) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Democracy", - "LaunchPeriod", + "Staking", + "HistoryDepth", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -11572,11 +11106,13 @@ pub mod api { ], ) } - #[doc = " How often (in blocks) to check for new votes."] - pub fn voting_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + #[doc = " Number of sessions per era."] + pub fn sessions_per_era( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Democracy", - "VotingPeriod", + "Staking", + "SessionsPerEra", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -11585,16 +11121,13 @@ pub mod api { ], ) } - #[doc = " The minimum period of vote locking."] - #[doc = ""] - #[doc = " It should be no shorter than enactment period to ensure that in the case of an approval,"] - #[doc = " those successful voters are locked into the consequences that their votes entail."] - pub fn vote_locking_period( + #[doc = " Number of eras that staked funds must remain bonded for."] + pub fn bonding_duration( &self, ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Democracy", - "VoteLockingPeriod", + "Staking", + "BondingDuration", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -11603,43 +11136,16 @@ pub mod api { ], ) } - #[doc = " The minimum amount to be used as a deposit for a public referendum proposal."] - pub fn minimum_deposit( + #[doc = " Number of eras that slashes are deferred by, after computation."] + #[doc = ""] + #[doc = " This should be less than the bonding duration. Set to 0 if slashes"] + #[doc = " should be applied immediately, without opportunity for intervention."] + pub fn slash_defer_duration( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { + ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Democracy", - "MinimumDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Indicator for whether an emergency origin is even allowed to happen. Some chains may"] - #[doc = " want to set this permanently to `false`, others may want to condition it on things such"] - #[doc = " as an upgrade having happened recently."] - pub fn instant_allowed( - &self, - ) -> ::subxt::constants::Address<::core::primitive::bool> { - ::subxt::constants::Address::new_static( - "Democracy", - "InstantAllowed", - [ - 165u8, 28u8, 112u8, 190u8, 18u8, 129u8, 182u8, 206u8, 237u8, 1u8, 68u8, - 252u8, 125u8, 234u8, 185u8, 50u8, 149u8, 164u8, 47u8, 126u8, 134u8, - 100u8, 14u8, 86u8, 209u8, 39u8, 20u8, 4u8, 233u8, 115u8, 102u8, 131u8, - ], - ) - } - #[doc = " Minimum voting period allowed for a fast-track referendum."] - pub fn fast_track_voting_period( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Democracy", - "FastTrackVotingPeriod", + "Staking", + "SlashDeferDuration", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -11648,13 +11154,16 @@ pub mod api { ], ) } - #[doc = " Period in blocks where an external proposal may not be re-submitted after being vetoed."] - pub fn cooloff_period( + #[doc = " The maximum number of nominators rewarded for each validator."] + #[doc = ""] + #[doc = " For each validator only the `$MaxNominatorRewardedPerValidator` biggest stakers can"] + #[doc = " claim their reward. This used to limit the i/o cost for the nominator payout."] + pub fn max_nominator_rewarded_per_validator( &self, ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Democracy", - "CooloffPeriod", + "Staking", + "MaxNominatorRewardedPerValidator", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -11663,55 +11172,22 @@ pub mod api { ], ) } - #[doc = " The maximum number of votes for an account."] + #[doc = " The maximum number of `unlocking` chunks a [`StakingLedger`] can"] + #[doc = " have. Effectively determines how many unique eras a staker may be"] + #[doc = " unbonding in."] #[doc = ""] - #[doc = " Also used to compute weight, an overly big value can"] - #[doc = " lead to extrinsic with very big weight: see `delegate` for instance."] - pub fn max_votes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Democracy", - "MaxVotes", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of public proposals that can exist at any time."] - pub fn max_proposals(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Democracy", - "MaxProposals", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of deposits a public proposal may have at any time."] - pub fn max_deposits(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Democracy", - "MaxDeposits", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of items which can be blacklisted."] - pub fn max_blacklisted( + #[doc = " Note: `MaxUnlockingChunks` is used as the upper bound for the"] + #[doc = " `BoundedVec` item `StakingLedger.unlocking`. Setting this value"] + #[doc = " lower than the existing value can lead to inconsistencies in the"] + #[doc = " `StakingLedger` and will need to be handled properly in a runtime"] + #[doc = " migration. The test `reducing_max_unlocking_chunks_abrupt` shows"] + #[doc = " this effect."] + pub fn max_unlocking_chunks( &self, ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Democracy", - "MaxBlacklisted", + "Staking", + "MaxUnlockingChunks", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -11723,79 +11199,13 @@ pub mod api { } } } - pub mod council { + pub mod offences { use super::root_mod; use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_collective::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; + #[doc = "Events type."] + pub type Event = runtime_types::pallet_offences::pallet::Event; + pub mod events { use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMembers { - pub new_members: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub prime: ::core::option::Option<::subxt::utils::AccountId32>, - pub old_count: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Execute { - pub proposal: ::std::boxed::Box, - #[codec(compact)] - pub length_bound: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Propose { - #[codec(compact)] - pub threshold: ::core::primitive::u32, - pub proposal: ::std::boxed::Box, - #[codec(compact)] - pub length_bound: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vote { - pub proposal: ::subxt::utils::H256, - #[codec(compact)] - pub index: ::core::primitive::u32, - pub approve: ::core::primitive::bool, - } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -11806,247 +11216,236 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DisapproveProposal { - pub proposal_hash: ::subxt::utils::H256, + #[doc = "There is an offence reported of the given `kind` happened at the `session_index` and"] + #[doc = "(kind-specific) time slot. This event is not deposited for duplicate slashes."] + #[doc = "\\[kind, timeslot\\]."] + pub struct Offence { + pub kind: [::core::primitive::u8; 16usize], + pub timeslot: ::std::vec::Vec<::core::primitive::u8>, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Close { - pub proposal_hash: ::subxt::utils::H256, - #[codec(compact)] - pub index: ::core::primitive::u32, - pub proposal_weight_bound: runtime_types::sp_weights::weight_v2::Weight, - #[codec(compact)] - pub length_bound: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for Offence { + const PALLET: &'static str = "Offences"; + const EVENT: &'static str = "Offence"; } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Set the collective's membership."] - #[doc = ""] - #[doc = "- `new_members`: The new member list. Be nice to the chain and provide it sorted."] - #[doc = "- `prime`: The prime member whose vote sets the default."] - #[doc = "- `old_count`: The upper bound for the previous number of members in storage. Used for"] - #[doc = " weight estimation."] - #[doc = ""] - #[doc = "The dispatch of this call must be `SetMembersOrigin`."] - #[doc = ""] - #[doc = "NOTE: Does not enforce the expected `MaxMembers` limit on the amount of members, but"] - #[doc = " the weight estimations rely on it to estimate dispatchable weight."] - #[doc = ""] - #[doc = "# WARNING:"] - #[doc = ""] - #[doc = "The `pallet-collective` can also be managed by logic outside of the pallet through the"] - #[doc = "implementation of the trait [`ChangeMembers`]."] - #[doc = "Any call to `set_members` must be careful that the member set doesn't get out of sync"] - #[doc = "with other logic managing the member set."] - #[doc = ""] - #[doc = "## Complexity:"] - #[doc = "- `O(MP + N)` where:"] - #[doc = " - `M` old-members-count (code- and governance-bounded)"] - #[doc = " - `N` new-members-count (code- and governance-bounded)"] - #[doc = " - `P` proposals-count (code-bounded)"] - pub fn set_members( + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The primary structure that holds all offence records keyed by report identifiers."] + pub fn reports( &self, - new_members: ::std::vec::Vec<::subxt::utils::AccountId32>, - prime: ::core::option::Option<::subxt::utils::AccountId32>, - old_count: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Council", - "set_members", - types::SetMembers { - new_members, - prime, - old_count, - }, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_staking::offence::OffenceDetails< + ::subxt::utils::AccountId32, + ( + ::subxt::utils::AccountId32, + runtime_types::pallet_staking::Exposure< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + ), + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Offences", + "Reports", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 196u8, 103u8, 123u8, 125u8, 226u8, 177u8, 126u8, 37u8, 160u8, 114u8, - 34u8, 136u8, 219u8, 84u8, 199u8, 94u8, 242u8, 20u8, 126u8, 126u8, - 166u8, 190u8, 198u8, 33u8, 162u8, 113u8, 237u8, 222u8, 90u8, 1u8, 2u8, - 234u8, + 144u8, 30u8, 66u8, 199u8, 102u8, 236u8, 175u8, 201u8, 206u8, 170u8, + 55u8, 162u8, 137u8, 120u8, 220u8, 213u8, 57u8, 252u8, 0u8, 88u8, 210u8, + 68u8, 5u8, 25u8, 77u8, 114u8, 204u8, 23u8, 190u8, 32u8, 211u8, 30u8, ], ) } - #[doc = "Dispatch a proposal from a member using the `Member` origin."] - #[doc = ""] - #[doc = "Origin must be a member of the collective."] - #[doc = ""] - #[doc = "## Complexity:"] - #[doc = "- `O(B + M + P)` where:"] - #[doc = "- `B` is `proposal` size in bytes (length-fee-bounded)"] - #[doc = "- `M` members-count (code-bounded)"] - #[doc = "- `P` complexity of dispatching `proposal`"] - pub fn execute( + #[doc = " The primary structure that holds all offence records keyed by report identifiers."] + pub fn reports_root( &self, - proposal: runtime_types::polkadot_runtime::RuntimeCall, - length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Council", - "execute", - types::Execute { - proposal: ::std::boxed::Box::new(proposal), - length_bound, - }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_staking::offence::OffenceDetails< + ::subxt::utils::AccountId32, + ( + ::subxt::utils::AccountId32, + runtime_types::pallet_staking::Exposure< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + ), + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Offences", + "Reports", + Vec::new(), [ - 0u8, 74u8, 70u8, 223u8, 112u8, 196u8, 199u8, 189u8, 93u8, 14u8, 101u8, - 211u8, 221u8, 38u8, 32u8, 220u8, 90u8, 120u8, 94u8, 107u8, 46u8, 121u8, - 250u8, 150u8, 26u8, 24u8, 20u8, 242u8, 253u8, 229u8, 43u8, 195u8, + 144u8, 30u8, 66u8, 199u8, 102u8, 236u8, 175u8, 201u8, 206u8, 170u8, + 55u8, 162u8, 137u8, 120u8, 220u8, 213u8, 57u8, 252u8, 0u8, 88u8, 210u8, + 68u8, 5u8, 25u8, 77u8, 114u8, 204u8, 23u8, 190u8, 32u8, 211u8, 30u8, ], ) } - #[doc = "Add a new proposal to either be voted on or executed directly."] - #[doc = ""] - #[doc = "Requires the sender to be member."] - #[doc = ""] - #[doc = "`threshold` determines whether `proposal` is executed directly (`threshold < 2`)"] - #[doc = "or put up for voting."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(B + M + P1)` or `O(B + M + P2)` where:"] - #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] - #[doc = " - `M` is members-count (code- and governance-bounded)"] - #[doc = " - branching is influenced by `threshold` where:"] - #[doc = " - `P1` is proposal execution complexity (`threshold < 2`)"] - #[doc = " - `P2` is proposals-count (code-bounded) (`threshold >= 2`)"] - pub fn propose( + #[doc = " A vector of reports of the same kind that happened at the same time slot."] + pub fn concurrent_reports_index( &self, - threshold: ::core::primitive::u32, - proposal: runtime_types::polkadot_runtime::RuntimeCall, - length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Council", - "propose", - types::Propose { - threshold, - proposal: ::std::boxed::Box::new(proposal), - length_bound, - }, + _0: impl ::std::borrow::Borrow<[::core::primitive::u8; 16usize]>, + _1: impl ::std::borrow::Borrow<[::core::primitive::u8]>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::subxt::utils::H256>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Offences", + "ConcurrentReportsIndex", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], [ - 157u8, 103u8, 73u8, 75u8, 15u8, 79u8, 50u8, 64u8, 5u8, 151u8, 194u8, - 216u8, 45u8, 47u8, 128u8, 206u8, 191u8, 52u8, 5u8, 104u8, 70u8, 6u8, - 139u8, 184u8, 12u8, 190u8, 109u8, 132u8, 195u8, 177u8, 197u8, 179u8, + 106u8, 21u8, 104u8, 5u8, 4u8, 66u8, 28u8, 70u8, 161u8, 195u8, 238u8, + 28u8, 69u8, 241u8, 221u8, 113u8, 140u8, 103u8, 181u8, 143u8, 60u8, + 177u8, 13u8, 129u8, 224u8, 149u8, 77u8, 32u8, 75u8, 74u8, 101u8, 65u8, ], ) } - #[doc = "Add an aye or nay vote for the sender to the given proposal."] - #[doc = ""] - #[doc = "Requires the sender to be a member."] - #[doc = ""] - #[doc = "Transaction fees will be waived if the member is voting on any particular proposal"] - #[doc = "for the first time and the call is successful. Subsequent vote changes will charge a"] - #[doc = "fee."] - #[doc = "## Complexity"] - #[doc = "- `O(M)` where `M` is members-count (code- and governance-bounded)"] - pub fn vote( + #[doc = " A vector of reports of the same kind that happened at the same time slot."] + pub fn concurrent_reports_index_root( &self, - proposal: ::subxt::utils::H256, - index: ::core::primitive::u32, - approve: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Council", - "vote", - types::Vote { - proposal, - index, - approve, - }, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::subxt::utils::H256>, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Offences", + "ConcurrentReportsIndex", + Vec::new(), [ - 108u8, 46u8, 180u8, 148u8, 145u8, 24u8, 173u8, 56u8, 36u8, 100u8, - 216u8, 43u8, 178u8, 202u8, 26u8, 136u8, 93u8, 84u8, 80u8, 134u8, 14u8, - 42u8, 248u8, 205u8, 68u8, 92u8, 79u8, 11u8, 113u8, 115u8, 157u8, 100u8, + 106u8, 21u8, 104u8, 5u8, 4u8, 66u8, 28u8, 70u8, 161u8, 195u8, 238u8, + 28u8, 69u8, 241u8, 221u8, 113u8, 140u8, 103u8, 181u8, 143u8, 60u8, + 177u8, 13u8, 129u8, 224u8, 149u8, 77u8, 32u8, 75u8, 74u8, 101u8, 65u8, ], ) } - #[doc = "Disapprove a proposal, close, and remove it from the system, regardless of its current"] - #[doc = "state."] - #[doc = ""] - #[doc = "Must be called by the Root origin."] + } + } + } + pub mod historical { + use super::root_mod; + use super::runtime_types; + } + pub mod session { + use super::root_mod; + use super::runtime_types; + #[doc = "Error for the session pallet."] + pub type Error = runtime_types::pallet_session::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetKeys { + pub keys: runtime_types::polkadot_runtime::SessionKeys, + pub proof: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PurgeKeys; + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Sets the session key(s) of the function caller to `keys`."] + #[doc = "Allows an account to set its session key prior to becoming a validator."] + #[doc = "This doesn't take effect until the next session."] #[doc = ""] - #[doc = "Parameters:"] - #[doc = "* `proposal_hash`: The hash of the proposal that should be disapproved."] + #[doc = "The dispatch origin of this function must be signed."] #[doc = ""] #[doc = "## Complexity"] - #[doc = "O(P) where P is the number of max proposals"] - pub fn disapprove_proposal( + #[doc = "- `O(1)`. Actual cost depends on the number of length of `T::Keys::key_ids()` which is"] + #[doc = " fixed."] + pub fn set_keys( &self, - proposal_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + keys: runtime_types::polkadot_runtime::SessionKeys, + proof: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Council", - "disapprove_proposal", - types::DisapproveProposal { proposal_hash }, + "Session", + "set_keys", + types::SetKeys { keys, proof }, [ - 25u8, 123u8, 1u8, 8u8, 74u8, 37u8, 3u8, 40u8, 97u8, 37u8, 175u8, 224u8, - 72u8, 155u8, 123u8, 109u8, 104u8, 43u8, 91u8, 125u8, 199u8, 51u8, 17u8, - 225u8, 133u8, 38u8, 120u8, 76u8, 164u8, 5u8, 194u8, 201u8, + 17u8, 127u8, 23u8, 71u8, 118u8, 133u8, 89u8, 105u8, 93u8, 52u8, 46u8, + 201u8, 151u8, 19u8, 124u8, 195u8, 228u8, 229u8, 22u8, 216u8, 32u8, + 54u8, 67u8, 222u8, 91u8, 175u8, 206u8, 7u8, 238u8, 118u8, 81u8, 112u8, ], ) } - #[doc = "Close a vote that is either approved, disapproved or whose voting period has ended."] - #[doc = ""] - #[doc = "May be called by any signed account in order to finish voting and close the proposal."] - #[doc = ""] - #[doc = "If called before the end of the voting period it will only close the vote if it is"] - #[doc = "has enough votes to be approved or disapproved."] - #[doc = ""] - #[doc = "If called after the end of the voting period abstentions are counted as rejections"] - #[doc = "unless there is a prime member set and the prime member cast an approval."] + #[doc = "Removes any session key(s) of the function caller."] #[doc = ""] - #[doc = "If the close operation completes successfully with disapproval, the transaction fee will"] - #[doc = "be waived. Otherwise execution of the approved operation will be charged to the caller."] + #[doc = "This doesn't take effect until the next session."] #[doc = ""] - #[doc = "+ `proposal_weight_bound`: The maximum amount of weight consumed by executing the closed"] - #[doc = "proposal."] - #[doc = "+ `length_bound`: The upper bound for the length of the proposal in storage. Checked via"] - #[doc = "`storage::read` so it is `size_of::() == 4` larger than the pure length."] + #[doc = "The dispatch origin of this function must be Signed and the account must be either be"] + #[doc = "convertible to a validator ID using the chain's typical addressing system (this usually"] + #[doc = "means being a controller account) or directly convertible into a validator ID (which"] + #[doc = "usually means being a stash account)."] #[doc = ""] #[doc = "## Complexity"] - #[doc = "- `O(B + M + P1 + P2)` where:"] - #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] - #[doc = " - `M` is members-count (code- and governance-bounded)"] - #[doc = " - `P1` is the complexity of `proposal` preimage."] - #[doc = " - `P2` is proposal-count (code-bounded)"] - pub fn close( - &self, - proposal_hash: ::subxt::utils::H256, - index: ::core::primitive::u32, - proposal_weight_bound: runtime_types::sp_weights::weight_v2::Weight, - length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + #[doc = "- `O(1)` in number of key types. Actual cost depends on the number of length of"] + #[doc = " `T::Keys::key_ids()` which is fixed."] + pub fn purge_keys(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Council", - "close", - types::Close { - proposal_hash, - index, - proposal_weight_bound, - length_bound, - }, + "Session", + "purge_keys", + types::PurgeKeys {}, [ - 191u8, 138u8, 89u8, 247u8, 97u8, 51u8, 45u8, 193u8, 76u8, 16u8, 80u8, - 225u8, 197u8, 83u8, 204u8, 133u8, 169u8, 16u8, 86u8, 32u8, 125u8, 16u8, - 116u8, 185u8, 45u8, 20u8, 76u8, 148u8, 206u8, 163u8, 154u8, 30u8, + 200u8, 255u8, 4u8, 213u8, 188u8, 92u8, 99u8, 116u8, 163u8, 152u8, 29u8, + 35u8, 133u8, 119u8, 246u8, 44u8, 91u8, 31u8, 145u8, 23u8, 213u8, 64u8, + 71u8, 242u8, 207u8, 239u8, 231u8, 37u8, 61u8, 63u8, 190u8, 35u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_collective::pallet::Event; + pub type Event = runtime_types::pallet_session::pallet::Event; pub mod events { use super::runtime_types; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -12056,674 +11455,396 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A motion (given hash) has been proposed (by given account) with a threshold (given"] - #[doc = "`MemberCount`)."] - pub struct Proposed { - pub account: ::subxt::utils::AccountId32, - pub proposal_index: ::core::primitive::u32, - pub proposal_hash: ::subxt::utils::H256, - pub threshold: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Proposed { - const PALLET: &'static str = "Council"; - const EVENT: &'static str = "Proposed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A motion (given hash) has been voted on by given account, leaving"] - #[doc = "a tally (yes votes and no votes given respectively as `MemberCount`)."] - pub struct Voted { - pub account: ::subxt::utils::AccountId32, - pub proposal_hash: ::subxt::utils::H256, - pub voted: ::core::primitive::bool, - pub yes: ::core::primitive::u32, - pub no: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Voted { - const PALLET: &'static str = "Council"; - const EVENT: &'static str = "Voted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A motion was approved by the required threshold."] - pub struct Approved { - pub proposal_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Approved { - const PALLET: &'static str = "Council"; - const EVENT: &'static str = "Approved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A motion was not approved by the required threshold."] - pub struct Disapproved { - pub proposal_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Disapproved { - const PALLET: &'static str = "Council"; - const EVENT: &'static str = "Disapproved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A motion was executed; result will be `Ok` if it returned without error."] - pub struct Executed { - pub proposal_hash: ::subxt::utils::H256, - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for Executed { - const PALLET: &'static str = "Council"; - const EVENT: &'static str = "Executed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A single member did some action; result will be `Ok` if it returned without error."] - pub struct MemberExecuted { - pub proposal_hash: ::subxt::utils::H256, - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for MemberExecuted { - const PALLET: &'static str = "Council"; - const EVENT: &'static str = "MemberExecuted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proposal was closed because its threshold was reached or after its duration was up."] - pub struct Closed { - pub proposal_hash: ::subxt::utils::H256, - pub yes: ::core::primitive::u32, - pub no: ::core::primitive::u32, + #[doc = "New session has happened. Note that the argument is the session index, not the"] + #[doc = "block number as the type might suggest."] + pub struct NewSession { + pub session_index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for Closed { - const PALLET: &'static str = "Council"; - const EVENT: &'static str = "Closed"; + impl ::subxt::events::StaticEvent for NewSession { + const PALLET: &'static str = "Session"; + const EVENT: &'static str = "NewSession"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " The hashes of the active proposals."] - pub fn proposals( + #[doc = " The current set of validators."] + pub fn validators( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::H256, - >, + ::std::vec::Vec<::subxt::utils::AccountId32>, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "Council", - "Proposals", + "Session", + "Validators", vec![], [ - 10u8, 133u8, 82u8, 54u8, 193u8, 41u8, 253u8, 159u8, 56u8, 96u8, 249u8, - 148u8, 43u8, 57u8, 116u8, 43u8, 222u8, 243u8, 237u8, 231u8, 238u8, - 60u8, 26u8, 225u8, 19u8, 203u8, 213u8, 220u8, 114u8, 217u8, 100u8, - 27u8, + 144u8, 235u8, 200u8, 43u8, 151u8, 57u8, 147u8, 172u8, 201u8, 202u8, + 242u8, 96u8, 57u8, 76u8, 124u8, 77u8, 42u8, 113u8, 218u8, 220u8, 230u8, + 32u8, 151u8, 152u8, 172u8, 106u8, 60u8, 227u8, 122u8, 118u8, 137u8, + 68u8, ], ) } - #[doc = " Actual proposal for a given hash, if it's current."] - pub fn proposal_of( + #[doc = " Current index of the session."] + pub fn current_index( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime::RuntimeCall, + ::core::primitive::u32, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Council", - "ProposalOf", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Session", + "CurrentIndex", + vec![], [ - 6u8, 23u8, 244u8, 48u8, 73u8, 203u8, 222u8, 109u8, 218u8, 166u8, 6u8, - 137u8, 121u8, 88u8, 54u8, 188u8, 37u8, 8u8, 229u8, 217u8, 170u8, 108u8, - 198u8, 66u8, 36u8, 92u8, 107u8, 168u8, 162u8, 204u8, 210u8, 20u8, + 148u8, 179u8, 159u8, 15u8, 197u8, 95u8, 214u8, 30u8, 209u8, 251u8, + 183u8, 231u8, 91u8, 25u8, 181u8, 191u8, 143u8, 252u8, 227u8, 80u8, + 159u8, 66u8, 194u8, 67u8, 113u8, 74u8, 111u8, 91u8, 218u8, 187u8, + 130u8, 40u8, ], ) } - #[doc = " Actual proposal for a given hash, if it's current."] - pub fn proposal_of_root( + #[doc = " True if the underlying economic identities or weighting behind the validators"] + #[doc = " has changed in the queued validator set."] + pub fn queued_changed( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime::RuntimeCall, - (), - (), + ::core::primitive::bool, ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Council", - "ProposalOf", - Vec::new(), + "Session", + "QueuedChanged", + vec![], [ - 6u8, 23u8, 244u8, 48u8, 73u8, 203u8, 222u8, 109u8, 218u8, 166u8, 6u8, - 137u8, 121u8, 88u8, 54u8, 188u8, 37u8, 8u8, 229u8, 217u8, 170u8, 108u8, - 198u8, 66u8, 36u8, 92u8, 107u8, 168u8, 162u8, 204u8, 210u8, 20u8, + 105u8, 140u8, 235u8, 218u8, 96u8, 100u8, 252u8, 10u8, 58u8, 221u8, + 244u8, 251u8, 67u8, 91u8, 80u8, 202u8, 152u8, 42u8, 50u8, 113u8, 200u8, + 247u8, 59u8, 213u8, 77u8, 195u8, 1u8, 150u8, 220u8, 18u8, 245u8, 46u8, ], ) } - #[doc = " Votes on a given proposal, if it is ongoing."] - pub fn voting( + #[doc = " The queued keys for the next session. When the next session begins, these keys"] + #[doc = " will be used to determine the validator's session keys."] + pub fn queued_keys( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_collective::Votes< + ::std::vec::Vec<( ::subxt::utils::AccountId32, - ::core::primitive::u32, - >, + runtime_types::polkadot_runtime::SessionKeys, + )>, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Council", - "Voting", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Session", + "QueuedKeys", + vec![], [ - 89u8, 108u8, 65u8, 58u8, 60u8, 116u8, 54u8, 68u8, 179u8, 73u8, 161u8, - 168u8, 78u8, 213u8, 208u8, 54u8, 244u8, 58u8, 70u8, 209u8, 170u8, - 136u8, 215u8, 3u8, 2u8, 105u8, 229u8, 217u8, 240u8, 230u8, 107u8, - 221u8, + 197u8, 174u8, 245u8, 219u8, 36u8, 118u8, 73u8, 184u8, 156u8, 93u8, + 167u8, 107u8, 142u8, 7u8, 41u8, 51u8, 77u8, 191u8, 68u8, 95u8, 71u8, + 76u8, 253u8, 137u8, 73u8, 194u8, 169u8, 234u8, 217u8, 76u8, 157u8, + 223u8, ], ) } - #[doc = " Votes on a given proposal, if it is ongoing."] - pub fn voting_root( + #[doc = " Indices of disabled validators."] + #[doc = ""] + #[doc = " The vec is always kept sorted so that we can find whether a given validator is"] + #[doc = " disabled using binary search. It gets cleared when `on_session_ending` returns"] + #[doc = " a new set of identities."] + pub fn disabled_validators( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_collective::Votes< - ::subxt::utils::AccountId32, - ::core::primitive::u32, - >, - (), - (), + ::std::vec::Vec<::core::primitive::u32>, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Council", - "Voting", - Vec::new(), + "Session", + "DisabledValidators", + vec![], [ - 89u8, 108u8, 65u8, 58u8, 60u8, 116u8, 54u8, 68u8, 179u8, 73u8, 161u8, - 168u8, 78u8, 213u8, 208u8, 54u8, 244u8, 58u8, 70u8, 209u8, 170u8, - 136u8, 215u8, 3u8, 2u8, 105u8, 229u8, 217u8, 240u8, 230u8, 107u8, - 221u8, + 135u8, 22u8, 22u8, 97u8, 82u8, 217u8, 144u8, 141u8, 121u8, 240u8, + 189u8, 16u8, 176u8, 88u8, 177u8, 31u8, 20u8, 242u8, 73u8, 104u8, 11u8, + 110u8, 214u8, 34u8, 52u8, 217u8, 106u8, 33u8, 174u8, 174u8, 198u8, + 84u8, ], ) } - #[doc = " Proposals so far."] - pub fn proposal_count( + #[doc = " The next session keys for a validator."] + pub fn next_keys( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, + runtime_types::polkadot_runtime::SessionKeys, ::subxt::storage::address::Yes, (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Council", - "ProposalCount", - vec![], + "Session", + "NextKeys", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 132u8, 145u8, 78u8, 218u8, 51u8, 189u8, 55u8, 172u8, 143u8, 33u8, - 140u8, 99u8, 124u8, 208u8, 57u8, 232u8, 154u8, 110u8, 32u8, 142u8, - 24u8, 149u8, 109u8, 105u8, 30u8, 83u8, 39u8, 177u8, 127u8, 160u8, 34u8, - 70u8, + 94u8, 197u8, 147u8, 245u8, 165u8, 97u8, 186u8, 57u8, 142u8, 66u8, + 132u8, 213u8, 126u8, 3u8, 77u8, 88u8, 191u8, 33u8, 82u8, 153u8, 11u8, + 109u8, 96u8, 252u8, 193u8, 171u8, 158u8, 131u8, 29u8, 192u8, 248u8, + 166u8, ], ) } - #[doc = " The current members of the collective. This is stored sorted (just by value)."] - pub fn members( + #[doc = " The next session keys for a validator."] + pub fn next_keys_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::AccountId32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + runtime_types::polkadot_runtime::SessionKeys, (), + (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Council", - "Members", - vec![], + "Session", + "NextKeys", + Vec::new(), [ - 162u8, 72u8, 174u8, 204u8, 140u8, 105u8, 205u8, 176u8, 197u8, 117u8, - 206u8, 134u8, 157u8, 110u8, 139u8, 54u8, 43u8, 233u8, 25u8, 51u8, 36u8, - 238u8, 94u8, 124u8, 221u8, 52u8, 237u8, 71u8, 125u8, 56u8, 129u8, - 222u8, + 94u8, 197u8, 147u8, 245u8, 165u8, 97u8, 186u8, 57u8, 142u8, 66u8, + 132u8, 213u8, 126u8, 3u8, 77u8, 88u8, 191u8, 33u8, 82u8, 153u8, 11u8, + 109u8, 96u8, 252u8, 193u8, 171u8, 158u8, 131u8, 29u8, 192u8, 248u8, + 166u8, ], ) } - #[doc = " The prime member that helps determine the default vote behavior in case of absentations."] - pub fn prime( + #[doc = " The owner of a key. The key is the `KeyTypeId` + the encoded key."] + pub fn key_owner( &self, + _0: impl ::std::borrow::Borrow, + _1: impl ::std::borrow::Borrow<[::core::primitive::u8]>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, ::subxt::utils::AccountId32, ::subxt::storage::address::Yes, (), - (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Council", - "Prime", - vec![], + "Session", + "KeyOwner", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], [ - 108u8, 118u8, 54u8, 193u8, 207u8, 227u8, 119u8, 97u8, 23u8, 239u8, - 157u8, 69u8, 56u8, 142u8, 106u8, 17u8, 215u8, 159u8, 48u8, 42u8, 185u8, - 209u8, 49u8, 159u8, 32u8, 168u8, 111u8, 158u8, 159u8, 217u8, 244u8, - 158u8, + 4u8, 91u8, 25u8, 84u8, 250u8, 201u8, 174u8, 129u8, 201u8, 58u8, 197u8, + 199u8, 137u8, 240u8, 118u8, 33u8, 99u8, 2u8, 195u8, 57u8, 53u8, 172u8, + 0u8, 148u8, 203u8, 144u8, 149u8, 64u8, 135u8, 254u8, 242u8, 215u8, ], ) } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The maximum weight of a dispatch call that can be proposed and executed."] - pub fn max_proposal_weight( + #[doc = " The owner of a key. The key is the `KeyTypeId` + the encoded key."] + pub fn key_owner_root( &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "Council", - "MaxProposalWeight", + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::AccountId32, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Session", + "KeyOwner", + Vec::new(), [ - 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, - 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, - 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, - 106u8, 76u8, + 4u8, 91u8, 25u8, 84u8, 250u8, 201u8, 174u8, 129u8, 201u8, 58u8, 197u8, + 199u8, 137u8, 240u8, 118u8, 33u8, 99u8, 2u8, 195u8, 57u8, 53u8, 172u8, + 0u8, 148u8, 203u8, 144u8, 149u8, 64u8, 135u8, 254u8, 242u8, 215u8, ], ) } } } } - pub mod technical_committee { + pub mod grandpa { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_collective::pallet::Error; + pub type Error = runtime_types::pallet_grandpa::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMembers { - pub new_members: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub prime: ::core::option::Option<::subxt::utils::AccountId32>, - pub old_count: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Execute { - pub proposal: ::std::boxed::Box, - #[codec(compact)] - pub length_bound: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Propose { - #[codec(compact)] - pub threshold: ::core::primitive::u32, - pub proposal: ::std::boxed::Box, - #[codec(compact)] - pub length_bound: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vote { - pub proposal: ::subxt::utils::H256, - #[codec(compact)] - pub index: ::core::primitive::u32, - pub approve: ::core::primitive::bool, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DisapproveProposal { - pub proposal_hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Close { - pub proposal_hash: ::subxt::utils::H256, - #[codec(compact)] - pub index: ::core::primitive::u32, - pub proposal_weight_bound: runtime_types::sp_weights::weight_v2::Weight, - #[codec(compact)] - pub length_bound: ::core::primitive::u32, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReportEquivocation { + pub equivocation_proof: ::std::boxed::Box< + runtime_types::sp_consensus_grandpa::EquivocationProof< + ::subxt::utils::H256, + ::core::primitive::u32, + >, + >, + pub key_owner_proof: runtime_types::sp_session::MembershipProof, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReportEquivocationUnsigned { + pub equivocation_proof: ::std::boxed::Box< + runtime_types::sp_consensus_grandpa::EquivocationProof< + ::subxt::utils::H256, + ::core::primitive::u32, + >, + >, + pub key_owner_proof: runtime_types::sp_session::MembershipProof, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct NoteStalled { + pub delay: ::core::primitive::u32, + pub best_finalized_block_number: ::core::primitive::u32, + } } pub struct TransactionApi; impl TransactionApi { - #[doc = "Set the collective's membership."] - #[doc = ""] - #[doc = "- `new_members`: The new member list. Be nice to the chain and provide it sorted."] - #[doc = "- `prime`: The prime member whose vote sets the default."] - #[doc = "- `old_count`: The upper bound for the previous number of members in storage. Used for"] - #[doc = " weight estimation."] - #[doc = ""] - #[doc = "The dispatch of this call must be `SetMembersOrigin`."] - #[doc = ""] - #[doc = "NOTE: Does not enforce the expected `MaxMembers` limit on the amount of members, but"] - #[doc = " the weight estimations rely on it to estimate dispatchable weight."] - #[doc = ""] - #[doc = "# WARNING:"] - #[doc = ""] - #[doc = "The `pallet-collective` can also be managed by logic outside of the pallet through the"] - #[doc = "implementation of the trait [`ChangeMembers`]."] - #[doc = "Any call to `set_members` must be careful that the member set doesn't get out of sync"] - #[doc = "with other logic managing the member set."] - #[doc = ""] - #[doc = "## Complexity:"] - #[doc = "- `O(MP + N)` where:"] - #[doc = " - `M` old-members-count (code- and governance-bounded)"] - #[doc = " - `N` new-members-count (code- and governance-bounded)"] - #[doc = " - `P` proposals-count (code-bounded)"] - pub fn set_members( - &self, - new_members: ::std::vec::Vec<::subxt::utils::AccountId32>, - prime: ::core::option::Option<::subxt::utils::AccountId32>, - old_count: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "TechnicalCommittee", - "set_members", - types::SetMembers { - new_members, - prime, - old_count, - }, - [ - 196u8, 103u8, 123u8, 125u8, 226u8, 177u8, 126u8, 37u8, 160u8, 114u8, - 34u8, 136u8, 219u8, 84u8, 199u8, 94u8, 242u8, 20u8, 126u8, 126u8, - 166u8, 190u8, 198u8, 33u8, 162u8, 113u8, 237u8, 222u8, 90u8, 1u8, 2u8, - 234u8, - ], - ) - } - #[doc = "Dispatch a proposal from a member using the `Member` origin."] - #[doc = ""] - #[doc = "Origin must be a member of the collective."] - #[doc = ""] - #[doc = "## Complexity:"] - #[doc = "- `O(B + M + P)` where:"] - #[doc = "- `B` is `proposal` size in bytes (length-fee-bounded)"] - #[doc = "- `M` members-count (code-bounded)"] - #[doc = "- `P` complexity of dispatching `proposal`"] - pub fn execute( - &self, - proposal: runtime_types::polkadot_runtime::RuntimeCall, - length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "TechnicalCommittee", - "execute", - types::Execute { - proposal: ::std::boxed::Box::new(proposal), - length_bound, - }, - [ - 0u8, 74u8, 70u8, 223u8, 112u8, 196u8, 199u8, 189u8, 93u8, 14u8, 101u8, - 211u8, 221u8, 38u8, 32u8, 220u8, 90u8, 120u8, 94u8, 107u8, 46u8, 121u8, - 250u8, 150u8, 26u8, 24u8, 20u8, 242u8, 253u8, 229u8, 43u8, 195u8, - ], - ) - } - #[doc = "Add a new proposal to either be voted on or executed directly."] - #[doc = ""] - #[doc = "Requires the sender to be member."] - #[doc = ""] - #[doc = "`threshold` determines whether `proposal` is executed directly (`threshold < 2`)"] - #[doc = "or put up for voting."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(B + M + P1)` or `O(B + M + P2)` where:"] - #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] - #[doc = " - `M` is members-count (code- and governance-bounded)"] - #[doc = " - branching is influenced by `threshold` where:"] - #[doc = " - `P1` is proposal execution complexity (`threshold < 2`)"] - #[doc = " - `P2` is proposals-count (code-bounded) (`threshold >= 2`)"] - pub fn propose( + #[doc = "Report voter equivocation/misbehavior. This method will verify the"] + #[doc = "equivocation proof and validate the given key ownership proof"] + #[doc = "against the extracted offender. If both are valid, the offence"] + #[doc = "will be reported."] + pub fn report_equivocation( &self, - threshold: ::core::primitive::u32, - proposal: runtime_types::polkadot_runtime::RuntimeCall, - length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + equivocation_proof: runtime_types::sp_consensus_grandpa::EquivocationProof< + ::subxt::utils::H256, + ::core::primitive::u32, + >, + key_owner_proof: runtime_types::sp_session::MembershipProof, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "TechnicalCommittee", - "propose", - types::Propose { - threshold, - proposal: ::std::boxed::Box::new(proposal), - length_bound, + "Grandpa", + "report_equivocation", + types::ReportEquivocation { + equivocation_proof: ::std::boxed::Box::new(equivocation_proof), + key_owner_proof, }, [ - 157u8, 103u8, 73u8, 75u8, 15u8, 79u8, 50u8, 64u8, 5u8, 151u8, 194u8, - 216u8, 45u8, 47u8, 128u8, 206u8, 191u8, 52u8, 5u8, 104u8, 70u8, 6u8, - 139u8, 184u8, 12u8, 190u8, 109u8, 132u8, 195u8, 177u8, 197u8, 179u8, + 156u8, 162u8, 189u8, 89u8, 60u8, 156u8, 129u8, 176u8, 62u8, 35u8, + 214u8, 7u8, 68u8, 245u8, 130u8, 117u8, 30u8, 3u8, 73u8, 218u8, 142u8, + 82u8, 13u8, 141u8, 124u8, 19u8, 53u8, 138u8, 70u8, 4u8, 40u8, 32u8, ], ) } - #[doc = "Add an aye or nay vote for the sender to the given proposal."] - #[doc = ""] - #[doc = "Requires the sender to be a member."] + #[doc = "Report voter equivocation/misbehavior. This method will verify the"] + #[doc = "equivocation proof and validate the given key ownership proof"] + #[doc = "against the extracted offender. If both are valid, the offence"] + #[doc = "will be reported."] #[doc = ""] - #[doc = "Transaction fees will be waived if the member is voting on any particular proposal"] - #[doc = "for the first time and the call is successful. Subsequent vote changes will charge a"] - #[doc = "fee."] - #[doc = "## Complexity"] - #[doc = "- `O(M)` where `M` is members-count (code- and governance-bounded)"] - pub fn vote( + #[doc = "This extrinsic must be called unsigned and it is expected that only"] + #[doc = "block authors will call it (validated in `ValidateUnsigned`), as such"] + #[doc = "if the block author is defined it will be defined as the equivocation"] + #[doc = "reporter."] + pub fn report_equivocation_unsigned( &self, - proposal: ::subxt::utils::H256, - index: ::core::primitive::u32, - approve: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { + equivocation_proof: runtime_types::sp_consensus_grandpa::EquivocationProof< + ::subxt::utils::H256, + ::core::primitive::u32, + >, + key_owner_proof: runtime_types::sp_session::MembershipProof, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "TechnicalCommittee", - "vote", - types::Vote { - proposal, - index, - approve, + "Grandpa", + "report_equivocation_unsigned", + types::ReportEquivocationUnsigned { + equivocation_proof: ::std::boxed::Box::new(equivocation_proof), + key_owner_proof, }, [ - 108u8, 46u8, 180u8, 148u8, 145u8, 24u8, 173u8, 56u8, 36u8, 100u8, - 216u8, 43u8, 178u8, 202u8, 26u8, 136u8, 93u8, 84u8, 80u8, 134u8, 14u8, - 42u8, 248u8, 205u8, 68u8, 92u8, 79u8, 11u8, 113u8, 115u8, 157u8, 100u8, - ], - ) - } - #[doc = "Disapprove a proposal, close, and remove it from the system, regardless of its current"] - #[doc = "state."] - #[doc = ""] - #[doc = "Must be called by the Root origin."] - #[doc = ""] - #[doc = "Parameters:"] - #[doc = "* `proposal_hash`: The hash of the proposal that should be disapproved."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "O(P) where P is the number of max proposals"] - pub fn disapprove_proposal( - &self, - proposal_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "TechnicalCommittee", - "disapprove_proposal", - types::DisapproveProposal { proposal_hash }, - [ - 25u8, 123u8, 1u8, 8u8, 74u8, 37u8, 3u8, 40u8, 97u8, 37u8, 175u8, 224u8, - 72u8, 155u8, 123u8, 109u8, 104u8, 43u8, 91u8, 125u8, 199u8, 51u8, 17u8, - 225u8, 133u8, 38u8, 120u8, 76u8, 164u8, 5u8, 194u8, 201u8, + 166u8, 26u8, 217u8, 185u8, 215u8, 37u8, 174u8, 170u8, 137u8, 160u8, + 151u8, 43u8, 246u8, 86u8, 58u8, 18u8, 248u8, 73u8, 99u8, 161u8, 158u8, + 93u8, 212u8, 186u8, 224u8, 253u8, 234u8, 18u8, 151u8, 111u8, 227u8, + 249u8, ], ) } - #[doc = "Close a vote that is either approved, disapproved or whose voting period has ended."] - #[doc = ""] - #[doc = "May be called by any signed account in order to finish voting and close the proposal."] - #[doc = ""] - #[doc = "If called before the end of the voting period it will only close the vote if it is"] - #[doc = "has enough votes to be approved or disapproved."] - #[doc = ""] - #[doc = "If called after the end of the voting period abstentions are counted as rejections"] - #[doc = "unless there is a prime member set and the prime member cast an approval."] - #[doc = ""] - #[doc = "If the close operation completes successfully with disapproval, the transaction fee will"] - #[doc = "be waived. Otherwise execution of the approved operation will be charged to the caller."] + #[doc = "Note that the current authority set of the GRANDPA finality gadget has stalled."] #[doc = ""] - #[doc = "+ `proposal_weight_bound`: The maximum amount of weight consumed by executing the closed"] - #[doc = "proposal."] - #[doc = "+ `length_bound`: The upper bound for the length of the proposal in storage. Checked via"] - #[doc = "`storage::read` so it is `size_of::() == 4` larger than the pure length."] + #[doc = "This will trigger a forced authority set change at the beginning of the next session, to"] + #[doc = "be enacted `delay` blocks after that. The `delay` should be high enough to safely assume"] + #[doc = "that the block signalling the forced change will not be re-orged e.g. 1000 blocks."] + #[doc = "The block production rate (which may be slowed down because of finality lagging) should"] + #[doc = "be taken into account when choosing the `delay`. The GRANDPA voters based on the new"] + #[doc = "authority will start voting on top of `best_finalized_block_number` for new finalized"] + #[doc = "blocks. `best_finalized_block_number` should be the highest of the latest finalized"] + #[doc = "block of all validators of the new authority set."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(B + M + P1 + P2)` where:"] - #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] - #[doc = " - `M` is members-count (code- and governance-bounded)"] - #[doc = " - `P1` is the complexity of `proposal` preimage."] - #[doc = " - `P2` is proposal-count (code-bounded)"] - pub fn close( + #[doc = "Only callable by root."] + pub fn note_stalled( &self, - proposal_hash: ::subxt::utils::H256, - index: ::core::primitive::u32, - proposal_weight_bound: runtime_types::sp_weights::weight_v2::Weight, - length_bound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + delay: ::core::primitive::u32, + best_finalized_block_number: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "TechnicalCommittee", - "close", - types::Close { - proposal_hash, - index, - proposal_weight_bound, - length_bound, + "Grandpa", + "note_stalled", + types::NoteStalled { + delay, + best_finalized_block_number, }, [ - 191u8, 138u8, 89u8, 247u8, 97u8, 51u8, 45u8, 193u8, 76u8, 16u8, 80u8, - 225u8, 197u8, 83u8, 204u8, 133u8, 169u8, 16u8, 86u8, 32u8, 125u8, 16u8, - 116u8, 185u8, 45u8, 20u8, 76u8, 148u8, 206u8, 163u8, 154u8, 30u8, + 197u8, 236u8, 137u8, 32u8, 46u8, 200u8, 144u8, 13u8, 89u8, 181u8, + 235u8, 73u8, 167u8, 131u8, 174u8, 93u8, 42u8, 136u8, 238u8, 59u8, + 129u8, 60u8, 83u8, 100u8, 5u8, 182u8, 99u8, 250u8, 145u8, 180u8, 1u8, + 199u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_collective::pallet::Event; + pub type Event = runtime_types::pallet_grandpa::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -12736,95 +11857,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A motion (given hash) has been proposed (by given account) with a threshold (given"] - #[doc = "`MemberCount`)."] - pub struct Proposed { - pub account: ::subxt::utils::AccountId32, - pub proposal_index: ::core::primitive::u32, - pub proposal_hash: ::subxt::utils::H256, - pub threshold: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Proposed { - const PALLET: &'static str = "TechnicalCommittee"; - const EVENT: &'static str = "Proposed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A motion (given hash) has been voted on by given account, leaving"] - #[doc = "a tally (yes votes and no votes given respectively as `MemberCount`)."] - pub struct Voted { - pub account: ::subxt::utils::AccountId32, - pub proposal_hash: ::subxt::utils::H256, - pub voted: ::core::primitive::bool, - pub yes: ::core::primitive::u32, - pub no: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Voted { - const PALLET: &'static str = "TechnicalCommittee"; - const EVENT: &'static str = "Voted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A motion was approved by the required threshold."] - pub struct Approved { - pub proposal_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Approved { - const PALLET: &'static str = "TechnicalCommittee"; - const EVENT: &'static str = "Approved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A motion was not approved by the required threshold."] - pub struct Disapproved { - pub proposal_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Disapproved { - const PALLET: &'static str = "TechnicalCommittee"; - const EVENT: &'static str = "Disapproved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A motion was executed; result will be `Ok` if it returned without error."] - pub struct Executed { - pub proposal_hash: ::subxt::utils::H256, - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + #[doc = "New authority set has been applied."] + pub struct NewAuthorities { + pub authority_set: ::std::vec::Vec<( + runtime_types::sp_consensus_grandpa::app::Public, + ::core::primitive::u64, + )>, } - impl ::subxt::events::StaticEvent for Executed { - const PALLET: &'static str = "TechnicalCommittee"; - const EVENT: &'static str = "Executed"; + impl ::subxt::events::StaticEvent for NewAuthorities { + const PALLET: &'static str = "Grandpa"; + const EVENT: &'static str = "NewAuthorities"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -12836,14 +11878,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A single member did some action; result will be `Ok` if it returned without error."] - pub struct MemberExecuted { - pub proposal_hash: ::subxt::utils::H256, - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for MemberExecuted { - const PALLET: &'static str = "TechnicalCommittee"; - const EVENT: &'static str = "MemberExecuted"; + #[doc = "Current authority set has been paused."] + pub struct Paused; + impl ::subxt::events::StaticEvent for Paused { + const PALLET: &'static str = "Grandpa"; + const EVENT: &'static str = "Paused"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -12855,206 +11894,518 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proposal was closed because its threshold was reached or after its duration was up."] - pub struct Closed { - pub proposal_hash: ::subxt::utils::H256, - pub yes: ::core::primitive::u32, - pub no: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Closed { - const PALLET: &'static str = "TechnicalCommittee"; - const EVENT: &'static str = "Closed"; + #[doc = "Current authority set has been resumed."] + pub struct Resumed; + impl ::subxt::events::StaticEvent for Resumed { + const PALLET: &'static str = "Grandpa"; + const EVENT: &'static str = "Resumed"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " The hashes of the active proposals."] - pub fn proposals( + #[doc = " State of the current authority set."] + pub fn state( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::H256, - >, + runtime_types::pallet_grandpa::StoredState<::core::primitive::u32>, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "TechnicalCommittee", - "Proposals", + "Grandpa", + "State", vec![], [ - 10u8, 133u8, 82u8, 54u8, 193u8, 41u8, 253u8, 159u8, 56u8, 96u8, 249u8, - 148u8, 43u8, 57u8, 116u8, 43u8, 222u8, 243u8, 237u8, 231u8, 238u8, - 60u8, 26u8, 225u8, 19u8, 203u8, 213u8, 220u8, 114u8, 217u8, 100u8, - 27u8, + 211u8, 149u8, 114u8, 217u8, 206u8, 194u8, 115u8, 67u8, 12u8, 218u8, + 246u8, 213u8, 208u8, 29u8, 216u8, 104u8, 2u8, 39u8, 123u8, 172u8, + 252u8, 210u8, 52u8, 129u8, 147u8, 237u8, 244u8, 68u8, 252u8, 169u8, + 97u8, 148u8, ], ) } - #[doc = " Actual proposal for a given hash, if it's current."] - pub fn proposal_of( + #[doc = " Pending change: (signaled at, scheduled change)."] + pub fn pending_change( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime::RuntimeCall, + runtime_types::pallet_grandpa::StoredPendingChange<::core::primitive::u32>, ::subxt::storage::address::Yes, (), - ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "TechnicalCommittee", - "ProposalOf", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Grandpa", + "PendingChange", + vec![], [ - 6u8, 23u8, 244u8, 48u8, 73u8, 203u8, 222u8, 109u8, 218u8, 166u8, 6u8, - 137u8, 121u8, 88u8, 54u8, 188u8, 37u8, 8u8, 229u8, 217u8, 170u8, 108u8, - 198u8, 66u8, 36u8, 92u8, 107u8, 168u8, 162u8, 204u8, 210u8, 20u8, + 178u8, 24u8, 140u8, 7u8, 8u8, 196u8, 18u8, 58u8, 3u8, 226u8, 181u8, + 47u8, 155u8, 160u8, 70u8, 12u8, 75u8, 189u8, 38u8, 255u8, 104u8, 141u8, + 64u8, 34u8, 134u8, 201u8, 102u8, 21u8, 75u8, 81u8, 218u8, 60u8, ], ) } - #[doc = " Actual proposal for a given hash, if it's current."] - pub fn proposal_of_root( + #[doc = " next block number where we can force a change."] + pub fn next_forced( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime::RuntimeCall, + ::core::primitive::u32, + ::subxt::storage::address::Yes, (), (), - ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "TechnicalCommittee", - "ProposalOf", - Vec::new(), + "Grandpa", + "NextForced", + vec![], [ - 6u8, 23u8, 244u8, 48u8, 73u8, 203u8, 222u8, 109u8, 218u8, 166u8, 6u8, - 137u8, 121u8, 88u8, 54u8, 188u8, 37u8, 8u8, 229u8, 217u8, 170u8, 108u8, - 198u8, 66u8, 36u8, 92u8, 107u8, 168u8, 162u8, 204u8, 210u8, 20u8, + 99u8, 43u8, 245u8, 201u8, 60u8, 9u8, 122u8, 99u8, 188u8, 29u8, 67u8, + 6u8, 193u8, 133u8, 179u8, 67u8, 202u8, 208u8, 62u8, 179u8, 19u8, 169u8, + 196u8, 119u8, 107u8, 75u8, 100u8, 3u8, 121u8, 18u8, 80u8, 156u8, ], ) } - #[doc = " Votes on a given proposal, if it is ongoing."] - pub fn voting( + #[doc = " `true` if we are currently stalled."] + pub fn stalled( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_collective::Votes< - ::subxt::utils::AccountId32, - ::core::primitive::u32, - >, + (::core::primitive::u32, ::core::primitive::u32), ::subxt::storage::address::Yes, (), - ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "TechnicalCommittee", - "Voting", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Grandpa", + "Stalled", + vec![], [ - 89u8, 108u8, 65u8, 58u8, 60u8, 116u8, 54u8, 68u8, 179u8, 73u8, 161u8, - 168u8, 78u8, 213u8, 208u8, 54u8, 244u8, 58u8, 70u8, 209u8, 170u8, - 136u8, 215u8, 3u8, 2u8, 105u8, 229u8, 217u8, 240u8, 230u8, 107u8, - 221u8, + 219u8, 8u8, 37u8, 78u8, 150u8, 55u8, 0u8, 57u8, 201u8, 170u8, 186u8, + 189u8, 56u8, 161u8, 44u8, 15u8, 53u8, 178u8, 224u8, 208u8, 231u8, + 109u8, 14u8, 209u8, 57u8, 205u8, 237u8, 153u8, 231u8, 156u8, 24u8, + 185u8, ], ) } - #[doc = " Votes on a given proposal, if it is ongoing."] - pub fn voting_root( + #[doc = " The number of changes (both in terms of keys and underlying economic responsibilities)"] + #[doc = " in the \"set\" of Grandpa validators from genesis."] + pub fn current_set_id( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_collective::Votes< - ::subxt::utils::AccountId32, - ::core::primitive::u32, - >, - (), - (), + ::core::primitive::u64, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "TechnicalCommittee", - "Voting", - Vec::new(), + "Grandpa", + "CurrentSetId", + vec![], [ - 89u8, 108u8, 65u8, 58u8, 60u8, 116u8, 54u8, 68u8, 179u8, 73u8, 161u8, - 168u8, 78u8, 213u8, 208u8, 54u8, 244u8, 58u8, 70u8, 209u8, 170u8, - 136u8, 215u8, 3u8, 2u8, 105u8, 229u8, 217u8, 240u8, 230u8, 107u8, - 221u8, + 129u8, 7u8, 62u8, 101u8, 199u8, 60u8, 56u8, 33u8, 54u8, 158u8, 20u8, + 178u8, 244u8, 145u8, 189u8, 197u8, 157u8, 163u8, 116u8, 36u8, 105u8, + 52u8, 149u8, 244u8, 108u8, 94u8, 109u8, 111u8, 244u8, 137u8, 7u8, + 108u8, ], ) } - #[doc = " Proposals so far."] - pub fn proposal_count( + #[doc = " A mapping from grandpa set ID to the index of the *most recent* session for which its"] + #[doc = " members were responsible."] + #[doc = ""] + #[doc = " This is only used for validating equivocation proofs. An equivocation proof must"] + #[doc = " contains a key-ownership proof for a given session, therefore we need a way to tie"] + #[doc = " together sessions and GRANDPA set ids, i.e. we need to validate that a validator"] + #[doc = " was the owner of a given key on a given session, and what the active set ID was"] + #[doc = " during that session."] + #[doc = ""] + #[doc = " TWOX-NOTE: `SetId` is not under user control."] + pub fn set_id_session( &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u64>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, ::core::primitive::u32, ::subxt::storage::address::Yes, + (), ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Grandpa", + "SetIdSession", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 91u8, 175u8, 145u8, 127u8, 242u8, 81u8, 13u8, 231u8, 110u8, 11u8, + 166u8, 169u8, 103u8, 146u8, 123u8, 133u8, 157u8, 15u8, 33u8, 234u8, + 108u8, 13u8, 88u8, 115u8, 254u8, 9u8, 145u8, 199u8, 102u8, 47u8, 53u8, + 134u8, + ], + ) + } + #[doc = " A mapping from grandpa set ID to the index of the *most recent* session for which its"] + #[doc = " members were responsible."] + #[doc = ""] + #[doc = " This is only used for validating equivocation proofs. An equivocation proof must"] + #[doc = " contains a key-ownership proof for a given session, therefore we need a way to tie"] + #[doc = " together sessions and GRANDPA set ids, i.e. we need to validate that a validator"] + #[doc = " was the owner of a given key on a given session, and what the active set ID was"] + #[doc = " during that session."] + #[doc = ""] + #[doc = " TWOX-NOTE: `SetId` is not under user control."] + pub fn set_id_session_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, (), + (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "TechnicalCommittee", - "ProposalCount", + "Grandpa", + "SetIdSession", + Vec::new(), + [ + 91u8, 175u8, 145u8, 127u8, 242u8, 81u8, 13u8, 231u8, 110u8, 11u8, + 166u8, 169u8, 103u8, 146u8, 123u8, 133u8, 157u8, 15u8, 33u8, 234u8, + 108u8, 13u8, 88u8, 115u8, 254u8, 9u8, 145u8, 199u8, 102u8, 47u8, 53u8, + 134u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " Max Authorities in use"] + pub fn max_authorities( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Grandpa", + "MaxAuthorities", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The maximum number of entries to keep in the set id to session index mapping."] + #[doc = ""] + #[doc = " Since the `SetIdSession` map is only used for validating equivocations this"] + #[doc = " value should relate to the bonding duration of whatever staking system is"] + #[doc = " being used (if any). If equivocation handling is not enabled then this value"] + #[doc = " can be zero."] + pub fn max_set_id_session_entries( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u64> { + ::subxt::constants::Address::new_static( + "Grandpa", + "MaxSetIdSessionEntries", + [ + 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, + 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, + 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, + 246u8, + ], + ) + } + } + } + } + pub mod im_online { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_im_online::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Heartbeat { + pub heartbeat: + runtime_types::pallet_im_online::Heartbeat<::core::primitive::u32>, + pub signature: runtime_types::pallet_im_online::sr25519::app_sr25519::Signature, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "## Complexity:"] + #[doc = "- `O(K + E)` where K is length of `Keys` (heartbeat.validators_len) and E is length of"] + #[doc = " `heartbeat.network_state.external_address`"] + #[doc = " - `O(K)`: decoding of length `K`"] + #[doc = " - `O(E)`: decoding/encoding of length `E`"] + pub fn heartbeat( + &self, + heartbeat: runtime_types::pallet_im_online::Heartbeat<::core::primitive::u32>, + signature: runtime_types::pallet_im_online::sr25519::app_sr25519::Signature, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ImOnline", + "heartbeat", + types::Heartbeat { + heartbeat, + signature, + }, + [ + 212u8, 23u8, 174u8, 246u8, 60u8, 220u8, 178u8, 137u8, 53u8, 146u8, + 165u8, 225u8, 179u8, 209u8, 233u8, 152u8, 129u8, 210u8, 126u8, 32u8, + 216u8, 22u8, 76u8, 196u8, 255u8, 128u8, 246u8, 161u8, 30u8, 186u8, + 249u8, 34u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_im_online::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new heartbeat was received from `AuthorityId`."] + pub struct HeartbeatReceived { + pub authority_id: runtime_types::pallet_im_online::sr25519::app_sr25519::Public, + } + impl ::subxt::events::StaticEvent for HeartbeatReceived { + const PALLET: &'static str = "ImOnline"; + const EVENT: &'static str = "HeartbeatReceived"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "At the end of the session, no offence was committed."] + pub struct AllGood; + impl ::subxt::events::StaticEvent for AllGood { + const PALLET: &'static str = "ImOnline"; + const EVENT: &'static str = "AllGood"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "At the end of the session, at least one validator was found to be offline."] + pub struct SomeOffline { + pub offline: ::std::vec::Vec<( + ::subxt::utils::AccountId32, + runtime_types::pallet_staking::Exposure< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + )>, + } + impl ::subxt::events::StaticEvent for SomeOffline { + const PALLET: &'static str = "ImOnline"; + const EVENT: &'static str = "SomeOffline"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The block number after which it's ok to send heartbeats in the current"] + #[doc = " session."] + #[doc = ""] + #[doc = " At the beginning of each session we set this to a value that should fall"] + #[doc = " roughly in the middle of the session duration. The idea is to first wait for"] + #[doc = " the validators to produce a block in the current session, so that the"] + #[doc = " heartbeat later on will not be necessary."] + #[doc = ""] + #[doc = " This value will only be used as a fallback if we fail to get a proper session"] + #[doc = " progress estimate from `NextSessionRotation`, as those estimates should be"] + #[doc = " more accurate then the value we calculate for `HeartbeatAfter`."] + pub fn heartbeat_after( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ImOnline", + "HeartbeatAfter", vec![], [ - 132u8, 145u8, 78u8, 218u8, 51u8, 189u8, 55u8, 172u8, 143u8, 33u8, - 140u8, 99u8, 124u8, 208u8, 57u8, 232u8, 154u8, 110u8, 32u8, 142u8, - 24u8, 149u8, 109u8, 105u8, 30u8, 83u8, 39u8, 177u8, 127u8, 160u8, 34u8, - 70u8, + 108u8, 100u8, 85u8, 198u8, 226u8, 122u8, 94u8, 225u8, 97u8, 154u8, + 135u8, 95u8, 106u8, 28u8, 185u8, 78u8, 192u8, 196u8, 35u8, 191u8, 12u8, + 19u8, 163u8, 46u8, 232u8, 235u8, 193u8, 81u8, 126u8, 204u8, 25u8, + 228u8, ], ) } - #[doc = " The current members of the collective. This is stored sorted (just by value)."] - pub fn members( + #[doc = " The current set of keys that may issue a heartbeat."] + pub fn keys( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::AccountId32>, + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + runtime_types::pallet_im_online::sr25519::app_sr25519::Public, + >, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "TechnicalCommittee", - "Members", + "ImOnline", + "Keys", vec![], [ - 162u8, 72u8, 174u8, 204u8, 140u8, 105u8, 205u8, 176u8, 197u8, 117u8, - 206u8, 134u8, 157u8, 110u8, 139u8, 54u8, 43u8, 233u8, 25u8, 51u8, 36u8, - 238u8, 94u8, 124u8, 221u8, 52u8, 237u8, 71u8, 125u8, 56u8, 129u8, - 222u8, + 6u8, 198u8, 221u8, 58u8, 14u8, 166u8, 245u8, 103u8, 191u8, 20u8, 69u8, + 233u8, 147u8, 245u8, 24u8, 64u8, 207u8, 180u8, 39u8, 208u8, 252u8, + 236u8, 247u8, 112u8, 187u8, 97u8, 70u8, 11u8, 248u8, 148u8, 208u8, + 106u8, ], ) } - #[doc = " The prime member that helps determine the default vote behavior in case of absentations."] - pub fn prime( + #[doc = " For each session index, we keep a mapping of `SessionIndex` and `AuthIndex` to"] + #[doc = " `WrapperOpaque`."] + pub fn received_heartbeats( &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, + runtime_types::frame_support::traits::misc::WrapperOpaque< + runtime_types::pallet_im_online::BoundedOpaqueNetworkState, + >, + ::subxt::storage::address::Yes, + (), ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ImOnline", + "ReceivedHeartbeats", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 233u8, 128u8, 140u8, 233u8, 55u8, 146u8, 172u8, 54u8, 54u8, 57u8, + 141u8, 106u8, 168u8, 59u8, 147u8, 253u8, 119u8, 48u8, 50u8, 251u8, + 242u8, 109u8, 251u8, 2u8, 136u8, 80u8, 146u8, 121u8, 180u8, 219u8, + 245u8, 37u8, + ], + ) + } + #[doc = " For each session index, we keep a mapping of `SessionIndex` and `AuthIndex` to"] + #[doc = " `WrapperOpaque`."] + pub fn received_heartbeats_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::frame_support::traits::misc::WrapperOpaque< + runtime_types::pallet_im_online::BoundedOpaqueNetworkState, + >, (), (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "TechnicalCommittee", - "Prime", - vec![], + "ImOnline", + "ReceivedHeartbeats", + Vec::new(), [ - 108u8, 118u8, 54u8, 193u8, 207u8, 227u8, 119u8, 97u8, 23u8, 239u8, - 157u8, 69u8, 56u8, 142u8, 106u8, 17u8, 215u8, 159u8, 48u8, 42u8, 185u8, - 209u8, 49u8, 159u8, 32u8, 168u8, 111u8, 158u8, 159u8, 217u8, 244u8, - 158u8, + 233u8, 128u8, 140u8, 233u8, 55u8, 146u8, 172u8, 54u8, 54u8, 57u8, + 141u8, 106u8, 168u8, 59u8, 147u8, 253u8, 119u8, 48u8, 50u8, 251u8, + 242u8, 109u8, 251u8, 2u8, 136u8, 80u8, 146u8, 121u8, 180u8, 219u8, + 245u8, 37u8, + ], + ) + } + #[doc = " For each session index, we keep a mapping of `ValidatorId` to the"] + #[doc = " number of blocks authored by the given authority."] + pub fn authored_blocks( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ImOnline", + "AuthoredBlocks", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 50u8, 4u8, 242u8, 240u8, 247u8, 184u8, 114u8, 245u8, 233u8, 170u8, + 24u8, 197u8, 18u8, 245u8, 8u8, 28u8, 33u8, 115u8, 166u8, 245u8, 221u8, + 223u8, 56u8, 144u8, 33u8, 139u8, 10u8, 227u8, 228u8, 223u8, 103u8, + 151u8, + ], + ) + } + #[doc = " For each session index, we keep a mapping of `ValidatorId` to the"] + #[doc = " number of blocks authored by the given authority."] + pub fn authored_blocks_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ImOnline", + "AuthoredBlocks", + Vec::new(), + [ + 50u8, 4u8, 242u8, 240u8, 247u8, 184u8, 114u8, 245u8, 233u8, 170u8, + 24u8, 197u8, 18u8, 245u8, 8u8, 28u8, 33u8, 115u8, 166u8, 245u8, 221u8, + 223u8, 56u8, 144u8, 33u8, 139u8, 10u8, 227u8, 228u8, 223u8, 103u8, + 151u8, ], ) } @@ -13064,30 +12415,36 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " The maximum weight of a dispatch call that can be proposed and executed."] - pub fn max_proposal_weight( + #[doc = " A configuration for base priority of unsigned transactions."] + #[doc = ""] + #[doc = " This is exposed so that it can be tuned for particular runtime, when"] + #[doc = " multiple pallets send unsigned transactions."] + pub fn unsigned_priority( &self, - ) -> ::subxt::constants::Address - { + ) -> ::subxt::constants::Address<::core::primitive::u64> { ::subxt::constants::Address::new_static( - "TechnicalCommittee", - "MaxProposalWeight", + "ImOnline", + "UnsignedPriority", [ - 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, - 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, - 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, - 106u8, 76u8, + 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, + 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, + 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, + 246u8, ], ) } } } } - pub mod phragmen_election { + pub mod authority_discovery { + use super::root_mod; + use super::runtime_types; + } + pub mod democracy { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_elections_phragmen::pallet::Error; + pub type Error = runtime_types::pallet_democracy::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -13105,8 +12462,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vote { - pub votes: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub struct Propose { + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, #[codec(compact)] pub value: ::core::primitive::u128, } @@ -13120,7 +12479,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveVoter; + pub struct Second { + #[codec(compact)] + pub proposal: ::core::primitive::u32, + } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -13131,11 +12493,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SubmitCandidacy { + pub struct Vote { #[codec(compact)] - pub candidate_count: ::core::primitive::u32, + pub ref_index: ::core::primitive::u32, + pub vote: + runtime_types::pallet_democracy::vote::AccountVote<::core::primitive::u128>, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -13145,8 +12510,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RenounceCandidacy { - pub renouncing: runtime_types::pallet_elections_phragmen::Renouncing, + pub struct EmergencyCancel { + pub ref_index: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -13158,10 +12523,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveMember { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub slash_bond: ::core::primitive::bool, - pub rerun_election: ::core::primitive::bool, + pub struct ExternalPropose { + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -13173,916 +12538,729 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CleanDefunctVoters { - pub num_voters: ::core::primitive::u32, - pub num_defunct: ::core::primitive::u32, + pub struct ExternalProposeMajority { + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Vote for a set of candidates for the upcoming round of election. This can be called to"] - #[doc = "set the initial votes, or update already existing votes."] - #[doc = ""] - #[doc = "Upon initial voting, `value` units of `who`'s balance is locked and a deposit amount is"] - #[doc = "reserved. The deposit is based on the number of votes and can be updated over time."] - #[doc = ""] - #[doc = "The `votes` should:"] - #[doc = " - not be empty."] - #[doc = " - be less than the number of possible candidates. Note that all current members and"] - #[doc = " runners-up are also automatically candidates for the next round."] - #[doc = ""] - #[doc = "If `value` is more than `who`'s free balance, then the maximum of the two is used."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be signed."] - #[doc = ""] - #[doc = "### Warning"] - #[doc = ""] - #[doc = "It is the responsibility of the caller to **NOT** place all of their balance into the"] - #[doc = "lock and keep some for further operations."] - pub fn vote( - &self, - votes: ::std::vec::Vec<::subxt::utils::AccountId32>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PhragmenElection", - "vote", - types::Vote { votes, value }, - [ - 71u8, 90u8, 175u8, 225u8, 51u8, 202u8, 197u8, 252u8, 183u8, 92u8, - 239u8, 83u8, 112u8, 144u8, 128u8, 211u8, 109u8, 33u8, 252u8, 6u8, - 156u8, 15u8, 91u8, 88u8, 70u8, 19u8, 32u8, 29u8, 224u8, 255u8, 26u8, - 145u8, - ], - ) + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ExternalProposeDefault { + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, } - #[doc = "Remove `origin` as a voter."] - #[doc = ""] - #[doc = "This removes the lock and returns the deposit."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be signed and be a voter."] - pub fn remove_voter(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PhragmenElection", - "remove_voter", - types::RemoveVoter {}, - [ - 254u8, 46u8, 140u8, 4u8, 218u8, 45u8, 150u8, 72u8, 67u8, 131u8, 108u8, - 201u8, 46u8, 157u8, 104u8, 161u8, 53u8, 155u8, 130u8, 50u8, 88u8, - 149u8, 255u8, 12u8, 17u8, 85u8, 95u8, 69u8, 153u8, 130u8, 221u8, 1u8, + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct FastTrack { + pub proposal_hash: ::subxt::utils::H256, + pub voting_period: ::core::primitive::u32, + pub delay: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct VetoExternal { + pub proposal_hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelReferendum { + #[codec(compact)] + pub ref_index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Delegate { + pub to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub conviction: runtime_types::pallet_democracy::conviction::Conviction, + pub balance: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Undelegate; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClearPublicProposals; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Unlock { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveVote { + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveOtherVote { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Blacklist { + pub proposal_hash: ::subxt::utils::H256, + pub maybe_ref_index: ::core::option::Option<::core::primitive::u32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelProposal { + #[codec(compact)] + pub prop_index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMetadata { + pub owner: runtime_types::pallet_democracy::types::MetadataOwner, + pub maybe_hash: ::core::option::Option<::subxt::utils::H256>, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Propose a sensitive action to be taken."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be _Signed_ and the sender must"] + #[doc = "have funds to cover the deposit."] + #[doc = ""] + #[doc = "- `proposal_hash`: The hash of the proposal preimage."] + #[doc = "- `value`: The amount of deposit (must be at least `MinimumDeposit`)."] + #[doc = ""] + #[doc = "Emits `Proposed`."] + pub fn propose( + &self, + proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "propose", + types::Propose { proposal, value }, + [ + 123u8, 3u8, 204u8, 140u8, 194u8, 195u8, 214u8, 39u8, 167u8, 126u8, + 45u8, 4u8, 219u8, 17u8, 143u8, 185u8, 29u8, 224u8, 230u8, 68u8, 253u8, + 15u8, 170u8, 90u8, 232u8, 123u8, 46u8, 255u8, 168u8, 39u8, 204u8, 63u8, ], ) } - #[doc = "Submit oneself for candidacy. A fixed amount of deposit is recorded."] + #[doc = "Signals agreement with a particular proposal."] #[doc = ""] - #[doc = "All candidates are wiped at the end of the term. They either become a member/runner-up,"] - #[doc = "or leave the system while their deposit is slashed."] + #[doc = "The dispatch origin of this call must be _Signed_ and the sender"] + #[doc = "must have funds to cover the deposit, equal to the original deposit."] #[doc = ""] - #[doc = "The dispatch origin of this call must be signed."] + #[doc = "- `proposal`: The index of the proposal to second."] + pub fn second( + &self, + proposal: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "second", + types::Second { proposal }, + [ + 59u8, 240u8, 183u8, 218u8, 61u8, 93u8, 184u8, 67u8, 10u8, 4u8, 138u8, + 196u8, 168u8, 49u8, 42u8, 69u8, 154u8, 42u8, 90u8, 112u8, 179u8, 69u8, + 51u8, 148u8, 159u8, 212u8, 221u8, 226u8, 132u8, 228u8, 51u8, 83u8, + ], + ) + } + #[doc = "Vote in a referendum. If `vote.is_aye()`, the vote is to enact the proposal;"] + #[doc = "otherwise it is a vote to keep the status quo."] #[doc = ""] - #[doc = "### Warning"] + #[doc = "The dispatch origin of this call must be _Signed_."] #[doc = ""] - #[doc = "Even if a candidate ends up being a member, they must call [`Call::renounce_candidacy`]"] - #[doc = "to get their deposit back. Losing the spot in an election will always lead to a slash."] + #[doc = "- `ref_index`: The index of the referendum to vote for."] + #[doc = "- `vote`: The vote configuration."] + pub fn vote( + &self, + ref_index: ::core::primitive::u32, + vote: runtime_types::pallet_democracy::vote::AccountVote< + ::core::primitive::u128, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "vote", + types::Vote { ref_index, vote }, + [ + 138u8, 213u8, 229u8, 111u8, 1u8, 191u8, 73u8, 3u8, 145u8, 28u8, 44u8, + 88u8, 163u8, 188u8, 129u8, 188u8, 64u8, 15u8, 64u8, 103u8, 250u8, 97u8, + 234u8, 188u8, 29u8, 205u8, 51u8, 6u8, 116u8, 58u8, 156u8, 201u8, + ], + ) + } + #[doc = "Schedule an emergency cancellation of a referendum. Cannot happen twice to the same"] + #[doc = "referendum."] #[doc = ""] - #[doc = "The number of current candidates must be provided as witness data."] - #[doc = "## Complexity"] - #[doc = "O(C + log(C)) where C is candidate_count."] - pub fn submit_candidacy( + #[doc = "The dispatch origin of this call must be `CancellationOrigin`."] + #[doc = ""] + #[doc = "-`ref_index`: The index of the referendum to cancel."] + #[doc = ""] + #[doc = "Weight: `O(1)`."] + pub fn emergency_cancel( &self, - candidate_count: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + ref_index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "PhragmenElection", - "submit_candidacy", - types::SubmitCandidacy { candidate_count }, + "Democracy", + "emergency_cancel", + types::EmergencyCancel { ref_index }, [ - 228u8, 63u8, 217u8, 99u8, 128u8, 104u8, 175u8, 10u8, 30u8, 35u8, 47u8, - 14u8, 254u8, 122u8, 146u8, 239u8, 61u8, 145u8, 82u8, 7u8, 181u8, 98u8, - 238u8, 208u8, 23u8, 84u8, 48u8, 255u8, 177u8, 255u8, 84u8, 83u8, + 139u8, 213u8, 133u8, 75u8, 34u8, 206u8, 124u8, 245u8, 35u8, 237u8, + 132u8, 92u8, 49u8, 167u8, 117u8, 80u8, 188u8, 93u8, 198u8, 237u8, + 132u8, 77u8, 195u8, 65u8, 29u8, 37u8, 86u8, 74u8, 214u8, 119u8, 71u8, + 204u8, ], ) } - #[doc = "Renounce one's intention to be a candidate for the next election round. 3 potential"] - #[doc = "outcomes exist:"] + #[doc = "Schedule a referendum to be tabled once it is legal to schedule an external"] + #[doc = "referendum."] #[doc = ""] - #[doc = "- `origin` is a candidate and not elected in any set. In this case, the deposit is"] - #[doc = " unreserved, returned and origin is removed as a candidate."] - #[doc = "- `origin` is a current runner-up. In this case, the deposit is unreserved, returned and"] - #[doc = " origin is removed as a runner-up."] - #[doc = "- `origin` is a current member. In this case, the deposit is unreserved and origin is"] - #[doc = " removed as a member, consequently not being a candidate for the next round anymore."] - #[doc = " Similar to [`remove_member`](Self::remove_member), if replacement runners exists, they"] - #[doc = " are immediately used. If the prime is renouncing, then no prime will exist until the"] - #[doc = " next round."] + #[doc = "The dispatch origin of this call must be `ExternalOrigin`."] #[doc = ""] - #[doc = "The dispatch origin of this call must be signed, and have one of the above roles."] - #[doc = "The type of renouncing must be provided as witness data."] + #[doc = "- `proposal_hash`: The preimage hash of the proposal."] + pub fn external_propose( + &self, + proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "external_propose", + types::ExternalPropose { proposal }, + [ + 164u8, 193u8, 14u8, 122u8, 105u8, 232u8, 20u8, 194u8, 99u8, 227u8, + 36u8, 105u8, 218u8, 146u8, 16u8, 208u8, 56u8, 62u8, 100u8, 65u8, 35u8, + 33u8, 51u8, 208u8, 17u8, 43u8, 223u8, 198u8, 202u8, 16u8, 56u8, 75u8, + ], + ) + } + #[doc = "Schedule a majority-carries referendum to be tabled next once it is legal to schedule"] + #[doc = "an external referendum."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = " - Renouncing::Candidate(count): O(count + log(count))"] - #[doc = " - Renouncing::Member: O(1)"] - #[doc = " - Renouncing::RunnerUp: O(1)"] - pub fn renounce_candidacy( + #[doc = "The dispatch of this call must be `ExternalMajorityOrigin`."] + #[doc = ""] + #[doc = "- `proposal_hash`: The preimage hash of the proposal."] + #[doc = ""] + #[doc = "Unlike `external_propose`, blacklisting has no effect on this and it may replace a"] + #[doc = "pre-scheduled `external_propose` call."] + #[doc = ""] + #[doc = "Weight: `O(1)`"] + pub fn external_propose_majority( &self, - renouncing: runtime_types::pallet_elections_phragmen::Renouncing, - ) -> ::subxt::tx::Payload { + proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "PhragmenElection", - "renounce_candidacy", - types::RenounceCandidacy { renouncing }, + "Democracy", + "external_propose_majority", + types::ExternalProposeMajority { proposal }, [ - 70u8, 72u8, 208u8, 36u8, 80u8, 245u8, 224u8, 75u8, 60u8, 142u8, 19u8, - 49u8, 142u8, 90u8, 14u8, 69u8, 15u8, 61u8, 170u8, 235u8, 16u8, 252u8, - 86u8, 200u8, 120u8, 127u8, 36u8, 42u8, 143u8, 130u8, 217u8, 128u8, + 129u8, 124u8, 147u8, 253u8, 69u8, 115u8, 230u8, 186u8, 155u8, 4u8, + 220u8, 103u8, 28u8, 132u8, 115u8, 153u8, 196u8, 88u8, 9u8, 130u8, + 129u8, 234u8, 75u8, 96u8, 202u8, 216u8, 145u8, 189u8, 231u8, 101u8, + 127u8, 11u8, ], ) } - #[doc = "Remove a particular member from the set. This is effective immediately and the bond of"] - #[doc = "the outgoing member is slashed."] + #[doc = "Schedule a negative-turnout-bias referendum to be tabled next once it is legal to"] + #[doc = "schedule an external referendum."] #[doc = ""] - #[doc = "If a runner-up is available, then the best runner-up will be removed and replaces the"] - #[doc = "outgoing member. Otherwise, if `rerun_election` is `true`, a new phragmen election is"] - #[doc = "started, else, nothing happens."] + #[doc = "The dispatch of this call must be `ExternalDefaultOrigin`."] #[doc = ""] - #[doc = "If `slash_bond` is set to true, the bond of the member being removed is slashed. Else,"] - #[doc = "it is returned."] + #[doc = "- `proposal_hash`: The preimage hash of the proposal."] #[doc = ""] - #[doc = "The dispatch origin of this call must be root."] + #[doc = "Unlike `external_propose`, blacklisting has no effect on this and it may replace a"] + #[doc = "pre-scheduled `external_propose` call."] #[doc = ""] - #[doc = "Note that this does not affect the designated block number of the next election."] + #[doc = "Weight: `O(1)`"] + pub fn external_propose_default( + &self, + proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "external_propose_default", + types::ExternalProposeDefault { proposal }, + [ + 96u8, 15u8, 108u8, 208u8, 141u8, 247u8, 4u8, 73u8, 2u8, 30u8, 231u8, + 40u8, 184u8, 250u8, 42u8, 161u8, 248u8, 45u8, 217u8, 50u8, 53u8, 13u8, + 181u8, 214u8, 136u8, 51u8, 93u8, 95u8, 165u8, 3u8, 83u8, 190u8, + ], + ) + } + #[doc = "Schedule the currently externally-proposed majority-carries referendum to be tabled"] + #[doc = "immediately. If there is no externally-proposed referendum currently, or if there is one"] + #[doc = "but it is not a majority-carries referendum then it fails."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- Check details of remove_and_replace_member() and do_phragmen()."] - pub fn remove_member( + #[doc = "The dispatch of this call must be `FastTrackOrigin`."] + #[doc = ""] + #[doc = "- `proposal_hash`: The hash of the current external proposal."] + #[doc = "- `voting_period`: The period that is allowed for voting on this proposal. Increased to"] + #[doc = "\tMust be always greater than zero."] + #[doc = "\tFor `FastTrackOrigin` must be equal or greater than `FastTrackVotingPeriod`."] + #[doc = "- `delay`: The number of block after voting has ended in approval and this should be"] + #[doc = " enacted. This doesn't have a minimum amount."] + #[doc = ""] + #[doc = "Emits `Started`."] + #[doc = ""] + #[doc = "Weight: `O(1)`"] + pub fn fast_track( &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - slash_bond: ::core::primitive::bool, - rerun_election: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { + proposal_hash: ::subxt::utils::H256, + voting_period: ::core::primitive::u32, + delay: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "PhragmenElection", - "remove_member", - types::RemoveMember { - who, - slash_bond, - rerun_election, + "Democracy", + "fast_track", + types::FastTrack { + proposal_hash, + voting_period, + delay, }, [ - 45u8, 106u8, 9u8, 19u8, 133u8, 38u8, 20u8, 233u8, 12u8, 169u8, 216u8, - 40u8, 23u8, 139u8, 184u8, 202u8, 2u8, 124u8, 202u8, 48u8, 205u8, 176u8, - 161u8, 43u8, 66u8, 24u8, 189u8, 183u8, 233u8, 62u8, 102u8, 237u8, + 125u8, 209u8, 107u8, 120u8, 93u8, 205u8, 129u8, 147u8, 254u8, 126u8, + 45u8, 126u8, 39u8, 0u8, 56u8, 14u8, 233u8, 49u8, 245u8, 220u8, 156u8, + 10u8, 252u8, 31u8, 102u8, 90u8, 163u8, 236u8, 178u8, 85u8, 13u8, 24u8, ], ) } - #[doc = "Clean all voters who are defunct (i.e. they do not serve any purpose at all). The"] - #[doc = "deposit of the removed voters are returned."] + #[doc = "Veto and blacklist the external proposal hash."] #[doc = ""] - #[doc = "This is an root function to be used only for cleaning the state."] + #[doc = "The dispatch origin of this call must be `VetoOrigin`."] #[doc = ""] - #[doc = "The dispatch origin of this call must be root."] + #[doc = "- `proposal_hash`: The preimage hash of the proposal to veto and blacklist."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- Check is_defunct_voter() details."] - pub fn clean_defunct_voters( + #[doc = "Emits `Vetoed`."] + #[doc = ""] + #[doc = "Weight: `O(V + log(V))` where V is number of `existing vetoers`"] + pub fn veto_external( &self, - num_voters: ::core::primitive::u32, - num_defunct: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + proposal_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "PhragmenElection", - "clean_defunct_voters", - types::CleanDefunctVoters { - num_voters, - num_defunct, - }, + "Democracy", + "veto_external", + types::VetoExternal { proposal_hash }, [ - 198u8, 162u8, 30u8, 249u8, 191u8, 38u8, 141u8, 123u8, 230u8, 90u8, - 213u8, 103u8, 168u8, 28u8, 5u8, 215u8, 213u8, 152u8, 46u8, 189u8, - 238u8, 209u8, 209u8, 142u8, 159u8, 222u8, 161u8, 26u8, 161u8, 250u8, - 9u8, 100u8, + 209u8, 18u8, 18u8, 103u8, 186u8, 160u8, 214u8, 124u8, 150u8, 207u8, + 112u8, 90u8, 84u8, 197u8, 95u8, 157u8, 165u8, 65u8, 109u8, 101u8, 75u8, + 201u8, 41u8, 149u8, 75u8, 154u8, 37u8, 178u8, 239u8, 121u8, 124u8, + 23u8, ], ) } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_elections_phragmen::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new term with new_members. This indicates that enough candidates existed to run"] - #[doc = "the election, not that enough have has been elected. The inner value must be examined"] - #[doc = "for this purpose. A `NewTerm(\\[\\])` indicates that some candidates got their bond"] - #[doc = "slashed and none were elected, whilst `EmptyTerm` means that no candidates existed to"] - #[doc = "begin with."] - pub struct NewTerm { - pub new_members: - ::std::vec::Vec<(::subxt::utils::AccountId32, ::core::primitive::u128)>, - } - impl ::subxt::events::StaticEvent for NewTerm { - const PALLET: &'static str = "PhragmenElection"; - const EVENT: &'static str = "NewTerm"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "No (or not enough) candidates existed for this round. This is different from"] - #[doc = "`NewTerm(\\[\\])`. See the description of `NewTerm`."] - pub struct EmptyTerm; - impl ::subxt::events::StaticEvent for EmptyTerm { - const PALLET: &'static str = "PhragmenElection"; - const EVENT: &'static str = "EmptyTerm"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Internal error happened while trying to perform election."] - pub struct ElectionError; - impl ::subxt::events::StaticEvent for ElectionError { - const PALLET: &'static str = "PhragmenElection"; - const EVENT: &'static str = "ElectionError"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A member has been removed. This should always be followed by either `NewTerm` or"] - #[doc = "`EmptyTerm`."] - pub struct MemberKicked { - pub member: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for MemberKicked { - const PALLET: &'static str = "PhragmenElection"; - const EVENT: &'static str = "MemberKicked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Someone has renounced their candidacy."] - pub struct Renounced { - pub candidate: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Renounced { - const PALLET: &'static str = "PhragmenElection"; - const EVENT: &'static str = "Renounced"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A candidate was slashed by amount due to failing to obtain a seat as member or"] - #[doc = "runner-up."] - #[doc = ""] - #[doc = "Note that old members and runners-up are also candidates."] - pub struct CandidateSlashed { - pub candidate: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for CandidateSlashed { - const PALLET: &'static str = "PhragmenElection"; - const EVENT: &'static str = "CandidateSlashed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A seat holder was slashed by amount by being forcefully removed from the set."] - pub struct SeatHolderSlashed { - pub seat_holder: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for SeatHolderSlashed { - const PALLET: &'static str = "PhragmenElection"; - const EVENT: &'static str = "SeatHolderSlashed"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The current elected members."] + #[doc = "Remove a referendum."] #[doc = ""] - #[doc = " Invariant: Always sorted based on account id."] - pub fn members( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::pallet_elections_phragmen::SeatHolder< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "PhragmenElection", - "Members", - vec![], - [ - 2u8, 182u8, 43u8, 180u8, 87u8, 185u8, 26u8, 79u8, 196u8, 55u8, 28u8, - 26u8, 174u8, 133u8, 158u8, 221u8, 101u8, 161u8, 83u8, 9u8, 221u8, - 175u8, 221u8, 220u8, 81u8, 80u8, 1u8, 236u8, 74u8, 121u8, 10u8, 82u8, - ], - ) - } - #[doc = " The current reserved runners-up."] + #[doc = "The dispatch origin of this call must be _Root_."] #[doc = ""] - #[doc = " Invariant: Always sorted based on rank (worse to best). Upon removal of a member, the"] - #[doc = " last (i.e. _best_) runner-up will be replaced."] - pub fn runners_up( + #[doc = "- `ref_index`: The index of the referendum to cancel."] + #[doc = ""] + #[doc = "# Weight: `O(1)`."] + pub fn cancel_referendum( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::pallet_elections_phragmen::SeatHolder< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "PhragmenElection", - "RunnersUp", - vec![], + ref_index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "cancel_referendum", + types::CancelReferendum { ref_index }, [ - 248u8, 81u8, 190u8, 53u8, 121u8, 49u8, 55u8, 69u8, 116u8, 177u8, 46u8, - 30u8, 131u8, 14u8, 32u8, 198u8, 10u8, 132u8, 73u8, 117u8, 2u8, 146u8, - 188u8, 146u8, 214u8, 227u8, 97u8, 77u8, 7u8, 131u8, 208u8, 209u8, + 51u8, 25u8, 25u8, 251u8, 236u8, 115u8, 130u8, 230u8, 72u8, 186u8, + 119u8, 71u8, 165u8, 137u8, 55u8, 167u8, 187u8, 128u8, 55u8, 8u8, 212u8, + 139u8, 245u8, 232u8, 103u8, 136u8, 229u8, 113u8, 125u8, 36u8, 1u8, + 149u8, ], ) } - #[doc = " The present candidate list. A current member or runner-up can never enter this vector"] - #[doc = " and is always implicitly assumed to be a candidate."] + #[doc = "Delegate the voting power (with some given conviction) of the sending account."] #[doc = ""] - #[doc = " Second element is the deposit."] + #[doc = "The balance delegated is locked for as long as it's delegated, and thereafter for the"] + #[doc = "time appropriate for the conviction's lock period."] #[doc = ""] - #[doc = " Invariant: Always sorted based on account id."] - pub fn candidates( + #[doc = "The dispatch origin of this call must be _Signed_, and the signing account must either:"] + #[doc = " - be delegating already; or"] + #[doc = " - have no voting activity (if there is, then it will need to be removed/consolidated"] + #[doc = " through `reap_vote` or `unvote`)."] + #[doc = ""] + #[doc = "- `to`: The account whose voting the `target` account's voting power will follow."] + #[doc = "- `conviction`: The conviction that will be attached to the delegated votes. When the"] + #[doc = " account is undelegated, the funds will be locked for the corresponding period."] + #[doc = "- `balance`: The amount of the account's balance to be used in delegating. This must not"] + #[doc = " be more than the account's current balance."] + #[doc = ""] + #[doc = "Emits `Delegated`."] + #[doc = ""] + #[doc = "Weight: `O(R)` where R is the number of referendums the voter delegating to has"] + #[doc = " voted on. Weight is charged as if maximum votes."] + pub fn delegate( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<(::subxt::utils::AccountId32, ::core::primitive::u128)>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "PhragmenElection", - "Candidates", - vec![], + to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + conviction: runtime_types::pallet_democracy::conviction::Conviction, + balance: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "delegate", + types::Delegate { + to, + conviction, + balance, + }, [ - 224u8, 107u8, 141u8, 11u8, 54u8, 86u8, 117u8, 45u8, 195u8, 252u8, - 152u8, 21u8, 165u8, 23u8, 198u8, 117u8, 5u8, 216u8, 183u8, 163u8, - 243u8, 56u8, 11u8, 102u8, 85u8, 107u8, 219u8, 250u8, 45u8, 80u8, 108u8, - 127u8, + 22u8, 205u8, 202u8, 196u8, 63u8, 1u8, 196u8, 109u8, 4u8, 190u8, 38u8, + 142u8, 248u8, 200u8, 136u8, 12u8, 194u8, 170u8, 237u8, 176u8, 70u8, + 21u8, 112u8, 154u8, 93u8, 169u8, 211u8, 120u8, 156u8, 68u8, 14u8, + 231u8, ], ) } - #[doc = " The total number of vote rounds that have happened, excluding the upcoming one."] - pub fn election_rounds( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "PhragmenElection", - "ElectionRounds", - vec![], + #[doc = "Undelegate the voting power of the sending account."] + #[doc = ""] + #[doc = "Tokens may be unlocked following once an amount of time consistent with the lock period"] + #[doc = "of the conviction with which the delegation was issued."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be _Signed_ and the signing account must be"] + #[doc = "currently delegating."] + #[doc = ""] + #[doc = "Emits `Undelegated`."] + #[doc = ""] + #[doc = "Weight: `O(R)` where R is the number of referendums the voter delegating to has"] + #[doc = " voted on. Weight is charged as if maximum votes."] + pub fn undelegate(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "undelegate", + types::Undelegate {}, [ - 144u8, 146u8, 10u8, 32u8, 149u8, 147u8, 59u8, 205u8, 61u8, 246u8, 28u8, - 169u8, 130u8, 136u8, 143u8, 104u8, 253u8, 86u8, 228u8, 68u8, 19u8, - 184u8, 166u8, 214u8, 58u8, 103u8, 176u8, 160u8, 240u8, 249u8, 117u8, - 115u8, + 165u8, 40u8, 183u8, 209u8, 57u8, 153u8, 111u8, 29u8, 114u8, 109u8, + 107u8, 235u8, 97u8, 61u8, 53u8, 155u8, 44u8, 245u8, 28u8, 220u8, 56u8, + 134u8, 43u8, 122u8, 248u8, 156u8, 191u8, 154u8, 4u8, 121u8, 152u8, + 153u8, ], ) } - #[doc = " Votes and locked stake of a particular voter."] + #[doc = "Clears all public proposals."] #[doc = ""] - #[doc = " TWOX-NOTE: SAFE as `AccountId` is a crypto hash."] - pub fn voting( + #[doc = "The dispatch origin of this call must be _Root_."] + #[doc = ""] + #[doc = "Weight: `O(1)`."] + pub fn clear_public_proposals( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_elections_phragmen::Voter< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PhragmenElection", - "Voting", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "clear_public_proposals", + types::ClearPublicProposals {}, [ - 9u8, 135u8, 76u8, 194u8, 240u8, 182u8, 111u8, 207u8, 102u8, 37u8, - 126u8, 36u8, 84u8, 112u8, 26u8, 216u8, 175u8, 5u8, 14u8, 189u8, 83u8, - 185u8, 136u8, 39u8, 171u8, 221u8, 147u8, 20u8, 168u8, 126u8, 111u8, - 137u8, + 59u8, 126u8, 254u8, 223u8, 252u8, 225u8, 75u8, 185u8, 188u8, 181u8, + 42u8, 179u8, 211u8, 73u8, 12u8, 141u8, 243u8, 197u8, 46u8, 130u8, + 215u8, 196u8, 225u8, 88u8, 48u8, 199u8, 231u8, 249u8, 195u8, 53u8, + 184u8, 204u8, ], ) } - #[doc = " Votes and locked stake of a particular voter."] + #[doc = "Unlock tokens that have an expired lock."] #[doc = ""] - #[doc = " TWOX-NOTE: SAFE as `AccountId` is a crypto hash."] - pub fn voting_root( + #[doc = "The dispatch origin of this call must be _Signed_."] + #[doc = ""] + #[doc = "- `target`: The account to remove the lock on."] + #[doc = ""] + #[doc = "Weight: `O(R)` with R number of vote of target."] + pub fn unlock( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_elections_phragmen::Voter< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PhragmenElection", - "Voting", - Vec::new(), + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "unlock", + types::Unlock { target }, [ - 9u8, 135u8, 76u8, 194u8, 240u8, 182u8, 111u8, 207u8, 102u8, 37u8, - 126u8, 36u8, 84u8, 112u8, 26u8, 216u8, 175u8, 5u8, 14u8, 189u8, 83u8, - 185u8, 136u8, 39u8, 171u8, 221u8, 147u8, 20u8, 168u8, 126u8, 111u8, - 137u8, + 126u8, 151u8, 230u8, 89u8, 49u8, 247u8, 242u8, 139u8, 190u8, 15u8, + 47u8, 2u8, 132u8, 165u8, 48u8, 205u8, 196u8, 66u8, 230u8, 222u8, 164u8, + 249u8, 152u8, 107u8, 0u8, 99u8, 238u8, 167u8, 72u8, 77u8, 145u8, 236u8, ], ) } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Identifier for the elections-phragmen pallet's lock"] - pub fn pallet_id( + #[doc = "Remove a vote for a referendum."] + #[doc = ""] + #[doc = "If:"] + #[doc = "- the referendum was cancelled, or"] + #[doc = "- the referendum is ongoing, or"] + #[doc = "- the referendum has ended such that"] + #[doc = " - the vote of the account was in opposition to the result; or"] + #[doc = " - there was no conviction to the account's vote; or"] + #[doc = " - the account made a split vote"] + #[doc = "...then the vote is removed cleanly and a following call to `unlock` may result in more"] + #[doc = "funds being available."] + #[doc = ""] + #[doc = "If, however, the referendum has ended and:"] + #[doc = "- it finished corresponding to the vote of the account, and"] + #[doc = "- the account made a standard vote with conviction, and"] + #[doc = "- the lock period of the conviction is not over"] + #[doc = "...then the lock will be aggregated into the overall account's lock, which may involve"] + #[doc = "*overlocking* (where the two locks are combined into a single lock that is the maximum"] + #[doc = "of both the amount locked and the time is it locked for)."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be _Signed_, and the signer must have a vote"] + #[doc = "registered for referendum `index`."] + #[doc = ""] + #[doc = "- `index`: The index of referendum of the vote to be removed."] + #[doc = ""] + #[doc = "Weight: `O(R + log R)` where R is the number of referenda that `target` has voted on."] + #[doc = " Weight is calculated for the maximum number of vote."] + pub fn remove_vote( &self, - ) -> ::subxt::constants::Address<[::core::primitive::u8; 8usize]> { - ::subxt::constants::Address::new_static( - "PhragmenElection", - "PalletId", + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "remove_vote", + types::RemoveVote { index }, [ - 224u8, 197u8, 247u8, 125u8, 62u8, 180u8, 69u8, 91u8, 226u8, 36u8, 82u8, - 148u8, 70u8, 147u8, 209u8, 40u8, 210u8, 229u8, 181u8, 191u8, 170u8, - 205u8, 138u8, 97u8, 127u8, 59u8, 124u8, 244u8, 252u8, 30u8, 213u8, - 179u8, + 148u8, 120u8, 14u8, 172u8, 81u8, 152u8, 159u8, 178u8, 106u8, 244u8, + 36u8, 98u8, 120u8, 189u8, 213u8, 93u8, 119u8, 156u8, 112u8, 34u8, + 241u8, 72u8, 206u8, 113u8, 212u8, 161u8, 164u8, 126u8, 122u8, 82u8, + 160u8, 74u8, ], ) } - #[doc = " How much should be locked up in order to submit one's candidacy."] - pub fn candidacy_bond( + #[doc = "Remove a vote for a referendum."] + #[doc = ""] + #[doc = "If the `target` is equal to the signer, then this function is exactly equivalent to"] + #[doc = "`remove_vote`. If not equal to the signer, then the vote must have expired,"] + #[doc = "either because the referendum was cancelled, because the voter lost the referendum or"] + #[doc = "because the conviction period is over."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be _Signed_."] + #[doc = ""] + #[doc = "- `target`: The account of the vote to be removed; this account must have voted for"] + #[doc = " referendum `index`."] + #[doc = "- `index`: The index of referendum of the vote to be removed."] + #[doc = ""] + #[doc = "Weight: `O(R + log R)` where R is the number of referenda that `target` has voted on."] + #[doc = " Weight is calculated for the maximum number of vote."] + pub fn remove_other_vote( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "PhragmenElection", - "CandidacyBond", + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "remove_other_vote", + types::RemoveOtherVote { target, index }, [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 151u8, 190u8, 115u8, 124u8, 185u8, 43u8, 70u8, 147u8, 98u8, 167u8, + 120u8, 25u8, 231u8, 143u8, 214u8, 25u8, 240u8, 74u8, 35u8, 58u8, 206u8, + 78u8, 121u8, 215u8, 190u8, 42u8, 2u8, 206u8, 241u8, 44u8, 92u8, 23u8, ], ) } - #[doc = " Base deposit associated with voting."] + #[doc = "Permanently place a proposal into the blacklist. This prevents it from ever being"] + #[doc = "proposed again."] #[doc = ""] - #[doc = " This should be sensibly high to economically ensure the pallet cannot be attacked by"] - #[doc = " creating a gigantic number of votes."] - pub fn voting_bond_base( + #[doc = "If called on a queued public or external proposal, then this will result in it being"] + #[doc = "removed. If the `ref_index` supplied is an active referendum with the proposal hash,"] + #[doc = "then it will be cancelled."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be `BlacklistOrigin`."] + #[doc = ""] + #[doc = "- `proposal_hash`: The proposal hash to blacklist permanently."] + #[doc = "- `ref_index`: An ongoing referendum whose hash is `proposal_hash`, which will be"] + #[doc = "cancelled."] + #[doc = ""] + #[doc = "Weight: `O(p)` (though as this is an high-privilege dispatch, we assume it has a"] + #[doc = " reasonable value)."] + pub fn blacklist( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "PhragmenElection", - "VotingBondBase", + proposal_hash: ::subxt::utils::H256, + maybe_ref_index: ::core::option::Option<::core::primitive::u32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "blacklist", + types::Blacklist { + proposal_hash, + maybe_ref_index, + }, [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 48u8, 144u8, 81u8, 164u8, 54u8, 111u8, 197u8, 134u8, 6u8, 98u8, 121u8, + 179u8, 254u8, 191u8, 204u8, 212u8, 84u8, 255u8, 86u8, 110u8, 225u8, + 130u8, 26u8, 65u8, 133u8, 56u8, 231u8, 15u8, 245u8, 137u8, 146u8, + 242u8, ], ) } - #[doc = " The amount of bond that need to be locked for each vote (32 bytes)."] - pub fn voting_bond_factor( + #[doc = "Remove a proposal."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be `CancelProposalOrigin`."] + #[doc = ""] + #[doc = "- `prop_index`: The index of the proposal to cancel."] + #[doc = ""] + #[doc = "Weight: `O(p)` where `p = PublicProps::::decode_len()`"] + pub fn cancel_proposal( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "PhragmenElection", - "VotingBondFactor", + prop_index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "cancel_proposal", + types::CancelProposal { prop_index }, [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 179u8, 3u8, 198u8, 244u8, 241u8, 124u8, 205u8, 58u8, 100u8, 80u8, + 177u8, 254u8, 98u8, 220u8, 189u8, 63u8, 229u8, 60u8, 157u8, 83u8, + 142u8, 6u8, 236u8, 183u8, 193u8, 235u8, 253u8, 126u8, 153u8, 185u8, + 74u8, 117u8, ], ) } - #[doc = " Number of members to elect."] - pub fn desired_members( + #[doc = "Set or clear a metadata of a proposal or a referendum."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `origin`: Must correspond to the `MetadataOwner`."] + #[doc = " - `ExternalOrigin` for an external proposal with the `SuperMajorityApprove`"] + #[doc = " threshold."] + #[doc = " - `ExternalDefaultOrigin` for an external proposal with the `SuperMajorityAgainst`"] + #[doc = " threshold."] + #[doc = " - `ExternalMajorityOrigin` for an external proposal with the `SimpleMajority`"] + #[doc = " threshold."] + #[doc = " - `Signed` by a creator for a public proposal."] + #[doc = " - `Signed` to clear a metadata for a finished referendum."] + #[doc = " - `Root` to set a metadata for an ongoing referendum."] + #[doc = "- `owner`: an identifier of a metadata owner."] + #[doc = "- `maybe_hash`: The hash of an on-chain stored preimage. `None` to clear a metadata."] + pub fn set_metadata( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "PhragmenElection", - "DesiredMembers", + owner: runtime_types::pallet_democracy::types::MetadataOwner, + maybe_hash: ::core::option::Option<::subxt::utils::H256>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Democracy", + "set_metadata", + types::SetMetadata { owner, maybe_hash }, [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Number of runners_up to keep."] - pub fn desired_runners_up( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "PhragmenElection", - "DesiredRunnersUp", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " How long each seat is kept. This defines the next block number at which an election"] - #[doc = " round will happen. If set to zero, no elections are ever triggered and the module will"] - #[doc = " be in passive mode."] - pub fn term_duration(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "PhragmenElection", - "TermDuration", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of candidates in a phragmen election."] - #[doc = ""] - #[doc = " Warning: This impacts the size of the election which is run onchain. Chose wisely, and"] - #[doc = " consider how it will impact `T::WeightInfo::election_phragmen`."] - #[doc = ""] - #[doc = " When this limit is reached no more candidates are accepted in the election."] - pub fn max_candidates( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "PhragmenElection", - "MaxCandidates", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of voters to allow in a phragmen election."] - #[doc = ""] - #[doc = " Warning: This impacts the size of the election which is run onchain. Chose wisely, and"] - #[doc = " consider how it will impact `T::WeightInfo::election_phragmen`."] - #[doc = ""] - #[doc = " When the limit is reached the new voters are ignored."] - pub fn max_voters(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "PhragmenElection", - "MaxVoters", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Maximum numbers of votes per voter."] - #[doc = ""] - #[doc = " Warning: This impacts the size of the election which is run onchain. Chose wisely, and"] - #[doc = " consider how it will impact `T::WeightInfo::election_phragmen`."] - pub fn max_votes_per_voter( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "PhragmenElection", - "MaxVotesPerVoter", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod technical_membership { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_membership::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddMember { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveMember { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SwapMember { - pub remove: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub add: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ResetMembers { - pub members: ::std::vec::Vec<::subxt::utils::AccountId32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ChangeKey { - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetPrime { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClearPrime; - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Add a member `who` to the set."] - #[doc = ""] - #[doc = "May only be called from `T::AddOrigin`."] - pub fn add_member( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "TechnicalMembership", - "add_member", - types::AddMember { who }, - [ - 165u8, 116u8, 123u8, 50u8, 236u8, 196u8, 108u8, 211u8, 112u8, 214u8, - 121u8, 105u8, 7u8, 88u8, 125u8, 99u8, 24u8, 0u8, 168u8, 65u8, 158u8, - 100u8, 42u8, 62u8, 101u8, 59u8, 30u8, 174u8, 170u8, 119u8, 141u8, - 121u8, - ], - ) - } - #[doc = "Remove a member `who` from the set."] - #[doc = ""] - #[doc = "May only be called from `T::RemoveOrigin`."] - pub fn remove_member( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "TechnicalMembership", - "remove_member", - types::RemoveMember { who }, - [ - 177u8, 18u8, 217u8, 235u8, 254u8, 40u8, 137u8, 79u8, 146u8, 5u8, 55u8, - 187u8, 129u8, 28u8, 54u8, 132u8, 115u8, 220u8, 132u8, 139u8, 91u8, - 81u8, 0u8, 110u8, 188u8, 248u8, 1u8, 135u8, 93u8, 153u8, 95u8, 193u8, - ], - ) - } - #[doc = "Swap out one member `remove` for another `add`."] - #[doc = ""] - #[doc = "May only be called from `T::SwapOrigin`."] - #[doc = ""] - #[doc = "Prime membership is *not* passed from `remove` to `add`, if extant."] - pub fn swap_member( - &self, - remove: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - add: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "TechnicalMembership", - "swap_member", - types::SwapMember { remove, add }, - [ - 96u8, 248u8, 50u8, 206u8, 192u8, 242u8, 162u8, 62u8, 28u8, 91u8, 11u8, - 208u8, 15u8, 84u8, 188u8, 234u8, 219u8, 233u8, 200u8, 215u8, 157u8, - 155u8, 40u8, 220u8, 132u8, 182u8, 57u8, 210u8, 94u8, 240u8, 95u8, - 252u8, - ], - ) - } - #[doc = "Change the membership to a new set, disregarding the existing membership. Be nice and"] - #[doc = "pass `members` pre-sorted."] - #[doc = ""] - #[doc = "May only be called from `T::ResetOrigin`."] - pub fn reset_members( - &self, - members: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "TechnicalMembership", - "reset_members", - types::ResetMembers { members }, - [ - 9u8, 35u8, 28u8, 59u8, 158u8, 232u8, 89u8, 78u8, 101u8, 53u8, 240u8, - 98u8, 13u8, 104u8, 235u8, 161u8, 201u8, 150u8, 117u8, 32u8, 75u8, - 209u8, 166u8, 252u8, 57u8, 131u8, 96u8, 215u8, 51u8, 81u8, 42u8, 123u8, - ], - ) - } - #[doc = "Swap out the sending member for some other key `new`."] - #[doc = ""] - #[doc = "May only be called from `Signed` origin of a current member."] - #[doc = ""] - #[doc = "Prime membership is passed from the origin account to `new`, if extant."] - pub fn change_key( - &self, - new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "TechnicalMembership", - "change_key", - types::ChangeKey { new }, - [ - 27u8, 236u8, 241u8, 168u8, 98u8, 39u8, 176u8, 220u8, 145u8, 48u8, - 173u8, 25u8, 179u8, 103u8, 170u8, 13u8, 166u8, 181u8, 131u8, 160u8, - 131u8, 219u8, 116u8, 34u8, 152u8, 152u8, 46u8, 100u8, 46u8, 5u8, 156u8, - 195u8, - ], - ) - } - #[doc = "Set the prime member. Must be a current member."] - #[doc = ""] - #[doc = "May only be called from `T::PrimeOrigin`."] - pub fn set_prime( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "TechnicalMembership", - "set_prime", - types::SetPrime { who }, - [ - 0u8, 42u8, 111u8, 52u8, 151u8, 19u8, 239u8, 149u8, 183u8, 252u8, 87u8, - 194u8, 145u8, 21u8, 245u8, 112u8, 221u8, 181u8, 87u8, 28u8, 48u8, 39u8, - 210u8, 133u8, 241u8, 207u8, 255u8, 209u8, 139u8, 232u8, 119u8, 64u8, - ], - ) - } - #[doc = "Remove the prime member if it exists."] - #[doc = ""] - #[doc = "May only be called from `T::PrimeOrigin`."] - pub fn clear_prime(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "TechnicalMembership", - "clear_prime", - types::ClearPrime {}, - [ - 186u8, 182u8, 225u8, 90u8, 71u8, 124u8, 69u8, 100u8, 234u8, 25u8, 53u8, - 23u8, 182u8, 32u8, 176u8, 81u8, 54u8, 140u8, 235u8, 126u8, 247u8, 7u8, - 155u8, 62u8, 35u8, 135u8, 48u8, 61u8, 88u8, 160u8, 183u8, 72u8, + 182u8, 2u8, 168u8, 244u8, 247u8, 35u8, 65u8, 9u8, 39u8, 164u8, 30u8, + 141u8, 69u8, 137u8, 75u8, 156u8, 158u8, 107u8, 67u8, 28u8, 145u8, 65u8, + 175u8, 30u8, 254u8, 231u8, 4u8, 77u8, 207u8, 166u8, 157u8, 73u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_membership::pallet::Event; + pub type Event = runtime_types::pallet_democracy::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -14095,11 +13273,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The given member was added; see the transaction for who."] - pub struct MemberAdded; - impl ::subxt::events::StaticEvent for MemberAdded { - const PALLET: &'static str = "TechnicalMembership"; - const EVENT: &'static str = "MemberAdded"; + #[doc = "A motion has been proposed by a public account."] + pub struct Proposed { + pub proposal_index: ::core::primitive::u32, + pub deposit: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Proposed { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "Proposed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -14111,11 +13292,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The given member was removed; see the transaction for who."] - pub struct MemberRemoved; - impl ::subxt::events::StaticEvent for MemberRemoved { - const PALLET: &'static str = "TechnicalMembership"; - const EVENT: &'static str = "MemberRemoved"; + #[doc = "A public proposal has been tabled for referendum vote."] + pub struct Tabled { + pub proposal_index: ::core::primitive::u32, + pub deposit: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Tabled { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "Tabled"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -14127,11 +13311,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Two members were swapped; see the transaction for who."] - pub struct MembersSwapped; - impl ::subxt::events::StaticEvent for MembersSwapped { - const PALLET: &'static str = "TechnicalMembership"; - const EVENT: &'static str = "MembersSwapped"; + #[doc = "An external proposal has been tabled."] + pub struct ExternalTabled; + impl ::subxt::events::StaticEvent for ExternalTabled { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "ExternalTabled"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -14143,13 +13327,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The membership was reset; see the transaction for who the new set is."] - pub struct MembersReset; - impl ::subxt::events::StaticEvent for MembersReset { - const PALLET: &'static str = "TechnicalMembership"; - const EVENT: &'static str = "MembersReset"; + #[doc = "A referendum has begun."] + pub struct Started { + pub ref_index: ::core::primitive::u32, + pub threshold: runtime_types::pallet_democracy::vote_threshold::VoteThreshold, + } + impl ::subxt::events::StaticEvent for Started { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "Started"; } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -14159,13 +13347,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "One of the members' keys changed."] - pub struct KeyChanged; - impl ::subxt::events::StaticEvent for KeyChanged { - const PALLET: &'static str = "TechnicalMembership"; - const EVENT: &'static str = "KeyChanged"; + #[doc = "A proposal has been approved by referendum."] + pub struct Passed { + pub ref_index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Passed { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "Passed"; } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -14175,279 +13366,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Phantom member, never used."] - pub struct Dummy; - impl ::subxt::events::StaticEvent for Dummy { - const PALLET: &'static str = "TechnicalMembership"; - const EVENT: &'static str = "Dummy"; + #[doc = "A proposal has been rejected by referendum."] + pub struct NotPassed { + pub ref_index: ::core::primitive::u32, } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The current membership, stored as an ordered Vec."] - pub fn members( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "TechnicalMembership", - "Members", - vec![], - [ - 56u8, 56u8, 29u8, 90u8, 26u8, 115u8, 252u8, 185u8, 37u8, 108u8, 16u8, - 46u8, 136u8, 139u8, 30u8, 19u8, 235u8, 78u8, 176u8, 129u8, 180u8, 57u8, - 178u8, 239u8, 211u8, 6u8, 64u8, 129u8, 195u8, 46u8, 178u8, 157u8, - ], - ) - } - #[doc = " The current prime member, if one exists."] - pub fn prime( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "TechnicalMembership", - "Prime", - vec![], - [ - 108u8, 118u8, 54u8, 193u8, 207u8, 227u8, 119u8, 97u8, 23u8, 239u8, - 157u8, 69u8, 56u8, 142u8, 106u8, 17u8, 215u8, 159u8, 48u8, 42u8, 185u8, - 209u8, 49u8, 159u8, 32u8, 168u8, 111u8, 158u8, 159u8, 217u8, 244u8, - 158u8, - ], - ) - } + impl ::subxt::events::StaticEvent for NotPassed { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "NotPassed"; } - } - } - pub mod treasury { - use super::root_mod; - use super::runtime_types; - #[doc = "Error for the treasury pallet."] - pub type Error = runtime_types::pallet_treasury::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeSpend { - #[codec(compact)] - pub value: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RejectProposal { - #[codec(compact)] - pub proposal_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApproveProposal { - #[codec(compact)] - pub proposal_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Spend { - #[codec(compact)] - pub amount: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveApproval { - #[codec(compact)] - pub proposal_id: ::core::primitive::u32, - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Put forward a suggestion for spending. A deposit proportional to the value"] - #[doc = "is reserved and slashed if the proposal is rejected. It is returned once the"] - #[doc = "proposal is awarded."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(1)"] - pub fn propose_spend( - &self, - value: ::core::primitive::u128, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "propose_spend", - types::ProposeSpend { value, beneficiary }, - [ - 109u8, 46u8, 8u8, 159u8, 127u8, 79u8, 27u8, 100u8, 92u8, 244u8, 78u8, - 46u8, 105u8, 246u8, 169u8, 210u8, 149u8, 7u8, 108u8, 153u8, 203u8, - 223u8, 8u8, 117u8, 126u8, 250u8, 255u8, 52u8, 245u8, 69u8, 45u8, 136u8, - ], - ) - } - #[doc = "Reject a proposed spend. The original deposit will be slashed."] - #[doc = ""] - #[doc = "May only be called from `T::RejectOrigin`."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(1)"] - pub fn reject_proposal( - &self, - proposal_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "reject_proposal", - types::RejectProposal { proposal_id }, - [ - 106u8, 223u8, 97u8, 22u8, 111u8, 208u8, 128u8, 26u8, 198u8, 140u8, - 118u8, 126u8, 187u8, 51u8, 193u8, 50u8, 193u8, 68u8, 143u8, 144u8, - 34u8, 132u8, 44u8, 244u8, 105u8, 186u8, 223u8, 234u8, 17u8, 145u8, - 209u8, 145u8, - ], - ) - } - #[doc = "Approve a proposal. At a later time, the proposal will be allocated to the beneficiary"] - #[doc = "and the original deposit will be returned."] - #[doc = ""] - #[doc = "May only be called from `T::ApproveOrigin`."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = " - O(1)."] - pub fn approve_proposal( - &self, - proposal_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "approve_proposal", - types::ApproveProposal { proposal_id }, - [ - 164u8, 229u8, 172u8, 98u8, 129u8, 62u8, 84u8, 128u8, 47u8, 108u8, 33u8, - 120u8, 89u8, 79u8, 57u8, 121u8, 4u8, 197u8, 170u8, 153u8, 156u8, 17u8, - 59u8, 164u8, 123u8, 227u8, 175u8, 195u8, 220u8, 160u8, 60u8, 186u8, - ], - ) - } - #[doc = "Propose and approve a spend of treasury funds."] - #[doc = ""] - #[doc = "- `origin`: Must be `SpendOrigin` with the `Success` value being at least `amount`."] - #[doc = "- `amount`: The amount to be transferred from the treasury to the `beneficiary`."] - #[doc = "- `beneficiary`: The destination account for the transfer."] - #[doc = ""] - #[doc = "NOTE: For record-keeping purposes, the proposer is deemed to be equivalent to the"] - #[doc = "beneficiary."] - pub fn spend( - &self, - amount: ::core::primitive::u128, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "spend", - types::Spend { - amount, - beneficiary, - }, - [ - 177u8, 178u8, 242u8, 136u8, 135u8, 237u8, 114u8, 71u8, 233u8, 239u8, - 7u8, 84u8, 14u8, 228u8, 58u8, 31u8, 158u8, 185u8, 25u8, 91u8, 70u8, - 33u8, 19u8, 92u8, 100u8, 162u8, 5u8, 48u8, 20u8, 120u8, 9u8, 109u8, - ], - ) - } - #[doc = "Force a previously approved proposal to be removed from the approval queue."] - #[doc = "The original deposit will no longer be returned."] - #[doc = ""] - #[doc = "May only be called from `T::RejectOrigin`."] - #[doc = "- `proposal_id`: The index of a proposal"] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(A) where `A` is the number of approvals"] - #[doc = ""] - #[doc = "Errors:"] - #[doc = "- `ProposalNotApproved`: The `proposal_id` supplied was not found in the approval queue,"] - #[doc = "i.e., the proposal has not been approved. This could also mean the proposal does not"] - #[doc = "exist altogether, thus there is no way it would have been approved in the first place."] - pub fn remove_approval( - &self, - proposal_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "remove_approval", - types::RemoveApproval { proposal_id }, - [ - 133u8, 126u8, 181u8, 47u8, 196u8, 243u8, 7u8, 46u8, 25u8, 251u8, 154u8, - 125u8, 217u8, 77u8, 54u8, 245u8, 240u8, 180u8, 97u8, 34u8, 186u8, 53u8, - 225u8, 144u8, 155u8, 107u8, 172u8, 54u8, 250u8, 184u8, 178u8, 86u8, - ], - ) - } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_treasury::pallet::Event; - pub mod events { - use super::runtime_types; #[derive( :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, @@ -14459,16 +13385,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "New proposal."] - pub struct Proposed { - pub proposal_index: ::core::primitive::u32, + #[doc = "A referendum has been cancelled."] + pub struct Cancelled { + pub ref_index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for Proposed { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Proposed"; + impl ::subxt::events::StaticEvent for Cancelled { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "Cancelled"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -14478,13 +13403,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "We have ended a spend period and will now allocate funds."] - pub struct Spending { - pub budget_remaining: ::core::primitive::u128, + #[doc = "An account has delegated their vote to another account."] + pub struct Delegated { + pub who: ::subxt::utils::AccountId32, + pub target: ::subxt::utils::AccountId32, } - impl ::subxt::events::StaticEvent for Spending { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Spending"; + impl ::subxt::events::StaticEvent for Delegated { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "Delegated"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -14496,15 +13422,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some funds have been allocated."] - pub struct Awarded { - pub proposal_index: ::core::primitive::u32, - pub award: ::core::primitive::u128, + #[doc = "An account has cancelled a previous delegation operation."] + pub struct Undelegated { pub account: ::subxt::utils::AccountId32, } - impl ::subxt::events::StaticEvent for Awarded { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Awarded"; + impl ::subxt::events::StaticEvent for Undelegated { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "Undelegated"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -14516,17 +13440,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proposal was rejected; funds were slashed."] - pub struct Rejected { - pub proposal_index: ::core::primitive::u32, - pub slashed: ::core::primitive::u128, + #[doc = "An external proposal has been vetoed."] + pub struct Vetoed { + pub who: ::subxt::utils::AccountId32, + pub proposal_hash: ::subxt::utils::H256, + pub until: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for Rejected { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Rejected"; + impl ::subxt::events::StaticEvent for Vetoed { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "Vetoed"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -14536,16 +13460,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some of our funds have been burnt."] - pub struct Burnt { - pub burnt_funds: ::core::primitive::u128, + #[doc = "A proposal_hash has been blacklisted permanently."] + pub struct Blacklisted { + pub proposal_hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for Burnt { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Burnt"; + impl ::subxt::events::StaticEvent for Blacklisted { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "Blacklisted"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -14555,13 +13478,35 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Spending has finished; this is the amount that rolls over until next spend."] - pub struct Rollover { - pub rollover_balance: ::core::primitive::u128, + #[doc = "An account has voted in a referendum"] + pub struct Voted { + pub voter: ::subxt::utils::AccountId32, + pub ref_index: ::core::primitive::u32, + pub vote: + runtime_types::pallet_democracy::vote::AccountVote<::core::primitive::u128>, } - impl ::subxt::events::StaticEvent for Rollover { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Rollover"; + impl ::subxt::events::StaticEvent for Voted { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "Voted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account has secconded a proposal"] + pub struct Seconded { + pub seconder: ::subxt::utils::AccountId32, + pub prop_index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Seconded { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "Seconded"; } #[derive( :: subxt :: ext :: codec :: CompactAs, @@ -14574,13 +13519,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some funds have been deposited."] - pub struct Deposit { - pub value: ::core::primitive::u128, + #[doc = "A proposal got canceled."] + pub struct ProposalCanceled { + pub prop_index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for Deposit { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Deposit"; + impl ::subxt::events::StaticEvent for ProposalCanceled { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "ProposalCanceled"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -14592,15 +13537,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new spend proposal has been approved."] - pub struct SpendApproved { - pub proposal_index: ::core::primitive::u32, - pub amount: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::AccountId32, + #[doc = "Metadata for a proposal or a referendum has been set."] + pub struct MetadataSet { + pub owner: runtime_types::pallet_democracy::types::MetadataOwner, + pub hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for SpendApproved { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "SpendApproved"; + impl ::subxt::events::StaticEvent for MetadataSet { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "MetadataSet"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -14612,22 +13556,42 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The inactive funds of the pallet have been updated."] - pub struct UpdatedInactive { - pub reactivated: ::core::primitive::u128, - pub deactivated: ::core::primitive::u128, + #[doc = "Metadata for a proposal or a referendum has been cleared."] + pub struct MetadataCleared { + pub owner: runtime_types::pallet_democracy::types::MetadataOwner, + pub hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for UpdatedInactive { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "UpdatedInactive"; + impl ::subxt::events::StaticEvent for MetadataCleared { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "MetadataCleared"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Metadata has been transferred to new owner."] + pub struct MetadataTransferred { + pub prev_owner: runtime_types::pallet_democracy::types::MetadataOwner, + pub owner: runtime_types::pallet_democracy::types::MetadataOwner, + pub hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for MetadataTransferred { + const PALLET: &'static str = "Democracy"; + const EVENT: &'static str = "MetadataTransferred"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " Number of proposals that have been made."] - pub fn proposal_count( + #[doc = " The number of (public) proposals that have been made so far."] + pub fn public_prop_count( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, @@ -14637,697 +13601,484 @@ pub mod api { (), > { ::subxt::storage::address::Address::new_static( - "Treasury", - "ProposalCount", + "Democracy", + "PublicPropCount", vec![], [ - 132u8, 145u8, 78u8, 218u8, 51u8, 189u8, 55u8, 172u8, 143u8, 33u8, - 140u8, 99u8, 124u8, 208u8, 57u8, 232u8, 154u8, 110u8, 32u8, 142u8, - 24u8, 149u8, 109u8, 105u8, 30u8, 83u8, 39u8, 177u8, 127u8, 160u8, 34u8, - 70u8, + 91u8, 14u8, 171u8, 94u8, 37u8, 157u8, 46u8, 157u8, 254u8, 13u8, 68u8, + 144u8, 23u8, 146u8, 128u8, 159u8, 9u8, 174u8, 74u8, 174u8, 218u8, + 197u8, 23u8, 235u8, 152u8, 226u8, 216u8, 4u8, 120u8, 121u8, 27u8, + 138u8, ], ) } - #[doc = " Proposals that have been made."] - pub fn proposals( + #[doc = " The public proposals. Unsorted. The second item is the proposal."] + pub fn public_props( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_treasury::Proposal< + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u32, + runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, ::subxt::utils::AccountId32, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Democracy", + "PublicProps", + vec![], + [ + 63u8, 172u8, 211u8, 85u8, 27u8, 14u8, 86u8, 49u8, 133u8, 5u8, 132u8, + 189u8, 138u8, 137u8, 219u8, 37u8, 209u8, 49u8, 172u8, 86u8, 240u8, + 235u8, 42u8, 201u8, 203u8, 12u8, 122u8, 225u8, 0u8, 109u8, 205u8, + 103u8, + ], + ) + } + #[doc = " Those who have locked a deposit."] + #[doc = ""] + #[doc = " TWOX-NOTE: Safe, as increasing integer keys are safe."] + pub fn deposit_of( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::AccountId32, + >, ::core::primitive::u128, - >, + ), ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Treasury", - "Proposals", + "Democracy", + "DepositOf", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 62u8, 223u8, 55u8, 209u8, 151u8, 134u8, 122u8, 65u8, 207u8, 38u8, - 113u8, 213u8, 237u8, 48u8, 129u8, 32u8, 91u8, 228u8, 108u8, 91u8, 37u8, - 49u8, 94u8, 4u8, 75u8, 122u8, 25u8, 34u8, 198u8, 224u8, 246u8, 160u8, + 9u8, 219u8, 11u8, 58u8, 17u8, 194u8, 248u8, 154u8, 135u8, 119u8, 123u8, + 235u8, 252u8, 176u8, 190u8, 162u8, 236u8, 45u8, 237u8, 125u8, 98u8, + 176u8, 184u8, 160u8, 8u8, 181u8, 213u8, 65u8, 14u8, 84u8, 200u8, 64u8, ], ) } - #[doc = " Proposals that have been made."] - pub fn proposals_root( + #[doc = " Those who have locked a deposit."] + #[doc = ""] + #[doc = " TWOX-NOTE: Safe, as increasing integer keys are safe."] + pub fn deposit_of_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_treasury::Proposal< - ::subxt::utils::AccountId32, + ( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::AccountId32, + >, ::core::primitive::u128, - >, + ), (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Treasury", - "Proposals", + "Democracy", + "DepositOf", Vec::new(), [ - 62u8, 223u8, 55u8, 209u8, 151u8, 134u8, 122u8, 65u8, 207u8, 38u8, - 113u8, 213u8, 237u8, 48u8, 129u8, 32u8, 91u8, 228u8, 108u8, 91u8, 37u8, - 49u8, 94u8, 4u8, 75u8, 122u8, 25u8, 34u8, 198u8, 224u8, 246u8, 160u8, + 9u8, 219u8, 11u8, 58u8, 17u8, 194u8, 248u8, 154u8, 135u8, 119u8, 123u8, + 235u8, 252u8, 176u8, 190u8, 162u8, 236u8, 45u8, 237u8, 125u8, 98u8, + 176u8, 184u8, 160u8, 8u8, 181u8, 213u8, 65u8, 14u8, 84u8, 200u8, 64u8, ], ) } - #[doc = " The amount which has been reported as inactive to Currency."] - pub fn deactivated( + #[doc = " The next free referendum index, aka the number of referenda started so far."] + pub fn referendum_count( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, + ::core::primitive::u32, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "Treasury", - "Deactivated", + "Democracy", + "ReferendumCount", vec![], [ - 159u8, 57u8, 5u8, 85u8, 136u8, 128u8, 70u8, 43u8, 67u8, 76u8, 123u8, - 206u8, 48u8, 253u8, 51u8, 40u8, 14u8, 35u8, 162u8, 173u8, 127u8, 79u8, - 38u8, 235u8, 9u8, 141u8, 201u8, 37u8, 211u8, 176u8, 119u8, 106u8, + 153u8, 210u8, 106u8, 244u8, 156u8, 70u8, 124u8, 251u8, 123u8, 75u8, + 7u8, 189u8, 199u8, 145u8, 95u8, 119u8, 137u8, 11u8, 240u8, 160u8, + 151u8, 248u8, 229u8, 231u8, 89u8, 222u8, 18u8, 237u8, 144u8, 78u8, + 99u8, 58u8, ], ) } - #[doc = " Proposal indices that have been approved but not yet awarded."] - pub fn approvals( + #[doc = " The lowest referendum index representing an unbaked referendum. Equal to"] + #[doc = " `ReferendumCount` if there isn't a unbaked referendum."] + pub fn lowest_unbaked( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u32, - >, + ::core::primitive::u32, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "Treasury", - "Approvals", + "Democracy", + "LowestUnbaked", vec![], [ - 202u8, 106u8, 189u8, 40u8, 127u8, 172u8, 108u8, 50u8, 193u8, 4u8, - 248u8, 226u8, 176u8, 101u8, 212u8, 222u8, 64u8, 206u8, 244u8, 175u8, - 111u8, 106u8, 86u8, 96u8, 19u8, 109u8, 218u8, 152u8, 30u8, 59u8, 96u8, - 1u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Fraction of a proposal's value that should be bonded in order to place the proposal."] - #[doc = " An accepted proposal gets these back. A rejected proposal does not."] - pub fn proposal_bond( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "Treasury", - "ProposalBond", - [ - 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, - 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, - 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, + 4u8, 51u8, 108u8, 11u8, 48u8, 165u8, 19u8, 251u8, 182u8, 76u8, 163u8, + 73u8, 227u8, 2u8, 212u8, 74u8, 128u8, 27u8, 165u8, 164u8, 111u8, 22u8, + 209u8, 190u8, 103u8, 7u8, 116u8, 16u8, 160u8, 144u8, 123u8, 64u8, ], ) } - #[doc = " Minimum amount of funds that should be placed in a deposit for making a proposal."] - pub fn proposal_bond_minimum( + #[doc = " Information concerning any given referendum."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE as indexes are not under an attacker’s control."] + pub fn referendum_info_of( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Treasury", - "ProposalBondMinimum", + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_democracy::types::ReferendumInfo< + ::core::primitive::u32, + runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + ::core::primitive::u128, + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Democracy", + "ReferendumInfoOf", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 167u8, 58u8, 230u8, 197u8, 185u8, 56u8, 181u8, 32u8, 81u8, 150u8, 29u8, + 138u8, 142u8, 38u8, 255u8, 216u8, 139u8, 93u8, 56u8, 148u8, 196u8, + 169u8, 168u8, 144u8, 193u8, 200u8, 187u8, 5u8, 141u8, 201u8, 254u8, + 248u8, ], ) } - #[doc = " Maximum amount of funds that should be placed in a deposit for making a proposal."] - pub fn proposal_bond_maximum( + #[doc = " Information concerning any given referendum."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE as indexes are not under an attacker’s control."] + pub fn referendum_info_of_root( &self, - ) -> ::subxt::constants::Address<::core::option::Option<::core::primitive::u128>> - { - ::subxt::constants::Address::new_static( - "Treasury", - "ProposalBondMaximum", - [ - 84u8, 154u8, 218u8, 83u8, 84u8, 189u8, 32u8, 20u8, 120u8, 194u8, 88u8, - 205u8, 109u8, 216u8, 114u8, 193u8, 120u8, 198u8, 154u8, 237u8, 134u8, - 204u8, 102u8, 247u8, 52u8, 103u8, 231u8, 43u8, 243u8, 122u8, 60u8, - 216u8, - ], - ) - } - #[doc = " Period between successive spends."] - pub fn spend_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Treasury", - "SpendPeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Percentage of spare funds (if any) that are burnt per spend period."] - pub fn burn( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "Treasury", - "Burn", - [ - 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, - 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, - 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, - ], - ) - } - #[doc = " The treasury's pallet id, used for deriving its sovereign account ID."] - pub fn pallet_id( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "Treasury", - "PalletId", - [ - 139u8, 109u8, 228u8, 151u8, 252u8, 32u8, 130u8, 69u8, 112u8, 154u8, - 174u8, 45u8, 83u8, 245u8, 51u8, 132u8, 173u8, 5u8, 186u8, 24u8, 243u8, - 9u8, 12u8, 214u8, 80u8, 74u8, 69u8, 189u8, 30u8, 94u8, 22u8, 39u8, - ], - ) - } - #[doc = " The maximum number of approvals that can wait in the spending queue."] - #[doc = ""] - #[doc = " NOTE: This parameter is also used within the Bounties Pallet extension if enabled."] - pub fn max_approvals(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Treasury", - "MaxApprovals", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod conviction_voting { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_conviction_voting::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vote { - #[codec(compact)] - pub poll_index: ::core::primitive::u32, - pub vote: runtime_types::pallet_conviction_voting::vote::AccountVote< - ::core::primitive::u128, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Delegate { - pub class: ::core::primitive::u16, - pub to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub conviction: runtime_types::pallet_conviction_voting::conviction::Conviction, - pub balance: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Undelegate { - pub class: ::core::primitive::u16, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Unlock { - pub class: ::core::primitive::u16, - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveVote { - pub class: ::core::option::Option<::core::primitive::u16>, - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveOtherVote { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub class: ::core::primitive::u16, - pub index: ::core::primitive::u32, - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Vote in a poll. If `vote.is_aye()`, the vote is to enact the proposal;"] - #[doc = "otherwise it is a vote to keep the status quo."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_."] - #[doc = ""] - #[doc = "- `poll_index`: The index of the poll to vote for."] - #[doc = "- `vote`: The vote configuration."] - #[doc = ""] - #[doc = "Weight: `O(R)` where R is the number of polls the voter has voted on."] - pub fn vote( - &self, - poll_index: ::core::primitive::u32, - vote: runtime_types::pallet_conviction_voting::vote::AccountVote< + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_democracy::types::ReferendumInfo< + ::core::primitive::u32, + runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, ::core::primitive::u128, >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ConvictionVoting", - "vote", - Vote { poll_index, vote }, - [ - 255u8, 8u8, 191u8, 166u8, 7u8, 48u8, 227u8, 0u8, 34u8, 109u8, 3u8, - 172u8, 168u8, 37u8, 220u8, 229u8, 88u8, 61u8, 117u8, 212u8, 131u8, - 124u8, 74u8, 60u8, 83u8, 62u8, 193u8, 66u8, 162u8, 121u8, 76u8, 180u8, - ], - ) - } - #[doc = "Delegate the voting power (with some given conviction) of the sending account for a"] - #[doc = "particular class of polls."] - #[doc = ""] - #[doc = "The balance delegated is locked for as long as it's delegated, and thereafter for the"] - #[doc = "time appropriate for the conviction's lock period."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_, and the signing account must either:"] - #[doc = " - be delegating already; or"] - #[doc = " - have no voting activity (if there is, then it will need to be removed/consolidated"] - #[doc = " through `reap_vote` or `unvote`)."] - #[doc = ""] - #[doc = "- `to`: The account whose voting the `target` account's voting power will follow."] - #[doc = "- `class`: The class of polls to delegate. To delegate multiple classes, multiple calls"] - #[doc = " to this function are required."] - #[doc = "- `conviction`: The conviction that will be attached to the delegated votes. When the"] - #[doc = " account is undelegated, the funds will be locked for the corresponding period."] - #[doc = "- `balance`: The amount of the account's balance to be used in delegating. This must not"] - #[doc = " be more than the account's current balance."] - #[doc = ""] - #[doc = "Emits `Delegated`."] - #[doc = ""] - #[doc = "Weight: `O(R)` where R is the number of polls the voter delegating to has"] - #[doc = " voted on. Weight is initially charged as if maximum votes, but is refunded later."] - pub fn delegate( - &self, - class: ::core::primitive::u16, - to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - conviction: runtime_types::pallet_conviction_voting::conviction::Conviction, - balance: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ConvictionVoting", - "delegate", - Delegate { - class, - to, - conviction, - balance, - }, - [ - 241u8, 83u8, 114u8, 135u8, 173u8, 98u8, 8u8, 2u8, 197u8, 164u8, 105u8, - 93u8, 87u8, 243u8, 54u8, 149u8, 10u8, 168u8, 199u8, 211u8, 102u8, - 176u8, 217u8, 244u8, 78u8, 211u8, 124u8, 133u8, 32u8, 28u8, 235u8, - 222u8, - ], - ) - } - #[doc = "Undelegate the voting power of the sending account for a particular class of polls."] - #[doc = ""] - #[doc = "Tokens may be unlocked following once an amount of time consistent with the lock period"] - #[doc = "of the conviction with which the delegation was issued has passed."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_ and the signing account must be"] - #[doc = "currently delegating."] - #[doc = ""] - #[doc = "- `class`: The class of polls to remove the delegation from."] - #[doc = ""] - #[doc = "Emits `Undelegated`."] - #[doc = ""] - #[doc = "Weight: `O(R)` where R is the number of polls the voter delegating to has"] - #[doc = " voted on. Weight is initially charged as if maximum votes, but is refunded later."] - pub fn undelegate( - &self, - class: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ConvictionVoting", - "undelegate", - Undelegate { class }, - [ - 0u8, 244u8, 151u8, 108u8, 96u8, 240u8, 126u8, 247u8, 29u8, 33u8, 25u8, - 34u8, 253u8, 207u8, 107u8, 227u8, 139u8, 64u8, 184u8, 112u8, 246u8, - 81u8, 201u8, 41u8, 32u8, 201u8, 194u8, 201u8, 4u8, 170u8, 40u8, 83u8, - ], - ) - } - #[doc = "Remove the lock caused by prior voting/delegating which has expired within a particular"] - #[doc = "class."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_."] - #[doc = ""] - #[doc = "- `class`: The class of polls to unlock."] - #[doc = "- `target`: The account to remove the lock on."] - #[doc = ""] - #[doc = "Weight: `O(R)` with R number of vote of target."] - pub fn unlock( - &self, - class: ::core::primitive::u16, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ConvictionVoting", - "unlock", - Unlock { class, target }, - [ - 130u8, 244u8, 207u8, 112u8, 194u8, 4u8, 121u8, 4u8, 59u8, 75u8, 168u8, - 246u8, 210u8, 249u8, 247u8, 242u8, 252u8, 28u8, 190u8, 93u8, 11u8, 8u8, - 234u8, 222u8, 22u8, 110u8, 182u8, 252u8, 82u8, 64u8, 74u8, 169u8, - ], - ) - } - #[doc = "Remove a vote for a poll."] - #[doc = ""] - #[doc = "If:"] - #[doc = "- the poll was cancelled, or"] - #[doc = "- the poll is ongoing, or"] - #[doc = "- the poll has ended such that"] - #[doc = " - the vote of the account was in opposition to the result; or"] - #[doc = " - there was no conviction to the account's vote; or"] - #[doc = " - the account made a split vote"] - #[doc = "...then the vote is removed cleanly and a following call to `unlock` may result in more"] - #[doc = "funds being available."] - #[doc = ""] - #[doc = "If, however, the poll has ended and:"] - #[doc = "- it finished corresponding to the vote of the account, and"] - #[doc = "- the account made a standard vote with conviction, and"] - #[doc = "- the lock period of the conviction is not over"] - #[doc = "...then the lock will be aggregated into the overall account's lock, which may involve"] - #[doc = "*overlocking* (where the two locks are combined into a single lock that is the maximum"] - #[doc = "of both the amount locked and the time is it locked for)."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_, and the signer must have a vote"] - #[doc = "registered for poll `index`."] - #[doc = ""] - #[doc = "- `index`: The index of poll of the vote to be removed."] - #[doc = "- `class`: Optional parameter, if given it indicates the class of the poll. For polls"] - #[doc = " which have finished or are cancelled, this must be `Some`."] - #[doc = ""] - #[doc = "Weight: `O(R + log R)` where R is the number of polls that `target` has voted on."] - #[doc = " Weight is calculated for the maximum number of vote."] - pub fn remove_vote( - &self, - class: ::core::option::Option<::core::primitive::u16>, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ConvictionVoting", - "remove_vote", - RemoveVote { class, index }, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Democracy", + "ReferendumInfoOf", + Vec::new(), [ - 151u8, 255u8, 135u8, 195u8, 137u8, 27u8, 116u8, 193u8, 245u8, 78u8, - 38u8, 130u8, 233u8, 28u8, 235u8, 50u8, 144u8, 191u8, 39u8, 68u8, 17u8, - 214u8, 25u8, 2u8, 120u8, 14u8, 219u8, 205u8, 59u8, 192u8, 125u8, 142u8, + 167u8, 58u8, 230u8, 197u8, 185u8, 56u8, 181u8, 32u8, 81u8, 150u8, 29u8, + 138u8, 142u8, 38u8, 255u8, 216u8, 139u8, 93u8, 56u8, 148u8, 196u8, + 169u8, 168u8, 144u8, 193u8, 200u8, 187u8, 5u8, 141u8, 201u8, 254u8, + 248u8, ], ) } - #[doc = "Remove a vote for a poll."] - #[doc = ""] - #[doc = "If the `target` is equal to the signer, then this function is exactly equivalent to"] - #[doc = "`remove_vote`. If not equal to the signer, then the vote must have expired,"] - #[doc = "either because the poll was cancelled, because the voter lost the poll or"] - #[doc = "because the conviction period is over."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be _Signed_."] - #[doc = ""] - #[doc = "- `target`: The account of the vote to be removed; this account must have voted for poll"] - #[doc = " `index`."] - #[doc = "- `index`: The index of poll of the vote to be removed."] - #[doc = "- `class`: The class of the poll."] + #[doc = " All votes for a particular voter. We store the balance for the number of votes that we"] + #[doc = " have recorded. The second item is the total amount of delegations, that will be added."] #[doc = ""] - #[doc = "Weight: `O(R + log R)` where R is the number of polls that `target` has voted on."] - #[doc = " Weight is calculated for the maximum number of vote."] - pub fn remove_other_vote( - &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - class: ::core::primitive::u16, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ConvictionVoting", - "remove_other_vote", - RemoveOtherVote { - target, - class, - index, - }, - [ - 0u8, 148u8, 112u8, 202u8, 220u8, 85u8, 1u8, 77u8, 199u8, 156u8, 47u8, - 38u8, 105u8, 128u8, 71u8, 108u8, 185u8, 231u8, 252u8, 132u8, 37u8, - 114u8, 211u8, 110u8, 142u8, 64u8, 80u8, 90u8, 138u8, 108u8, 59u8, 87u8, - ], - ) - } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_conviction_voting::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has delegated their vote to another account. \\[who, target\\]"] - pub struct Delegated( - pub ::subxt::utils::AccountId32, - pub ::subxt::utils::AccountId32, - ); - impl ::subxt::events::StaticEvent for Delegated { - const PALLET: &'static str = "ConvictionVoting"; - const EVENT: &'static str = "Delegated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An \\[account\\] has cancelled a previous delegation operation."] - pub struct Undelegated(pub ::subxt::utils::AccountId32); - impl ::subxt::events::StaticEvent for Undelegated { - const PALLET: &'static str = "ConvictionVoting"; - const EVENT: &'static str = "Undelegated"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " All voting for a particular voter in a particular voting class. We store the balance for the"] - #[doc = " number of votes that we have recorded."] - pub fn voting_for( + #[doc = " TWOX-NOTE: SAFE as `AccountId`s are crypto hashes anyway."] + pub fn voting_of( &self, _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - _1: impl ::std::borrow::Borrow<::core::primitive::u16>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_conviction_voting::vote::Voting< + runtime_types::pallet_democracy::vote::Voting< ::core::primitive::u128, ::subxt::utils::AccountId32, ::core::primitive::u32, - ::core::primitive::u32, >, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ConvictionVoting", - "VotingFor", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + "Democracy", + "VotingOf", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 45u8, 18u8, 71u8, 145u8, 31u8, 220u8, 221u8, 51u8, 69u8, 73u8, 153u8, - 139u8, 46u8, 231u8, 122u8, 15u8, 98u8, 186u8, 57u8, 121u8, 24u8, 241u8, - 161u8, 150u8, 252u8, 133u8, 65u8, 232u8, 21u8, 28u8, 25u8, 75u8, + 125u8, 121u8, 167u8, 170u8, 18u8, 194u8, 183u8, 38u8, 176u8, 48u8, + 30u8, 88u8, 233u8, 196u8, 33u8, 119u8, 160u8, 201u8, 29u8, 183u8, 88u8, + 67u8, 219u8, 137u8, 6u8, 195u8, 11u8, 63u8, 162u8, 181u8, 82u8, 243u8, ], ) } - #[doc = " All voting for a particular voter in a particular voting class. We store the balance for the"] - #[doc = " number of votes that we have recorded."] - pub fn voting_for_root( + #[doc = " All votes for a particular voter. We store the balance for the number of votes that we"] + #[doc = " have recorded. The second item is the total amount of delegations, that will be added."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE as `AccountId`s are crypto hashes anyway."] + pub fn voting_of_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_conviction_voting::vote::Voting< + runtime_types::pallet_democracy::vote::Voting< ::core::primitive::u128, ::subxt::utils::AccountId32, ::core::primitive::u32, - ::core::primitive::u32, >, (), ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ConvictionVoting", - "VotingFor", + "Democracy", + "VotingOf", Vec::new(), [ - 45u8, 18u8, 71u8, 145u8, 31u8, 220u8, 221u8, 51u8, 69u8, 73u8, 153u8, - 139u8, 46u8, 231u8, 122u8, 15u8, 98u8, 186u8, 57u8, 121u8, 24u8, 241u8, - 161u8, 150u8, 252u8, 133u8, 65u8, 232u8, 21u8, 28u8, 25u8, 75u8, + 125u8, 121u8, 167u8, 170u8, 18u8, 194u8, 183u8, 38u8, 176u8, 48u8, + 30u8, 88u8, 233u8, 196u8, 33u8, 119u8, 160u8, 201u8, 29u8, 183u8, 88u8, + 67u8, 219u8, 137u8, 6u8, 195u8, 11u8, 63u8, 162u8, 181u8, 82u8, 243u8, ], ) } - #[doc = " The voting classes which have a non-zero lock requirement and the lock amounts which they"] - #[doc = " require. The actual amount locked on behalf of this pallet should always be the maximum of"] - #[doc = " this list."] - pub fn class_locks_for( + #[doc = " True if the last referendum tabled was submitted externally. False if it was a public"] + #[doc = " proposal."] + pub fn last_tabled_was_external( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u16, - ::core::primitive::u128, - )>, - ::subxt::storage::address::Yes, + ::core::primitive::bool, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "ConvictionVoting", - "ClassLocksFor", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Democracy", + "LastTabledWasExternal", + vec![], [ - 65u8, 181u8, 225u8, 49u8, 35u8, 141u8, 185u8, 155u8, 124u8, 178u8, - 118u8, 51u8, 220u8, 232u8, 95u8, 24u8, 181u8, 135u8, 42u8, 207u8, - 103u8, 166u8, 244u8, 249u8, 106u8, 96u8, 177u8, 56u8, 243u8, 117u8, - 228u8, 145u8, + 3u8, 67u8, 106u8, 1u8, 89u8, 204u8, 4u8, 145u8, 121u8, 44u8, 34u8, + 76u8, 18u8, 206u8, 65u8, 214u8, 222u8, 82u8, 31u8, 223u8, 144u8, 169u8, + 17u8, 6u8, 138u8, 36u8, 113u8, 155u8, 241u8, 106u8, 189u8, 218u8, ], ) } - #[doc = " The voting classes which have a non-zero lock requirement and the lock amounts which they"] - #[doc = " require. The actual amount locked on behalf of this pallet should always be the maximum of"] - #[doc = " this list."] - pub fn class_locks_for_root( + #[doc = " The referendum to be tabled whenever it would be valid to table an external proposal."] + #[doc = " This happens when a referendum needs to be tabled and one of two conditions are met:"] + #[doc = " - `LastTabledWasExternal` is `false`; or"] + #[doc = " - `PublicProps` is empty."] + pub fn next_external( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u16, - ::core::primitive::u128, - )>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ConvictionVoting", - "ClassLocksFor", + ( + runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + runtime_types::pallet_democracy::vote_threshold::VoteThreshold, + ), + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Democracy", + "NextExternal", + vec![], + [ + 213u8, 36u8, 235u8, 75u8, 153u8, 33u8, 140u8, 121u8, 191u8, 197u8, + 17u8, 57u8, 234u8, 67u8, 81u8, 55u8, 123u8, 179u8, 207u8, 124u8, 238u8, + 147u8, 243u8, 126u8, 200u8, 2u8, 16u8, 143u8, 165u8, 143u8, 159u8, + 93u8, + ], + ) + } + #[doc = " A record of who vetoed what. Maps proposal hash to a possible existent block number"] + #[doc = " (until when it may not be resubmitted) and who vetoed it."] + pub fn blacklist( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ( + ::core::primitive::u32, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::AccountId32, + >, + ), + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Democracy", + "Blacklist", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 8u8, 227u8, 185u8, 179u8, 192u8, 92u8, 171u8, 125u8, 237u8, 224u8, + 109u8, 207u8, 44u8, 181u8, 78u8, 17u8, 254u8, 183u8, 199u8, 241u8, + 49u8, 90u8, 101u8, 168u8, 46u8, 89u8, 253u8, 155u8, 38u8, 183u8, 112u8, + 35u8, + ], + ) + } + #[doc = " A record of who vetoed what. Maps proposal hash to a possible existent block number"] + #[doc = " (until when it may not be resubmitted) and who vetoed it."] + pub fn blacklist_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ( + ::core::primitive::u32, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::AccountId32, + >, + ), + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Democracy", + "Blacklist", Vec::new(), [ - 65u8, 181u8, 225u8, 49u8, 35u8, 141u8, 185u8, 155u8, 124u8, 178u8, - 118u8, 51u8, 220u8, 232u8, 95u8, 24u8, 181u8, 135u8, 42u8, 207u8, - 103u8, 166u8, 244u8, 249u8, 106u8, 96u8, 177u8, 56u8, 243u8, 117u8, - 228u8, 145u8, + 8u8, 227u8, 185u8, 179u8, 192u8, 92u8, 171u8, 125u8, 237u8, 224u8, + 109u8, 207u8, 44u8, 181u8, 78u8, 17u8, 254u8, 183u8, 199u8, 241u8, + 49u8, 90u8, 101u8, 168u8, 46u8, 89u8, 253u8, 155u8, 38u8, 183u8, 112u8, + 35u8, + ], + ) + } + #[doc = " Record of all proposals that have been subject to emergency cancellation."] + pub fn cancellations( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Democracy", + "Cancellations", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 154u8, 36u8, 172u8, 46u8, 65u8, 218u8, 30u8, 151u8, 173u8, 186u8, + 166u8, 79u8, 35u8, 226u8, 94u8, 200u8, 67u8, 44u8, 47u8, 7u8, 17u8, + 89u8, 169u8, 166u8, 236u8, 101u8, 68u8, 54u8, 114u8, 141u8, 177u8, + 135u8, + ], + ) + } + #[doc = " Record of all proposals that have been subject to emergency cancellation."] + pub fn cancellations_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Democracy", + "Cancellations", + Vec::new(), + [ + 154u8, 36u8, 172u8, 46u8, 65u8, 218u8, 30u8, 151u8, 173u8, 186u8, + 166u8, 79u8, 35u8, 226u8, 94u8, 200u8, 67u8, 44u8, 47u8, 7u8, 17u8, + 89u8, 169u8, 166u8, 236u8, 101u8, 68u8, 54u8, 114u8, 141u8, 177u8, + 135u8, + ], + ) + } + #[doc = " General information concerning any proposal or referendum."] + #[doc = " The `PreimageHash` refers to the preimage of the `Preimages` provider which can be a JSON"] + #[doc = " dump or IPFS hash of a JSON file."] + #[doc = ""] + #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] + #[doc = " large preimages."] + pub fn metadata_of( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::pallet_democracy::types::MetadataOwner, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Democracy", + "MetadataOf", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 157u8, 252u8, 120u8, 151u8, 76u8, 82u8, 189u8, 77u8, 196u8, 65u8, + 113u8, 138u8, 138u8, 57u8, 199u8, 136u8, 22u8, 35u8, 114u8, 144u8, + 172u8, 42u8, 130u8, 19u8, 19u8, 245u8, 76u8, 177u8, 145u8, 146u8, + 107u8, 23u8, + ], + ) + } + #[doc = " General information concerning any proposal or referendum."] + #[doc = " The `PreimageHash` refers to the preimage of the `Preimages` provider which can be a JSON"] + #[doc = " dump or IPFS hash of a JSON file."] + #[doc = ""] + #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] + #[doc = " large preimages."] + pub fn metadata_of_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Democracy", + "MetadataOf", + Vec::new(), + [ + 157u8, 252u8, 120u8, 151u8, 76u8, 82u8, 189u8, 77u8, 196u8, 65u8, + 113u8, 138u8, 138u8, 57u8, 199u8, 136u8, 22u8, 35u8, 114u8, 144u8, + 172u8, 42u8, 130u8, 19u8, 19u8, 245u8, 76u8, 177u8, 145u8, 146u8, + 107u8, 23u8, ], ) } @@ -15337,14 +14088,43 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " The maximum number of concurrent votes an account may have."] + #[doc = " The period between a proposal being approved and enacted."] #[doc = ""] - #[doc = " Also used to compute weight, an overly large value can lead to extrinsics with large"] - #[doc = " weight estimation: see `delegate` for instance."] - pub fn max_votes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + #[doc = " It should generally be a little more than the unstake period to ensure that"] + #[doc = " voting stakers have an opportunity to remove themselves from the system in the case"] + #[doc = " where they are on the losing side of a vote."] + pub fn enactment_period( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "ConvictionVoting", - "MaxVotes", + "Democracy", + "EnactmentPeriod", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " How often (in blocks) new public referenda are launched."] + pub fn launch_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Democracy", + "LaunchPeriod", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " How often (in blocks) to check for new votes."] + pub fn voting_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Democracy", + "VotingPeriod", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -15361,7 +14141,7 @@ pub mod api { &self, ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "ConvictionVoting", + "Democracy", "VoteLockingPeriod", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, @@ -15371,367 +14151,450 @@ pub mod api { ], ) } - } - } - } - pub mod referenda { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_referenda::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Submit { - pub proposal_origin: - ::std::boxed::Box, - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - pub enactment_moment: runtime_types::frame_support::traits::schedule::DispatchTime< - ::core::primitive::u32, - >, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PlaceDecisionDeposit { - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RefundDecisionDeposit { - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Cancel { - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Kill { - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NudgeReferendum { - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OneFewerDeciding { - pub track: ::core::primitive::u16, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RefundSubmissionDeposit { - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMetadata { - pub index: ::core::primitive::u32, - pub maybe_hash: ::core::option::Option<::subxt::utils::H256>, - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Propose a referendum on a privileged action."] - #[doc = ""] - #[doc = "- `origin`: must be `SubmitOrigin` and the account must have `SubmissionDeposit` funds"] - #[doc = " available."] - #[doc = "- `proposal_origin`: The origin from which the proposal should be executed."] - #[doc = "- `proposal`: The proposal."] - #[doc = "- `enactment_moment`: The moment that the proposal should be enacted."] - #[doc = ""] - #[doc = "Emits `Submitted`."] - pub fn submit( + #[doc = " The minimum amount to be used as a deposit for a public referendum proposal."] + pub fn minimum_deposit( &self, - proposal_origin: runtime_types::polkadot_runtime::OriginCaller, - proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - enactment_moment: runtime_types::frame_support::traits::schedule::DispatchTime< - ::core::primitive::u32, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "submit", - Submit { - proposal_origin: ::std::boxed::Box::new(proposal_origin), - proposal, - enactment_moment, - }, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Democracy", + "MinimumDeposit", [ - 213u8, 114u8, 86u8, 47u8, 165u8, 41u8, 216u8, 45u8, 93u8, 56u8, 92u8, - 228u8, 10u8, 88u8, 70u8, 82u8, 134u8, 252u8, 214u8, 45u8, 154u8, 150u8, - 221u8, 52u8, 235u8, 186u8, 47u8, 120u8, 221u8, 170u8, 29u8, 239u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = "Post the Decision Deposit for a referendum."] - #[doc = ""] - #[doc = "- `origin`: must be `Signed` and the account must have funds available for the"] - #[doc = " referendum's track's Decision Deposit."] - #[doc = "- `index`: The index of the submitted referendum whose Decision Deposit is yet to be"] - #[doc = " posted."] - #[doc = ""] - #[doc = "Emits `DecisionDepositPlaced`."] - pub fn place_decision_deposit( + #[doc = " Indicator for whether an emergency origin is even allowed to happen. Some chains may"] + #[doc = " want to set this permanently to `false`, others may want to condition it on things such"] + #[doc = " as an upgrade having happened recently."] + pub fn instant_allowed( &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "place_decision_deposit", - PlaceDecisionDeposit { index }, + ) -> ::subxt::constants::Address<::core::primitive::bool> { + ::subxt::constants::Address::new_static( + "Democracy", + "InstantAllowed", [ - 118u8, 227u8, 8u8, 55u8, 41u8, 171u8, 244u8, 40u8, 164u8, 232u8, 119u8, - 129u8, 139u8, 123u8, 77u8, 70u8, 219u8, 236u8, 145u8, 159u8, 84u8, - 111u8, 36u8, 4u8, 206u8, 5u8, 139u8, 231u8, 11u8, 231u8, 6u8, 30u8, + 165u8, 28u8, 112u8, 190u8, 18u8, 129u8, 182u8, 206u8, 237u8, 1u8, 68u8, + 252u8, 125u8, 234u8, 185u8, 50u8, 149u8, 164u8, 47u8, 126u8, 134u8, + 100u8, 14u8, 86u8, 209u8, 39u8, 20u8, 4u8, 233u8, 115u8, 102u8, 131u8, ], ) } - #[doc = "Refund the Decision Deposit for a closed referendum back to the depositor."] - #[doc = ""] - #[doc = "- `origin`: must be `Signed` or `Root`."] - #[doc = "- `index`: The index of a closed referendum whose Decision Deposit has not yet been"] - #[doc = " refunded."] - #[doc = ""] - #[doc = "Emits `DecisionDepositRefunded`."] - pub fn refund_decision_deposit( + #[doc = " Minimum voting period allowed for a fast-track referendum."] + pub fn fast_track_voting_period( &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "refund_decision_deposit", - RefundDecisionDeposit { index }, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Democracy", + "FastTrackVotingPeriod", [ - 120u8, 116u8, 89u8, 51u8, 255u8, 76u8, 150u8, 74u8, 54u8, 93u8, 19u8, - 64u8, 13u8, 177u8, 144u8, 93u8, 132u8, 150u8, 244u8, 48u8, 202u8, - 223u8, 201u8, 130u8, 112u8, 167u8, 29u8, 207u8, 112u8, 181u8, 43u8, - 93u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Cancel an ongoing referendum."] - #[doc = ""] - #[doc = "- `origin`: must be the `CancelOrigin`."] - #[doc = "- `index`: The index of the referendum to be cancelled."] - #[doc = ""] - #[doc = "Emits `Cancelled`."] - pub fn cancel( + #[doc = " Period in blocks where an external proposal may not be re-submitted after being vetoed."] + pub fn cooloff_period( &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "cancel", - Cancel { index }, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Democracy", + "CooloffPeriod", [ - 247u8, 55u8, 146u8, 211u8, 168u8, 140u8, 248u8, 217u8, 218u8, 235u8, - 25u8, 39u8, 47u8, 132u8, 134u8, 18u8, 239u8, 70u8, 223u8, 50u8, 245u8, - 101u8, 97u8, 39u8, 226u8, 4u8, 196u8, 16u8, 66u8, 177u8, 178u8, 252u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Cancel an ongoing referendum and slash the deposits."] - #[doc = ""] - #[doc = "- `origin`: must be the `KillOrigin`."] - #[doc = "- `index`: The index of the referendum to be cancelled."] + #[doc = " The maximum number of votes for an account."] #[doc = ""] - #[doc = "Emits `Killed` and `DepositSlashed`."] - pub fn kill(&self, index: ::core::primitive::u32) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "kill", - Kill { index }, + #[doc = " Also used to compute weight, an overly big value can"] + #[doc = " lead to extrinsic with very big weight: see `delegate` for instance."] + pub fn max_votes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Democracy", + "MaxVotes", [ - 98u8, 109u8, 143u8, 42u8, 24u8, 80u8, 39u8, 243u8, 249u8, 141u8, 104u8, - 195u8, 29u8, 93u8, 149u8, 37u8, 27u8, 130u8, 84u8, 178u8, 246u8, 26u8, - 113u8, 224u8, 157u8, 94u8, 16u8, 14u8, 158u8, 80u8, 148u8, 198u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Advance a referendum onto its next logical state. Only used internally."] - #[doc = ""] - #[doc = "- `origin`: must be `Root`."] - #[doc = "- `index`: the referendum to be advanced."] - pub fn nudge_referendum( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "nudge_referendum", - NudgeReferendum { index }, - [ - 60u8, 221u8, 153u8, 136u8, 107u8, 209u8, 59u8, 178u8, 208u8, 170u8, - 10u8, 225u8, 213u8, 170u8, 228u8, 64u8, 204u8, 166u8, 7u8, 230u8, - 243u8, 15u8, 206u8, 114u8, 8u8, 128u8, 46u8, 150u8, 114u8, 241u8, - 112u8, 97u8, + #[doc = " The maximum number of public proposals that can exist at any time."] + pub fn max_proposals(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Democracy", + "MaxProposals", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Advance a track onto its next logical state. Only used internally."] + #[doc = " The maximum number of deposits a public proposal may have at any time."] + pub fn max_deposits(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Democracy", + "MaxDeposits", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The maximum number of items which can be blacklisted."] + pub fn max_blacklisted( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Democracy", + "MaxBlacklisted", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod council { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_collective::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMembers { + pub new_members: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub prime: ::core::option::Option<::subxt::utils::AccountId32>, + pub old_count: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Execute { + pub proposal: ::std::boxed::Box, + #[codec(compact)] + pub length_bound: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Propose { + #[codec(compact)] + pub threshold: ::core::primitive::u32, + pub proposal: ::std::boxed::Box, + #[codec(compact)] + pub length_bound: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Vote { + pub proposal: ::subxt::utils::H256, + #[codec(compact)] + pub index: ::core::primitive::u32, + pub approve: ::core::primitive::bool, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DisapproveProposal { + pub proposal_hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Close { + pub proposal_hash: ::subxt::utils::H256, + #[codec(compact)] + pub index: ::core::primitive::u32, + pub proposal_weight_bound: runtime_types::sp_weights::weight_v2::Weight, + #[codec(compact)] + pub length_bound: ::core::primitive::u32, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Set the collective's membership."] #[doc = ""] - #[doc = "- `origin`: must be `Root`."] - #[doc = "- `track`: the track to be advanced."] + #[doc = "- `new_members`: The new member list. Be nice to the chain and provide it sorted."] + #[doc = "- `prime`: The prime member whose vote sets the default."] + #[doc = "- `old_count`: The upper bound for the previous number of members in storage. Used for"] + #[doc = " weight estimation."] #[doc = ""] - #[doc = "Action item for when there is now one fewer referendum in the deciding phase and the"] - #[doc = "`DecidingCount` is not yet updated. This means that we should either:"] - #[doc = "- begin deciding another referendum (and leave `DecidingCount` alone); or"] - #[doc = "- decrement `DecidingCount`."] - pub fn one_fewer_deciding( + #[doc = "The dispatch of this call must be `SetMembersOrigin`."] + #[doc = ""] + #[doc = "NOTE: Does not enforce the expected `MaxMembers` limit on the amount of members, but"] + #[doc = " the weight estimations rely on it to estimate dispatchable weight."] + #[doc = ""] + #[doc = "# WARNING:"] + #[doc = ""] + #[doc = "The `pallet-collective` can also be managed by logic outside of the pallet through the"] + #[doc = "implementation of the trait [`ChangeMembers`]."] + #[doc = "Any call to `set_members` must be careful that the member set doesn't get out of sync"] + #[doc = "with other logic managing the member set."] + #[doc = ""] + #[doc = "## Complexity:"] + #[doc = "- `O(MP + N)` where:"] + #[doc = " - `M` old-members-count (code- and governance-bounded)"] + #[doc = " - `N` new-members-count (code- and governance-bounded)"] + #[doc = " - `P` proposals-count (code-bounded)"] + pub fn set_members( &self, - track: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { + new_members: ::std::vec::Vec<::subxt::utils::AccountId32>, + prime: ::core::option::Option<::subxt::utils::AccountId32>, + old_count: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Referenda", - "one_fewer_deciding", - OneFewerDeciding { track }, + "Council", + "set_members", + types::SetMembers { + new_members, + prime, + old_count, + }, [ - 239u8, 43u8, 70u8, 73u8, 77u8, 28u8, 75u8, 62u8, 29u8, 67u8, 110u8, - 120u8, 234u8, 236u8, 126u8, 99u8, 46u8, 183u8, 169u8, 16u8, 143u8, - 233u8, 137u8, 247u8, 138u8, 96u8, 32u8, 223u8, 149u8, 52u8, 214u8, - 195u8, + 196u8, 103u8, 123u8, 125u8, 226u8, 177u8, 126u8, 37u8, 160u8, 114u8, + 34u8, 136u8, 219u8, 84u8, 199u8, 94u8, 242u8, 20u8, 126u8, 126u8, + 166u8, 190u8, 198u8, 33u8, 162u8, 113u8, 237u8, 222u8, 90u8, 1u8, 2u8, + 234u8, ], ) } - #[doc = "Refund the Submission Deposit for a closed referendum back to the depositor."] + #[doc = "Dispatch a proposal from a member using the `Member` origin."] #[doc = ""] - #[doc = "- `origin`: must be `Signed` or `Root`."] - #[doc = "- `index`: The index of a closed referendum whose Submission Deposit has not yet been"] - #[doc = " refunded."] + #[doc = "Origin must be a member of the collective."] #[doc = ""] - #[doc = "Emits `SubmissionDepositRefunded`."] - pub fn refund_submission_deposit( + #[doc = "## Complexity:"] + #[doc = "- `O(B + M + P)` where:"] + #[doc = "- `B` is `proposal` size in bytes (length-fee-bounded)"] + #[doc = "- `M` members-count (code-bounded)"] + #[doc = "- `P` complexity of dispatching `proposal`"] + pub fn execute( + &self, + proposal: runtime_types::polkadot_runtime::RuntimeCall, + length_bound: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Council", + "execute", + types::Execute { + proposal: ::std::boxed::Box::new(proposal), + length_bound, + }, + [ + 0u8, 74u8, 70u8, 223u8, 112u8, 196u8, 199u8, 189u8, 93u8, 14u8, 101u8, + 211u8, 221u8, 38u8, 32u8, 220u8, 90u8, 120u8, 94u8, 107u8, 46u8, 121u8, + 250u8, 150u8, 26u8, 24u8, 20u8, 242u8, 253u8, 229u8, 43u8, 195u8, + ], + ) + } + #[doc = "Add a new proposal to either be voted on or executed directly."] + #[doc = ""] + #[doc = "Requires the sender to be member."] + #[doc = ""] + #[doc = "`threshold` determines whether `proposal` is executed directly (`threshold < 2`)"] + #[doc = "or put up for voting."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(B + M + P1)` or `O(B + M + P2)` where:"] + #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] + #[doc = " - `M` is members-count (code- and governance-bounded)"] + #[doc = " - branching is influenced by `threshold` where:"] + #[doc = " - `P1` is proposal execution complexity (`threshold < 2`)"] + #[doc = " - `P2` is proposals-count (code-bounded) (`threshold >= 2`)"] + pub fn propose( + &self, + threshold: ::core::primitive::u32, + proposal: runtime_types::polkadot_runtime::RuntimeCall, + length_bound: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Council", + "propose", + types::Propose { + threshold, + proposal: ::std::boxed::Box::new(proposal), + length_bound, + }, + [ + 157u8, 103u8, 73u8, 75u8, 15u8, 79u8, 50u8, 64u8, 5u8, 151u8, 194u8, + 216u8, 45u8, 47u8, 128u8, 206u8, 191u8, 52u8, 5u8, 104u8, 70u8, 6u8, + 139u8, 184u8, 12u8, 190u8, 109u8, 132u8, 195u8, 177u8, 197u8, 179u8, + ], + ) + } + #[doc = "Add an aye or nay vote for the sender to the given proposal."] + #[doc = ""] + #[doc = "Requires the sender to be a member."] + #[doc = ""] + #[doc = "Transaction fees will be waived if the member is voting on any particular proposal"] + #[doc = "for the first time and the call is successful. Subsequent vote changes will charge a"] + #[doc = "fee."] + #[doc = "## Complexity"] + #[doc = "- `O(M)` where `M` is members-count (code- and governance-bounded)"] + pub fn vote( &self, + proposal: ::subxt::utils::H256, index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + approve: ::core::primitive::bool, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Referenda", - "refund_submission_deposit", - RefundSubmissionDeposit { index }, + "Council", + "vote", + types::Vote { + proposal, + index, + approve, + }, [ - 101u8, 147u8, 237u8, 27u8, 220u8, 116u8, 73u8, 131u8, 191u8, 92u8, - 134u8, 31u8, 175u8, 172u8, 129u8, 225u8, 91u8, 33u8, 23u8, 132u8, 89u8, - 19u8, 81u8, 238u8, 133u8, 243u8, 56u8, 70u8, 143u8, 43u8, 176u8, 83u8, + 108u8, 46u8, 180u8, 148u8, 145u8, 24u8, 173u8, 56u8, 36u8, 100u8, + 216u8, 43u8, 178u8, 202u8, 26u8, 136u8, 93u8, 84u8, 80u8, 134u8, 14u8, + 42u8, 248u8, 205u8, 68u8, 92u8, 79u8, 11u8, 113u8, 115u8, 157u8, 100u8, ], ) } - #[doc = "Set or clear metadata of a referendum."] + #[doc = "Disapprove a proposal, close, and remove it from the system, regardless of its current"] + #[doc = "state."] + #[doc = ""] + #[doc = "Must be called by the Root origin."] #[doc = ""] #[doc = "Parameters:"] - #[doc = "- `origin`: Must be `Signed` by a creator of a referendum or by anyone to clear a"] - #[doc = " metadata of a finished referendum."] - #[doc = "- `index`: The index of a referendum to set or clear metadata for."] - #[doc = "- `maybe_hash`: The hash of an on-chain stored preimage. `None` to clear a metadata."] - pub fn set_metadata( + #[doc = "* `proposal_hash`: The hash of the proposal that should be disapproved."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "O(P) where P is the number of max proposals"] + pub fn disapprove_proposal( + &self, + proposal_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Council", + "disapprove_proposal", + types::DisapproveProposal { proposal_hash }, + [ + 25u8, 123u8, 1u8, 8u8, 74u8, 37u8, 3u8, 40u8, 97u8, 37u8, 175u8, 224u8, + 72u8, 155u8, 123u8, 109u8, 104u8, 43u8, 91u8, 125u8, 199u8, 51u8, 17u8, + 225u8, 133u8, 38u8, 120u8, 76u8, 164u8, 5u8, 194u8, 201u8, + ], + ) + } + #[doc = "Close a vote that is either approved, disapproved or whose voting period has ended."] + #[doc = ""] + #[doc = "May be called by any signed account in order to finish voting and close the proposal."] + #[doc = ""] + #[doc = "If called before the end of the voting period it will only close the vote if it is"] + #[doc = "has enough votes to be approved or disapproved."] + #[doc = ""] + #[doc = "If called after the end of the voting period abstentions are counted as rejections"] + #[doc = "unless there is a prime member set and the prime member cast an approval."] + #[doc = ""] + #[doc = "If the close operation completes successfully with disapproval, the transaction fee will"] + #[doc = "be waived. Otherwise execution of the approved operation will be charged to the caller."] + #[doc = ""] + #[doc = "+ `proposal_weight_bound`: The maximum amount of weight consumed by executing the closed"] + #[doc = "proposal."] + #[doc = "+ `length_bound`: The upper bound for the length of the proposal in storage. Checked via"] + #[doc = "`storage::read` so it is `size_of::() == 4` larger than the pure length."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(B + M + P1 + P2)` where:"] + #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] + #[doc = " - `M` is members-count (code- and governance-bounded)"] + #[doc = " - `P1` is the complexity of `proposal` preimage."] + #[doc = " - `P2` is proposal-count (code-bounded)"] + pub fn close( &self, + proposal_hash: ::subxt::utils::H256, index: ::core::primitive::u32, - maybe_hash: ::core::option::Option<::subxt::utils::H256>, - ) -> ::subxt::tx::Payload { + proposal_weight_bound: runtime_types::sp_weights::weight_v2::Weight, + length_bound: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Referenda", - "set_metadata", - SetMetadata { index, maybe_hash }, + "Council", + "close", + types::Close { + proposal_hash, + index, + proposal_weight_bound, + length_bound, + }, [ - 235u8, 215u8, 66u8, 214u8, 157u8, 177u8, 233u8, 214u8, 103u8, 92u8, - 216u8, 228u8, 7u8, 123u8, 167u8, 225u8, 128u8, 16u8, 161u8, 102u8, - 217u8, 36u8, 80u8, 207u8, 137u8, 24u8, 219u8, 239u8, 42u8, 234u8, - 144u8, 133u8, + 191u8, 138u8, 89u8, 247u8, 97u8, 51u8, 45u8, 193u8, 76u8, 16u8, 80u8, + 225u8, 197u8, 83u8, 204u8, 133u8, 169u8, 16u8, 86u8, 32u8, 125u8, 16u8, + 116u8, 185u8, 45u8, 20u8, 76u8, 148u8, 206u8, 163u8, 154u8, 30u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_referenda::pallet::Event; + pub type Event = runtime_types::pallet_collective::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -15744,37 +14607,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been submitted."] - pub struct Submitted { - pub index: ::core::primitive::u32, - pub track: ::core::primitive::u16, - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - } - impl ::subxt::events::StaticEvent for Submitted { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "Submitted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The decision deposit has been placed."] - pub struct DecisionDepositPlaced { - pub index: ::core::primitive::u32, - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, + #[doc = "A motion (given hash) has been proposed (by given account) with a threshold (given"] + #[doc = "`MemberCount`)."] + pub struct Proposed { + pub account: ::subxt::utils::AccountId32, + pub proposal_index: ::core::primitive::u32, + pub proposal_hash: ::subxt::utils::H256, + pub threshold: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for DecisionDepositPlaced { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "DecisionDepositPlaced"; + impl ::subxt::events::StaticEvent for Proposed { + const PALLET: &'static str = "Council"; + const EVENT: &'static str = "Proposed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15786,15 +14629,18 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The decision deposit has been refunded."] - pub struct DecisionDepositRefunded { - pub index: ::core::primitive::u32, - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, + #[doc = "A motion (given hash) has been voted on by given account, leaving"] + #[doc = "a tally (yes votes and no votes given respectively as `MemberCount`)."] + pub struct Voted { + pub account: ::subxt::utils::AccountId32, + pub proposal_hash: ::subxt::utils::H256, + pub voted: ::core::primitive::bool, + pub yes: ::core::primitive::u32, + pub no: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for DecisionDepositRefunded { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "DecisionDepositRefunded"; + impl ::subxt::events::StaticEvent for Voted { + const PALLET: &'static str = "Council"; + const EVENT: &'static str = "Voted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15806,14 +14652,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A deposit has been slashaed."] - pub struct DepositSlashed { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, + #[doc = "A motion was approved by the required threshold."] + pub struct Approved { + pub proposal_hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for DepositSlashed { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "DepositSlashed"; + impl ::subxt::events::StaticEvent for Approved { + const PALLET: &'static str = "Council"; + const EVENT: &'static str = "Approved"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15825,22 +14670,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has moved into the deciding phase."] - pub struct DecisionStarted { - pub index: ::core::primitive::u32, - pub track: ::core::primitive::u16, - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - pub tally: - runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, + #[doc = "A motion was not approved by the required threshold."] + pub struct Disapproved { + pub proposal_hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for DecisionStarted { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "DecisionStarted"; + impl ::subxt::events::StaticEvent for Disapproved { + const PALLET: &'static str = "Council"; + const EVENT: &'static str = "Disapproved"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -15850,15 +14688,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ConfirmStarted { - pub index: ::core::primitive::u32, + #[doc = "A motion was executed; result will be `Ok` if it returned without error."] + pub struct Executed { + pub proposal_hash: ::subxt::utils::H256, + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, } - impl ::subxt::events::StaticEvent for ConfirmStarted { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "ConfirmStarted"; + impl ::subxt::events::StaticEvent for Executed { + const PALLET: &'static str = "Council"; + const EVENT: &'static str = "Executed"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -15868,12 +14707,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ConfirmAborted { - pub index: ::core::primitive::u32, + #[doc = "A single member did some action; result will be `Ok` if it returned without error."] + pub struct MemberExecuted { + pub proposal_hash: ::subxt::utils::H256, + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, } - impl ::subxt::events::StaticEvent for ConfirmAborted { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "ConfirmAborted"; + impl ::subxt::events::StaticEvent for MemberExecuted { + const PALLET: &'static str = "Council"; + const EVENT: &'static str = "MemberExecuted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -15885,431 +14726,206 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has ended its confirmation phase and is ready for approval."] - pub struct Confirmed { - pub index: ::core::primitive::u32, - pub tally: - runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, - } - impl ::subxt::events::StaticEvent for Confirmed { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "Confirmed"; + #[doc = "A proposal was closed because its threshold was reached or after its duration was up."] + pub struct Closed { + pub proposal_hash: ::subxt::utils::H256, + pub yes: ::core::primitive::u32, + pub no: ::core::primitive::u32, } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been approved and its proposal has been scheduled."] - pub struct Approved { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Approved { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "Approved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proposal has been rejected by referendum."] - pub struct Rejected { - pub index: ::core::primitive::u32, - pub tally: - runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, - } - impl ::subxt::events::StaticEvent for Rejected { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "Rejected"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been timed out without being decided."] - pub struct TimedOut { - pub index: ::core::primitive::u32, - pub tally: - runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, - } - impl ::subxt::events::StaticEvent for TimedOut { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "TimedOut"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been cancelled."] - pub struct Cancelled { - pub index: ::core::primitive::u32, - pub tally: - runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, - } - impl ::subxt::events::StaticEvent for Cancelled { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "Cancelled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been killed."] - pub struct Killed { - pub index: ::core::primitive::u32, - pub tally: - runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, - } - impl ::subxt::events::StaticEvent for Killed { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "Killed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The submission deposit has been refunded."] - pub struct SubmissionDepositRefunded { - pub index: ::core::primitive::u32, - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for SubmissionDepositRefunded { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "SubmissionDepositRefunded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Metadata for a referendum has been set."] - pub struct MetadataSet { - pub index: ::core::primitive::u32, - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for MetadataSet { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "MetadataSet"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Metadata for a referendum has been cleared."] - pub struct MetadataCleared { - pub index: ::core::primitive::u32, - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for MetadataCleared { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "MetadataCleared"; + impl ::subxt::events::StaticEvent for Closed { + const PALLET: &'static str = "Council"; + const EVENT: &'static str = "Closed"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " The next free referendum index, aka the number of referenda started so far."] - pub fn referendum_count( + #[doc = " The hashes of the active proposals."] + pub fn proposals( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::H256, + >, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "Referenda", - "ReferendumCount", + "Council", + "Proposals", vec![], [ - 153u8, 210u8, 106u8, 244u8, 156u8, 70u8, 124u8, 251u8, 123u8, 75u8, - 7u8, 189u8, 199u8, 145u8, 95u8, 119u8, 137u8, 11u8, 240u8, 160u8, - 151u8, 248u8, 229u8, 231u8, 89u8, 222u8, 18u8, 237u8, 144u8, 78u8, - 99u8, 58u8, + 10u8, 133u8, 82u8, 54u8, 193u8, 41u8, 253u8, 159u8, 56u8, 96u8, 249u8, + 148u8, 43u8, 57u8, 116u8, 43u8, 222u8, 243u8, 237u8, 231u8, 238u8, + 60u8, 26u8, 225u8, 19u8, 203u8, 213u8, 220u8, 114u8, 217u8, 100u8, + 27u8, ], ) } - #[doc = " Information concerning any given referendum."] - pub fn referendum_info_for( + #[doc = " Actual proposal for a given hash, if it's current."] + pub fn proposal_of( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_referenda::types::ReferendumInfo< - ::core::primitive::u16, - runtime_types::polkadot_runtime::OriginCaller, - ::core::primitive::u32, - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - ::core::primitive::u128, - runtime_types::pallet_conviction_voting::types::Tally< - ::core::primitive::u128, - >, - ::subxt::utils::AccountId32, - (::core::primitive::u32, ::core::primitive::u32), - >, + runtime_types::polkadot_runtime::RuntimeCall, ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Referenda", - "ReferendumInfoFor", + "Council", + "ProposalOf", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 180u8, 213u8, 110u8, 2u8, 75u8, 24u8, 34u8, 143u8, 56u8, 197u8, 106u8, - 105u8, 182u8, 118u8, 114u8, 242u8, 48u8, 85u8, 147u8, 22u8, 29u8, - 211u8, 246u8, 127u8, 217u8, 251u8, 208u8, 20u8, 9u8, 84u8, 53u8, 249u8, + 6u8, 23u8, 244u8, 48u8, 73u8, 203u8, 222u8, 109u8, 218u8, 166u8, 6u8, + 137u8, 121u8, 88u8, 54u8, 188u8, 37u8, 8u8, 229u8, 217u8, 170u8, 108u8, + 198u8, 66u8, 36u8, 92u8, 107u8, 168u8, 162u8, 204u8, 210u8, 20u8, ], ) } - #[doc = " Information concerning any given referendum."] - pub fn referendum_info_for_root( + #[doc = " Actual proposal for a given hash, if it's current."] + pub fn proposal_of_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_referenda::types::ReferendumInfo< - ::core::primitive::u16, - runtime_types::polkadot_runtime::OriginCaller, - ::core::primitive::u32, - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::polkadot_runtime::RuntimeCall, - >, - ::core::primitive::u128, - runtime_types::pallet_conviction_voting::types::Tally< - ::core::primitive::u128, - >, - ::subxt::utils::AccountId32, - (::core::primitive::u32, ::core::primitive::u32), - >, + runtime_types::polkadot_runtime::RuntimeCall, (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Referenda", - "ReferendumInfoFor", + "Council", + "ProposalOf", Vec::new(), [ - 180u8, 213u8, 110u8, 2u8, 75u8, 24u8, 34u8, 143u8, 56u8, 197u8, 106u8, - 105u8, 182u8, 118u8, 114u8, 242u8, 48u8, 85u8, 147u8, 22u8, 29u8, - 211u8, 246u8, 127u8, 217u8, 251u8, 208u8, 20u8, 9u8, 84u8, 53u8, 249u8, + 6u8, 23u8, 244u8, 48u8, 73u8, 203u8, 222u8, 109u8, 218u8, 166u8, 6u8, + 137u8, 121u8, 88u8, 54u8, 188u8, 37u8, 8u8, 229u8, 217u8, 170u8, 108u8, + 198u8, 66u8, 36u8, 92u8, 107u8, 168u8, 162u8, 204u8, 210u8, 20u8, ], ) } - #[doc = " The sorted list of referenda ready to be decided but not yet being decided, ordered by"] - #[doc = " conviction-weighted approvals."] - #[doc = ""] - #[doc = " This should be empty if `DecidingCount` is less than `TrackInfo::max_deciding`."] - pub fn track_queue( + #[doc = " Votes on a given proposal, if it is ongoing."] + pub fn voting( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u16>, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( + runtime_types::pallet_collective::Votes< + ::subxt::utils::AccountId32, ::core::primitive::u32, - ::core::primitive::u128, - )>, - ::subxt::storage::address::Yes, + >, ::subxt::storage::address::Yes, + (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Referenda", - "TrackQueue", + "Council", + "Voting", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 254u8, 82u8, 183u8, 246u8, 168u8, 87u8, 175u8, 224u8, 192u8, 117u8, - 129u8, 244u8, 18u8, 18u8, 249u8, 30u8, 51u8, 133u8, 244u8, 117u8, - 194u8, 174u8, 99u8, 51u8, 155u8, 76u8, 206u8, 202u8, 109u8, 39u8, - 253u8, 240u8, + 89u8, 108u8, 65u8, 58u8, 60u8, 116u8, 54u8, 68u8, 179u8, 73u8, 161u8, + 168u8, 78u8, 213u8, 208u8, 54u8, 244u8, 58u8, 70u8, 209u8, 170u8, + 136u8, 215u8, 3u8, 2u8, 105u8, 229u8, 217u8, 240u8, 230u8, 107u8, + 221u8, ], ) } - #[doc = " The sorted list of referenda ready to be decided but not yet being decided, ordered by"] - #[doc = " conviction-weighted approvals."] - #[doc = ""] - #[doc = " This should be empty if `DecidingCount` is less than `TrackInfo::max_deciding`."] - pub fn track_queue_root( + #[doc = " Votes on a given proposal, if it is ongoing."] + pub fn voting_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( + runtime_types::pallet_collective::Votes< + ::subxt::utils::AccountId32, ::core::primitive::u32, - ::core::primitive::u128, - )>, + >, + (), (), - ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Referenda", - "TrackQueue", + "Council", + "Voting", Vec::new(), [ - 254u8, 82u8, 183u8, 246u8, 168u8, 87u8, 175u8, 224u8, 192u8, 117u8, - 129u8, 244u8, 18u8, 18u8, 249u8, 30u8, 51u8, 133u8, 244u8, 117u8, - 194u8, 174u8, 99u8, 51u8, 155u8, 76u8, 206u8, 202u8, 109u8, 39u8, - 253u8, 240u8, + 89u8, 108u8, 65u8, 58u8, 60u8, 116u8, 54u8, 68u8, 179u8, 73u8, 161u8, + 168u8, 78u8, 213u8, 208u8, 54u8, 244u8, 58u8, 70u8, 209u8, 170u8, + 136u8, 215u8, 3u8, 2u8, 105u8, 229u8, 217u8, 240u8, 230u8, 107u8, + 221u8, ], ) } - #[doc = " The number of referenda being decided currently."] - pub fn deciding_count( + #[doc = " Proposals so far."] + pub fn proposal_count( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u16>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, ::core::primitive::u32, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Referenda", - "DecidingCount", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 101u8, 153u8, 200u8, 225u8, 229u8, 227u8, 232u8, 26u8, 98u8, 60u8, - 60u8, 94u8, 204u8, 195u8, 193u8, 69u8, 50u8, 72u8, 31u8, 250u8, 224u8, - 179u8, 139u8, 207u8, 19u8, 156u8, 67u8, 234u8, 177u8, 223u8, 63u8, - 150u8, - ], - ) - } - #[doc = " The number of referenda being decided currently."] - pub fn deciding_count_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Referenda", - "DecidingCount", - Vec::new(), + "Council", + "ProposalCount", + vec![], [ - 101u8, 153u8, 200u8, 225u8, 229u8, 227u8, 232u8, 26u8, 98u8, 60u8, - 60u8, 94u8, 204u8, 195u8, 193u8, 69u8, 50u8, 72u8, 31u8, 250u8, 224u8, - 179u8, 139u8, 207u8, 19u8, 156u8, 67u8, 234u8, 177u8, 223u8, 63u8, - 150u8, + 132u8, 145u8, 78u8, 218u8, 51u8, 189u8, 55u8, 172u8, 143u8, 33u8, + 140u8, 99u8, 124u8, 208u8, 57u8, 232u8, 154u8, 110u8, 32u8, 142u8, + 24u8, 149u8, 109u8, 105u8, 30u8, 83u8, 39u8, 177u8, 127u8, 160u8, 34u8, + 70u8, ], ) } - #[doc = " The metadata is a general information concerning the referendum."] - #[doc = " The `PreimageHash` refers to the preimage of the `Preimages` provider which can be a JSON"] - #[doc = " dump or IPFS hash of a JSON file."] - #[doc = ""] - #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] - #[doc = " large preimages."] - pub fn metadata_of( + #[doc = " The current members of the collective. This is stored sorted (just by value)."] + pub fn members( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, + ::std::vec::Vec<::subxt::utils::AccountId32>, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Referenda", - "MetadataOf", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Council", + "Members", + vec![], [ - 104u8, 255u8, 134u8, 120u8, 111u8, 124u8, 108u8, 232u8, 61u8, 47u8, - 251u8, 228u8, 50u8, 49u8, 125u8, 229u8, 254u8, 88u8, 215u8, 90u8, - 116u8, 145u8, 111u8, 72u8, 132u8, 91u8, 106u8, 207u8, 13u8, 104u8, - 164u8, 100u8, + 162u8, 72u8, 174u8, 204u8, 140u8, 105u8, 205u8, 176u8, 197u8, 117u8, + 206u8, 134u8, 157u8, 110u8, 139u8, 54u8, 43u8, 233u8, 25u8, 51u8, 36u8, + 238u8, 94u8, 124u8, 221u8, 52u8, 237u8, 71u8, 125u8, 56u8, 129u8, + 222u8, ], ) } - #[doc = " The metadata is a general information concerning the referendum."] - #[doc = " The `PreimageHash` refers to the preimage of the `Preimages` provider which can be a JSON"] - #[doc = " dump or IPFS hash of a JSON file."] - #[doc = ""] - #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] - #[doc = " large preimages."] - pub fn metadata_of_root( + #[doc = " The prime member that helps determine the default vote behavior in case of absentations."] + pub fn prime( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, + ::subxt::utils::AccountId32, + ::subxt::storage::address::Yes, (), (), - ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Referenda", - "MetadataOf", - Vec::new(), + "Council", + "Prime", + vec![], [ - 104u8, 255u8, 134u8, 120u8, 111u8, 124u8, 108u8, 232u8, 61u8, 47u8, - 251u8, 228u8, 50u8, 49u8, 125u8, 229u8, 254u8, 88u8, 215u8, 90u8, - 116u8, 145u8, 111u8, 72u8, 132u8, 91u8, 106u8, 207u8, 13u8, 104u8, - 164u8, 100u8, + 108u8, 118u8, 54u8, 193u8, 207u8, 227u8, 119u8, 97u8, 23u8, 239u8, + 157u8, 69u8, 56u8, 142u8, 106u8, 17u8, 215u8, 159u8, 48u8, 42u8, 185u8, + 209u8, 49u8, 159u8, 32u8, 168u8, 111u8, 158u8, 159u8, 217u8, 244u8, + 158u8, ], ) } @@ -16319,346 +14935,30 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " The minimum amount to be used as a deposit for a public referendum proposal."] - pub fn submission_deposit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Referenda", - "SubmissionDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Maximum size of the referendum queue for a single track."] - pub fn max_queued(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Referenda", - "MaxQueued", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The number of blocks after submission that a referendum must begin being decided by."] - #[doc = " Once this passes, then anyone may cancel the referendum."] - pub fn undeciding_timeout( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Referenda", - "UndecidingTimeout", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Quantization level for the referendum wakeup scheduler. A higher number will result in"] - #[doc = " fewer storage reads/writes needed for smaller voters, but also result in delays to the"] - #[doc = " automatic referendum status changes. Explicit servicing instructions are unaffected."] - pub fn alarm_interval( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Referenda", - "AlarmInterval", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Information concerning the different referendum tracks."] - pub fn tracks( + #[doc = " The maximum weight of a dispatch call that can be proposed and executed."] + pub fn max_proposal_weight( &self, - ) -> ::subxt::constants::Address< - ::std::vec::Vec<( - ::core::primitive::u16, - runtime_types::pallet_referenda::types::TrackInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - )>, - > { + ) -> ::subxt::constants::Address + { ::subxt::constants::Address::new_static( - "Referenda", - "Tracks", + "Council", + "MaxProposalWeight", [ - 71u8, 253u8, 246u8, 54u8, 168u8, 190u8, 182u8, 15u8, 207u8, 26u8, 50u8, - 138u8, 212u8, 124u8, 13u8, 203u8, 27u8, 35u8, 224u8, 1u8, 176u8, 192u8, - 197u8, 220u8, 147u8, 94u8, 196u8, 150u8, 125u8, 23u8, 48u8, 255u8, + 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, + 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, + 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, + 106u8, 76u8, ], ) } } } } - pub mod whitelist { + pub mod technical_committee { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_whitelist::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WhitelistCall { - pub call_hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveWhitelistedCall { - pub call_hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DispatchWhitelistedCall { - pub call_hash: ::subxt::utils::H256, - pub call_encoded_len: ::core::primitive::u32, - pub call_weight_witness: runtime_types::sp_weights::weight_v2::Weight, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DispatchWhitelistedCallWithPreimage { - pub call: ::std::boxed::Box, - } - pub struct TransactionApi; - impl TransactionApi { - pub fn whitelist_call( - &self, - call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Whitelist", - "whitelist_call", - WhitelistCall { call_hash }, - [ - 21u8, 246u8, 244u8, 176u8, 163u8, 80u8, 45u8, 191u8, 3u8, 180u8, 150u8, - 66u8, 168u8, 3u8, 196u8, 129u8, 177u8, 104u8, 48u8, 5u8, 201u8, 208u8, - 226u8, 76u8, 148u8, 116u8, 206u8, 119u8, 145u8, 78u8, 86u8, 41u8, - ], - ) - } - pub fn remove_whitelisted_call( - &self, - call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Whitelist", - "remove_whitelisted_call", - RemoveWhitelistedCall { call_hash }, - [ - 142u8, 227u8, 198u8, 110u8, 90u8, 127u8, 218u8, 117u8, 181u8, 209u8, - 210u8, 86u8, 133u8, 95u8, 244u8, 64u8, 50u8, 240u8, 220u8, 50u8, 212u8, - 106u8, 4u8, 189u8, 2u8, 72u8, 96u8, 52u8, 187u8, 140u8, 144u8, 76u8, - ], - ) - } - pub fn dispatch_whitelisted_call( - &self, - call_hash: ::subxt::utils::H256, - call_encoded_len: ::core::primitive::u32, - call_weight_witness: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Whitelist", - "dispatch_whitelisted_call", - DispatchWhitelistedCall { - call_hash, - call_encoded_len, - call_weight_witness, - }, - [ - 243u8, 130u8, 216u8, 251u8, 131u8, 220u8, 75u8, 210u8, 203u8, 137u8, - 174u8, 95u8, 134u8, 252u8, 76u8, 33u8, 230u8, 185u8, 125u8, 15u8, - 200u8, 85u8, 46u8, 43u8, 34u8, 205u8, 245u8, 85u8, 46u8, 78u8, 245u8, - 135u8, - ], - ) - } - pub fn dispatch_whitelisted_call_with_preimage( - &self, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Whitelist", - "dispatch_whitelisted_call_with_preimage", - DispatchWhitelistedCallWithPreimage { - call: ::std::boxed::Box::new(call), - }, - [ - 97u8, 254u8, 134u8, 138u8, 68u8, 168u8, 207u8, 37u8, 107u8, 232u8, - 197u8, 219u8, 22u8, 91u8, 16u8, 162u8, 159u8, 99u8, 232u8, 92u8, 187u8, - 182u8, 231u8, 220u8, 235u8, 215u8, 186u8, 185u8, 40u8, 131u8, 191u8, - 37u8, - ], - ) - } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_whitelist::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CallWhitelisted { - pub call_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for CallWhitelisted { - const PALLET: &'static str = "Whitelist"; - const EVENT: &'static str = "CallWhitelisted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WhitelistedCallRemoved { - pub call_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for WhitelistedCallRemoved { - const PALLET: &'static str = "Whitelist"; - const EVENT: &'static str = "WhitelistedCallRemoved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WhitelistedCallDispatched { - pub call_hash: ::subxt::utils::H256, - pub result: ::core::result::Result< - runtime_types::frame_support::dispatch::PostDispatchInfo, - runtime_types::sp_runtime::DispatchErrorWithPostInfo< - runtime_types::frame_support::dispatch::PostDispatchInfo, - >, - >, - } - impl ::subxt::events::StaticEvent for WhitelistedCallDispatched { - const PALLET: &'static str = "Whitelist"; - const EVENT: &'static str = "WhitelistedCallDispatched"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - pub fn whitelisted_call( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (), - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Whitelist", - "WhitelistedCall", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 251u8, 179u8, 58u8, 232u8, 231u8, 121u8, 89u8, 218u8, 90u8, 70u8, 96u8, - 132u8, 54u8, 41u8, 18u8, 129u8, 197u8, 122u8, 221u8, 206u8, 41u8, - 100u8, 200u8, 141u8, 71u8, 98u8, 3u8, 3u8, 112u8, 167u8, 196u8, 77u8, - ], - ) - } - pub fn whitelisted_call_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Whitelist", - "WhitelistedCall", - Vec::new(), - [ - 251u8, 179u8, 58u8, 232u8, 231u8, 121u8, 89u8, 218u8, 90u8, 70u8, 96u8, - 132u8, 54u8, 41u8, 18u8, 129u8, 197u8, 122u8, 221u8, 206u8, 41u8, - 100u8, 200u8, 141u8, 71u8, 98u8, 3u8, 3u8, 112u8, 167u8, 196u8, 77u8, - ], - ) - } - } - } - } - pub mod claims { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_common::claims::pallet::Error; + pub type Error = runtime_types::pallet_collective::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -16676,10 +14976,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Claim { - pub dest: ::subxt::utils::AccountId32, - pub ethereum_signature: - runtime_types::polkadot_runtime_common::claims::EcdsaSignature, + pub struct SetMembers { + pub new_members: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub prime: ::core::option::Option<::subxt::utils::AccountId32>, + pub old_count: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -16691,17 +14991,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MintClaim { - pub who: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub value: ::core::primitive::u128, - pub vesting_schedule: ::core::option::Option<( - ::core::primitive::u128, - ::core::primitive::u128, - ::core::primitive::u32, - )>, - pub statement: ::core::option::Option< - runtime_types::polkadot_runtime_common::claims::StatementKind, - >, + pub struct Execute { + pub proposal: ::std::boxed::Box, + #[codec(compact)] + pub length_bound: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -16713,11 +15006,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimAttest { - pub dest: ::subxt::utils::AccountId32, - pub ethereum_signature: - runtime_types::polkadot_runtime_common::claims::EcdsaSignature, - pub statement: ::std::vec::Vec<::core::primitive::u8>, + pub struct Propose { + #[codec(compact)] + pub threshold: ::core::primitive::u32, + pub proposal: ::std::boxed::Box, + #[codec(compact)] + pub length_bound: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -16729,8 +15023,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Attest { - pub statement: ::std::vec::Vec<::core::primitive::u8>, + pub struct Vote { + pub proposal: ::subxt::utils::H256, + #[codec(compact)] + pub index: ::core::primitive::u32, + pub approve: ::core::primitive::bool, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -16742,454 +15039,576 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MoveClaim { - pub old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, + pub struct DisapproveProposal { + pub proposal_hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Close { + pub proposal_hash: ::subxt::utils::H256, + #[codec(compact)] + pub index: ::core::primitive::u32, + pub proposal_weight_bound: runtime_types::sp_weights::weight_v2::Weight, + #[codec(compact)] + pub length_bound: ::core::primitive::u32, } } pub struct TransactionApi; impl TransactionApi { - #[doc = "Make a claim to collect your DOTs."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _None_."] + #[doc = "Set the collective's membership."] #[doc = ""] - #[doc = "Unsigned Validation:"] - #[doc = "A call to claim is deemed valid if the signature provided matches"] - #[doc = "the expected signed message of:"] + #[doc = "- `new_members`: The new member list. Be nice to the chain and provide it sorted."] + #[doc = "- `prime`: The prime member whose vote sets the default."] + #[doc = "- `old_count`: The upper bound for the previous number of members in storage. Used for"] + #[doc = " weight estimation."] #[doc = ""] - #[doc = "> Ethereum Signed Message:"] - #[doc = "> (configured prefix string)(address)"] + #[doc = "The dispatch of this call must be `SetMembersOrigin`."] #[doc = ""] - #[doc = "and `address` matches the `dest` account."] + #[doc = "NOTE: Does not enforce the expected `MaxMembers` limit on the amount of members, but"] + #[doc = " the weight estimations rely on it to estimate dispatchable weight."] #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `dest`: The destination account to payout the claim."] - #[doc = "- `ethereum_signature`: The signature of an ethereum signed message"] - #[doc = " matching the format described above."] + #[doc = "# WARNING:"] #[doc = ""] - #[doc = ""] - #[doc = "The weight of this call is invariant over the input parameters."] - #[doc = "Weight includes logic to validate unsigned `claim` call."] + #[doc = "The `pallet-collective` can also be managed by logic outside of the pallet through the"] + #[doc = "implementation of the trait [`ChangeMembers`]."] + #[doc = "Any call to `set_members` must be careful that the member set doesn't get out of sync"] + #[doc = "with other logic managing the member set."] #[doc = ""] - #[doc = "Total Complexity: O(1)"] - #[doc = ""] - pub fn claim( + #[doc = "## Complexity:"] + #[doc = "- `O(MP + N)` where:"] + #[doc = " - `M` old-members-count (code- and governance-bounded)"] + #[doc = " - `N` new-members-count (code- and governance-bounded)"] + #[doc = " - `P` proposals-count (code-bounded)"] + pub fn set_members( &self, - dest: ::subxt::utils::AccountId32, - ethereum_signature : runtime_types :: polkadot_runtime_common :: claims :: EcdsaSignature, - ) -> ::subxt::tx::Payload { + new_members: ::std::vec::Vec<::subxt::utils::AccountId32>, + prime: ::core::option::Option<::subxt::utils::AccountId32>, + old_count: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Claims", - "claim", - types::Claim { - dest, - ethereum_signature, + "TechnicalCommittee", + "set_members", + types::SetMembers { + new_members, + prime, + old_count, }, [ - 33u8, 63u8, 71u8, 104u8, 200u8, 179u8, 248u8, 38u8, 193u8, 198u8, - 250u8, 49u8, 106u8, 26u8, 109u8, 183u8, 33u8, 50u8, 217u8, 28u8, 50u8, - 107u8, 249u8, 80u8, 199u8, 10u8, 192u8, 1u8, 54u8, 41u8, 146u8, 11u8, + 196u8, 103u8, 123u8, 125u8, 226u8, 177u8, 126u8, 37u8, 160u8, 114u8, + 34u8, 136u8, 219u8, 84u8, 199u8, 94u8, 242u8, 20u8, 126u8, 126u8, + 166u8, 190u8, 198u8, 33u8, 162u8, 113u8, 237u8, 222u8, 90u8, 1u8, 2u8, + 234u8, ], ) } - #[doc = "Mint a new claim to collect DOTs."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Root_."] - #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `who`: The Ethereum address allowed to collect this claim."] - #[doc = "- `value`: The number of DOTs that will be claimed."] - #[doc = "- `vesting_schedule`: An optional vesting schedule for these DOTs."] + #[doc = "Dispatch a proposal from a member using the `Member` origin."] #[doc = ""] - #[doc = ""] - #[doc = "The weight of this call is invariant over the input parameters."] - #[doc = "We assume worst case that both vesting and statement is being inserted."] + #[doc = "Origin must be a member of the collective."] #[doc = ""] - #[doc = "Total Complexity: O(1)"] - #[doc = ""] - pub fn mint_claim( + #[doc = "## Complexity:"] + #[doc = "- `O(B + M + P)` where:"] + #[doc = "- `B` is `proposal` size in bytes (length-fee-bounded)"] + #[doc = "- `M` members-count (code-bounded)"] + #[doc = "- `P` complexity of dispatching `proposal`"] + pub fn execute( &self, - who: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - value: ::core::primitive::u128, - vesting_schedule: ::core::option::Option<( - ::core::primitive::u128, - ::core::primitive::u128, - ::core::primitive::u32, - )>, - statement: ::core::option::Option< - runtime_types::polkadot_runtime_common::claims::StatementKind, - >, - ) -> ::subxt::tx::Payload { + proposal: runtime_types::polkadot_runtime::RuntimeCall, + length_bound: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Claims", - "mint_claim", - types::MintClaim { - who, - value, - vesting_schedule, - statement, + "TechnicalCommittee", + "execute", + types::Execute { + proposal: ::std::boxed::Box::new(proposal), + length_bound, }, [ - 213u8, 79u8, 204u8, 40u8, 104u8, 84u8, 82u8, 62u8, 193u8, 93u8, 246u8, - 21u8, 37u8, 244u8, 166u8, 132u8, 208u8, 18u8, 86u8, 195u8, 156u8, 9u8, - 220u8, 120u8, 40u8, 183u8, 28u8, 103u8, 84u8, 163u8, 153u8, 110u8, + 0u8, 74u8, 70u8, 223u8, 112u8, 196u8, 199u8, 189u8, 93u8, 14u8, 101u8, + 211u8, 221u8, 38u8, 32u8, 220u8, 90u8, 120u8, 94u8, 107u8, 46u8, 121u8, + 250u8, 150u8, 26u8, 24u8, 20u8, 242u8, 253u8, 229u8, 43u8, 195u8, ], ) } - #[doc = "Make a claim to collect your DOTs by signing a statement."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _None_."] - #[doc = ""] - #[doc = "Unsigned Validation:"] - #[doc = "A call to `claim_attest` is deemed valid if the signature provided matches"] - #[doc = "the expected signed message of:"] - #[doc = ""] - #[doc = "> Ethereum Signed Message:"] - #[doc = "> (configured prefix string)(address)(statement)"] - #[doc = ""] - #[doc = "and `address` matches the `dest` account; the `statement` must match that which is"] - #[doc = "expected according to your purchase arrangement."] + #[doc = "Add a new proposal to either be voted on or executed directly."] #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `dest`: The destination account to payout the claim."] - #[doc = "- `ethereum_signature`: The signature of an ethereum signed message"] - #[doc = " matching the format described above."] - #[doc = "- `statement`: The identity of the statement which is being attested to in the signature."] + #[doc = "Requires the sender to be member."] #[doc = ""] - #[doc = ""] - #[doc = "The weight of this call is invariant over the input parameters."] - #[doc = "Weight includes logic to validate unsigned `claim_attest` call."] + #[doc = "`threshold` determines whether `proposal` is executed directly (`threshold < 2`)"] + #[doc = "or put up for voting."] #[doc = ""] - #[doc = "Total Complexity: O(1)"] - #[doc = ""] - pub fn claim_attest( + #[doc = "## Complexity"] + #[doc = "- `O(B + M + P1)` or `O(B + M + P2)` where:"] + #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] + #[doc = " - `M` is members-count (code- and governance-bounded)"] + #[doc = " - branching is influenced by `threshold` where:"] + #[doc = " - `P1` is proposal execution complexity (`threshold < 2`)"] + #[doc = " - `P2` is proposals-count (code-bounded) (`threshold >= 2`)"] + pub fn propose( &self, - dest: ::subxt::utils::AccountId32, - ethereum_signature : runtime_types :: polkadot_runtime_common :: claims :: EcdsaSignature, - statement: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + threshold: ::core::primitive::u32, + proposal: runtime_types::polkadot_runtime::RuntimeCall, + length_bound: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Claims", - "claim_attest", - types::ClaimAttest { - dest, - ethereum_signature, - statement, + "TechnicalCommittee", + "propose", + types::Propose { + threshold, + proposal: ::std::boxed::Box::new(proposal), + length_bound, }, [ - 255u8, 10u8, 87u8, 106u8, 101u8, 195u8, 249u8, 25u8, 109u8, 82u8, - 213u8, 95u8, 203u8, 145u8, 224u8, 113u8, 92u8, 141u8, 31u8, 54u8, - 218u8, 47u8, 218u8, 239u8, 211u8, 206u8, 77u8, 176u8, 19u8, 176u8, - 175u8, 135u8, + 157u8, 103u8, 73u8, 75u8, 15u8, 79u8, 50u8, 64u8, 5u8, 151u8, 194u8, + 216u8, 45u8, 47u8, 128u8, 206u8, 191u8, 52u8, 5u8, 104u8, 70u8, 6u8, + 139u8, 184u8, 12u8, 190u8, 109u8, 132u8, 195u8, 177u8, 197u8, 179u8, ], ) } - #[doc = "Attest to a statement, needed to finalize the claims process."] - #[doc = ""] - #[doc = "WARNING: Insecure unless your chain includes `PrevalidateAttests` as a `SignedExtension`."] - #[doc = ""] - #[doc = "Unsigned Validation:"] - #[doc = "A call to attest is deemed valid if the sender has a `Preclaim` registered"] - #[doc = "and provides a `statement` which is expected for the account."] - #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `statement`: The identity of the statement which is being attested to in the signature."] + #[doc = "Add an aye or nay vote for the sender to the given proposal."] #[doc = ""] - #[doc = ""] - #[doc = "The weight of this call is invariant over the input parameters."] - #[doc = "Weight includes logic to do pre-validation on `attest` call."] + #[doc = "Requires the sender to be a member."] #[doc = ""] - #[doc = "Total Complexity: O(1)"] - #[doc = ""] - pub fn attest( + #[doc = "Transaction fees will be waived if the member is voting on any particular proposal"] + #[doc = "for the first time and the call is successful. Subsequent vote changes will charge a"] + #[doc = "fee."] + #[doc = "## Complexity"] + #[doc = "- `O(M)` where `M` is members-count (code- and governance-bounded)"] + pub fn vote( &self, - statement: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { + proposal: ::subxt::utils::H256, + index: ::core::primitive::u32, + approve: ::core::primitive::bool, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Claims", - "attest", - types::Attest { statement }, + "TechnicalCommittee", + "vote", + types::Vote { + proposal, + index, + approve, + }, [ - 8u8, 218u8, 97u8, 237u8, 185u8, 61u8, 55u8, 4u8, 134u8, 18u8, 244u8, - 226u8, 40u8, 97u8, 222u8, 246u8, 221u8, 74u8, 253u8, 22u8, 52u8, 223u8, - 224u8, 83u8, 21u8, 218u8, 248u8, 100u8, 107u8, 58u8, 247u8, 10u8, + 108u8, 46u8, 180u8, 148u8, 145u8, 24u8, 173u8, 56u8, 36u8, 100u8, + 216u8, 43u8, 178u8, 202u8, 26u8, 136u8, 93u8, 84u8, 80u8, 134u8, 14u8, + 42u8, 248u8, 205u8, 68u8, 92u8, 79u8, 11u8, 113u8, 115u8, 157u8, 100u8, ], ) } - pub fn move_claim( + #[doc = "Disapprove a proposal, close, and remove it from the system, regardless of its current"] + #[doc = "state."] + #[doc = ""] + #[doc = "Must be called by the Root origin."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "* `proposal_hash`: The hash of the proposal that should be disapproved."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "O(P) where P is the number of max proposals"] + pub fn disapprove_proposal( &self, - old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { + proposal_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Claims", - "move_claim", - types::MoveClaim { - old, - new, - maybe_preclaim, - }, + "TechnicalCommittee", + "disapprove_proposal", + types::DisapproveProposal { proposal_hash }, [ - 63u8, 48u8, 217u8, 16u8, 161u8, 102u8, 165u8, 241u8, 57u8, 185u8, - 230u8, 161u8, 202u8, 11u8, 223u8, 15u8, 57u8, 181u8, 34u8, 131u8, - 235u8, 168u8, 227u8, 152u8, 157u8, 4u8, 192u8, 243u8, 194u8, 120u8, - 130u8, 202u8, + 25u8, 123u8, 1u8, 8u8, 74u8, 37u8, 3u8, 40u8, 97u8, 37u8, 175u8, 224u8, + 72u8, 155u8, 123u8, 109u8, 104u8, 43u8, 91u8, 125u8, 199u8, 51u8, 17u8, + 225u8, 133u8, 38u8, 120u8, 76u8, 164u8, 5u8, 194u8, 201u8, ], ) } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::polkadot_runtime_common::claims::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] + #[doc = "Close a vote that is either approved, disapproved or whose voting period has ended."] + #[doc = ""] + #[doc = "May be called by any signed account in order to finish voting and close the proposal."] + #[doc = ""] + #[doc = "If called before the end of the voting period it will only close the vote if it is"] + #[doc = "has enough votes to be approved or disapproved."] + #[doc = ""] + #[doc = "If called after the end of the voting period abstentions are counted as rejections"] + #[doc = "unless there is a prime member set and the prime member cast an approval."] + #[doc = ""] + #[doc = "If the close operation completes successfully with disapproval, the transaction fee will"] + #[doc = "be waived. Otherwise execution of the approved operation will be charged to the caller."] + #[doc = ""] + #[doc = "+ `proposal_weight_bound`: The maximum amount of weight consumed by executing the closed"] + #[doc = "proposal."] + #[doc = "+ `length_bound`: The upper bound for the length of the proposal in storage. Checked via"] + #[doc = "`storage::read` so it is `size_of::() == 4` larger than the pure length."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(B + M + P1 + P2)` where:"] + #[doc = " - `B` is `proposal` size in bytes (length-fee-bounded)"] + #[doc = " - `M` is members-count (code- and governance-bounded)"] + #[doc = " - `P1` is the complexity of `proposal` preimage."] + #[doc = " - `P2` is proposal-count (code-bounded)"] + pub fn close( + &self, + proposal_hash: ::subxt::utils::H256, + index: ::core::primitive::u32, + proposal_weight_bound: runtime_types::sp_weights::weight_v2::Weight, + length_bound: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "TechnicalCommittee", + "close", + types::Close { + proposal_hash, + index, + proposal_weight_bound, + length_bound, + }, + [ + 191u8, 138u8, 89u8, 247u8, 97u8, 51u8, 45u8, 193u8, 76u8, 16u8, 80u8, + 225u8, 197u8, 83u8, 204u8, 133u8, 169u8, 16u8, 86u8, 32u8, 125u8, 16u8, + 116u8, 185u8, 45u8, 20u8, 76u8, 148u8, 206u8, 163u8, 154u8, 30u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_collective::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Someone claimed some DOTs."] - pub struct Claimed { - pub who: ::subxt::utils::AccountId32, - pub ethereum_address: - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub amount: ::core::primitive::u128, + #[doc = "A motion (given hash) has been proposed (by given account) with a threshold (given"] + #[doc = "`MemberCount`)."] + pub struct Proposed { + pub account: ::subxt::utils::AccountId32, + pub proposal_index: ::core::primitive::u32, + pub proposal_hash: ::subxt::utils::H256, + pub threshold: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for Claimed { - const PALLET: &'static str = "Claims"; - const EVENT: &'static str = "Claimed"; + impl ::subxt::events::StaticEvent for Proposed { + const PALLET: &'static str = "TechnicalCommittee"; + const EVENT: &'static str = "Proposed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A motion (given hash) has been voted on by given account, leaving"] + #[doc = "a tally (yes votes and no votes given respectively as `MemberCount`)."] + pub struct Voted { + pub account: ::subxt::utils::AccountId32, + pub proposal_hash: ::subxt::utils::H256, + pub voted: ::core::primitive::bool, + pub yes: ::core::primitive::u32, + pub no: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Voted { + const PALLET: &'static str = "TechnicalCommittee"; + const EVENT: &'static str = "Voted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A motion was approved by the required threshold."] + pub struct Approved { + pub proposal_hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for Approved { + const PALLET: &'static str = "TechnicalCommittee"; + const EVENT: &'static str = "Approved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A motion was not approved by the required threshold."] + pub struct Disapproved { + pub proposal_hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for Disapproved { + const PALLET: &'static str = "TechnicalCommittee"; + const EVENT: &'static str = "Disapproved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A motion was executed; result will be `Ok` if it returned without error."] + pub struct Executed { + pub proposal_hash: ::subxt::utils::H256, + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + } + impl ::subxt::events::StaticEvent for Executed { + const PALLET: &'static str = "TechnicalCommittee"; + const EVENT: &'static str = "Executed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A single member did some action; result will be `Ok` if it returned without error."] + pub struct MemberExecuted { + pub proposal_hash: ::subxt::utils::H256, + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + } + impl ::subxt::events::StaticEvent for MemberExecuted { + const PALLET: &'static str = "TechnicalCommittee"; + const EVENT: &'static str = "MemberExecuted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A proposal was closed because its threshold was reached or after its duration was up."] + pub struct Closed { + pub proposal_hash: ::subxt::utils::H256, + pub yes: ::core::primitive::u32, + pub no: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Closed { + const PALLET: &'static str = "TechnicalCommittee"; + const EVENT: &'static str = "Closed"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - pub fn claims( + #[doc = " The hashes of the active proposals."] + pub fn proposals( &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - >, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::H256, + >, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Claims", - "Claims", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "TechnicalCommittee", + "Proposals", + vec![], [ - 36u8, 247u8, 169u8, 171u8, 103u8, 176u8, 70u8, 213u8, 255u8, 175u8, - 97u8, 142u8, 231u8, 70u8, 90u8, 213u8, 128u8, 67u8, 50u8, 37u8, 51u8, - 184u8, 72u8, 27u8, 193u8, 254u8, 12u8, 253u8, 91u8, 60u8, 88u8, 182u8, + 10u8, 133u8, 82u8, 54u8, 193u8, 41u8, 253u8, 159u8, 56u8, 96u8, 249u8, + 148u8, 43u8, 57u8, 116u8, 43u8, 222u8, 243u8, 237u8, 231u8, 238u8, + 60u8, 26u8, 225u8, 19u8, 203u8, 213u8, 220u8, 114u8, 217u8, 100u8, + 27u8, ], ) } - pub fn claims_root( + #[doc = " Actual proposal for a given hash, if it's current."] + pub fn proposal_of( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - (), + runtime_types::polkadot_runtime::RuntimeCall, + ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Claims", - "Claims", - Vec::new(), + "TechnicalCommittee", + "ProposalOf", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 36u8, 247u8, 169u8, 171u8, 103u8, 176u8, 70u8, 213u8, 255u8, 175u8, - 97u8, 142u8, 231u8, 70u8, 90u8, 213u8, 128u8, 67u8, 50u8, 37u8, 51u8, - 184u8, 72u8, 27u8, 193u8, 254u8, 12u8, 253u8, 91u8, 60u8, 88u8, 182u8, + 6u8, 23u8, 244u8, 48u8, 73u8, 203u8, 222u8, 109u8, 218u8, 166u8, 6u8, + 137u8, 121u8, 88u8, 54u8, 188u8, 37u8, 8u8, 229u8, 217u8, 170u8, 108u8, + 198u8, 66u8, 36u8, 92u8, 107u8, 168u8, 162u8, 204u8, 210u8, 20u8, ], ) } - pub fn total( + #[doc = " Actual proposal for a given hash, if it's current."] + pub fn proposal_of_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, + runtime_types::polkadot_runtime::RuntimeCall, (), + (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Claims", - "Total", - vec![], + "TechnicalCommittee", + "ProposalOf", + Vec::new(), [ - 162u8, 59u8, 237u8, 63u8, 23u8, 44u8, 74u8, 169u8, 131u8, 166u8, 174u8, - 61u8, 127u8, 165u8, 32u8, 115u8, 73u8, 171u8, 36u8, 10u8, 6u8, 23u8, - 19u8, 202u8, 3u8, 189u8, 29u8, 169u8, 144u8, 187u8, 235u8, 77u8, + 6u8, 23u8, 244u8, 48u8, 73u8, 203u8, 222u8, 109u8, 218u8, 166u8, 6u8, + 137u8, 121u8, 88u8, 54u8, 188u8, 37u8, 8u8, 229u8, 217u8, 170u8, 108u8, + 198u8, 66u8, 36u8, 92u8, 107u8, 168u8, 162u8, 204u8, 210u8, 20u8, ], ) } - #[doc = " Vesting schedule for a claim."] - #[doc = " First balance is the total amount that should be held for vesting."] - #[doc = " Second balance is how much should be unlocked per block."] - #[doc = " The block number is when the vesting should start."] - pub fn vesting( + #[doc = " Votes on a given proposal, if it is ongoing."] + pub fn voting( &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - >, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u128, - ::core::primitive::u128, + runtime_types::pallet_collective::Votes< + ::subxt::utils::AccountId32, ::core::primitive::u32, - ), + >, ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Claims", - "Vesting", + "TechnicalCommittee", + "Voting", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 112u8, 174u8, 151u8, 185u8, 225u8, 170u8, 63u8, 147u8, 100u8, 23u8, - 102u8, 148u8, 244u8, 47u8, 87u8, 99u8, 28u8, 59u8, 48u8, 205u8, 43u8, - 41u8, 87u8, 225u8, 191u8, 164u8, 31u8, 208u8, 80u8, 53u8, 25u8, 205u8, + 89u8, 108u8, 65u8, 58u8, 60u8, 116u8, 54u8, 68u8, 179u8, 73u8, 161u8, + 168u8, 78u8, 213u8, 208u8, 54u8, 244u8, 58u8, 70u8, 209u8, 170u8, + 136u8, 215u8, 3u8, 2u8, 105u8, 229u8, 217u8, 240u8, 230u8, 107u8, + 221u8, ], ) } - #[doc = " Vesting schedule for a claim."] - #[doc = " First balance is the total amount that should be held for vesting."] - #[doc = " Second balance is how much should be unlocked per block."] - #[doc = " The block number is when the vesting should start."] - pub fn vesting_root( + #[doc = " Votes on a given proposal, if it is ongoing."] + pub fn voting_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u128, - ::core::primitive::u128, + runtime_types::pallet_collective::Votes< + ::subxt::utils::AccountId32, ::core::primitive::u32, - ), + >, (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Claims", - "Vesting", + "TechnicalCommittee", + "Voting", Vec::new(), [ - 112u8, 174u8, 151u8, 185u8, 225u8, 170u8, 63u8, 147u8, 100u8, 23u8, - 102u8, 148u8, 244u8, 47u8, 87u8, 99u8, 28u8, 59u8, 48u8, 205u8, 43u8, - 41u8, 87u8, 225u8, 191u8, 164u8, 31u8, 208u8, 80u8, 53u8, 25u8, 205u8, + 89u8, 108u8, 65u8, 58u8, 60u8, 116u8, 54u8, 68u8, 179u8, 73u8, 161u8, + 168u8, 78u8, 213u8, 208u8, 54u8, 244u8, 58u8, 70u8, 209u8, 170u8, + 136u8, 215u8, 3u8, 2u8, 105u8, 229u8, 217u8, 240u8, 230u8, 107u8, + 221u8, ], ) } - #[doc = " The statement kind that must be signed, if any."] - pub fn signing( + #[doc = " Proposals so far."] + pub fn proposal_count( &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - >, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::claims::StatementKind, + ::core::primitive::u32, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Signing", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 51u8, 184u8, 211u8, 207u8, 13u8, 194u8, 181u8, 153u8, 25u8, 212u8, - 106u8, 189u8, 149u8, 14u8, 19u8, 61u8, 210u8, 109u8, 23u8, 168u8, - 191u8, 74u8, 112u8, 190u8, 242u8, 112u8, 183u8, 17u8, 30u8, 125u8, - 85u8, 107u8, - ], - ) - } - #[doc = " The statement kind that must be signed, if any."] - pub fn signing_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::claims::StatementKind, - (), (), - ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Claims", - "Signing", - Vec::new(), + "TechnicalCommittee", + "ProposalCount", + vec![], [ - 51u8, 184u8, 211u8, 207u8, 13u8, 194u8, 181u8, 153u8, 25u8, 212u8, - 106u8, 189u8, 149u8, 14u8, 19u8, 61u8, 210u8, 109u8, 23u8, 168u8, - 191u8, 74u8, 112u8, 190u8, 242u8, 112u8, 183u8, 17u8, 30u8, 125u8, - 85u8, 107u8, + 132u8, 145u8, 78u8, 218u8, 51u8, 189u8, 55u8, 172u8, 143u8, 33u8, + 140u8, 99u8, 124u8, 208u8, 57u8, 232u8, 154u8, 110u8, 32u8, 142u8, + 24u8, 149u8, 109u8, 105u8, 30u8, 83u8, 39u8, 177u8, 127u8, 160u8, 34u8, + 70u8, ], ) } - #[doc = " Pre-claimed Ethereum accounts, by the Account ID that they are claimed to."] - pub fn preclaims( + #[doc = " The current members of the collective. This is stored sorted (just by value)."] + pub fn members( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::claims::EthereumAddress, + ::std::vec::Vec<::subxt::utils::AccountId32>, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Claims", - "Preclaims", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "TechnicalCommittee", + "Members", + vec![], [ - 149u8, 61u8, 170u8, 170u8, 60u8, 212u8, 29u8, 214u8, 141u8, 136u8, - 207u8, 248u8, 51u8, 135u8, 242u8, 105u8, 121u8, 91u8, 186u8, 30u8, 0u8, - 173u8, 154u8, 133u8, 20u8, 244u8, 58u8, 184u8, 133u8, 214u8, 67u8, - 95u8, + 162u8, 72u8, 174u8, 204u8, 140u8, 105u8, 205u8, 176u8, 197u8, 117u8, + 206u8, 134u8, 157u8, 110u8, 139u8, 54u8, 43u8, 233u8, 25u8, 51u8, 36u8, + 238u8, 94u8, 124u8, 221u8, 52u8, 237u8, 71u8, 125u8, 56u8, 129u8, + 222u8, ], ) } - #[doc = " Pre-claimed Ethereum accounts, by the Account ID that they are claimed to."] - pub fn preclaims_root( + #[doc = " The prime member that helps determine the default vote behavior in case of absentations."] + pub fn prime( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::claims::EthereumAddress, + ::subxt::utils::AccountId32, + ::subxt::storage::address::Yes, (), (), - ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Claims", - "Preclaims", - Vec::new(), + "TechnicalCommittee", + "Prime", + vec![], [ - 149u8, 61u8, 170u8, 170u8, 60u8, 212u8, 29u8, 214u8, 141u8, 136u8, - 207u8, 248u8, 51u8, 135u8, 242u8, 105u8, 121u8, 91u8, 186u8, 30u8, 0u8, - 173u8, 154u8, 133u8, 20u8, 244u8, 58u8, 184u8, 133u8, 214u8, 67u8, - 95u8, + 108u8, 118u8, 54u8, 193u8, 207u8, 227u8, 119u8, 97u8, 23u8, 239u8, + 157u8, 69u8, 56u8, 142u8, 106u8, 17u8, 215u8, 159u8, 48u8, 42u8, 185u8, + 209u8, 49u8, 159u8, 32u8, 168u8, 111u8, 158u8, 159u8, 217u8, 244u8, + 158u8, ], ) } @@ -17199,28 +15618,30 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - pub fn prefix( + #[doc = " The maximum weight of a dispatch call that can be proposed and executed."] + pub fn max_proposal_weight( &self, - ) -> ::subxt::constants::Address<::std::vec::Vec<::core::primitive::u8>> + ) -> ::subxt::constants::Address { ::subxt::constants::Address::new_static( - "Claims", - "Prefix", + "TechnicalCommittee", + "MaxProposalWeight", [ - 106u8, 50u8, 57u8, 116u8, 43u8, 202u8, 37u8, 248u8, 102u8, 22u8, 62u8, - 22u8, 242u8, 54u8, 152u8, 168u8, 107u8, 64u8, 72u8, 172u8, 124u8, 40u8, - 42u8, 110u8, 104u8, 145u8, 31u8, 144u8, 242u8, 189u8, 145u8, 208u8, + 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, + 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, + 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, + 106u8, 76u8, ], ) } } } } - pub mod vesting { + pub mod phragmen_election { use super::root_mod; use super::runtime_types; - #[doc = "Error for the vesting pallet."] - pub type Error = runtime_types::pallet_vesting::pallet::Error; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_elections_phragmen::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -17238,7 +15659,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vest; + pub struct Vote { + pub votes: ::std::vec::Vec<::subxt::utils::AccountId32>, + #[codec(compact)] + pub value: ::core::primitive::u128, + } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -17249,8 +15674,20 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VestOther { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub struct RemoveVoter; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SubmitCandidacy { + #[codec(compact)] + pub candidate_count: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17262,12 +15699,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VestedTransfer { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, + pub struct RenounceCandidacy { + pub renouncing: runtime_types::pallet_elections_phragmen::Renouncing, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17279,13 +15712,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceVestedTransfer { - pub source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, + pub struct RemoveMember { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub slash_bond: ::core::primitive::bool, + pub rerun_election: ::core::primitive::bool, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17297,176 +15727,201 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MergeSchedules { - pub schedule1_index: ::core::primitive::u32, - pub schedule2_index: ::core::primitive::u32, + pub struct CleanDefunctVoters { + pub num_voters: ::core::primitive::u32, + pub num_defunct: ::core::primitive::u32, } } pub struct TransactionApi; impl TransactionApi { - #[doc = "Unlock any vested funds of the sender account."] + #[doc = "Vote for a set of candidates for the upcoming round of election. This can be called to"] + #[doc = "set the initial votes, or update already existing votes."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have funds still"] - #[doc = "locked under this pallet."] + #[doc = "Upon initial voting, `value` units of `who`'s balance is locked and a deposit amount is"] + #[doc = "reserved. The deposit is based on the number of votes and can be updated over time."] #[doc = ""] - #[doc = "Emits either `VestingCompleted` or `VestingUpdated`."] + #[doc = "The `votes` should:"] + #[doc = " - not be empty."] + #[doc = " - be less than the number of possible candidates. Note that all current members and"] + #[doc = " runners-up are also automatically candidates for the next round."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(1)`."] - pub fn vest(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Vesting", - "vest", - types::Vest {}, - [ - 123u8, 54u8, 10u8, 208u8, 154u8, 24u8, 39u8, 166u8, 64u8, 27u8, 74u8, - 29u8, 243u8, 97u8, 155u8, 5u8, 130u8, 155u8, 65u8, 181u8, 196u8, 125u8, - 45u8, 133u8, 25u8, 33u8, 3u8, 34u8, 21u8, 167u8, 172u8, 54u8, - ], - ) - } - #[doc = "Unlock any vested funds of a `target` account."] + #[doc = "If `value` is more than `who`'s free balance, then the maximum of the two is used."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "The dispatch origin of this call must be signed."] #[doc = ""] - #[doc = "- `target`: The account whose vested funds should be unlocked. Must have funds still"] - #[doc = "locked under this pallet."] - #[doc = ""] - #[doc = "Emits either `VestingCompleted` or `VestingUpdated`."] + #[doc = "### Warning"] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(1)`."] - pub fn vest_other( + #[doc = "It is the responsibility of the caller to **NOT** place all of their balance into the"] + #[doc = "lock and keep some for further operations."] + pub fn vote( &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + votes: ::std::vec::Vec<::subxt::utils::AccountId32>, + value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Vesting", - "vest_other", - types::VestOther { target }, + "PhragmenElection", + "vote", + types::Vote { votes, value }, [ - 164u8, 19u8, 93u8, 81u8, 235u8, 101u8, 18u8, 52u8, 187u8, 81u8, 243u8, - 216u8, 116u8, 84u8, 188u8, 135u8, 1u8, 241u8, 128u8, 90u8, 117u8, - 164u8, 111u8, 0u8, 251u8, 148u8, 250u8, 248u8, 102u8, 79u8, 165u8, - 175u8, + 71u8, 90u8, 175u8, 225u8, 51u8, 202u8, 197u8, 252u8, 183u8, 92u8, + 239u8, 83u8, 112u8, 144u8, 128u8, 211u8, 109u8, 33u8, 252u8, 6u8, + 156u8, 15u8, 91u8, 88u8, 70u8, 19u8, 32u8, 29u8, 224u8, 255u8, 26u8, + 145u8, ], ) } - #[doc = "Create a vested transfer."] + #[doc = "Remove `origin` as a voter."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "This removes the lock and returns the deposit."] #[doc = ""] - #[doc = "- `target`: The account receiving the vested funds."] - #[doc = "- `schedule`: The vesting schedule attached to the transfer."] + #[doc = "The dispatch origin of this call must be signed and be a voter."] + pub fn remove_voter(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PhragmenElection", + "remove_voter", + types::RemoveVoter {}, + [ + 254u8, 46u8, 140u8, 4u8, 218u8, 45u8, 150u8, 72u8, 67u8, 131u8, 108u8, + 201u8, 46u8, 157u8, 104u8, 161u8, 53u8, 155u8, 130u8, 50u8, 88u8, + 149u8, 255u8, 12u8, 17u8, 85u8, 95u8, 69u8, 153u8, 130u8, 221u8, 1u8, + ], + ) + } + #[doc = "Submit oneself for candidacy. A fixed amount of deposit is recorded."] #[doc = ""] - #[doc = "Emits `VestingCreated`."] + #[doc = "All candidates are wiped at the end of the term. They either become a member/runner-up,"] + #[doc = "or leave the system while their deposit is slashed."] #[doc = ""] - #[doc = "NOTE: This will unlock all schedules through the current block."] + #[doc = "The dispatch origin of this call must be signed."] + #[doc = ""] + #[doc = "### Warning"] + #[doc = ""] + #[doc = "Even if a candidate ends up being a member, they must call [`Call::renounce_candidacy`]"] + #[doc = "to get their deposit back. Losing the spot in an election will always lead to a slash."] #[doc = ""] + #[doc = "The number of current candidates must be provided as witness data."] #[doc = "## Complexity"] - #[doc = "- `O(1)`."] - pub fn vested_transfer( + #[doc = "O(C + log(C)) where C is candidate_count."] + pub fn submit_candidacy( &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - ) -> ::subxt::tx::Payload { + candidate_count: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Vesting", - "vested_transfer", - types::VestedTransfer { target, schedule }, + "PhragmenElection", + "submit_candidacy", + types::SubmitCandidacy { candidate_count }, [ - 135u8, 172u8, 56u8, 97u8, 45u8, 141u8, 93u8, 173u8, 111u8, 252u8, 75u8, - 246u8, 92u8, 181u8, 138u8, 87u8, 145u8, 174u8, 71u8, 108u8, 126u8, - 118u8, 49u8, 122u8, 249u8, 132u8, 19u8, 2u8, 132u8, 160u8, 247u8, - 195u8, + 228u8, 63u8, 217u8, 99u8, 128u8, 104u8, 175u8, 10u8, 30u8, 35u8, 47u8, + 14u8, 254u8, 122u8, 146u8, 239u8, 61u8, 145u8, 82u8, 7u8, 181u8, 98u8, + 238u8, 208u8, 23u8, 84u8, 48u8, 255u8, 177u8, 255u8, 84u8, 83u8, ], ) } - #[doc = "Force a vested transfer."] + #[doc = "Renounce one's intention to be a candidate for the next election round. 3 potential"] + #[doc = "outcomes exist:"] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Root_."] + #[doc = "- `origin` is a candidate and not elected in any set. In this case, the deposit is"] + #[doc = " unreserved, returned and origin is removed as a candidate."] + #[doc = "- `origin` is a current runner-up. In this case, the deposit is unreserved, returned and"] + #[doc = " origin is removed as a runner-up."] + #[doc = "- `origin` is a current member. In this case, the deposit is unreserved and origin is"] + #[doc = " removed as a member, consequently not being a candidate for the next round anymore."] + #[doc = " Similar to [`remove_member`](Self::remove_member), if replacement runners exists, they"] + #[doc = " are immediately used. If the prime is renouncing, then no prime will exist until the"] + #[doc = " next round."] #[doc = ""] - #[doc = "- `source`: The account whose funds should be transferred."] - #[doc = "- `target`: The account that should be transferred the vested funds."] - #[doc = "- `schedule`: The vesting schedule attached to the transfer."] + #[doc = "The dispatch origin of this call must be signed, and have one of the above roles."] + #[doc = "The type of renouncing must be provided as witness data."] #[doc = ""] - #[doc = "Emits `VestingCreated`."] + #[doc = "## Complexity"] + #[doc = " - Renouncing::Candidate(count): O(count + log(count))"] + #[doc = " - Renouncing::Member: O(1)"] + #[doc = " - Renouncing::RunnerUp: O(1)"] + pub fn renounce_candidacy( + &self, + renouncing: runtime_types::pallet_elections_phragmen::Renouncing, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PhragmenElection", + "renounce_candidacy", + types::RenounceCandidacy { renouncing }, + [ + 70u8, 72u8, 208u8, 36u8, 80u8, 245u8, 224u8, 75u8, 60u8, 142u8, 19u8, + 49u8, 142u8, 90u8, 14u8, 69u8, 15u8, 61u8, 170u8, 235u8, 16u8, 252u8, + 86u8, 200u8, 120u8, 127u8, 36u8, 42u8, 143u8, 130u8, 217u8, 128u8, + ], + ) + } + #[doc = "Remove a particular member from the set. This is effective immediately and the bond of"] + #[doc = "the outgoing member is slashed."] #[doc = ""] - #[doc = "NOTE: This will unlock all schedules through the current block."] + #[doc = "If a runner-up is available, then the best runner-up will be removed and replaces the"] + #[doc = "outgoing member. Otherwise, if `rerun_election` is `true`, a new phragmen election is"] + #[doc = "started, else, nothing happens."] + #[doc = ""] + #[doc = "If `slash_bond` is set to true, the bond of the member being removed is slashed. Else,"] + #[doc = "it is returned."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be root."] + #[doc = ""] + #[doc = "Note that this does not affect the designated block number of the next election."] #[doc = ""] #[doc = "## Complexity"] - #[doc = "- `O(1)`."] - pub fn force_vested_transfer( + #[doc = "- Check details of remove_and_replace_member() and do_phragmen()."] + pub fn remove_member( &self, - source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - ) -> ::subxt::tx::Payload { + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + slash_bond: ::core::primitive::bool, + rerun_election: ::core::primitive::bool, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Vesting", - "force_vested_transfer", - types::ForceVestedTransfer { - source, - target, - schedule, + "PhragmenElection", + "remove_member", + types::RemoveMember { + who, + slash_bond, + rerun_election, }, [ - 110u8, 142u8, 63u8, 148u8, 90u8, 229u8, 237u8, 183u8, 240u8, 237u8, - 242u8, 32u8, 88u8, 48u8, 220u8, 101u8, 210u8, 212u8, 27u8, 7u8, 186u8, - 98u8, 28u8, 197u8, 148u8, 140u8, 77u8, 59u8, 202u8, 166u8, 63u8, 97u8, + 45u8, 106u8, 9u8, 19u8, 133u8, 38u8, 20u8, 233u8, 12u8, 169u8, 216u8, + 40u8, 23u8, 139u8, 184u8, 202u8, 2u8, 124u8, 202u8, 48u8, 205u8, 176u8, + 161u8, 43u8, 66u8, 24u8, 189u8, 183u8, 233u8, 62u8, 102u8, 237u8, ], ) } - #[doc = "Merge two vesting schedules together, creating a new vesting schedule that unlocks over"] - #[doc = "the highest possible start and end blocks. If both schedules have already started the"] - #[doc = "current block will be used as the schedule start; with the caveat that if one schedule"] - #[doc = "is finished by the current block, the other will be treated as the new merged schedule,"] - #[doc = "unmodified."] - #[doc = ""] - #[doc = "NOTE: If `schedule1_index == schedule2_index` this is a no-op."] - #[doc = "NOTE: This will unlock all schedules through the current block prior to merging."] - #[doc = "NOTE: If both schedules have ended by the current block, no new schedule will be created"] - #[doc = "and both will be removed."] + #[doc = "Clean all voters who are defunct (i.e. they do not serve any purpose at all). The"] + #[doc = "deposit of the removed voters are returned."] #[doc = ""] - #[doc = "Merged schedule attributes:"] - #[doc = "- `starting_block`: `MAX(schedule1.starting_block, scheduled2.starting_block,"] - #[doc = " current_block)`."] - #[doc = "- `ending_block`: `MAX(schedule1.ending_block, schedule2.ending_block)`."] - #[doc = "- `locked`: `schedule1.locked_at(current_block) + schedule2.locked_at(current_block)`."] + #[doc = "This is an root function to be used only for cleaning the state."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "The dispatch origin of this call must be root."] #[doc = ""] - #[doc = "- `schedule1_index`: index of the first schedule to merge."] - #[doc = "- `schedule2_index`: index of the second schedule to merge."] - pub fn merge_schedules( + #[doc = "## Complexity"] + #[doc = "- Check is_defunct_voter() details."] + pub fn clean_defunct_voters( &self, - schedule1_index: ::core::primitive::u32, - schedule2_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + num_voters: ::core::primitive::u32, + num_defunct: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Vesting", - "merge_schedules", - types::MergeSchedules { - schedule1_index, - schedule2_index, + "PhragmenElection", + "clean_defunct_voters", + types::CleanDefunctVoters { + num_voters, + num_defunct, }, [ - 95u8, 255u8, 147u8, 12u8, 49u8, 25u8, 70u8, 112u8, 55u8, 154u8, 183u8, - 97u8, 56u8, 244u8, 148u8, 61u8, 107u8, 163u8, 220u8, 31u8, 153u8, 25u8, - 193u8, 251u8, 131u8, 26u8, 166u8, 157u8, 75u8, 4u8, 110u8, 125u8, + 198u8, 162u8, 30u8, 249u8, 191u8, 38u8, 141u8, 123u8, 230u8, 90u8, + 213u8, 103u8, 168u8, 28u8, 5u8, 215u8, 213u8, 152u8, 46u8, 189u8, + 238u8, 209u8, 209u8, 142u8, 159u8, 222u8, 161u8, 26u8, 161u8, 250u8, + 9u8, 100u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_vesting::pallet::Event; + pub type Event = runtime_types::pallet_elections_phragmen::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -17479,15 +15934,18 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The amount vested has been updated. This could indicate a change in funds available."] - #[doc = "The balance given is the amount which is left unvested (and thus locked)."] - pub struct VestingUpdated { - pub account: ::subxt::utils::AccountId32, - pub unvested: ::core::primitive::u128, + #[doc = "A new term with new_members. This indicates that enough candidates existed to run"] + #[doc = "the election, not that enough have has been elected. The inner value must be examined"] + #[doc = "for this purpose. A `NewTerm(\\[\\])` indicates that some candidates got their bond"] + #[doc = "slashed and none were elected, whilst `EmptyTerm` means that no candidates existed to"] + #[doc = "begin with."] + pub struct NewTerm { + pub new_members: + ::std::vec::Vec<(::subxt::utils::AccountId32, ::core::primitive::u128)>, } - impl ::subxt::events::StaticEvent for VestingUpdated { - const PALLET: &'static str = "Vesting"; - const EVENT: &'static str = "VestingUpdated"; + impl ::subxt::events::StaticEvent for NewTerm { + const PALLET: &'static str = "PhragmenElection"; + const EVENT: &'static str = "NewTerm"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17499,158 +15957,469 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An \\[account\\] has become fully vested."] - pub struct VestingCompleted { - pub account: ::subxt::utils::AccountId32, + #[doc = "No (or not enough) candidates existed for this round. This is different from"] + #[doc = "`NewTerm(\\[\\])`. See the description of `NewTerm`."] + pub struct EmptyTerm; + impl ::subxt::events::StaticEvent for EmptyTerm { + const PALLET: &'static str = "PhragmenElection"; + const EVENT: &'static str = "EmptyTerm"; } - impl ::subxt::events::StaticEvent for VestingCompleted { - const PALLET: &'static str = "Vesting"; - const EVENT: &'static str = "VestingCompleted"; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Internal error happened while trying to perform election."] + pub struct ElectionError; + impl ::subxt::events::StaticEvent for ElectionError { + const PALLET: &'static str = "PhragmenElection"; + const EVENT: &'static str = "ElectionError"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A member has been removed. This should always be followed by either `NewTerm` or"] + #[doc = "`EmptyTerm`."] + pub struct MemberKicked { + pub member: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for MemberKicked { + const PALLET: &'static str = "PhragmenElection"; + const EVENT: &'static str = "MemberKicked"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Someone has renounced their candidacy."] + pub struct Renounced { + pub candidate: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for Renounced { + const PALLET: &'static str = "PhragmenElection"; + const EVENT: &'static str = "Renounced"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A candidate was slashed by amount due to failing to obtain a seat as member or"] + #[doc = "runner-up."] + #[doc = ""] + #[doc = "Note that old members and runners-up are also candidates."] + pub struct CandidateSlashed { + pub candidate: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for CandidateSlashed { + const PALLET: &'static str = "PhragmenElection"; + const EVENT: &'static str = "CandidateSlashed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A seat holder was slashed by amount by being forcefully removed from the set."] + pub struct SeatHolderSlashed { + pub seat_holder: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for SeatHolderSlashed { + const PALLET: &'static str = "PhragmenElection"; + const EVENT: &'static str = "SeatHolderSlashed"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " Information regarding the vesting of a given account."] - pub fn vesting( + #[doc = " The current elected members."] + #[doc = ""] + #[doc = " Invariant: Always sorted based on account id."] + pub fn members( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::std::vec::Vec< + runtime_types::pallet_elections_phragmen::SeatHolder< + ::subxt::utils::AccountId32, ::core::primitive::u128, - ::core::primitive::u32, >, >, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Vesting", - "Vesting", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "PhragmenElection", + "Members", + vec![], [ - 23u8, 209u8, 233u8, 126u8, 89u8, 156u8, 193u8, 204u8, 100u8, 90u8, - 14u8, 120u8, 36u8, 167u8, 148u8, 239u8, 179u8, 74u8, 207u8, 83u8, 54u8, - 77u8, 27u8, 135u8, 74u8, 31u8, 33u8, 11u8, 168u8, 239u8, 212u8, 36u8, + 2u8, 182u8, 43u8, 180u8, 87u8, 185u8, 26u8, 79u8, 196u8, 55u8, 28u8, + 26u8, 174u8, 133u8, 158u8, 221u8, 101u8, 161u8, 83u8, 9u8, 221u8, + 175u8, 221u8, 220u8, 81u8, 80u8, 1u8, 236u8, 74u8, 121u8, 10u8, 82u8, ], ) } - #[doc = " Information regarding the vesting of a given account."] - pub fn vesting_root( + #[doc = " The current reserved runners-up."] + #[doc = ""] + #[doc = " Invariant: Always sorted based on rank (worse to best). Upon removal of a member, the"] + #[doc = " last (i.e. _best_) runner-up will be replaced."] + pub fn runners_up( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::std::vec::Vec< + runtime_types::pallet_elections_phragmen::SeatHolder< + ::subxt::utils::AccountId32, ::core::primitive::u128, - ::core::primitive::u32, >, >, - (), - (), ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Vesting", - "Vesting", - Vec::new(), + "PhragmenElection", + "RunnersUp", + vec![], [ - 23u8, 209u8, 233u8, 126u8, 89u8, 156u8, 193u8, 204u8, 100u8, 90u8, - 14u8, 120u8, 36u8, 167u8, 148u8, 239u8, 179u8, 74u8, 207u8, 83u8, 54u8, - 77u8, 27u8, 135u8, 74u8, 31u8, 33u8, 11u8, 168u8, 239u8, 212u8, 36u8, + 248u8, 81u8, 190u8, 53u8, 121u8, 49u8, 55u8, 69u8, 116u8, 177u8, 46u8, + 30u8, 131u8, 14u8, 32u8, 198u8, 10u8, 132u8, 73u8, 117u8, 2u8, 146u8, + 188u8, 146u8, 214u8, 227u8, 97u8, 77u8, 7u8, 131u8, 208u8, 209u8, ], ) } - #[doc = " Storage version of the pallet."] + #[doc = " The present candidate list. A current member or runner-up can never enter this vector"] + #[doc = " and is always implicitly assumed to be a candidate."] #[doc = ""] - #[doc = " New networks start with latest version, as determined by the genesis build."] - pub fn storage_version( + #[doc = " Second element is the deposit."] + #[doc = ""] + #[doc = " Invariant: Always sorted based on account id."] + pub fn candidates( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_vesting::Releases, + ::std::vec::Vec<(::subxt::utils::AccountId32, ::core::primitive::u128)>, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "Vesting", - "StorageVersion", + "PhragmenElection", + "Candidates", vec![], [ - 50u8, 143u8, 26u8, 88u8, 129u8, 31u8, 61u8, 118u8, 19u8, 202u8, 119u8, - 160u8, 34u8, 219u8, 60u8, 57u8, 189u8, 66u8, 93u8, 239u8, 121u8, 114u8, - 241u8, 116u8, 0u8, 122u8, 232u8, 94u8, 189u8, 23u8, 45u8, 191u8, + 224u8, 107u8, 141u8, 11u8, 54u8, 86u8, 117u8, 45u8, 195u8, 252u8, + 152u8, 21u8, 165u8, 23u8, 198u8, 117u8, 5u8, 216u8, 183u8, 163u8, + 243u8, 56u8, 11u8, 102u8, 85u8, 107u8, 219u8, 250u8, 45u8, 80u8, 108u8, + 127u8, ], ) } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The minimum amount transferred to call `vested_transfer`."] - pub fn min_vested_transfer( + #[doc = " The total number of vote rounds that have happened, excluding the upcoming one."] + pub fn election_rounds( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Vesting", - "MinVestedTransfer", + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "PhragmenElection", + "ElectionRounds", + vec![], [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 144u8, 146u8, 10u8, 32u8, 149u8, 147u8, 59u8, 205u8, 61u8, 246u8, 28u8, + 169u8, 130u8, 136u8, 143u8, 104u8, 253u8, 86u8, 228u8, 68u8, 19u8, + 184u8, 166u8, 214u8, 58u8, 103u8, 176u8, 160u8, 240u8, 249u8, 117u8, + 115u8, ], ) } - pub fn max_vesting_schedules( + #[doc = " Votes and locked stake of a particular voter."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE as `AccountId` is a crypto hash."] + pub fn voting( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Vesting", - "MaxVestingSchedules", + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_elections_phragmen::Voter< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PhragmenElection", + "Voting", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 9u8, 135u8, 76u8, 194u8, 240u8, 182u8, 111u8, 207u8, 102u8, 37u8, + 126u8, 36u8, 84u8, 112u8, 26u8, 216u8, 175u8, 5u8, 14u8, 189u8, 83u8, + 185u8, 136u8, 39u8, 171u8, 221u8, 147u8, 20u8, 168u8, 126u8, 111u8, + 137u8, ], ) } - } - } - } - pub mod utility { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_utility::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, + #[doc = " Votes and locked stake of a particular voter."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE as `AccountId` is a crypto hash."] + pub fn voting_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_elections_phragmen::Voter< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PhragmenElection", + "Voting", + Vec::new(), + [ + 9u8, 135u8, 76u8, 194u8, 240u8, 182u8, 111u8, 207u8, 102u8, 37u8, + 126u8, 36u8, 84u8, 112u8, 26u8, 216u8, 175u8, 5u8, 14u8, 189u8, 83u8, + 185u8, 136u8, 39u8, 171u8, 221u8, 147u8, 20u8, 168u8, 126u8, 111u8, + 137u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " Identifier for the elections-phragmen pallet's lock"] + pub fn pallet_id( + &self, + ) -> ::subxt::constants::Address<[::core::primitive::u8; 8usize]> { + ::subxt::constants::Address::new_static( + "PhragmenElection", + "PalletId", + [ + 224u8, 197u8, 247u8, 125u8, 62u8, 180u8, 69u8, 91u8, 226u8, 36u8, 82u8, + 148u8, 70u8, 147u8, 209u8, 40u8, 210u8, 229u8, 181u8, 191u8, 170u8, + 205u8, 138u8, 97u8, 127u8, 59u8, 124u8, 244u8, 252u8, 30u8, 213u8, + 179u8, + ], + ) + } + #[doc = " How much should be locked up in order to submit one's candidacy."] + pub fn candidacy_bond( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "PhragmenElection", + "CandidacyBond", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " Base deposit associated with voting."] + #[doc = ""] + #[doc = " This should be sensibly high to economically ensure the pallet cannot be attacked by"] + #[doc = " creating a gigantic number of votes."] + pub fn voting_bond_base( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "PhragmenElection", + "VotingBondBase", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The amount of bond that need to be locked for each vote (32 bytes)."] + pub fn voting_bond_factor( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "PhragmenElection", + "VotingBondFactor", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " Number of members to elect."] + pub fn desired_members( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "PhragmenElection", + "DesiredMembers", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " Number of runners_up to keep."] + pub fn desired_runners_up( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "PhragmenElection", + "DesiredRunnersUp", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " How long each seat is kept. This defines the next block number at which an election"] + #[doc = " round will happen. If set to zero, no elections are ever triggered and the module will"] + #[doc = " be in passive mode."] + pub fn term_duration(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "PhragmenElection", + "TermDuration", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The maximum number of candidates in a phragmen election."] + #[doc = ""] + #[doc = " Warning: This impacts the size of the election which is run onchain. Chose wisely, and"] + #[doc = " consider how it will impact `T::WeightInfo::election_phragmen`."] + #[doc = ""] + #[doc = " When this limit is reached no more candidates are accepted in the election."] + pub fn max_candidates( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "PhragmenElection", + "MaxCandidates", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The maximum number of voters to allow in a phragmen election."] + #[doc = ""] + #[doc = " Warning: This impacts the size of the election which is run onchain. Chose wisely, and"] + #[doc = " consider how it will impact `T::WeightInfo::election_phragmen`."] + #[doc = ""] + #[doc = " When the limit is reached the new voters are ignored."] + pub fn max_voters(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "PhragmenElection", + "MaxVoters", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " Maximum numbers of votes per voter."] + #[doc = ""] + #[doc = " Warning: This impacts the size of the election which is run onchain. Chose wisely, and"] + #[doc = " consider how it will impact `T::WeightInfo::election_phragmen`."] + pub fn max_votes_per_voter( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "PhragmenElection", + "MaxVotesPerVoter", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod technical_membership { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_membership::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, )] # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Batch { - pub calls: ::std::vec::Vec, + pub struct AddMember { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17662,9 +16431,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsDerivative { - pub index: ::core::primitive::u16, - pub call: ::std::boxed::Box, + pub struct RemoveMember { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17676,8 +16444,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BatchAll { - pub calls: ::std::vec::Vec, + pub struct SwapMember { + pub remove: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub add: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17689,9 +16458,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DispatchAs { - pub as_origin: ::std::boxed::Box, - pub call: ::std::boxed::Box, + pub struct ResetMembers { + pub members: ::std::vec::Vec<::subxt::utils::AccountId32>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17703,8 +16471,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceBatch { - pub calls: ::std::vec::Vec, + pub struct ChangeKey { + pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17716,204 +16484,159 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WithWeight { - pub call: ::std::boxed::Box, - pub weight: runtime_types::sp_weights::weight_v2::Weight, + pub struct SetPrime { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WithWeight { - pub call: ::std::boxed::Box, - pub weight: runtime_types::sp_weights::weight_v2::Weight, + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClearPrime; } pub struct TransactionApi; impl TransactionApi { - #[doc = "Send a batch of dispatch calls."] - #[doc = ""] - #[doc = "May be called from any origin except `None`."] - #[doc = ""] - #[doc = "- `calls`: The calls to be dispatched from the same origin. The number of call must not"] - #[doc = " exceed the constant: `batched_calls_limit` (available in constant metadata)."] - #[doc = ""] - #[doc = "If origin is root then the calls are dispatched without checking origin filter. (This"] - #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(C) where C is the number of calls to be batched."] + #[doc = "Add a member `who` to the set."] #[doc = ""] - #[doc = "This will return `Ok` in all circumstances. To determine the success of the batch, an"] - #[doc = "event is deposited. If a call failed and the batch was interrupted, then the"] - #[doc = "`BatchInterrupted` event is deposited, along with the number of successful calls made"] - #[doc = "and the error of the failed call. If all were successful, then the `BatchCompleted`"] - #[doc = "event is deposited."] - pub fn batch( + #[doc = "May only be called from `T::AddOrigin`."] + pub fn add_member( &self, - calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Utility", - "batch", - types::Batch { calls }, + "TechnicalMembership", + "add_member", + types::AddMember { who }, [ - 221u8, 151u8, 56u8, 10u8, 237u8, 176u8, 153u8, 88u8, 29u8, 225u8, 27u8, - 231u8, 98u8, 222u8, 51u8, 94u8, 88u8, 16u8, 40u8, 253u8, 61u8, 35u8, - 70u8, 110u8, 15u8, 75u8, 102u8, 140u8, 125u8, 54u8, 223u8, 231u8, + 165u8, 116u8, 123u8, 50u8, 236u8, 196u8, 108u8, 211u8, 112u8, 214u8, + 121u8, 105u8, 7u8, 88u8, 125u8, 99u8, 24u8, 0u8, 168u8, 65u8, 158u8, + 100u8, 42u8, 62u8, 101u8, 59u8, 30u8, 174u8, 170u8, 119u8, 141u8, + 121u8, ], ) } - #[doc = "Send a call through an indexed pseudonym of the sender."] - #[doc = ""] - #[doc = "Filter from origin are passed along. The call will be dispatched with an origin which"] - #[doc = "use the same filter as the origin of this call."] - #[doc = ""] - #[doc = "NOTE: If you need to ensure that any account-based filtering is not honored (i.e."] - #[doc = "because you expect `proxy` to have been used prior in the call stack and you do not want"] - #[doc = "the call restrictions to apply to any sub-accounts), then use `as_multi_threshold_1`"] - #[doc = "in the Multisig pallet instead."] - #[doc = ""] - #[doc = "NOTE: Prior to version *12, this was called `as_limited_sub`."] + #[doc = "Remove a member `who` from the set."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - pub fn as_derivative( + #[doc = "May only be called from `T::RemoveOrigin`."] + pub fn remove_member( &self, - index: ::core::primitive::u16, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Utility", - "as_derivative", - types::AsDerivative { - index, - call: ::std::boxed::Box::new(call), - }, + "TechnicalMembership", + "remove_member", + types::RemoveMember { who }, [ - 154u8, 209u8, 156u8, 16u8, 183u8, 67u8, 69u8, 4u8, 187u8, 100u8, 27u8, - 221u8, 195u8, 187u8, 165u8, 6u8, 121u8, 94u8, 27u8, 111u8, 214u8, 91u8, - 83u8, 160u8, 242u8, 13u8, 236u8, 70u8, 155u8, 94u8, 78u8, 71u8, + 177u8, 18u8, 217u8, 235u8, 254u8, 40u8, 137u8, 79u8, 146u8, 5u8, 55u8, + 187u8, 129u8, 28u8, 54u8, 132u8, 115u8, 220u8, 132u8, 139u8, 91u8, + 81u8, 0u8, 110u8, 188u8, 248u8, 1u8, 135u8, 93u8, 153u8, 95u8, 193u8, ], ) } - #[doc = "Send a batch of dispatch calls and atomically execute them."] - #[doc = "The whole transaction will rollback and fail if any of the calls failed."] - #[doc = ""] - #[doc = "May be called from any origin except `None`."] - #[doc = ""] - #[doc = "- `calls`: The calls to be dispatched from the same origin. The number of call must not"] - #[doc = " exceed the constant: `batched_calls_limit` (available in constant metadata)."] + #[doc = "Swap out one member `remove` for another `add`."] #[doc = ""] - #[doc = "If origin is root then the calls are dispatched without checking origin filter. (This"] - #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] + #[doc = "May only be called from `T::SwapOrigin`."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(C) where C is the number of calls to be batched."] - pub fn batch_all( + #[doc = "Prime membership is *not* passed from `remove` to `add`, if extant."] + pub fn swap_member( &self, - calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { + remove: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + add: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Utility", - "batch_all", - types::BatchAll { calls }, + "TechnicalMembership", + "swap_member", + types::SwapMember { remove, add }, [ - 255u8, 107u8, 81u8, 108u8, 78u8, 19u8, 231u8, 220u8, 177u8, 177u8, - 28u8, 24u8, 100u8, 228u8, 227u8, 45u8, 3u8, 51u8, 132u8, 12u8, 48u8, - 158u8, 67u8, 201u8, 193u8, 126u8, 251u8, 177u8, 102u8, 251u8, 90u8, - 81u8, + 96u8, 248u8, 50u8, 206u8, 192u8, 242u8, 162u8, 62u8, 28u8, 91u8, 11u8, + 208u8, 15u8, 84u8, 188u8, 234u8, 219u8, 233u8, 200u8, 215u8, 157u8, + 155u8, 40u8, 220u8, 132u8, 182u8, 57u8, 210u8, 94u8, 240u8, 95u8, + 252u8, ], ) } - #[doc = "Dispatches a function call with a provided origin."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Root_."] + #[doc = "Change the membership to a new set, disregarding the existing membership. Be nice and"] + #[doc = "pass `members` pre-sorted."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(1)."] - pub fn dispatch_as( + #[doc = "May only be called from `T::ResetOrigin`."] + pub fn reset_members( &self, - as_origin: runtime_types::polkadot_runtime::OriginCaller, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + members: ::std::vec::Vec<::subxt::utils::AccountId32>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Utility", - "dispatch_as", - types::DispatchAs { - as_origin: ::std::boxed::Box::new(as_origin), - call: ::std::boxed::Box::new(call), - }, + "TechnicalMembership", + "reset_members", + types::ResetMembers { members }, [ - 74u8, 215u8, 136u8, 17u8, 87u8, 74u8, 107u8, 176u8, 229u8, 23u8, 109u8, - 233u8, 84u8, 229u8, 27u8, 35u8, 154u8, 93u8, 104u8, 222u8, 71u8, 167u8, - 39u8, 12u8, 235u8, 46u8, 204u8, 125u8, 67u8, 96u8, 236u8, 91u8, + 9u8, 35u8, 28u8, 59u8, 158u8, 232u8, 89u8, 78u8, 101u8, 53u8, 240u8, + 98u8, 13u8, 104u8, 235u8, 161u8, 201u8, 150u8, 117u8, 32u8, 75u8, + 209u8, 166u8, 252u8, 57u8, 131u8, 96u8, 215u8, 51u8, 81u8, 42u8, 123u8, ], ) } - #[doc = "Send a batch of dispatch calls."] - #[doc = "Unlike `batch`, it allows errors and won't interrupt."] - #[doc = ""] - #[doc = "May be called from any origin except `None`."] - #[doc = ""] - #[doc = "- `calls`: The calls to be dispatched from the same origin. The number of call must not"] - #[doc = " exceed the constant: `batched_calls_limit` (available in constant metadata)."] + #[doc = "Swap out the sending member for some other key `new`."] #[doc = ""] - #[doc = "If origin is root then the calls are dispatch without checking origin filter. (This"] - #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] + #[doc = "May only be called from `Signed` origin of a current member."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(C) where C is the number of calls to be batched."] - pub fn force_batch( + #[doc = "Prime membership is passed from the origin account to `new`, if extant."] + pub fn change_key( &self, - calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { + new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Utility", - "force_batch", - types::ForceBatch { calls }, + "TechnicalMembership", + "change_key", + types::ChangeKey { new }, [ - 183u8, 158u8, 12u8, 76u8, 9u8, 251u8, 54u8, 89u8, 139u8, 70u8, 51u8, - 72u8, 181u8, 28u8, 110u8, 207u8, 211u8, 236u8, 224u8, 44u8, 104u8, - 231u8, 238u8, 141u8, 176u8, 194u8, 100u8, 217u8, 63u8, 127u8, 166u8, - 24u8, + 27u8, 236u8, 241u8, 168u8, 98u8, 39u8, 176u8, 220u8, 145u8, 48u8, + 173u8, 25u8, 179u8, 103u8, 170u8, 13u8, 166u8, 181u8, 131u8, 160u8, + 131u8, 219u8, 116u8, 34u8, 152u8, 152u8, 46u8, 100u8, 46u8, 5u8, 156u8, + 195u8, ], ) } - #[doc = "Dispatch a function call with a specified weight."] - #[doc = ""] - #[doc = "This function does not check the weight of the call, and instead allows the"] - #[doc = "Root origin to specify the weight of the call."] + #[doc = "Set the prime member. Must be a current member."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Root_."] - pub fn with_weight( + #[doc = "May only be called from `T::PrimeOrigin`."] + pub fn set_prime( &self, - call: runtime_types::polkadot_runtime::RuntimeCall, - weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Utility", - "with_weight", - WithWeight { - call: ::std::boxed::Box::new(call), - weight, - }, + "TechnicalMembership", + "set_prime", + types::SetPrime { who }, [ - 206u8, 4u8, 190u8, 61u8, 107u8, 61u8, 249u8, 88u8, 255u8, 170u8, 65u8, - 96u8, 12u8, 54u8, 149u8, 75u8, 250u8, 153u8, 103u8, 142u8, 117u8, 64u8, - 45u8, 189u8, 129u8, 28u8, 143u8, 78u8, 53u8, 188u8, 178u8, 19u8, + 0u8, 42u8, 111u8, 52u8, 151u8, 19u8, 239u8, 149u8, 183u8, 252u8, 87u8, + 194u8, 145u8, 21u8, 245u8, 112u8, 221u8, 181u8, 87u8, 28u8, 48u8, 39u8, + 210u8, 133u8, 241u8, 207u8, 255u8, 209u8, 139u8, 232u8, 119u8, 64u8, + ], + ) + } + #[doc = "Remove the prime member if it exists."] + #[doc = ""] + #[doc = "May only be called from `T::PrimeOrigin`."] + pub fn clear_prime(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "TechnicalMembership", + "clear_prime", + types::ClearPrime {}, + [ + 186u8, 182u8, 225u8, 90u8, 71u8, 124u8, 69u8, 100u8, 234u8, 25u8, 53u8, + 23u8, 182u8, 32u8, 176u8, 81u8, 54u8, 140u8, 235u8, 126u8, 247u8, 7u8, + 155u8, 62u8, 35u8, 135u8, 48u8, 61u8, 88u8, 160u8, 183u8, 72u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_utility::pallet::Event; + pub type Event = runtime_types::pallet_membership::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -17926,15 +16649,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Batch of dispatches did not complete fully. Index of first failing dispatch given, as"] - #[doc = "well as the error."] - pub struct BatchInterrupted { - pub index: ::core::primitive::u32, - pub error: runtime_types::sp_runtime::DispatchError, - } - impl ::subxt::events::StaticEvent for BatchInterrupted { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "BatchInterrupted"; + #[doc = "The given member was added; see the transaction for who."] + pub struct MemberAdded; + impl ::subxt::events::StaticEvent for MemberAdded { + const PALLET: &'static str = "TechnicalMembership"; + const EVENT: &'static str = "MemberAdded"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17946,11 +16665,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Batch of dispatches completed fully with no error."] - pub struct BatchCompleted; - impl ::subxt::events::StaticEvent for BatchCompleted { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "BatchCompleted"; + #[doc = "The given member was removed; see the transaction for who."] + pub struct MemberRemoved; + impl ::subxt::events::StaticEvent for MemberRemoved { + const PALLET: &'static str = "TechnicalMembership"; + const EVENT: &'static str = "MemberRemoved"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17962,12 +16681,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Batch of dispatches completed but has errors."] - pub struct BatchCompletedWithErrors; - impl ::subxt::events::StaticEvent for BatchCompletedWithErrors { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "BatchCompletedWithErrors"; - } + #[doc = "Two members were swapped; see the transaction for who."] + pub struct MembersSwapped; + impl ::subxt::events::StaticEvent for MembersSwapped { + const PALLET: &'static str = "TechnicalMembership"; + const EVENT: &'static str = "MembersSwapped"; + } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -17978,11 +16697,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A single item within a Batch of dispatches has completed with no error."] - pub struct ItemCompleted; - impl ::subxt::events::StaticEvent for ItemCompleted { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "ItemCompleted"; + #[doc = "The membership was reset; see the transaction for who the new set is."] + pub struct MembersReset; + impl ::subxt::events::StaticEvent for MembersReset { + const PALLET: &'static str = "TechnicalMembership"; + const EVENT: &'static str = "MembersReset"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -17994,13 +16713,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A single item within a Batch of dispatches has completed with error."] - pub struct ItemFailed { - pub error: runtime_types::sp_runtime::DispatchError, - } - impl ::subxt::events::StaticEvent for ItemFailed { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "ItemFailed"; + #[doc = "One of the members' keys changed."] + pub struct KeyChanged; + impl ::subxt::events::StaticEvent for KeyChanged { + const PALLET: &'static str = "TechnicalMembership"; + const EVENT: &'static str = "KeyChanged"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18012,43 +16729,71 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A call was dispatched."] - pub struct DispatchedAs { - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for DispatchedAs { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "DispatchedAs"; + #[doc = "Phantom member, never used."] + pub struct Dummy; + impl ::subxt::events::StaticEvent for Dummy { + const PALLET: &'static str = "TechnicalMembership"; + const EVENT: &'static str = "Dummy"; } } - pub mod constants { + pub mod storage { use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The limit on the number of batched calls."] - pub fn batched_calls_limit( + pub struct StorageApi; + impl StorageApi { + #[doc = " The current membership, stored as an ordered Vec."] + pub fn members( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Utility", - "batched_calls_limit", + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::AccountId32, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "TechnicalMembership", + "Members", + vec![], [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 56u8, 56u8, 29u8, 90u8, 26u8, 115u8, 252u8, 185u8, 37u8, 108u8, 16u8, + 46u8, 136u8, 139u8, 30u8, 19u8, 235u8, 78u8, 176u8, 129u8, 180u8, 57u8, + 178u8, 239u8, 211u8, 6u8, 64u8, 129u8, 195u8, 46u8, 178u8, 157u8, + ], + ) + } + #[doc = " The current prime member, if one exists."] + pub fn prime( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::AccountId32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "TechnicalMembership", + "Prime", + vec![], + [ + 108u8, 118u8, 54u8, 193u8, 207u8, 227u8, 119u8, 97u8, 23u8, 239u8, + 157u8, 69u8, 56u8, 142u8, 106u8, 17u8, 215u8, 159u8, 48u8, 42u8, 185u8, + 209u8, 49u8, 159u8, 32u8, 168u8, 111u8, 158u8, 159u8, 217u8, 244u8, + 158u8, ], ) } } } } - pub mod identity { + pub mod treasury { use super::root_mod; use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_identity::pallet::Error; - #[doc = "Identity pallet declaration."] + #[doc = "Error for the treasury pallet."] + pub type Error = runtime_types::pallet_treasury::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; use super::runtime_types; @@ -18065,79 +16810,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddRegistrar { - pub account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetIdentity { - pub info: - ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetSubs { - pub subs: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::pallet_identity::types::Data, - )>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClearIdentity; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RequestJudgement { - #[codec(compact)] - pub reg_index: ::core::primitive::u32, + pub struct ProposeSpend { #[codec(compact)] - pub max_fee: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelRequest { - pub reg_index: ::core::primitive::u32, + pub value: ::core::primitive::u128, + pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18149,11 +16825,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetFee { - #[codec(compact)] - pub index: ::core::primitive::u32, + pub struct RejectProposal { #[codec(compact)] - pub fee: ::core::primitive::u128, + pub proposal_id: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18165,10 +16839,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetAccountId { + pub struct ApproveProposal { #[codec(compact)] - pub index: ::core::primitive::u32, - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub proposal_id: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18180,12 +16853,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetFields { + pub struct Spend { #[codec(compact)] - pub index: ::core::primitive::u32, - pub fields: runtime_types::pallet_identity::types::BitFlags< - runtime_types::pallet_identity::types::IdentityField, - >, + pub amount: ::core::primitive::u128, + pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18197,522 +16868,142 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProvideJudgement { + pub struct RemoveApproval { #[codec(compact)] - pub reg_index: ::core::primitive::u32, - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub judgement: - runtime_types::pallet_identity::types::Judgement<::core::primitive::u128>, - pub identity: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillIdentity { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddSub { - pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub data: runtime_types::pallet_identity::types::Data, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RenameSub { - pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub data: runtime_types::pallet_identity::types::Data, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveSub { - pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub proposal_id: ::core::primitive::u32, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QuitSub; } pub struct TransactionApi; impl TransactionApi { - #[doc = "Add a registrar to the system."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be `T::RegistrarOrigin`."] - #[doc = ""] - #[doc = "- `account`: the account of the registrar."] - #[doc = ""] - #[doc = "Emits `RegistrarAdded` if successful."] + #[doc = "Put forward a suggestion for spending. A deposit proportional to the value"] + #[doc = "is reserved and slashed if the proposal is rejected. It is returned once the"] + #[doc = "proposal is awarded."] #[doc = ""] #[doc = "## Complexity"] - #[doc = "- `O(R)` where `R` registrar-count (governance-bounded and code-bounded)."] - pub fn add_registrar( + #[doc = "- O(1)"] + pub fn propose_spend( &self, - account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + value: ::core::primitive::u128, + beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Identity", - "add_registrar", - types::AddRegistrar { account }, + "Treasury", + "propose_spend", + types::ProposeSpend { value, beneficiary }, [ - 157u8, 232u8, 252u8, 190u8, 203u8, 233u8, 127u8, 63u8, 111u8, 16u8, - 118u8, 200u8, 31u8, 234u8, 144u8, 111u8, 161u8, 224u8, 217u8, 86u8, - 179u8, 254u8, 162u8, 212u8, 248u8, 8u8, 125u8, 89u8, 23u8, 195u8, 4u8, - 231u8, + 109u8, 46u8, 8u8, 159u8, 127u8, 79u8, 27u8, 100u8, 92u8, 244u8, 78u8, + 46u8, 105u8, 246u8, 169u8, 210u8, 149u8, 7u8, 108u8, 153u8, 203u8, + 223u8, 8u8, 117u8, 126u8, 250u8, 255u8, 52u8, 245u8, 69u8, 45u8, 136u8, ], ) } - #[doc = "Set an account's identity information and reserve the appropriate deposit."] - #[doc = ""] - #[doc = "If the account already has identity information, the deposit is taken as part payment"] - #[doc = "for the new deposit."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "- `info`: The identity information."] + #[doc = "Reject a proposed spend. The original deposit will be slashed."] #[doc = ""] - #[doc = "Emits `IdentitySet` if successful."] + #[doc = "May only be called from `T::RejectOrigin`."] #[doc = ""] #[doc = "## Complexity"] - #[doc = "- `O(X + X' + R)`"] - #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)"] - #[doc = " - where `R` judgements-count (registrar-count-bounded)"] - pub fn set_identity( + #[doc = "- O(1)"] + pub fn reject_proposal( &self, - info: runtime_types::pallet_identity::types::IdentityInfo, - ) -> ::subxt::tx::Payload { + proposal_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Identity", - "set_identity", - types::SetIdentity { - info: ::std::boxed::Box::new(info), - }, + "Treasury", + "reject_proposal", + types::RejectProposal { proposal_id }, [ - 130u8, 89u8, 118u8, 6u8, 134u8, 166u8, 35u8, 192u8, 73u8, 6u8, 171u8, - 20u8, 225u8, 255u8, 152u8, 142u8, 111u8, 8u8, 206u8, 200u8, 64u8, 52u8, - 110u8, 123u8, 42u8, 101u8, 191u8, 242u8, 133u8, 139u8, 154u8, 205u8, + 106u8, 223u8, 97u8, 22u8, 111u8, 208u8, 128u8, 26u8, 198u8, 140u8, + 118u8, 126u8, 187u8, 51u8, 193u8, 50u8, 193u8, 68u8, 143u8, 144u8, + 34u8, 132u8, 44u8, 244u8, 105u8, 186u8, 223u8, 234u8, 17u8, 145u8, + 209u8, 145u8, ], ) } - #[doc = "Set the sub-accounts of the sender."] - #[doc = ""] - #[doc = "Payment: Any aggregate balance reserved by previous `set_subs` calls will be returned"] - #[doc = "and an amount `SubAccountDeposit` will be reserved for each item in `subs`."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] - #[doc = "identity."] + #[doc = "Approve a proposal. At a later time, the proposal will be allocated to the beneficiary"] + #[doc = "and the original deposit will be returned."] #[doc = ""] - #[doc = "- `subs`: The identity's (new) sub-accounts."] + #[doc = "May only be called from `T::ApproveOrigin`."] #[doc = ""] #[doc = "## Complexity"] - #[doc = "- `O(P + S)`"] - #[doc = " - where `P` old-subs-count (hard- and deposit-bounded)."] - #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] - pub fn set_subs( + #[doc = " - O(1)."] + pub fn approve_proposal( &self, - subs: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::pallet_identity::types::Data, - )>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_subs", - types::SetSubs { subs }, - [ - 177u8, 219u8, 84u8, 183u8, 5u8, 32u8, 192u8, 82u8, 174u8, 68u8, 198u8, - 224u8, 56u8, 85u8, 134u8, 171u8, 30u8, 132u8, 140u8, 236u8, 117u8, - 24u8, 150u8, 218u8, 146u8, 194u8, 144u8, 92u8, 103u8, 206u8, 46u8, - 90u8, - ], - ) - } - #[doc = "Clear an account's identity info and all sub-accounts and return all deposits."] - #[doc = ""] - #[doc = "Payment: All reserved balances on the account are returned."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] - #[doc = "identity."] - #[doc = ""] - #[doc = "Emits `IdentityCleared` if successful."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(R + S + X)`"] - #[doc = " - where `R` registrar-count (governance-bounded)."] - #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] - #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] - pub fn clear_identity(&self) -> ::subxt::tx::Payload { + proposal_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Identity", - "clear_identity", - types::ClearIdentity {}, + "Treasury", + "approve_proposal", + types::ApproveProposal { proposal_id }, [ - 75u8, 44u8, 74u8, 122u8, 149u8, 202u8, 114u8, 230u8, 0u8, 255u8, 140u8, - 122u8, 14u8, 196u8, 205u8, 249u8, 220u8, 94u8, 216u8, 34u8, 63u8, 14u8, - 8u8, 205u8, 74u8, 23u8, 181u8, 129u8, 252u8, 110u8, 231u8, 114u8, + 164u8, 229u8, 172u8, 98u8, 129u8, 62u8, 84u8, 128u8, 47u8, 108u8, 33u8, + 120u8, 89u8, 79u8, 57u8, 121u8, 4u8, 197u8, 170u8, 153u8, 156u8, 17u8, + 59u8, 164u8, 123u8, 227u8, 175u8, 195u8, 220u8, 160u8, 60u8, 186u8, ], ) } - #[doc = "Request a judgement from a registrar."] - #[doc = ""] - #[doc = "Payment: At most `max_fee` will be reserved for payment to the registrar if judgement"] - #[doc = "given."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a"] - #[doc = "registered identity."] - #[doc = ""] - #[doc = "- `reg_index`: The index of the registrar whose judgement is requested."] - #[doc = "- `max_fee`: The maximum fee that may be paid. This should just be auto-populated as:"] - #[doc = ""] - #[doc = "```nocompile"] - #[doc = "Self::registrars().get(reg_index).unwrap().fee"] - #[doc = "```"] + #[doc = "Propose and approve a spend of treasury funds."] #[doc = ""] - #[doc = "Emits `JudgementRequested` if successful."] + #[doc = "- `origin`: Must be `SpendOrigin` with the `Success` value being at least `amount`."] + #[doc = "- `amount`: The amount to be transferred from the treasury to the `beneficiary`."] + #[doc = "- `beneficiary`: The destination account for the transfer."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(R + X)`."] - #[doc = " - where `R` registrar-count (governance-bounded)."] - #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] - pub fn request_judgement( + #[doc = "NOTE: For record-keeping purposes, the proposer is deemed to be equivalent to the"] + #[doc = "beneficiary."] + pub fn spend( &self, - reg_index: ::core::primitive::u32, - max_fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + amount: ::core::primitive::u128, + beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Identity", - "request_judgement", - types::RequestJudgement { reg_index, max_fee }, + "Treasury", + "spend", + types::Spend { + amount, + beneficiary, + }, [ - 186u8, 149u8, 61u8, 54u8, 159u8, 194u8, 77u8, 161u8, 220u8, 157u8, 3u8, - 216u8, 23u8, 105u8, 119u8, 76u8, 144u8, 198u8, 157u8, 45u8, 235u8, - 139u8, 87u8, 82u8, 81u8, 12u8, 25u8, 134u8, 225u8, 92u8, 182u8, 101u8, + 177u8, 178u8, 242u8, 136u8, 135u8, 237u8, 114u8, 71u8, 233u8, 239u8, + 7u8, 84u8, 14u8, 228u8, 58u8, 31u8, 158u8, 185u8, 25u8, 91u8, 70u8, + 33u8, 19u8, 92u8, 100u8, 162u8, 5u8, 48u8, 20u8, 120u8, 9u8, 109u8, ], ) } - #[doc = "Cancel a previous request."] - #[doc = ""] - #[doc = "Payment: A previously reserved deposit is returned on success."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a"] - #[doc = "registered identity."] - #[doc = ""] - #[doc = "- `reg_index`: The index of the registrar whose judgement is no longer requested."] + #[doc = "Force a previously approved proposal to be removed from the approval queue."] + #[doc = "The original deposit will no longer be returned."] #[doc = ""] - #[doc = "Emits `JudgementUnrequested` if successful."] + #[doc = "May only be called from `T::RejectOrigin`."] + #[doc = "- `proposal_id`: The index of a proposal"] #[doc = ""] #[doc = "## Complexity"] - #[doc = "- `O(R + X)`."] - #[doc = " - where `R` registrar-count (governance-bounded)."] - #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] - pub fn cancel_request( + #[doc = "- O(A) where `A` is the number of approvals"] + #[doc = ""] + #[doc = "Errors:"] + #[doc = "- `ProposalNotApproved`: The `proposal_id` supplied was not found in the approval queue,"] + #[doc = "i.e., the proposal has not been approved. This could also mean the proposal does not"] + #[doc = "exist altogether, thus there is no way it would have been approved in the first place."] + pub fn remove_approval( &self, - reg_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + proposal_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Identity", - "cancel_request", - types::CancelRequest { reg_index }, + "Treasury", + "remove_approval", + types::RemoveApproval { proposal_id }, [ - 83u8, 180u8, 239u8, 126u8, 32u8, 51u8, 17u8, 20u8, 180u8, 3u8, 59u8, - 96u8, 24u8, 32u8, 136u8, 92u8, 58u8, 254u8, 68u8, 70u8, 50u8, 11u8, - 51u8, 91u8, 180u8, 79u8, 81u8, 84u8, 216u8, 138u8, 6u8, 215u8, - ], - ) - } - #[doc = "Set the fee required for a judgement to be requested from a registrar."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] - #[doc = "of the registrar whose index is `index`."] - #[doc = ""] - #[doc = "- `index`: the index of the registrar whose fee is to be set."] - #[doc = "- `fee`: the new fee."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(R)`."] - #[doc = " - where `R` registrar-count (governance-bounded)."] - pub fn set_fee( - &self, - index: ::core::primitive::u32, - fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_fee", - types::SetFee { index, fee }, - [ - 21u8, 157u8, 123u8, 182u8, 160u8, 190u8, 117u8, 37u8, 136u8, 133u8, - 104u8, 234u8, 31u8, 145u8, 115u8, 154u8, 125u8, 40u8, 2u8, 87u8, 118u8, - 56u8, 247u8, 73u8, 89u8, 0u8, 251u8, 3u8, 58u8, 105u8, 239u8, 211u8, - ], - ) - } - #[doc = "Change the account associated with a registrar."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] - #[doc = "of the registrar whose index is `index`."] - #[doc = ""] - #[doc = "- `index`: the index of the registrar whose fee is to be set."] - #[doc = "- `new`: the new account ID."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(R)`."] - #[doc = " - where `R` registrar-count (governance-bounded)."] - pub fn set_account_id( - &self, - index: ::core::primitive::u32, - new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_account_id", - types::SetAccountId { index, new }, - [ - 13u8, 91u8, 36u8, 7u8, 88u8, 64u8, 151u8, 104u8, 94u8, 174u8, 195u8, - 99u8, 97u8, 181u8, 236u8, 251u8, 26u8, 236u8, 234u8, 40u8, 183u8, 38u8, - 220u8, 216u8, 48u8, 115u8, 7u8, 230u8, 216u8, 28u8, 123u8, 11u8, - ], - ) - } - #[doc = "Set the field information for a registrar."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] - #[doc = "of the registrar whose index is `index`."] - #[doc = ""] - #[doc = "- `index`: the index of the registrar whose fee is to be set."] - #[doc = "- `fields`: the fields that the registrar concerns themselves with."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(R)`."] - #[doc = " - where `R` registrar-count (governance-bounded)."] - pub fn set_fields( - &self, - index: ::core::primitive::u32, - fields: runtime_types::pallet_identity::types::BitFlags< - runtime_types::pallet_identity::types::IdentityField, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_fields", - types::SetFields { index, fields }, - [ - 50u8, 196u8, 179u8, 71u8, 66u8, 65u8, 235u8, 7u8, 51u8, 14u8, 81u8, - 173u8, 201u8, 58u8, 6u8, 151u8, 174u8, 245u8, 102u8, 184u8, 28u8, 84u8, - 125u8, 93u8, 126u8, 134u8, 92u8, 203u8, 200u8, 129u8, 240u8, 252u8, - ], - ) - } - #[doc = "Provide a judgement for an account's identity."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] - #[doc = "of the registrar whose index is `reg_index`."] - #[doc = ""] - #[doc = "- `reg_index`: the index of the registrar whose judgement is being made."] - #[doc = "- `target`: the account whose identity the judgement is upon. This must be an account"] - #[doc = " with a registered identity."] - #[doc = "- `judgement`: the judgement of the registrar of index `reg_index` about `target`."] - #[doc = "- `identity`: The hash of the [`IdentityInfo`] for that the judgement is provided."] - #[doc = ""] - #[doc = "Emits `JudgementGiven` if successful."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(R + X)`."] - #[doc = " - where `R` registrar-count (governance-bounded)."] - #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] - pub fn provide_judgement( - &self, - reg_index: ::core::primitive::u32, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - judgement: runtime_types::pallet_identity::types::Judgement< - ::core::primitive::u128, - >, - identity: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "provide_judgement", - types::ProvideJudgement { - reg_index, - target, - judgement, - identity, - }, - [ - 147u8, 66u8, 29u8, 90u8, 149u8, 65u8, 161u8, 115u8, 12u8, 254u8, 188u8, - 248u8, 165u8, 115u8, 191u8, 2u8, 167u8, 223u8, 199u8, 169u8, 203u8, - 64u8, 101u8, 217u8, 73u8, 185u8, 93u8, 109u8, 22u8, 184u8, 146u8, 73u8, - ], - ) - } - #[doc = "Remove an account's identity and sub-account information and slash the deposits."] - #[doc = ""] - #[doc = "Payment: Reserved balances from `set_subs` and `set_identity` are slashed and handled by"] - #[doc = "`Slash`. Verification request deposits are not returned; they should be cancelled"] - #[doc = "manually using `cancel_request`."] - #[doc = ""] - #[doc = "The dispatch origin for this call must match `T::ForceOrigin`."] - #[doc = ""] - #[doc = "- `target`: the account whose identity the judgement is upon. This must be an account"] - #[doc = " with a registered identity."] - #[doc = ""] - #[doc = "Emits `IdentityKilled` if successful."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(R + S + X)`"] - #[doc = " - where `R` registrar-count (governance-bounded)."] - #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] - #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] - pub fn kill_identity( - &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "kill_identity", - types::KillIdentity { target }, - [ - 76u8, 13u8, 158u8, 219u8, 221u8, 0u8, 151u8, 241u8, 137u8, 136u8, - 179u8, 194u8, 188u8, 230u8, 56u8, 16u8, 254u8, 28u8, 127u8, 216u8, - 205u8, 117u8, 224u8, 121u8, 240u8, 231u8, 126u8, 181u8, 230u8, 68u8, - 13u8, 174u8, - ], - ) - } - #[doc = "Add the given account to the sender's subs."] - #[doc = ""] - #[doc = "Payment: Balance reserved by a previous `set_subs` call for one sub will be repatriated"] - #[doc = "to the sender."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] - #[doc = "sub identity of `sub`."] - pub fn add_sub( - &self, - sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - data: runtime_types::pallet_identity::types::Data, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "add_sub", - types::AddSub { sub, data }, - [ - 122u8, 218u8, 25u8, 93u8, 33u8, 176u8, 191u8, 254u8, 223u8, 147u8, - 100u8, 135u8, 86u8, 71u8, 47u8, 163u8, 105u8, 222u8, 162u8, 173u8, - 207u8, 182u8, 130u8, 128u8, 214u8, 242u8, 101u8, 250u8, 242u8, 24u8, - 17u8, 84u8, - ], - ) - } - #[doc = "Alter the associated name of the given sub-account."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] - #[doc = "sub identity of `sub`."] - pub fn rename_sub( - &self, - sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - data: runtime_types::pallet_identity::types::Data, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "rename_sub", - types::RenameSub { sub, data }, - [ - 166u8, 167u8, 49u8, 114u8, 199u8, 168u8, 187u8, 221u8, 100u8, 85u8, - 147u8, 211u8, 157u8, 31u8, 109u8, 135u8, 194u8, 135u8, 15u8, 89u8, - 59u8, 57u8, 252u8, 163u8, 9u8, 138u8, 216u8, 189u8, 177u8, 42u8, 96u8, - 34u8, - ], - ) - } - #[doc = "Remove the given account from the sender's subs."] - #[doc = ""] - #[doc = "Payment: Balance reserved by a previous `set_subs` call for one sub will be repatriated"] - #[doc = "to the sender."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] - #[doc = "sub identity of `sub`."] - pub fn remove_sub( - &self, - sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "remove_sub", - types::RemoveSub { sub }, - [ - 106u8, 223u8, 210u8, 67u8, 54u8, 11u8, 144u8, 222u8, 42u8, 46u8, 157u8, - 33u8, 13u8, 245u8, 166u8, 195u8, 227u8, 81u8, 224u8, 149u8, 154u8, - 158u8, 187u8, 203u8, 215u8, 91u8, 43u8, 105u8, 69u8, 213u8, 141u8, - 124u8, - ], - ) - } - #[doc = "Remove the sender as a sub-account."] - #[doc = ""] - #[doc = "Payment: Balance reserved by a previous `set_subs` call for one sub will be repatriated"] - #[doc = "to the sender (*not* the original depositor)."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] - #[doc = "super-identity."] - #[doc = ""] - #[doc = "NOTE: This should not normally be used, but is provided in the case that the non-"] - #[doc = "controller of an account is maliciously registered as a sub-account."] - pub fn quit_sub(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "quit_sub", - types::QuitSub {}, - [ - 62u8, 57u8, 73u8, 72u8, 119u8, 216u8, 250u8, 155u8, 57u8, 169u8, 157u8, - 44u8, 87u8, 51u8, 63u8, 231u8, 77u8, 7u8, 0u8, 119u8, 244u8, 42u8, - 179u8, 51u8, 254u8, 240u8, 55u8, 25u8, 142u8, 38u8, 87u8, 44u8, + 133u8, 126u8, 181u8, 47u8, 196u8, 243u8, 7u8, 46u8, 25u8, 251u8, 154u8, + 125u8, 217u8, 77u8, 54u8, 245u8, 240u8, 180u8, 97u8, 34u8, 186u8, 53u8, + 225u8, 144u8, 155u8, 107u8, 172u8, 54u8, 250u8, 184u8, 178u8, 86u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_identity::pallet::Event; + pub type Event = runtime_types::pallet_treasury::pallet::Event; pub mod events { use super::runtime_types; #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -18722,34 +17013,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A name was set or reset (which will remove all judgements)."] - pub struct IdentitySet { - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for IdentitySet { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "IdentitySet"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A name was cleared, and the given balance returned."] - pub struct IdentityCleared { - pub who: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, + #[doc = "New proposal."] + pub struct Proposed { + pub proposal_index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for IdentityCleared { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "IdentityCleared"; + impl ::subxt::events::StaticEvent for Proposed { + const PALLET: &'static str = "Treasury"; + const EVENT: &'static str = "Proposed"; } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -18759,14 +17032,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A name was removed and the given balance slashed."] - pub struct IdentityKilled { - pub who: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, + #[doc = "We have ended a spend period and will now allocate funds."] + pub struct Spending { + pub budget_remaining: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for IdentityKilled { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "IdentityKilled"; + impl ::subxt::events::StaticEvent for Spending { + const PALLET: &'static str = "Treasury"; + const EVENT: &'static str = "Spending"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18778,14 +17050,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A judgement was asked from a registrar."] - pub struct JudgementRequested { - pub who: ::subxt::utils::AccountId32, - pub registrar_index: ::core::primitive::u32, + #[doc = "Some funds have been allocated."] + pub struct Awarded { + pub proposal_index: ::core::primitive::u32, + pub award: ::core::primitive::u128, + pub account: ::subxt::utils::AccountId32, } - impl ::subxt::events::StaticEvent for JudgementRequested { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "JudgementRequested"; + impl ::subxt::events::StaticEvent for Awarded { + const PALLET: &'static str = "Treasury"; + const EVENT: &'static str = "Awarded"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18797,16 +17070,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A judgement request was retracted."] - pub struct JudgementUnrequested { - pub who: ::subxt::utils::AccountId32, - pub registrar_index: ::core::primitive::u32, + #[doc = "A proposal was rejected; funds were slashed."] + pub struct Rejected { + pub proposal_index: ::core::primitive::u32, + pub slashed: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for JudgementUnrequested { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "JudgementUnrequested"; + impl ::subxt::events::StaticEvent for Rejected { + const PALLET: &'static str = "Treasury"; + const EVENT: &'static str = "Rejected"; } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -18816,14 +17090,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A judgement was given by a registrar."] - pub struct JudgementGiven { - pub target: ::subxt::utils::AccountId32, - pub registrar_index: ::core::primitive::u32, + #[doc = "Some of our funds have been burnt."] + pub struct Burnt { + pub burnt_funds: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for JudgementGiven { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "JudgementGiven"; + impl ::subxt::events::StaticEvent for Burnt { + const PALLET: &'static str = "Treasury"; + const EVENT: &'static str = "Burnt"; } #[derive( :: subxt :: ext :: codec :: CompactAs, @@ -18836,15 +17109,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A registrar was added."] - pub struct RegistrarAdded { - pub registrar_index: ::core::primitive::u32, + #[doc = "Spending has finished; this is the amount that rolls over until next spend."] + pub struct Rollover { + pub rollover_balance: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for RegistrarAdded { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "RegistrarAdded"; + impl ::subxt::events::StaticEvent for Rollover { + const PALLET: &'static str = "Treasury"; + const EVENT: &'static str = "Rollover"; } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -18854,15 +17128,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A sub-identity was added to an identity and the deposit paid."] - pub struct SubIdentityAdded { - pub sub: ::subxt::utils::AccountId32, - pub main: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, + #[doc = "Some funds have been deposited."] + pub struct Deposit { + pub value: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for SubIdentityAdded { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "SubIdentityAdded"; + impl ::subxt::events::StaticEvent for Deposit { + const PALLET: &'static str = "Treasury"; + const EVENT: &'static str = "Deposit"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18874,15 +17146,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A sub-identity was removed from an identity and the deposit freed."] - pub struct SubIdentityRemoved { - pub sub: ::subxt::utils::AccountId32, - pub main: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, + #[doc = "A new spend proposal has been approved."] + pub struct SpendApproved { + pub proposal_index: ::core::primitive::u32, + pub amount: ::core::primitive::u128, + pub beneficiary: ::subxt::utils::AccountId32, } - impl ::subxt::events::StaticEvent for SubIdentityRemoved { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "SubIdentityRemoved"; + impl ::subxt::events::StaticEvent for SpendApproved { + const PALLET: &'static str = "Treasury"; + const EVENT: &'static str = "SpendApproved"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -18894,219 +17166,135 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A sub-identity was cleared, and the given deposit repatriated from the"] - #[doc = "main identity account to the sub-identity account."] - pub struct SubIdentityRevoked { - pub sub: ::subxt::utils::AccountId32, - pub main: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, + #[doc = "The inactive funds of the pallet have been updated."] + pub struct UpdatedInactive { + pub reactivated: ::core::primitive::u128, + pub deactivated: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for SubIdentityRevoked { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "SubIdentityRevoked"; + impl ::subxt::events::StaticEvent for UpdatedInactive { + const PALLET: &'static str = "Treasury"; + const EVENT: &'static str = "UpdatedInactive"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " Information that is pertinent to identify the entity behind an account."] - #[doc = ""] - #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] - pub fn identity_of( + #[doc = " Number of proposals that have been made."] + pub fn proposal_count( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_identity::types::Registration<::core::primitive::u128>, + ::core::primitive::u32, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "IdentityOf", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 193u8, 195u8, 180u8, 188u8, 129u8, 250u8, 180u8, 219u8, 22u8, 95u8, - 175u8, 170u8, 143u8, 188u8, 80u8, 124u8, 234u8, 228u8, 245u8, 39u8, - 72u8, 153u8, 107u8, 199u8, 23u8, 75u8, 47u8, 247u8, 104u8, 208u8, - 171u8, 82u8, - ], - ) - } - #[doc = " Information that is pertinent to identify the entity behind an account."] - #[doc = ""] - #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] - pub fn identity_of_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_identity::types::Registration<::core::primitive::u128>, - (), (), - ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Identity", - "IdentityOf", - Vec::new(), + "Treasury", + "ProposalCount", + vec![], [ - 193u8, 195u8, 180u8, 188u8, 129u8, 250u8, 180u8, 219u8, 22u8, 95u8, - 175u8, 170u8, 143u8, 188u8, 80u8, 124u8, 234u8, 228u8, 245u8, 39u8, - 72u8, 153u8, 107u8, 199u8, 23u8, 75u8, 47u8, 247u8, 104u8, 208u8, - 171u8, 82u8, + 132u8, 145u8, 78u8, 218u8, 51u8, 189u8, 55u8, 172u8, 143u8, 33u8, + 140u8, 99u8, 124u8, 208u8, 57u8, 232u8, 154u8, 110u8, 32u8, 142u8, + 24u8, 149u8, 109u8, 105u8, 30u8, 83u8, 39u8, 177u8, 127u8, 160u8, 34u8, + 70u8, ], ) } - #[doc = " The super-identity of an alternative \"sub\" identity together with its name, within that"] - #[doc = " context. If the account is not some other account's sub-identity, then just `None`."] - pub fn super_of( + #[doc = " Proposals that have been made."] + pub fn proposals( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( + runtime_types::pallet_treasury::Proposal< ::subxt::utils::AccountId32, - runtime_types::pallet_identity::types::Data, - ), + ::core::primitive::u128, + >, ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Identity", - "SuperOf", + "Treasury", + "Proposals", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 170u8, 249u8, 112u8, 249u8, 75u8, 176u8, 21u8, 29u8, 152u8, 149u8, - 69u8, 113u8, 20u8, 92u8, 113u8, 130u8, 135u8, 62u8, 18u8, 204u8, 166u8, - 193u8, 133u8, 167u8, 248u8, 117u8, 80u8, 137u8, 158u8, 111u8, 100u8, - 137u8, + 62u8, 223u8, 55u8, 209u8, 151u8, 134u8, 122u8, 65u8, 207u8, 38u8, + 113u8, 213u8, 237u8, 48u8, 129u8, 32u8, 91u8, 228u8, 108u8, 91u8, 37u8, + 49u8, 94u8, 4u8, 75u8, 122u8, 25u8, 34u8, 198u8, 224u8, 246u8, 160u8, ], ) } - #[doc = " The super-identity of an alternative \"sub\" identity together with its name, within that"] - #[doc = " context. If the account is not some other account's sub-identity, then just `None`."] - pub fn super_of_root( + #[doc = " Proposals that have been made."] + pub fn proposals_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( + runtime_types::pallet_treasury::Proposal< ::subxt::utils::AccountId32, - runtime_types::pallet_identity::types::Data, - ), + ::core::primitive::u128, + >, (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Identity", - "SuperOf", + "Treasury", + "Proposals", Vec::new(), [ - 170u8, 249u8, 112u8, 249u8, 75u8, 176u8, 21u8, 29u8, 152u8, 149u8, - 69u8, 113u8, 20u8, 92u8, 113u8, 130u8, 135u8, 62u8, 18u8, 204u8, 166u8, - 193u8, 133u8, 167u8, 248u8, 117u8, 80u8, 137u8, 158u8, 111u8, 100u8, - 137u8, + 62u8, 223u8, 55u8, 209u8, 151u8, 134u8, 122u8, 65u8, 207u8, 38u8, + 113u8, 213u8, 237u8, 48u8, 129u8, 32u8, 91u8, 228u8, 108u8, 91u8, 37u8, + 49u8, 94u8, 4u8, 75u8, 122u8, 25u8, 34u8, 198u8, 224u8, 246u8, 160u8, ], ) } - #[doc = " Alternative \"sub\" identities of this account."] - #[doc = ""] - #[doc = " The first item is the deposit, the second is a vector of the accounts."] - #[doc = ""] - #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] - pub fn subs_of( + #[doc = " The amount which has been reported as inactive to Currency."] + pub fn deactivated( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u128, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - ), - ::subxt::storage::address::Yes, + ::core::primitive::u128, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), > { ::subxt::storage::address::Address::new_static( - "Identity", - "SubsOf", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "Treasury", + "Deactivated", + vec![], [ - 128u8, 15u8, 175u8, 155u8, 216u8, 225u8, 200u8, 169u8, 215u8, 206u8, - 110u8, 22u8, 204u8, 89u8, 212u8, 210u8, 159u8, 169u8, 53u8, 7u8, 44u8, - 164u8, 91u8, 151u8, 7u8, 227u8, 38u8, 230u8, 175u8, 84u8, 6u8, 4u8, + 159u8, 57u8, 5u8, 85u8, 136u8, 128u8, 70u8, 43u8, 67u8, 76u8, 123u8, + 206u8, 48u8, 253u8, 51u8, 40u8, 14u8, 35u8, 162u8, 173u8, 127u8, 79u8, + 38u8, 235u8, 9u8, 141u8, 201u8, 37u8, 211u8, 176u8, 119u8, 106u8, ], ) } - #[doc = " Alternative \"sub\" identities of this account."] - #[doc = ""] - #[doc = " The first item is the deposit, the second is a vector of the accounts."] - #[doc = ""] - #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] - pub fn subs_of_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u128, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - ), - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "SubsOf", - Vec::new(), - [ - 128u8, 15u8, 175u8, 155u8, 216u8, 225u8, 200u8, 169u8, 215u8, 206u8, - 110u8, 22u8, 204u8, 89u8, 212u8, 210u8, 159u8, 169u8, 53u8, 7u8, 44u8, - 164u8, 91u8, 151u8, 7u8, 227u8, 38u8, 230u8, 175u8, 84u8, 6u8, 4u8, - ], - ) - } - #[doc = " The set of registrars. Not expected to get very big as can only be added through a"] - #[doc = " special origin (likely a council motion)."] - #[doc = ""] - #[doc = " The index into this can be cast to `RegistrarIndex` to get a valid value."] - pub fn registrars( + #[doc = " Proposal indices that have been approved but not yet awarded."] + pub fn approvals( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::option::Option< - runtime_types::pallet_identity::types::RegistrarInfo< - ::core::primitive::u128, - ::subxt::utils::AccountId32, - >, - >, + ::core::primitive::u32, >, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "Identity", - "Registrars", + "Treasury", + "Approvals", vec![], [ - 157u8, 87u8, 39u8, 240u8, 154u8, 54u8, 241u8, 229u8, 76u8, 9u8, 62u8, - 252u8, 40u8, 143u8, 186u8, 182u8, 233u8, 187u8, 251u8, 61u8, 236u8, - 229u8, 19u8, 55u8, 42u8, 36u8, 82u8, 173u8, 215u8, 155u8, 229u8, 111u8, + 202u8, 106u8, 189u8, 40u8, 127u8, 172u8, 108u8, 50u8, 193u8, 4u8, + 248u8, 226u8, 176u8, 101u8, 212u8, 222u8, 64u8, 206u8, 244u8, 175u8, + 111u8, 106u8, 86u8, 96u8, 19u8, 109u8, 218u8, 152u8, 30u8, 59u8, 96u8, + 1u8, ], ) } @@ -19116,27 +17304,29 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " The amount held on deposit for a registered identity"] - pub fn basic_deposit( + #[doc = " Fraction of a proposal's value that should be bonded in order to place the proposal."] + #[doc = " An accepted proposal gets these back. A rejected proposal does not."] + pub fn proposal_bond( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { + ) -> ::subxt::constants::Address + { ::subxt::constants::Address::new_static( - "Identity", - "BasicDeposit", + "Treasury", + "ProposalBond", [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, + 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, + 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, ], ) } - #[doc = " The amount held on deposit per additional field for a registered identity."] - pub fn field_deposit( + #[doc = " Minimum amount of funds that should be placed in a deposit for making a proposal."] + pub fn proposal_bond_minimum( &self, ) -> ::subxt::constants::Address<::core::primitive::u128> { ::subxt::constants::Address::new_static( - "Identity", - "FieldDeposit", + "Treasury", + "ProposalBondMinimum", [ 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, @@ -19144,29 +17334,27 @@ pub mod api { ], ) } - #[doc = " The amount held on deposit for a registered subaccount. This should account for the fact"] - #[doc = " that one storage item's value will increase by the size of an account ID, and there will"] - #[doc = " be another trie item whose value is the size of an account ID plus 32 bytes."] - pub fn sub_account_deposit( + #[doc = " Maximum amount of funds that should be placed in a deposit for making a proposal."] + pub fn proposal_bond_maximum( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { + ) -> ::subxt::constants::Address<::core::option::Option<::core::primitive::u128>> + { ::subxt::constants::Address::new_static( - "Identity", - "SubAccountDeposit", + "Treasury", + "ProposalBondMaximum", [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 84u8, 154u8, 218u8, 83u8, 84u8, 189u8, 32u8, 20u8, 120u8, 194u8, 88u8, + 205u8, 109u8, 216u8, 114u8, 193u8, 120u8, 198u8, 154u8, 237u8, 134u8, + 204u8, 102u8, 247u8, 52u8, 103u8, 231u8, 43u8, 243u8, 122u8, 60u8, + 216u8, ], ) } - #[doc = " The maximum number of sub-accounts allowed per identified account."] - pub fn max_sub_accounts( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { + #[doc = " Period between successive spends."] + pub fn spend_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Identity", - "MaxSubAccounts", + "Treasury", + "SpendPeriod", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -19175,30 +17363,43 @@ pub mod api { ], ) } - #[doc = " Maximum number of additional fields that may be stored in an ID. Needed to bound the I/O"] - #[doc = " required to access an identity, but can be pretty high."] - pub fn max_additional_fields( + #[doc = " Percentage of spare funds (if any) that are burnt per spend period."] + pub fn burn( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { + ) -> ::subxt::constants::Address + { ::subxt::constants::Address::new_static( - "Identity", - "MaxAdditionalFields", + "Treasury", + "Burn", [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, + 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, + 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, ], ) } - #[doc = " Maxmimum number of registrars allowed in the system. Needed to bound the complexity"] - #[doc = " of, e.g., updating judgements."] - pub fn max_registrars( + #[doc = " The treasury's pallet id, used for deriving its sovereign account ID."] + pub fn pallet_id( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { + ) -> ::subxt::constants::Address + { ::subxt::constants::Address::new_static( - "Identity", - "MaxRegistrars", + "Treasury", + "PalletId", + [ + 139u8, 109u8, 228u8, 151u8, 252u8, 32u8, 130u8, 69u8, 112u8, 154u8, + 174u8, 45u8, 83u8, 245u8, 51u8, 132u8, 173u8, 5u8, 186u8, 24u8, 243u8, + 9u8, 12u8, 214u8, 80u8, 74u8, 69u8, 189u8, 30u8, 94u8, 22u8, 39u8, + ], + ) + } + #[doc = " The maximum number of approvals that can wait in the spending queue."] + #[doc = ""] + #[doc = " NOTE: This parameter is also used within the Bounties Pallet extension if enabled."] + pub fn max_approvals(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Treasury", + "MaxApprovals", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -19210,11 +17411,11 @@ pub mod api { } } } - pub mod proxy { + pub mod conviction_voting { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_proxy::pallet::Error; + pub type Error = runtime_types::pallet_conviction_voting::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -19232,67 +17433,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Proxy { - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub force_proxy_type: - ::core::option::Option, - pub call: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddProxy { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub delay: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveProxy { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub delay: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveProxies; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CreatePure { - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub delay: ::core::primitive::u32, - pub index: ::core::primitive::u16, + pub struct Vote { + #[codec(compact)] + pub poll_index: ::core::primitive::u32, + pub vote: runtime_types::pallet_conviction_voting::vote::AccountVote< + ::core::primitive::u128, + >, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19304,16 +17450,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillPure { - pub spawner: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub index: ::core::primitive::u16, - #[codec(compact)] - pub height: ::core::primitive::u32, - #[codec(compact)] - pub ext_index: ::core::primitive::u32, + pub struct Delegate { + pub class: ::core::primitive::u16, + pub to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub conviction: runtime_types::pallet_conviction_voting::conviction::Conviction, + pub balance: ::core::primitive::u128, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -19323,9 +17467,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Announce { - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call_hash: ::subxt::utils::H256, + pub struct Undelegate { + pub class: ::core::primitive::u16, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19337,9 +17480,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveAnnouncement { - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call_hash: ::subxt::utils::H256, + pub struct Unlock { + pub class: ::core::primitive::u16, + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19351,9 +17494,9 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RejectAnnouncement { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call_hash: ::subxt::utils::H256, + pub struct RemoveVote { + pub class: ::core::option::Option<::core::primitive::u16>, + pub index: ::core::primitive::u32, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19365,336 +17508,228 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProxyAnnounced { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub force_proxy_type: - ::core::option::Option, - pub call: ::std::boxed::Box, + pub struct RemoveOtherVote { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub class: ::core::primitive::u16, + pub index: ::core::primitive::u32, } } pub struct TransactionApi; impl TransactionApi { - #[doc = "Dispatch the given `call` from an account that the sender is authorised for through"] - #[doc = "`add_proxy`."] + #[doc = "Vote in a poll. If `vote.is_aye()`, the vote is to enact the proposal;"] + #[doc = "otherwise it is a vote to keep the status quo."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "The dispatch origin of this call must be _Signed_."] #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `real`: The account that the proxy will make a call on behalf of."] - #[doc = "- `force_proxy_type`: Specify the exact proxy type to be used and checked for this call."] - #[doc = "- `call`: The call to be made by the `real` account."] - pub fn proxy( + #[doc = "- `poll_index`: The index of the poll to vote for."] + #[doc = "- `vote`: The vote configuration."] + #[doc = ""] + #[doc = "Weight: `O(R)` where R is the number of polls the voter has voted on."] + pub fn vote( &self, - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - force_proxy_type: ::core::option::Option< - runtime_types::polkadot_runtime::ProxyType, + poll_index: ::core::primitive::u32, + vote: runtime_types::pallet_conviction_voting::vote::AccountVote< + ::core::primitive::u128, >, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Proxy", - "proxy", - types::Proxy { - real, - force_proxy_type, - call: ::std::boxed::Box::new(call), - }, + "ConvictionVoting", + "vote", + types::Vote { poll_index, vote }, [ - 29u8, 33u8, 67u8, 179u8, 234u8, 241u8, 45u8, 167u8, 110u8, 23u8, 85u8, - 27u8, 1u8, 184u8, 223u8, 187u8, 129u8, 206u8, 75u8, 237u8, 235u8, - 207u8, 43u8, 201u8, 194u8, 145u8, 149u8, 184u8, 95u8, 185u8, 205u8, - 248u8, + 255u8, 8u8, 191u8, 166u8, 7u8, 48u8, 227u8, 0u8, 34u8, 109u8, 3u8, + 172u8, 168u8, 37u8, 220u8, 229u8, 88u8, 61u8, 117u8, 212u8, 131u8, + 124u8, 74u8, 60u8, 83u8, 62u8, 193u8, 66u8, 162u8, 121u8, 76u8, 180u8, ], ) } - #[doc = "Register a proxy account for the sender that is able to make calls on its behalf."] + #[doc = "Delegate the voting power (with some given conviction) of the sending account for a"] + #[doc = "particular class of polls."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "The balance delegated is locked for as long as it's delegated, and thereafter for the"] + #[doc = "time appropriate for the conviction's lock period."] #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `proxy`: The account that the `caller` would like to make a proxy."] - #[doc = "- `proxy_type`: The permissions allowed for this proxy account."] - #[doc = "- `delay`: The announcement period required of the initial proxy. Will generally be"] - #[doc = "zero."] - pub fn add_proxy( + #[doc = "The dispatch origin of this call must be _Signed_, and the signing account must either:"] + #[doc = " - be delegating already; or"] + #[doc = " - have no voting activity (if there is, then it will need to be removed/consolidated"] + #[doc = " through `reap_vote` or `unvote`)."] + #[doc = ""] + #[doc = "- `to`: The account whose voting the `target` account's voting power will follow."] + #[doc = "- `class`: The class of polls to delegate. To delegate multiple classes, multiple calls"] + #[doc = " to this function are required."] + #[doc = "- `conviction`: The conviction that will be attached to the delegated votes. When the"] + #[doc = " account is undelegated, the funds will be locked for the corresponding period."] + #[doc = "- `balance`: The amount of the account's balance to be used in delegating. This must not"] + #[doc = " be more than the account's current balance."] + #[doc = ""] + #[doc = "Emits `Delegated`."] + #[doc = ""] + #[doc = "Weight: `O(R)` where R is the number of polls the voter delegating to has"] + #[doc = " voted on. Weight is initially charged as if maximum votes, but is refunded later."] + pub fn delegate( &self, - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - proxy_type: runtime_types::polkadot_runtime::ProxyType, - delay: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + class: ::core::primitive::u16, + to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + conviction: runtime_types::pallet_conviction_voting::conviction::Conviction, + balance: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Proxy", - "add_proxy", - types::AddProxy { - delegate, - proxy_type, - delay, + "ConvictionVoting", + "delegate", + types::Delegate { + class, + to, + conviction, + balance, }, [ - 76u8, 227u8, 139u8, 167u8, 131u8, 37u8, 104u8, 137u8, 224u8, 66u8, - 37u8, 1u8, 89u8, 113u8, 232u8, 199u8, 79u8, 187u8, 176u8, 106u8, 168u8, - 144u8, 68u8, 32u8, 0u8, 227u8, 188u8, 28u8, 218u8, 84u8, 82u8, 96u8, + 241u8, 83u8, 114u8, 135u8, 173u8, 98u8, 8u8, 2u8, 197u8, 164u8, 105u8, + 93u8, 87u8, 243u8, 54u8, 149u8, 10u8, 168u8, 199u8, 211u8, 102u8, + 176u8, 217u8, 244u8, 78u8, 211u8, 124u8, 133u8, 32u8, 28u8, 235u8, + 222u8, ], ) } - #[doc = "Unregister a proxy account for the sender."] + #[doc = "Undelegate the voting power of the sending account for a particular class of polls."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "Tokens may be unlocked following once an amount of time consistent with the lock period"] + #[doc = "of the conviction with which the delegation was issued has passed."] #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `proxy`: The account that the `caller` would like to remove as a proxy."] - #[doc = "- `proxy_type`: The permissions currently enabled for the removed proxy account."] - pub fn remove_proxy( + #[doc = "The dispatch origin of this call must be _Signed_ and the signing account must be"] + #[doc = "currently delegating."] + #[doc = ""] + #[doc = "- `class`: The class of polls to remove the delegation from."] + #[doc = ""] + #[doc = "Emits `Undelegated`."] + #[doc = ""] + #[doc = "Weight: `O(R)` where R is the number of polls the voter delegating to has"] + #[doc = " voted on. Weight is initially charged as if maximum votes, but is refunded later."] + pub fn undelegate( &self, - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - proxy_type: runtime_types::polkadot_runtime::ProxyType, - delay: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + class: ::core::primitive::u16, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Proxy", - "remove_proxy", - types::RemoveProxy { - delegate, - proxy_type, - delay, - }, + "ConvictionVoting", + "undelegate", + types::Undelegate { class }, [ - 46u8, 235u8, 142u8, 33u8, 21u8, 200u8, 243u8, 213u8, 62u8, 162u8, 70u8, - 132u8, 204u8, 76u8, 156u8, 66u8, 83u8, 95u8, 13u8, 208u8, 241u8, 242u8, - 219u8, 39u8, 229u8, 238u8, 221u8, 135u8, 66u8, 159u8, 38u8, 50u8, + 0u8, 244u8, 151u8, 108u8, 96u8, 240u8, 126u8, 247u8, 29u8, 33u8, 25u8, + 34u8, 253u8, 207u8, 107u8, 227u8, 139u8, 64u8, 184u8, 112u8, 246u8, + 81u8, 201u8, 41u8, 32u8, 201u8, 194u8, 201u8, 4u8, 170u8, 40u8, 83u8, ], ) } - #[doc = "Unregister all proxy accounts for the sender."] + #[doc = "Remove the lock caused by prior voting/delegating which has expired within a particular"] + #[doc = "class."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "The dispatch origin of this call must be _Signed_."] #[doc = ""] - #[doc = "WARNING: This may be called on accounts created by `pure`, however if done, then"] - #[doc = "the unreserved fees will be inaccessible. **All access to this account will be lost.**"] - pub fn remove_proxies(&self) -> ::subxt::tx::Payload { + #[doc = "- `class`: The class of polls to unlock."] + #[doc = "- `target`: The account to remove the lock on."] + #[doc = ""] + #[doc = "Weight: `O(R)` with R number of vote of target."] + pub fn unlock( + &self, + class: ::core::primitive::u16, + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Proxy", - "remove_proxies", - types::RemoveProxies {}, + "ConvictionVoting", + "unlock", + types::Unlock { class, target }, [ - 15u8, 237u8, 27u8, 166u8, 254u8, 218u8, 92u8, 5u8, 213u8, 239u8, 99u8, - 59u8, 1u8, 26u8, 73u8, 252u8, 81u8, 94u8, 214u8, 227u8, 169u8, 58u8, - 40u8, 253u8, 187u8, 225u8, 192u8, 26u8, 19u8, 23u8, 121u8, 129u8, + 130u8, 244u8, 207u8, 112u8, 194u8, 4u8, 121u8, 4u8, 59u8, 75u8, 168u8, + 246u8, 210u8, 249u8, 247u8, 242u8, 252u8, 28u8, 190u8, 93u8, 11u8, 8u8, + 234u8, 222u8, 22u8, 110u8, 182u8, 252u8, 82u8, 64u8, 74u8, 169u8, ], ) } - #[doc = "Spawn a fresh new account that is guaranteed to be otherwise inaccessible, and"] - #[doc = "initialize it with a proxy of `proxy_type` for `origin` sender."] + #[doc = "Remove a vote for a poll."] #[doc = ""] - #[doc = "Requires a `Signed` origin."] + #[doc = "If:"] + #[doc = "- the poll was cancelled, or"] + #[doc = "- the poll is ongoing, or"] + #[doc = "- the poll has ended such that"] + #[doc = " - the vote of the account was in opposition to the result; or"] + #[doc = " - there was no conviction to the account's vote; or"] + #[doc = " - the account made a split vote"] + #[doc = "...then the vote is removed cleanly and a following call to `unlock` may result in more"] + #[doc = "funds being available."] #[doc = ""] - #[doc = "- `proxy_type`: The type of the proxy that the sender will be registered as over the"] - #[doc = "new account. This will almost always be the most permissive `ProxyType` possible to"] - #[doc = "allow for maximum flexibility."] - #[doc = "- `index`: A disambiguation index, in case this is called multiple times in the same"] - #[doc = "transaction (e.g. with `utility::batch`). Unless you're using `batch` you probably just"] - #[doc = "want to use `0`."] - #[doc = "- `delay`: The announcement period required of the initial proxy. Will generally be"] - #[doc = "zero."] + #[doc = "If, however, the poll has ended and:"] + #[doc = "- it finished corresponding to the vote of the account, and"] + #[doc = "- the account made a standard vote with conviction, and"] + #[doc = "- the lock period of the conviction is not over"] + #[doc = "...then the lock will be aggregated into the overall account's lock, which may involve"] + #[doc = "*overlocking* (where the two locks are combined into a single lock that is the maximum"] + #[doc = "of both the amount locked and the time is it locked for)."] #[doc = ""] - #[doc = "Fails with `Duplicate` if this has already been called in this transaction, from the"] - #[doc = "same sender, with the same parameters."] + #[doc = "The dispatch origin of this call must be _Signed_, and the signer must have a vote"] + #[doc = "registered for poll `index`."] #[doc = ""] - #[doc = "Fails if there are insufficient funds to pay for deposit."] - pub fn create_pure( + #[doc = "- `index`: The index of poll of the vote to be removed."] + #[doc = "- `class`: Optional parameter, if given it indicates the class of the poll. For polls"] + #[doc = " which have finished or are cancelled, this must be `Some`."] + #[doc = ""] + #[doc = "Weight: `O(R + log R)` where R is the number of polls that `target` has voted on."] + #[doc = " Weight is calculated for the maximum number of vote."] + pub fn remove_vote( &self, - proxy_type: runtime_types::polkadot_runtime::ProxyType, - delay: ::core::primitive::u32, - index: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { + class: ::core::option::Option<::core::primitive::u16>, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Proxy", - "create_pure", - types::CreatePure { - proxy_type, - delay, - index, - }, + "ConvictionVoting", + "remove_vote", + types::RemoveVote { class, index }, [ - 184u8, 127u8, 177u8, 255u8, 195u8, 192u8, 136u8, 114u8, 249u8, 70u8, - 222u8, 77u8, 10u8, 213u8, 209u8, 6u8, 238u8, 173u8, 47u8, 182u8, 129u8, - 69u8, 74u8, 249u8, 25u8, 170u8, 119u8, 106u8, 54u8, 165u8, 0u8, 100u8, + 151u8, 255u8, 135u8, 195u8, 137u8, 27u8, 116u8, 193u8, 245u8, 78u8, + 38u8, 130u8, 233u8, 28u8, 235u8, 50u8, 144u8, 191u8, 39u8, 68u8, 17u8, + 214u8, 25u8, 2u8, 120u8, 14u8, 219u8, 205u8, 59u8, 192u8, 125u8, 142u8, ], ) } - #[doc = "Removes a previously spawned pure proxy."] + #[doc = "Remove a vote for a poll."] #[doc = ""] - #[doc = "WARNING: **All access to this account will be lost.** Any funds held in it will be"] - #[doc = "inaccessible."] + #[doc = "If the `target` is equal to the signer, then this function is exactly equivalent to"] + #[doc = "`remove_vote`. If not equal to the signer, then the vote must have expired,"] + #[doc = "either because the poll was cancelled, because the voter lost the poll or"] + #[doc = "because the conviction period is over."] #[doc = ""] - #[doc = "Requires a `Signed` origin, and the sender account must have been created by a call to"] - #[doc = "`pure` with corresponding parameters."] + #[doc = "The dispatch origin of this call must be _Signed_."] #[doc = ""] - #[doc = "- `spawner`: The account that originally called `pure` to create this account."] - #[doc = "- `index`: The disambiguation index originally passed to `pure`. Probably `0`."] - #[doc = "- `proxy_type`: The proxy type originally passed to `pure`."] - #[doc = "- `height`: The height of the chain when the call to `pure` was processed."] - #[doc = "- `ext_index`: The extrinsic index in which the call to `pure` was processed."] + #[doc = "- `target`: The account of the vote to be removed; this account must have voted for poll"] + #[doc = " `index`."] + #[doc = "- `index`: The index of poll of the vote to be removed."] + #[doc = "- `class`: The class of the poll."] #[doc = ""] - #[doc = "Fails with `NoPermission` in case the caller is not a previously created pure"] - #[doc = "account whose `pure` call has corresponding parameters."] - pub fn kill_pure( + #[doc = "Weight: `O(R + log R)` where R is the number of polls that `target` has voted on."] + #[doc = " Weight is calculated for the maximum number of vote."] + pub fn remove_other_vote( &self, - spawner: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - proxy_type: runtime_types::polkadot_runtime::ProxyType, - index: ::core::primitive::u16, - height: ::core::primitive::u32, - ext_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + class: ::core::primitive::u16, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Proxy", - "kill_pure", - types::KillPure { - spawner, - proxy_type, + "ConvictionVoting", + "remove_other_vote", + types::RemoveOtherVote { + target, + class, index, - height, - ext_index, - }, - [ - 134u8, 133u8, 203u8, 194u8, 12u8, 188u8, 59u8, 222u8, 83u8, 30u8, - 217u8, 181u8, 224u8, 194u8, 81u8, 206u8, 30u8, 116u8, 94u8, 36u8, 87u8, - 227u8, 157u8, 129u8, 198u8, 115u8, 208u8, 105u8, 143u8, 175u8, 145u8, - 18u8, - ], - ) - } - #[doc = "Publish the hash of a proxy-call that will be made in the future."] - #[doc = ""] - #[doc = "This must be called some number of blocks before the corresponding `proxy` is attempted"] - #[doc = "if the delay associated with the proxy relationship is greater than zero."] - #[doc = ""] - #[doc = "No more than `MaxPending` announcements may be made at any one time."] - #[doc = ""] - #[doc = "This will take a deposit of `AnnouncementDepositFactor` as well as"] - #[doc = "`AnnouncementDepositBase` if there are no other pending announcements."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and a proxy of `real`."] - #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `real`: The account that the proxy will make a call on behalf of."] - #[doc = "- `call_hash`: The hash of the call to be made by the `real` account."] - pub fn announce( - &self, - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "announce", - types::Announce { real, call_hash }, - [ - 235u8, 116u8, 208u8, 53u8, 128u8, 91u8, 100u8, 68u8, 255u8, 254u8, - 119u8, 253u8, 108u8, 130u8, 88u8, 56u8, 113u8, 99u8, 105u8, 179u8, - 16u8, 143u8, 131u8, 203u8, 234u8, 76u8, 199u8, 191u8, 35u8, 158u8, - 130u8, 209u8, - ], - ) - } - #[doc = "Remove a given announcement."] - #[doc = ""] - #[doc = "May be called by a proxy account to remove a call they previously announced and return"] - #[doc = "the deposit."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `real`: The account that the proxy will make a call on behalf of."] - #[doc = "- `call_hash`: The hash of the call to be made by the `real` account."] - pub fn remove_announcement( - &self, - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "remove_announcement", - types::RemoveAnnouncement { real, call_hash }, - [ - 140u8, 186u8, 140u8, 129u8, 40u8, 124u8, 57u8, 61u8, 84u8, 247u8, - 123u8, 241u8, 148u8, 15u8, 94u8, 146u8, 121u8, 78u8, 190u8, 68u8, - 185u8, 125u8, 62u8, 49u8, 108u8, 131u8, 229u8, 82u8, 68u8, 37u8, 184u8, - 223u8, - ], - ) - } - #[doc = "Remove the given announcement of a delegate."] - #[doc = ""] - #[doc = "May be called by a target (proxied) account to remove a call that one of their delegates"] - #[doc = "(`delegate`) has announced they want to execute. The deposit is returned."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `delegate`: The account that previously announced the call."] - #[doc = "- `call_hash`: The hash of the call to be made."] - pub fn reject_announcement( - &self, - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "reject_announcement", - types::RejectAnnouncement { - delegate, - call_hash, - }, - [ - 225u8, 198u8, 31u8, 173u8, 157u8, 141u8, 121u8, 51u8, 226u8, 170u8, - 219u8, 86u8, 14u8, 131u8, 122u8, 157u8, 161u8, 200u8, 157u8, 37u8, - 43u8, 97u8, 143u8, 97u8, 46u8, 206u8, 204u8, 42u8, 78u8, 33u8, 85u8, - 127u8, - ], - ) - } - #[doc = "Dispatch the given `call` from an account that the sender is authorized for through"] - #[doc = "`add_proxy`."] - #[doc = ""] - #[doc = "Removes any corresponding announcement(s)."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "Parameters:"] - #[doc = "- `real`: The account that the proxy will make a call on behalf of."] - #[doc = "- `force_proxy_type`: Specify the exact proxy type to be used and checked for this call."] - #[doc = "- `call`: The call to be made by the `real` account."] - pub fn proxy_announced( - &self, - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - force_proxy_type: ::core::option::Option< - runtime_types::polkadot_runtime::ProxyType, - >, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "proxy_announced", - types::ProxyAnnounced { - delegate, - real, - force_proxy_type, - call: ::std::boxed::Box::new(call), }, [ - 144u8, 103u8, 250u8, 31u8, 18u8, 158u8, 175u8, 139u8, 73u8, 56u8, - 178u8, 80u8, 164u8, 100u8, 162u8, 163u8, 119u8, 102u8, 177u8, 28u8, - 229u8, 128u8, 250u8, 242u8, 26u8, 223u8, 74u8, 180u8, 127u8, 124u8, - 134u8, 123u8, + 0u8, 148u8, 112u8, 202u8, 220u8, 85u8, 1u8, 77u8, 199u8, 156u8, 47u8, + 38u8, 105u8, 128u8, 71u8, 108u8, 185u8, 231u8, 252u8, 132u8, 37u8, + 114u8, 211u8, 110u8, 142u8, 64u8, 80u8, 90u8, 138u8, 108u8, 59u8, 87u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_proxy::pallet::Event; + pub type Event = runtime_types::pallet_conviction_voting::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -19707,76 +17742,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proxy was executed correctly, with the given."] - pub struct ProxyExecuted { - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for ProxyExecuted { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "ProxyExecuted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A pure account has been created by new proxy with given"] - #[doc = "disambiguation index and proxy type."] - pub struct PureCreated { - pub pure: ::subxt::utils::AccountId32, - pub who: ::subxt::utils::AccountId32, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub disambiguation_index: ::core::primitive::u16, - } - impl ::subxt::events::StaticEvent for PureCreated { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "PureCreated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An announcement was placed to make a call in the future."] - pub struct Announced { - pub real: ::subxt::utils::AccountId32, - pub proxy: ::subxt::utils::AccountId32, - pub call_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Announced { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "Announced"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proxy was added."] - pub struct ProxyAdded { - pub delegator: ::subxt::utils::AccountId32, - pub delegatee: ::subxt::utils::AccountId32, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub delay: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for ProxyAdded { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "ProxyAdded"; + #[doc = "An account has delegated their vote to another account. \\[who, target\\]"] + pub struct Delegated( + pub ::subxt::utils::AccountId32, + pub ::subxt::utils::AccountId32, + ); + impl ::subxt::events::StaticEvent for Delegated { + const PALLET: &'static str = "ConvictionVoting"; + const EVENT: &'static str = "Delegated"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -19788,149 +17761,130 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proxy was removed."] - pub struct ProxyRemoved { - pub delegator: ::subxt::utils::AccountId32, - pub delegatee: ::subxt::utils::AccountId32, - pub proxy_type: runtime_types::polkadot_runtime::ProxyType, - pub delay: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for ProxyRemoved { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "ProxyRemoved"; + #[doc = "An \\[account\\] has cancelled a previous delegation operation."] + pub struct Undelegated(pub ::subxt::utils::AccountId32); + impl ::subxt::events::StaticEvent for Undelegated { + const PALLET: &'static str = "ConvictionVoting"; + const EVENT: &'static str = "Undelegated"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " The set of account proxies. Maps the account which has delegated to the accounts"] - #[doc = " which are being delegated to, together with the amount held on deposit."] - pub fn proxies( + #[doc = " All voting for a particular voter in a particular voting class. We store the balance for the"] + #[doc = " number of votes that we have recorded."] + pub fn voting_for( &self, _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _1: impl ::std::borrow::Borrow<::core::primitive::u16>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_proxy::ProxyDefinition< - ::subxt::utils::AccountId32, - runtime_types::polkadot_runtime::ProxyType, - ::core::primitive::u32, - >, - >, + runtime_types::pallet_conviction_voting::vote::Voting< ::core::primitive::u128, - ), + ::subxt::utils::AccountId32, + ::core::primitive::u32, + ::core::primitive::u32, + >, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Proxy", - "Proxies", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + "ConvictionVoting", + "VotingFor", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], [ - 80u8, 71u8, 244u8, 42u8, 237u8, 5u8, 46u8, 156u8, 84u8, 213u8, 84u8, - 212u8, 157u8, 221u8, 174u8, 97u8, 157u8, 218u8, 166u8, 127u8, 162u8, - 139u8, 110u8, 98u8, 229u8, 166u8, 49u8, 172u8, 48u8, 237u8, 240u8, - 42u8, + 45u8, 18u8, 71u8, 145u8, 31u8, 220u8, 221u8, 51u8, 69u8, 73u8, 153u8, + 139u8, 46u8, 231u8, 122u8, 15u8, 98u8, 186u8, 57u8, 121u8, 24u8, 241u8, + 161u8, 150u8, 252u8, 133u8, 65u8, 232u8, 21u8, 28u8, 25u8, 75u8, ], ) } - #[doc = " The set of account proxies. Maps the account which has delegated to the accounts"] - #[doc = " which are being delegated to, together with the amount held on deposit."] - pub fn proxies_root( + #[doc = " All voting for a particular voter in a particular voting class. We store the balance for the"] + #[doc = " number of votes that we have recorded."] + pub fn voting_for_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_proxy::ProxyDefinition< - ::subxt::utils::AccountId32, - runtime_types::polkadot_runtime::ProxyType, - ::core::primitive::u32, - >, - >, + runtime_types::pallet_conviction_voting::vote::Voting< ::core::primitive::u128, - ), + ::subxt::utils::AccountId32, + ::core::primitive::u32, + ::core::primitive::u32, + >, (), ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Proxy", - "Proxies", + "ConvictionVoting", + "VotingFor", Vec::new(), [ - 80u8, 71u8, 244u8, 42u8, 237u8, 5u8, 46u8, 156u8, 84u8, 213u8, 84u8, - 212u8, 157u8, 221u8, 174u8, 97u8, 157u8, 218u8, 166u8, 127u8, 162u8, - 139u8, 110u8, 98u8, 229u8, 166u8, 49u8, 172u8, 48u8, 237u8, 240u8, - 42u8, + 45u8, 18u8, 71u8, 145u8, 31u8, 220u8, 221u8, 51u8, 69u8, 73u8, 153u8, + 139u8, 46u8, 231u8, 122u8, 15u8, 98u8, 186u8, 57u8, 121u8, 24u8, 241u8, + 161u8, 150u8, 252u8, 133u8, 65u8, 232u8, 21u8, 28u8, 25u8, 75u8, ], ) } - #[doc = " The announcements made by the proxy (key)."] - pub fn announcements( + #[doc = " The voting classes which have a non-zero lock requirement and the lock amounts which they"] + #[doc = " require. The actual amount locked on behalf of this pallet should always be the maximum of"] + #[doc = " this list."] + pub fn class_locks_for( &self, _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_proxy::Announcement< - ::subxt::utils::AccountId32, - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u16, ::core::primitive::u128, - ), + )>, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Proxy", - "Announcements", + "ConvictionVoting", + "ClassLocksFor", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 233u8, 38u8, 249u8, 89u8, 103u8, 87u8, 64u8, 52u8, 140u8, 228u8, 110u8, - 37u8, 8u8, 92u8, 48u8, 7u8, 46u8, 99u8, 179u8, 83u8, 232u8, 171u8, - 160u8, 45u8, 37u8, 23u8, 151u8, 198u8, 237u8, 103u8, 217u8, 53u8, + 65u8, 181u8, 225u8, 49u8, 35u8, 141u8, 185u8, 155u8, 124u8, 178u8, + 118u8, 51u8, 220u8, 232u8, 95u8, 24u8, 181u8, 135u8, 42u8, 207u8, + 103u8, 166u8, 244u8, 249u8, 106u8, 96u8, 177u8, 56u8, 243u8, 117u8, + 228u8, 145u8, ], ) } - #[doc = " The announcements made by the proxy (key)."] - pub fn announcements_root( + #[doc = " The voting classes which have a non-zero lock requirement and the lock amounts which they"] + #[doc = " require. The actual amount locked on behalf of this pallet should always be the maximum of"] + #[doc = " this list."] + pub fn class_locks_for_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_proxy::Announcement< - ::subxt::utils::AccountId32, - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u16, ::core::primitive::u128, - ), + )>, (), ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Proxy", - "Announcements", + "ConvictionVoting", + "ClassLocksFor", Vec::new(), [ - 233u8, 38u8, 249u8, 89u8, 103u8, 87u8, 64u8, 52u8, 140u8, 228u8, 110u8, - 37u8, 8u8, 92u8, 48u8, 7u8, 46u8, 99u8, 179u8, 83u8, 232u8, 171u8, - 160u8, 45u8, 37u8, 23u8, 151u8, 198u8, 237u8, 103u8, 217u8, 53u8, + 65u8, 181u8, 225u8, 49u8, 35u8, 141u8, 185u8, 155u8, 124u8, 178u8, + 118u8, 51u8, 220u8, 232u8, 95u8, 24u8, 181u8, 135u8, 42u8, 207u8, + 103u8, 166u8, 244u8, 249u8, 106u8, 96u8, 177u8, 56u8, 243u8, 117u8, + 228u8, 145u8, ], ) } @@ -19940,46 +17894,14 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " The base amount of currency needed to reserve for creating a proxy."] - #[doc = ""] - #[doc = " This is held for an additional storage item whose value size is"] - #[doc = " `sizeof(Balance)` bytes and whose key size is `sizeof(AccountId)` bytes."] - pub fn proxy_deposit_base( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Proxy", - "ProxyDepositBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount of currency needed per proxy added."] + #[doc = " The maximum number of concurrent votes an account may have."] #[doc = ""] - #[doc = " This is held for adding 32 bytes plus an instance of `ProxyType` more into a"] - #[doc = " pre-existing storage value. Thus, when configuring `ProxyDepositFactor` one should take"] - #[doc = " into account `32 + proxy_type.encode().len()` bytes of data."] - pub fn proxy_deposit_factor( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Proxy", - "ProxyDepositFactor", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum amount of proxies allowed for a single account."] - pub fn max_proxies(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + #[doc = " Also used to compute weight, an overly large value can lead to extrinsics with large"] + #[doc = " weight estimation: see `delegate` for instance."] + pub fn max_votes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Proxy", - "MaxProxies", + "ConvictionVoting", + "MaxVotes", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -19988,11 +17910,16 @@ pub mod api { ], ) } - #[doc = " The maximum amount of time-delayed announcements that are allowed to be pending."] - pub fn max_pending(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + #[doc = " The minimum period of vote locking."] + #[doc = ""] + #[doc = " It should be no shorter than enactment period to ensure that in the case of an approval,"] + #[doc = " those successful voters are locked into the consequences that their votes entail."] + pub fn vote_locking_period( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Proxy", - "MaxPending", + "ConvictionVoting", + "VoteLockingPeriod", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -20001,48 +17928,14 @@ pub mod api { ], ) } - #[doc = " The base amount of currency needed to reserve for creating an announcement."] - #[doc = ""] - #[doc = " This is held when a new storage item holding a `Balance` is created (typically 16"] - #[doc = " bytes)."] - pub fn announcement_deposit_base( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Proxy", - "AnnouncementDepositBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount of currency needed per announcement made."] - #[doc = ""] - #[doc = " This is held for adding an `AccountId`, `Hash` and `BlockNumber` (typically 68 bytes)"] - #[doc = " into a pre-existing storage value."] - pub fn announcement_deposit_factor( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Proxy", - "AnnouncementDepositFactor", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } } } } - pub mod multisig { + pub mod referenda { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_multisig::pallet::Error; + pub type Error = runtime_types::pallet_referenda::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -20060,11 +17953,19 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsMultiThreshold1 { - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub call: ::std::boxed::Box, + pub struct Submit { + pub proposal_origin: + ::std::boxed::Box, + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + pub enactment_moment: + runtime_types::frame_support::traits::schedule::DispatchTime< + ::core::primitive::u32, + >, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -20074,16 +17975,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - pub call: ::std::boxed::Box, - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, + pub struct PlaceDecisionDeposit { + pub index: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -20093,16 +17989,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApproveAsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - pub call_hash: [::core::primitive::u8; 32usize], - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, + pub struct RefundDecisionDeposit { + pub index: ::core::primitive::u32, } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -20112,221 +18003,299 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelAsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub call_hash: [::core::primitive::u8; 32usize], + pub struct Cancel { + pub index: ::core::primitive::u32, } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Immediately dispatch a multi-signature call using a single approval from the caller."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "- `other_signatories`: The accounts (other than the sender) who are part of the"] - #[doc = "multi-signature, but do not participate in the approval process."] - #[doc = "- `call`: The call to be executed."] + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Kill { + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct NudgeReferendum { + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OneFewerDeciding { + pub track: ::core::primitive::u16, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RefundSubmissionDeposit { + pub index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMetadata { + pub index: ::core::primitive::u32, + pub maybe_hash: ::core::option::Option<::subxt::utils::H256>, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Propose a referendum on a privileged action."] #[doc = ""] - #[doc = "Result is equivalent to the dispatched result."] + #[doc = "- `origin`: must be `SubmitOrigin` and the account must have `SubmissionDeposit` funds"] + #[doc = " available."] + #[doc = "- `proposal_origin`: The origin from which the proposal should be executed."] + #[doc = "- `proposal`: The proposal."] + #[doc = "- `enactment_moment`: The moment that the proposal should be enacted."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "O(Z + C) where Z is the length of the call and C its execution weight."] - pub fn as_multi_threshold_1( + #[doc = "Emits `Submitted`."] + pub fn submit( &self, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - call: runtime_types::polkadot_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { + proposal_origin: runtime_types::polkadot_runtime::OriginCaller, + proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + enactment_moment: runtime_types::frame_support::traits::schedule::DispatchTime< + ::core::primitive::u32, + >, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Multisig", - "as_multi_threshold_1", - types::AsMultiThreshold1 { - other_signatories, - call: ::std::boxed::Box::new(call), + "Referenda", + "submit", + types::Submit { + proposal_origin: ::std::boxed::Box::new(proposal_origin), + proposal, + enactment_moment, }, [ - 113u8, 140u8, 77u8, 180u8, 170u8, 232u8, 85u8, 229u8, 218u8, 187u8, - 62u8, 64u8, 168u8, 186u8, 173u8, 27u8, 125u8, 216u8, 54u8, 167u8, - 225u8, 241u8, 10u8, 226u8, 138u8, 151u8, 242u8, 255u8, 212u8, 160u8, - 106u8, 69u8, + 213u8, 114u8, 86u8, 47u8, 165u8, 41u8, 216u8, 45u8, 93u8, 56u8, 92u8, + 228u8, 10u8, 88u8, 70u8, 82u8, 134u8, 252u8, 214u8, 45u8, 154u8, 150u8, + 221u8, 52u8, 235u8, 186u8, 47u8, 120u8, 221u8, 170u8, 29u8, 239u8, ], ) } - #[doc = "Register approval for a dispatch to be made from a deterministic composite account if"] - #[doc = "approved by a total of `threshold - 1` of `other_signatories`."] - #[doc = ""] - #[doc = "If there are enough, then dispatch the call."] + #[doc = "Post the Decision Deposit for a referendum."] #[doc = ""] - #[doc = "Payment: `DepositBase` will be reserved if this is the first approval, plus"] - #[doc = "`threshold` times `DepositFactor`. It is returned once this dispatch happens or"] - #[doc = "is cancelled."] + #[doc = "- `origin`: must be `Signed` and the account must have funds available for the"] + #[doc = " referendum's track's Decision Deposit."] + #[doc = "- `index`: The index of the submitted referendum whose Decision Deposit is yet to be"] + #[doc = " posted."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "Emits `DecisionDepositPlaced`."] + pub fn place_decision_deposit( + &self, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Referenda", + "place_decision_deposit", + types::PlaceDecisionDeposit { index }, + [ + 118u8, 227u8, 8u8, 55u8, 41u8, 171u8, 244u8, 40u8, 164u8, 232u8, 119u8, + 129u8, 139u8, 123u8, 77u8, 70u8, 219u8, 236u8, 145u8, 159u8, 84u8, + 111u8, 36u8, 4u8, 206u8, 5u8, 139u8, 231u8, 11u8, 231u8, 6u8, 30u8, + ], + ) + } + #[doc = "Refund the Decision Deposit for a closed referendum back to the depositor."] #[doc = ""] - #[doc = "- `threshold`: The total number of approvals for this dispatch before it is executed."] - #[doc = "- `other_signatories`: The accounts (other than the sender) who can approve this"] - #[doc = "dispatch. May not be empty."] - #[doc = "- `maybe_timepoint`: If this is the first approval, then this must be `None`. If it is"] - #[doc = "not the first approval, then it must be `Some`, with the timepoint (block number and"] - #[doc = "transaction index) of the first approval transaction."] - #[doc = "- `call`: The call to be executed."] + #[doc = "- `origin`: must be `Signed` or `Root`."] + #[doc = "- `index`: The index of a closed referendum whose Decision Deposit has not yet been"] + #[doc = " refunded."] #[doc = ""] - #[doc = "NOTE: Unless this is the final approval, you will generally want to use"] - #[doc = "`approve_as_multi` instead, since it only requires a hash of the call."] + #[doc = "Emits `DecisionDepositRefunded`."] + pub fn refund_decision_deposit( + &self, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Referenda", + "refund_decision_deposit", + types::RefundDecisionDeposit { index }, + [ + 120u8, 116u8, 89u8, 51u8, 255u8, 76u8, 150u8, 74u8, 54u8, 93u8, 19u8, + 64u8, 13u8, 177u8, 144u8, 93u8, 132u8, 150u8, 244u8, 48u8, 202u8, + 223u8, 201u8, 130u8, 112u8, 167u8, 29u8, 207u8, 112u8, 181u8, 43u8, + 93u8, + ], + ) + } + #[doc = "Cancel an ongoing referendum."] #[doc = ""] - #[doc = "Result is equivalent to the dispatched result if `threshold` is exactly `1`. Otherwise"] - #[doc = "on success, result is `Ok` and the result from the interior call, if it was executed,"] - #[doc = "may be found in the deposited `MultisigExecuted` event."] + #[doc = "- `origin`: must be the `CancelOrigin`."] + #[doc = "- `index`: The index of the referendum to be cancelled."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(S + Z + Call)`."] - #[doc = "- Up to one balance-reserve or unreserve operation."] - #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] - #[doc = " signatories. `S` is capped by `MaxSignatories`, with weight being proportional."] - #[doc = "- One call encode & hash, both of complexity `O(Z)` where `Z` is tx-len."] - #[doc = "- One encode & hash, both of complexity `O(S)`."] - #[doc = "- Up to one binary search and insert (`O(logS + S)`)."] - #[doc = "- I/O: 1 read `O(S)`, up to 1 mutate `O(S)`. Up to one remove."] - #[doc = "- One event."] - #[doc = "- The weight of the `call`."] - #[doc = "- Storage: inserts one item, value size bounded by `MaxSignatories`, with a deposit"] - #[doc = " taken for its lifetime of `DepositBase + threshold * DepositFactor`."] - pub fn as_multi( + #[doc = "Emits `Cancelled`."] + pub fn cancel( &self, - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - call: runtime_types::polkadot_runtime::RuntimeCall, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Multisig", - "as_multi", - types::AsMulti { - threshold, - other_signatories, - maybe_timepoint, - call: ::std::boxed::Box::new(call), - max_weight, - }, + "Referenda", + "cancel", + types::Cancel { index }, [ - 167u8, 155u8, 31u8, 18u8, 196u8, 45u8, 139u8, 126u8, 185u8, 246u8, - 31u8, 88u8, 200u8, 228u8, 82u8, 139u8, 123u8, 239u8, 169u8, 185u8, - 227u8, 160u8, 71u8, 242u8, 152u8, 146u8, 87u8, 243u8, 170u8, 237u8, - 11u8, 6u8, + 247u8, 55u8, 146u8, 211u8, 168u8, 140u8, 248u8, 217u8, 218u8, 235u8, + 25u8, 39u8, 47u8, 132u8, 134u8, 18u8, 239u8, 70u8, 223u8, 50u8, 245u8, + 101u8, 97u8, 39u8, 226u8, 4u8, 196u8, 16u8, 66u8, 177u8, 178u8, 252u8, ], ) } - #[doc = "Register approval for a dispatch to be made from a deterministic composite account if"] - #[doc = "approved by a total of `threshold - 1` of `other_signatories`."] + #[doc = "Cancel an ongoing referendum and slash the deposits."] #[doc = ""] - #[doc = "Payment: `DepositBase` will be reserved if this is the first approval, plus"] - #[doc = "`threshold` times `DepositFactor`. It is returned once this dispatch happens or"] - #[doc = "is cancelled."] + #[doc = "- `origin`: must be the `KillOrigin`."] + #[doc = "- `index`: The index of the referendum to be cancelled."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "Emits `Killed` and `DepositSlashed`."] + pub fn kill( + &self, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Referenda", + "kill", + types::Kill { index }, + [ + 98u8, 109u8, 143u8, 42u8, 24u8, 80u8, 39u8, 243u8, 249u8, 141u8, 104u8, + 195u8, 29u8, 93u8, 149u8, 37u8, 27u8, 130u8, 84u8, 178u8, 246u8, 26u8, + 113u8, 224u8, 157u8, 94u8, 16u8, 14u8, 158u8, 80u8, 148u8, 198u8, + ], + ) + } + #[doc = "Advance a referendum onto its next logical state. Only used internally."] #[doc = ""] - #[doc = "- `threshold`: The total number of approvals for this dispatch before it is executed."] - #[doc = "- `other_signatories`: The accounts (other than the sender) who can approve this"] - #[doc = "dispatch. May not be empty."] - #[doc = "- `maybe_timepoint`: If this is the first approval, then this must be `None`. If it is"] - #[doc = "not the first approval, then it must be `Some`, with the timepoint (block number and"] - #[doc = "transaction index) of the first approval transaction."] - #[doc = "- `call_hash`: The hash of the call to be executed."] + #[doc = "- `origin`: must be `Root`."] + #[doc = "- `index`: the referendum to be advanced."] + pub fn nudge_referendum( + &self, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Referenda", + "nudge_referendum", + types::NudgeReferendum { index }, + [ + 60u8, 221u8, 153u8, 136u8, 107u8, 209u8, 59u8, 178u8, 208u8, 170u8, + 10u8, 225u8, 213u8, 170u8, 228u8, 64u8, 204u8, 166u8, 7u8, 230u8, + 243u8, 15u8, 206u8, 114u8, 8u8, 128u8, 46u8, 150u8, 114u8, 241u8, + 112u8, 97u8, + ], + ) + } + #[doc = "Advance a track onto its next logical state. Only used internally."] #[doc = ""] - #[doc = "NOTE: If this is the final approval, you will want to use `as_multi` instead."] + #[doc = "- `origin`: must be `Root`."] + #[doc = "- `track`: the track to be advanced."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(S)`."] - #[doc = "- Up to one balance-reserve or unreserve operation."] - #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] - #[doc = " signatories. `S` is capped by `MaxSignatories`, with weight being proportional."] - #[doc = "- One encode & hash, both of complexity `O(S)`."] - #[doc = "- Up to one binary search and insert (`O(logS + S)`)."] - #[doc = "- I/O: 1 read `O(S)`, up to 1 mutate `O(S)`. Up to one remove."] - #[doc = "- One event."] - #[doc = "- Storage: inserts one item, value size bounded by `MaxSignatories`, with a deposit"] - #[doc = " taken for its lifetime of `DepositBase + threshold * DepositFactor`."] - pub fn approve_as_multi( + #[doc = "Action item for when there is now one fewer referendum in the deciding phase and the"] + #[doc = "`DecidingCount` is not yet updated. This means that we should either:"] + #[doc = "- begin deciding another referendum (and leave `DecidingCount` alone); or"] + #[doc = "- decrement `DecidingCount`."] + pub fn one_fewer_deciding( &self, - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - call_hash: [::core::primitive::u8; 32usize], - max_weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { + track: ::core::primitive::u16, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Multisig", - "approve_as_multi", - types::ApproveAsMulti { - threshold, - other_signatories, - maybe_timepoint, - call_hash, - max_weight, - }, + "Referenda", + "one_fewer_deciding", + types::OneFewerDeciding { track }, [ - 133u8, 113u8, 121u8, 66u8, 218u8, 219u8, 48u8, 64u8, 211u8, 114u8, - 163u8, 193u8, 164u8, 21u8, 140u8, 218u8, 253u8, 237u8, 240u8, 126u8, - 200u8, 213u8, 184u8, 50u8, 187u8, 182u8, 30u8, 52u8, 142u8, 72u8, - 210u8, 101u8, + 239u8, 43u8, 70u8, 73u8, 77u8, 28u8, 75u8, 62u8, 29u8, 67u8, 110u8, + 120u8, 234u8, 236u8, 126u8, 99u8, 46u8, 183u8, 169u8, 16u8, 143u8, + 233u8, 137u8, 247u8, 138u8, 96u8, 32u8, 223u8, 149u8, 52u8, 214u8, + 195u8, ], ) } - #[doc = "Cancel a pre-existing, on-going multisig transaction. Any deposit reserved previously"] - #[doc = "for this operation will be unreserved on success."] + #[doc = "Refund the Submission Deposit for a closed referendum back to the depositor."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "- `origin`: must be `Signed` or `Root`."] + #[doc = "- `index`: The index of a closed referendum whose Submission Deposit has not yet been"] + #[doc = " refunded."] #[doc = ""] - #[doc = "- `threshold`: The total number of approvals for this dispatch before it is executed."] - #[doc = "- `other_signatories`: The accounts (other than the sender) who can approve this"] - #[doc = "dispatch. May not be empty."] - #[doc = "- `timepoint`: The timepoint (block number and transaction index) of the first approval"] - #[doc = "transaction for this dispatch."] - #[doc = "- `call_hash`: The hash of the call to be executed."] + #[doc = "Emits `SubmissionDepositRefunded`."] + pub fn refund_submission_deposit( + &self, + index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Referenda", + "refund_submission_deposit", + types::RefundSubmissionDeposit { index }, + [ + 101u8, 147u8, 237u8, 27u8, 220u8, 116u8, 73u8, 131u8, 191u8, 92u8, + 134u8, 31u8, 175u8, 172u8, 129u8, 225u8, 91u8, 33u8, 23u8, 132u8, 89u8, + 19u8, 81u8, 238u8, 133u8, 243u8, 56u8, 70u8, 143u8, 43u8, 176u8, 83u8, + ], + ) + } + #[doc = "Set or clear metadata of a referendum."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(S)`."] - #[doc = "- Up to one balance-reserve or unreserve operation."] - #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] - #[doc = " signatories. `S` is capped by `MaxSignatories`, with weight being proportional."] - #[doc = "- One encode & hash, both of complexity `O(S)`."] - #[doc = "- One event."] - #[doc = "- I/O: 1 read `O(S)`, one remove."] - #[doc = "- Storage: removes one item."] - pub fn cancel_as_multi( + #[doc = "Parameters:"] + #[doc = "- `origin`: Must be `Signed` by a creator of a referendum or by anyone to clear a"] + #[doc = " metadata of a finished referendum."] + #[doc = "- `index`: The index of a referendum to set or clear metadata for."] + #[doc = "- `maybe_hash`: The hash of an on-chain stored preimage. `None` to clear a metadata."] + pub fn set_metadata( &self, - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - call_hash: [::core::primitive::u8; 32usize], - ) -> ::subxt::tx::Payload { + index: ::core::primitive::u32, + maybe_hash: ::core::option::Option<::subxt::utils::H256>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Multisig", - "cancel_as_multi", - types::CancelAsMulti { - threshold, - other_signatories, - timepoint, - call_hash, - }, + "Referenda", + "set_metadata", + types::SetMetadata { index, maybe_hash }, [ - 30u8, 25u8, 186u8, 142u8, 168u8, 81u8, 235u8, 164u8, 82u8, 209u8, 66u8, - 129u8, 209u8, 78u8, 172u8, 9u8, 163u8, 222u8, 125u8, 57u8, 2u8, 43u8, - 169u8, 174u8, 159u8, 167u8, 25u8, 226u8, 254u8, 110u8, 80u8, 216u8, + 235u8, 215u8, 66u8, 214u8, 157u8, 177u8, 233u8, 214u8, 103u8, 92u8, + 216u8, 228u8, 7u8, 123u8, 167u8, 225u8, 128u8, 16u8, 161u8, 102u8, + 217u8, 36u8, 80u8, 207u8, 137u8, 24u8, 219u8, 239u8, 42u8, 234u8, + 144u8, 133u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_multisig::pallet::Event; + pub type Event = runtime_types::pallet_referenda::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -20339,15 +18308,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new multisig operation has begun."] - pub struct NewMultisig { - pub approving: ::subxt::utils::AccountId32, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], + #[doc = "A referendum has been submitted."] + pub struct Submitted { + pub index: ::core::primitive::u32, + pub track: ::core::primitive::u16, + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, } - impl ::subxt::events::StaticEvent for NewMultisig { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "NewMultisig"; + impl ::subxt::events::StaticEvent for Submitted { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "Submitted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -20359,16 +18330,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A multisig operation has been approved by someone."] - pub struct MultisigApproval { - pub approving: ::subxt::utils::AccountId32, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], + #[doc = "The decision deposit has been placed."] + pub struct DecisionDepositPlaced { + pub index: ::core::primitive::u32, + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for MultisigApproval { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "MultisigApproval"; + impl ::subxt::events::StaticEvent for DecisionDepositPlaced { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "DecisionDepositPlaced"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -20380,17 +18350,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A multisig operation has been executed."] - pub struct MultisigExecuted { - pub approving: ::subxt::utils::AccountId32, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + #[doc = "The decision deposit has been refunded."] + pub struct DecisionDepositRefunded { + pub index: ::core::primitive::u32, + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for MultisigExecuted { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "MultisigExecuted"; + impl ::subxt::events::StaticEvent for DecisionDepositRefunded { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "DecisionDepositRefunded"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -20402,526 +18370,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A multisig operation has been cancelled."] - pub struct MultisigCancelled { - pub cancelling: ::subxt::utils::AccountId32, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], + #[doc = "A deposit has been slashaed."] + pub struct DepositSlashed { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for MultisigCancelled { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "MultisigCancelled"; + impl ::subxt::events::StaticEvent for DepositSlashed { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "DepositSlashed"; } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The set of open multisig operations."] - pub fn multisigs( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - _1: impl ::std::borrow::Borrow<[::core::primitive::u8; 32usize]>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_multisig::Multisig< - ::core::primitive::u32, - ::core::primitive::u128, - ::subxt::utils::AccountId32, - >, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Multisig", - "Multisigs", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 69u8, 153u8, 186u8, 204u8, 117u8, 95u8, 119u8, 182u8, 220u8, 87u8, 8u8, - 15u8, 123u8, 83u8, 5u8, 188u8, 115u8, 121u8, 163u8, 96u8, 218u8, 3u8, - 106u8, 44u8, 44u8, 187u8, 46u8, 238u8, 80u8, 203u8, 175u8, 155u8, - ], - ) - } - #[doc = " The set of open multisig operations."] - pub fn multisigs_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_multisig::Multisig< - ::core::primitive::u32, - ::core::primitive::u128, - ::subxt::utils::AccountId32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Multisig", - "Multisigs", - Vec::new(), - [ - 69u8, 153u8, 186u8, 204u8, 117u8, 95u8, 119u8, 182u8, 220u8, 87u8, 8u8, - 15u8, 123u8, 83u8, 5u8, 188u8, 115u8, 121u8, 163u8, 96u8, 218u8, 3u8, - 106u8, 44u8, 44u8, 187u8, 46u8, 238u8, 80u8, 203u8, 175u8, 155u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The base amount of currency needed to reserve for creating a multisig execution or to"] - #[doc = " store a dispatch call for later."] - #[doc = ""] - #[doc = " This is held for an additional storage item whose value size is"] - #[doc = " `4 + sizeof((BlockNumber, Balance, AccountId))` bytes and whose key size is"] - #[doc = " `32 + sizeof(AccountId)` bytes."] - pub fn deposit_base(&self) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Multisig", - "DepositBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount of currency needed per unit threshold when creating a multisig execution."] - #[doc = ""] - #[doc = " This is held for adding 32 bytes more into a pre-existing storage value."] - pub fn deposit_factor( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Multisig", - "DepositFactor", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum amount of signatories allowed in the multisig."] - pub fn max_signatories( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Multisig", - "MaxSignatories", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod bounties { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_bounties::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeBounty { - #[codec(compact)] - pub value: ::core::primitive::u128, - pub description: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApproveBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeCurator { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub fee: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnassignCurator { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AcceptCurator { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AwardBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExtendBountyExpiry { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - pub remark: ::std::vec::Vec<::core::primitive::u8>, - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Propose a new bounty."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "Payment: `TipReportDepositBase` will be reserved from the origin account, as well as"] - #[doc = "`DataDepositPerByte` for each byte in `reason`. It will be unreserved upon approval,"] - #[doc = "or slashed when rejected."] - #[doc = ""] - #[doc = "- `curator`: The curator account whom will manage this bounty."] - #[doc = "- `fee`: The curator fee."] - #[doc = "- `value`: The total payment amount of this bounty, curator fee included."] - #[doc = "- `description`: The description of this bounty."] - pub fn propose_bounty( - &self, - value: ::core::primitive::u128, - description: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "propose_bounty", - types::ProposeBounty { value, description }, - [ - 99u8, 160u8, 94u8, 74u8, 105u8, 161u8, 123u8, 239u8, 241u8, 117u8, - 97u8, 99u8, 84u8, 101u8, 87u8, 3u8, 88u8, 175u8, 75u8, 59u8, 114u8, - 87u8, 18u8, 113u8, 126u8, 26u8, 42u8, 104u8, 201u8, 128u8, 102u8, - 219u8, - ], - ) - } - #[doc = "Approve a bounty proposal. At a later time, the bounty will be funded and become active"] - #[doc = "and the original deposit will be returned."] - #[doc = ""] - #[doc = "May only be called from `T::SpendOrigin`."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(1)."] - pub fn approve_bounty( - &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "approve_bounty", - types::ApproveBounty { bounty_id }, - [ - 82u8, 228u8, 232u8, 103u8, 198u8, 173u8, 190u8, 148u8, 159u8, 86u8, - 48u8, 4u8, 32u8, 169u8, 1u8, 129u8, 96u8, 145u8, 235u8, 68u8, 48u8, - 34u8, 5u8, 1u8, 76u8, 26u8, 100u8, 228u8, 92u8, 198u8, 183u8, 173u8, - ], - ) - } - #[doc = "Assign a curator to a funded bounty."] - #[doc = ""] - #[doc = "May only be called from `T::SpendOrigin`."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(1)."] - pub fn propose_curator( - &self, - bounty_id: ::core::primitive::u32, - curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "propose_curator", - types::ProposeCurator { - bounty_id, - curator, - fee, - }, - [ - 123u8, 148u8, 21u8, 204u8, 216u8, 6u8, 47u8, 83u8, 182u8, 30u8, 171u8, - 48u8, 193u8, 200u8, 197u8, 147u8, 111u8, 88u8, 14u8, 242u8, 66u8, - 175u8, 241u8, 208u8, 95u8, 151u8, 41u8, 46u8, 213u8, 188u8, 65u8, - 196u8, - ], - ) - } - #[doc = "Unassign curator from a bounty."] - #[doc = ""] - #[doc = "This function can only be called by the `RejectOrigin` a signed origin."] - #[doc = ""] - #[doc = "If this function is called by the `RejectOrigin`, we assume that the curator is"] - #[doc = "malicious or inactive. As a result, we will slash the curator when possible."] - #[doc = ""] - #[doc = "If the origin is the curator, we take this as a sign they are unable to do their job and"] - #[doc = "they willingly give up. We could slash them, but for now we allow them to recover their"] - #[doc = "deposit and exit without issue. (We may want to change this if it is abused.)"] - #[doc = ""] - #[doc = "Finally, the origin can be anyone if and only if the curator is \"inactive\". This allows"] - #[doc = "anyone in the community to call out that a curator is not doing their due diligence, and"] - #[doc = "we should pick a new curator. In this case the curator should also be slashed."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(1)."] - pub fn unassign_curator( - &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "unassign_curator", - types::UnassignCurator { bounty_id }, - [ - 218u8, 241u8, 247u8, 89u8, 95u8, 120u8, 93u8, 18u8, 85u8, 114u8, 158u8, - 254u8, 68u8, 77u8, 230u8, 186u8, 230u8, 201u8, 63u8, 223u8, 28u8, - 173u8, 244u8, 82u8, 113u8, 177u8, 99u8, 27u8, 207u8, 247u8, 207u8, - 213u8, - ], - ) - } - #[doc = "Accept the curator role for a bounty."] - #[doc = "A deposit will be reserved from curator and refund upon successful payout."] - #[doc = ""] - #[doc = "May only be called from the curator."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(1)."] - pub fn accept_curator( - &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "accept_curator", - types::AcceptCurator { bounty_id }, - [ - 106u8, 96u8, 22u8, 67u8, 52u8, 109u8, 180u8, 225u8, 122u8, 253u8, - 209u8, 214u8, 132u8, 131u8, 247u8, 131u8, 162u8, 51u8, 144u8, 30u8, - 12u8, 126u8, 50u8, 152u8, 229u8, 119u8, 54u8, 116u8, 112u8, 235u8, - 34u8, 166u8, - ], - ) - } - #[doc = "Award bounty to a beneficiary account. The beneficiary will be able to claim the funds"] - #[doc = "after a delay."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be the curator of this bounty."] - #[doc = ""] - #[doc = "- `bounty_id`: Bounty ID to award."] - #[doc = "- `beneficiary`: The beneficiary account whom will receive the payout."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(1)."] - pub fn award_bounty( - &self, - bounty_id: ::core::primitive::u32, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "award_bounty", - types::AwardBounty { - bounty_id, - beneficiary, - }, - [ - 203u8, 164u8, 214u8, 242u8, 1u8, 11u8, 217u8, 32u8, 189u8, 136u8, 29u8, - 230u8, 88u8, 17u8, 134u8, 189u8, 15u8, 204u8, 223u8, 20u8, 168u8, - 182u8, 129u8, 48u8, 83u8, 25u8, 125u8, 25u8, 209u8, 155u8, 170u8, 68u8, - ], - ) - } - #[doc = "Claim the payout from an awarded bounty after payout delay."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be the beneficiary of this bounty."] - #[doc = ""] - #[doc = "- `bounty_id`: Bounty ID to claim."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(1)."] - pub fn claim_bounty( - &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "claim_bounty", - types::ClaimBounty { bounty_id }, - [ - 102u8, 95u8, 8u8, 89u8, 4u8, 126u8, 189u8, 28u8, 241u8, 16u8, 125u8, - 218u8, 42u8, 92u8, 177u8, 91u8, 8u8, 235u8, 33u8, 48u8, 64u8, 115u8, - 177u8, 95u8, 242u8, 97u8, 181u8, 50u8, 68u8, 37u8, 59u8, 85u8, - ], - ) - } - #[doc = "Cancel a proposed or active bounty. All the funds will be sent to treasury and"] - #[doc = "the curator deposit will be unreserved if possible."] - #[doc = ""] - #[doc = "Only `T::RejectOrigin` is able to cancel a bounty."] - #[doc = ""] - #[doc = "- `bounty_id`: Bounty ID to cancel."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(1)."] - pub fn close_bounty( - &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "close_bounty", - types::CloseBounty { bounty_id }, - [ - 64u8, 113u8, 151u8, 228u8, 90u8, 55u8, 251u8, 63u8, 27u8, 211u8, 119u8, - 229u8, 137u8, 137u8, 183u8, 240u8, 241u8, 146u8, 69u8, 169u8, 124u8, - 220u8, 236u8, 111u8, 98u8, 188u8, 100u8, 52u8, 127u8, 245u8, 244u8, - 92u8, - ], - ) - } - #[doc = "Extend the expiry time of an active bounty."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be the curator of this bounty."] - #[doc = ""] - #[doc = "- `bounty_id`: Bounty ID to extend."] - #[doc = "- `remark`: additional information."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(1)."] - pub fn extend_bounty_expiry( - &self, - bounty_id: ::core::primitive::u32, - remark: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "extend_bounty_expiry", - types::ExtendBountyExpiry { bounty_id, remark }, - [ - 97u8, 69u8, 157u8, 39u8, 59u8, 72u8, 79u8, 88u8, 104u8, 119u8, 91u8, - 26u8, 73u8, 216u8, 174u8, 95u8, 254u8, 214u8, 63u8, 138u8, 100u8, - 112u8, 185u8, 81u8, 159u8, 247u8, 221u8, 60u8, 87u8, 40u8, 80u8, 202u8, - ], - ) - } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_bounties::pallet::Event; - pub mod events { - use super::runtime_types; #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -20931,15 +18389,22 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "New bounty proposal."] - pub struct BountyProposed { + #[doc = "A referendum has moved into the deciding phase."] + pub struct DecisionStarted { pub index: ::core::primitive::u32, + pub track: ::core::primitive::u16, + pub proposal: runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + pub tally: + runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, } - impl ::subxt::events::StaticEvent for BountyProposed { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyProposed"; + impl ::subxt::events::StaticEvent for DecisionStarted { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "DecisionStarted"; } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -20949,14 +18414,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty proposal was rejected; funds were slashed."] - pub struct BountyRejected { + pub struct ConfirmStarted { pub index: ::core::primitive::u32, - pub bond: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for BountyRejected { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyRejected"; + impl ::subxt::events::StaticEvent for ConfirmStarted { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "ConfirmStarted"; } #[derive( :: subxt :: ext :: codec :: CompactAs, @@ -20969,13 +18432,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty proposal is funded and became active."] - pub struct BountyBecameActive { + pub struct ConfirmAborted { pub index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for BountyBecameActive { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyBecameActive"; + impl ::subxt::events::StaticEvent for ConfirmAborted { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "ConfirmAborted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -20987,16 +18449,18 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty is awarded to a beneficiary."] - pub struct BountyAwarded { + #[doc = "A referendum has ended its confirmation phase and is ready for approval."] + pub struct Confirmed { pub index: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::AccountId32, + pub tally: + runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, } - impl ::subxt::events::StaticEvent for BountyAwarded { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyAwarded"; + impl ::subxt::events::StaticEvent for Confirmed { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "Confirmed"; } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -21006,18 +18470,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty is claimed by beneficiary."] - pub struct BountyClaimed { + #[doc = "A referendum has been approved and its proposal has been scheduled."] + pub struct Approved { pub index: ::core::primitive::u32, - pub payout: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::AccountId32, } - impl ::subxt::events::StaticEvent for BountyClaimed { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyClaimed"; + impl ::subxt::events::StaticEvent for Approved { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "Approved"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -21027,16 +18488,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty is cancelled."] - pub struct BountyCanceled { + #[doc = "A proposal has been rejected by referendum."] + pub struct Rejected { pub index: ::core::primitive::u32, + pub tally: + runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, } - impl ::subxt::events::StaticEvent for BountyCanceled { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyCanceled"; + impl ::subxt::events::StaticEvent for Rejected { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "Rejected"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -21046,21 +18508,121 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty expiry is extended."] - pub struct BountyExtended { + #[doc = "A referendum has been timed out without being decided."] + pub struct TimedOut { pub index: ::core::primitive::u32, + pub tally: + runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, } - impl ::subxt::events::StaticEvent for BountyExtended { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyExtended"; + impl ::subxt::events::StaticEvent for TimedOut { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "TimedOut"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A referendum has been cancelled."] + pub struct Cancelled { + pub index: ::core::primitive::u32, + pub tally: + runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, + } + impl ::subxt::events::StaticEvent for Cancelled { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "Cancelled"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A referendum has been killed."] + pub struct Killed { + pub index: ::core::primitive::u32, + pub tally: + runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, + } + impl ::subxt::events::StaticEvent for Killed { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "Killed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The submission deposit has been refunded."] + pub struct SubmissionDepositRefunded { + pub index: ::core::primitive::u32, + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for SubmissionDepositRefunded { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "SubmissionDepositRefunded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Metadata for a referendum has been set."] + pub struct MetadataSet { + pub index: ::core::primitive::u32, + pub hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for MetadataSet { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "MetadataSet"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Metadata for a referendum has been cleared."] + pub struct MetadataCleared { + pub index: ::core::primitive::u32, + pub hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for MetadataCleared { + const PALLET: &'static str = "Referenda"; + const EVENT: &'static str = "MetadataCleared"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " Number of bounty proposals that have been made."] - pub fn bounty_count( + #[doc = " The next free referendum index, aka the number of referenda started so far."] + pub fn referendum_count( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, @@ -21070,140 +18632,248 @@ pub mod api { (), > { ::subxt::storage::address::Address::new_static( - "Bounties", - "BountyCount", + "Referenda", + "ReferendumCount", vec![], [ - 5u8, 188u8, 134u8, 220u8, 64u8, 49u8, 188u8, 98u8, 185u8, 186u8, 230u8, - 65u8, 247u8, 199u8, 28u8, 178u8, 202u8, 193u8, 41u8, 83u8, 115u8, - 253u8, 182u8, 123u8, 92u8, 138u8, 12u8, 31u8, 31u8, 213u8, 23u8, 118u8, + 153u8, 210u8, 106u8, 244u8, 156u8, 70u8, 124u8, 251u8, 123u8, 75u8, + 7u8, 189u8, 199u8, 145u8, 95u8, 119u8, 137u8, 11u8, 240u8, 160u8, + 151u8, 248u8, 229u8, 231u8, 89u8, 222u8, 18u8, 237u8, 144u8, 78u8, + 99u8, 58u8, ], ) } - #[doc = " Bounties that have been made."] - pub fn bounties( + #[doc = " Information concerning any given referendum."] + pub fn referendum_info_for( &self, _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bounties::Bounty< - ::subxt::utils::AccountId32, - ::core::primitive::u128, + runtime_types::pallet_referenda::types::ReferendumInfo< + ::core::primitive::u16, + runtime_types::polkadot_runtime::OriginCaller, ::core::primitive::u32, + runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + ::core::primitive::u128, + runtime_types::pallet_conviction_voting::types::Tally< + ::core::primitive::u128, + >, + ::subxt::utils::AccountId32, + (::core::primitive::u32, ::core::primitive::u32), >, ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Bounties", - "Bounties", + "Referenda", + "ReferendumInfoFor", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 111u8, 149u8, 33u8, 54u8, 172u8, 143u8, 41u8, 231u8, 184u8, 255u8, - 238u8, 206u8, 87u8, 142u8, 84u8, 10u8, 236u8, 141u8, 190u8, 193u8, - 72u8, 170u8, 19u8, 110u8, 135u8, 136u8, 220u8, 11u8, 99u8, 126u8, - 225u8, 208u8, + 180u8, 213u8, 110u8, 2u8, 75u8, 24u8, 34u8, 143u8, 56u8, 197u8, 106u8, + 105u8, 182u8, 118u8, 114u8, 242u8, 48u8, 85u8, 147u8, 22u8, 29u8, + 211u8, 246u8, 127u8, 217u8, 251u8, 208u8, 20u8, 9u8, 84u8, 53u8, 249u8, ], ) } - #[doc = " Bounties that have been made."] - pub fn bounties_root( + #[doc = " Information concerning any given referendum."] + pub fn referendum_info_for_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bounties::Bounty< - ::subxt::utils::AccountId32, - ::core::primitive::u128, + runtime_types::pallet_referenda::types::ReferendumInfo< + ::core::primitive::u16, + runtime_types::polkadot_runtime::OriginCaller, ::core::primitive::u32, + runtime_types::frame_support::traits::preimages::Bounded< + runtime_types::polkadot_runtime::RuntimeCall, + >, + ::core::primitive::u128, + runtime_types::pallet_conviction_voting::types::Tally< + ::core::primitive::u128, + >, + ::subxt::utils::AccountId32, + (::core::primitive::u32, ::core::primitive::u32), >, (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Bounties", - "Bounties", + "Referenda", + "ReferendumInfoFor", Vec::new(), [ - 111u8, 149u8, 33u8, 54u8, 172u8, 143u8, 41u8, 231u8, 184u8, 255u8, - 238u8, 206u8, 87u8, 142u8, 84u8, 10u8, 236u8, 141u8, 190u8, 193u8, - 72u8, 170u8, 19u8, 110u8, 135u8, 136u8, 220u8, 11u8, 99u8, 126u8, - 225u8, 208u8, + 180u8, 213u8, 110u8, 2u8, 75u8, 24u8, 34u8, 143u8, 56u8, 197u8, 106u8, + 105u8, 182u8, 118u8, 114u8, 242u8, 48u8, 85u8, 147u8, 22u8, 29u8, + 211u8, 246u8, 127u8, 217u8, 251u8, 208u8, 20u8, 9u8, 84u8, 53u8, 249u8, ], ) } - #[doc = " The description of each bounty."] - pub fn bounty_descriptions( + #[doc = " The sorted list of referenda ready to be decided but not yet being decided, ordered by"] + #[doc = " conviction-weighted approvals."] + #[doc = ""] + #[doc = " This should be empty if `DecidingCount` is less than `TrackInfo::max_deciding`."] + pub fn track_queue( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _0: impl ::std::borrow::Borrow<::core::primitive::u16>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u32, + ::core::primitive::u128, + )>, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Bounties", - "BountyDescriptions", + "Referenda", + "TrackQueue", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 252u8, 0u8, 9u8, 225u8, 13u8, 135u8, 7u8, 121u8, 154u8, 155u8, 116u8, - 83u8, 160u8, 37u8, 72u8, 11u8, 72u8, 0u8, 248u8, 73u8, 158u8, 84u8, - 125u8, 221u8, 176u8, 231u8, 100u8, 239u8, 111u8, 22u8, 29u8, 13u8, + 254u8, 82u8, 183u8, 246u8, 168u8, 87u8, 175u8, 224u8, 192u8, 117u8, + 129u8, 244u8, 18u8, 18u8, 249u8, 30u8, 51u8, 133u8, 244u8, 117u8, + 194u8, 174u8, 99u8, 51u8, 155u8, 76u8, 206u8, 202u8, 109u8, 39u8, + 253u8, 240u8, ], ) } - #[doc = " The description of each bounty."] - pub fn bounty_descriptions_root( + #[doc = " The sorted list of referenda ready to be decided but not yet being decided, ordered by"] + #[doc = " conviction-weighted approvals."] + #[doc = ""] + #[doc = " This should be empty if `DecidingCount` is less than `TrackInfo::max_deciding`."] + pub fn track_queue_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u32, + ::core::primitive::u128, + )>, (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Referenda", + "TrackQueue", + Vec::new(), + [ + 254u8, 82u8, 183u8, 246u8, 168u8, 87u8, 175u8, 224u8, 192u8, 117u8, + 129u8, 244u8, 18u8, 18u8, 249u8, 30u8, 51u8, 133u8, 244u8, 117u8, + 194u8, 174u8, 99u8, 51u8, 155u8, 76u8, 206u8, 202u8, 109u8, 39u8, + 253u8, 240u8, + ], + ) + } + #[doc = " The number of referenda being decided currently."] + pub fn deciding_count( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u16>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Referenda", + "DecidingCount", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 101u8, 153u8, 200u8, 225u8, 229u8, 227u8, 232u8, 26u8, 98u8, 60u8, + 60u8, 94u8, 204u8, 195u8, 193u8, 69u8, 50u8, 72u8, 31u8, 250u8, 224u8, + 179u8, 139u8, 207u8, 19u8, 156u8, 67u8, 234u8, 177u8, 223u8, 63u8, + 150u8, + ], + ) + } + #[doc = " The number of referenda being decided currently."] + pub fn deciding_count_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, (), ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Bounties", - "BountyDescriptions", + "Referenda", + "DecidingCount", Vec::new(), [ - 252u8, 0u8, 9u8, 225u8, 13u8, 135u8, 7u8, 121u8, 154u8, 155u8, 116u8, - 83u8, 160u8, 37u8, 72u8, 11u8, 72u8, 0u8, 248u8, 73u8, 158u8, 84u8, - 125u8, 221u8, 176u8, 231u8, 100u8, 239u8, 111u8, 22u8, 29u8, 13u8, + 101u8, 153u8, 200u8, 225u8, 229u8, 227u8, 232u8, 26u8, 98u8, 60u8, + 60u8, 94u8, 204u8, 195u8, 193u8, 69u8, 50u8, 72u8, 31u8, 250u8, 224u8, + 179u8, 139u8, 207u8, 19u8, 156u8, 67u8, 234u8, 177u8, 223u8, 63u8, + 150u8, ], ) } - #[doc = " Bounty indices that have been approved but not yet funded."] - pub fn bounty_approvals( + #[doc = " The metadata is a general information concerning the referendum."] + #[doc = " The `PreimageHash` refers to the preimage of the `Preimages` provider which can be a JSON"] + #[doc = " dump or IPFS hash of a JSON file."] + #[doc = ""] + #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] + #[doc = " large preimages."] + pub fn metadata_of( &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u32, - >, + ::subxt::utils::H256, ::subxt::storage::address::Yes, + (), ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Referenda", + "MetadataOf", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 104u8, 255u8, 134u8, 120u8, 111u8, 124u8, 108u8, 232u8, 61u8, 47u8, + 251u8, 228u8, 50u8, 49u8, 125u8, 229u8, 254u8, 88u8, 215u8, 90u8, + 116u8, 145u8, 111u8, 72u8, 132u8, 91u8, 106u8, 207u8, 13u8, 104u8, + 164u8, 100u8, + ], + ) + } + #[doc = " The metadata is a general information concerning the referendum."] + #[doc = " The `PreimageHash` refers to the preimage of the `Preimages` provider which can be a JSON"] + #[doc = " dump or IPFS hash of a JSON file."] + #[doc = ""] + #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] + #[doc = " large preimages."] + pub fn metadata_of_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + (), (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Bounties", - "BountyApprovals", - vec![], + "Referenda", + "MetadataOf", + Vec::new(), [ - 64u8, 93u8, 54u8, 94u8, 122u8, 9u8, 246u8, 86u8, 234u8, 30u8, 125u8, - 132u8, 49u8, 128u8, 1u8, 219u8, 241u8, 13u8, 217u8, 186u8, 48u8, 21u8, - 5u8, 227u8, 71u8, 157u8, 128u8, 226u8, 214u8, 49u8, 249u8, 183u8, + 104u8, 255u8, 134u8, 120u8, 111u8, 124u8, 108u8, 232u8, 61u8, 47u8, + 251u8, 228u8, 50u8, 49u8, 125u8, 229u8, 254u8, 88u8, 215u8, 90u8, + 116u8, 145u8, 111u8, 72u8, 132u8, 91u8, 106u8, 207u8, 13u8, 104u8, + 164u8, 100u8, ], ) } @@ -21213,13 +18883,13 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " The amount held on deposit for placing a bounty proposal."] - pub fn bounty_deposit_base( + #[doc = " The minimum amount to be used as a deposit for a public referendum proposal."] + pub fn submission_deposit( &self, ) -> ::subxt::constants::Address<::core::primitive::u128> { ::subxt::constants::Address::new_static( - "Bounties", - "BountyDepositBase", + "Referenda", + "SubmissionDeposit", [ 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, @@ -21227,13 +18897,11 @@ pub mod api { ], ) } - #[doc = " The delay period for which a bounty beneficiary need to wait before claim the payout."] - pub fn bounty_deposit_payout_delay( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { + #[doc = " Maximum size of the referendum queue for a single track."] + pub fn max_queued(&self) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Bounties", - "BountyDepositPayoutDelay", + "Referenda", + "MaxQueued", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -21242,13 +18910,14 @@ pub mod api { ], ) } - #[doc = " Bounty duration in blocks."] - pub fn bounty_update_period( + #[doc = " The number of blocks after submission that a referendum must begin being decided by."] + #[doc = " Once this passes, then anyone may cancel the referendum."] + pub fn undeciding_timeout( &self, ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Bounties", - "BountyUpdatePeriod", + "Referenda", + "UndecidingTimeout", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -21257,109 +18926,53 @@ pub mod api { ], ) } - #[doc = " The curator deposit is calculated as a percentage of the curator fee."] - #[doc = ""] - #[doc = " This deposit has optional upper and lower bounds with `CuratorDepositMax` and"] - #[doc = " `CuratorDepositMin`."] - pub fn curator_deposit_multiplier( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "Bounties", - "CuratorDepositMultiplier", - [ - 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, - 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, - 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, - ], - ) - } - #[doc = " Maximum amount of funds that should be placed in a deposit for making a proposal."] - pub fn curator_deposit_max( - &self, - ) -> ::subxt::constants::Address<::core::option::Option<::core::primitive::u128>> - { - ::subxt::constants::Address::new_static( - "Bounties", - "CuratorDepositMax", - [ - 84u8, 154u8, 218u8, 83u8, 84u8, 189u8, 32u8, 20u8, 120u8, 194u8, 88u8, - 205u8, 109u8, 216u8, 114u8, 193u8, 120u8, 198u8, 154u8, 237u8, 134u8, - 204u8, 102u8, 247u8, 52u8, 103u8, 231u8, 43u8, 243u8, 122u8, 60u8, - 216u8, - ], - ) - } - #[doc = " Minimum amount of funds that should be placed in a deposit for making a proposal."] - pub fn curator_deposit_min( - &self, - ) -> ::subxt::constants::Address<::core::option::Option<::core::primitive::u128>> - { - ::subxt::constants::Address::new_static( - "Bounties", - "CuratorDepositMin", - [ - 84u8, 154u8, 218u8, 83u8, 84u8, 189u8, 32u8, 20u8, 120u8, 194u8, 88u8, - 205u8, 109u8, 216u8, 114u8, 193u8, 120u8, 198u8, 154u8, 237u8, 134u8, - 204u8, 102u8, 247u8, 52u8, 103u8, 231u8, 43u8, 243u8, 122u8, 60u8, - 216u8, - ], - ) - } - #[doc = " Minimum value for a bounty."] - pub fn bounty_value_minimum( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Bounties", - "BountyValueMinimum", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount held on deposit per byte within the tip report reason or bounty description."] - pub fn data_deposit_per_byte( + #[doc = " Quantization level for the referendum wakeup scheduler. A higher number will result in"] + #[doc = " fewer storage reads/writes needed for smaller voters, but also result in delays to the"] + #[doc = " automatic referendum status changes. Explicit servicing instructions are unaffected."] + pub fn alarm_interval( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { + ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "Bounties", - "DataDepositPerByte", + "Referenda", + "AlarmInterval", [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = " Maximum acceptable reason length."] - #[doc = ""] - #[doc = " Benchmarks depend on this value, be sure to update weights file when changing this value"] - pub fn maximum_reason_length( + #[doc = " Information concerning the different referendum tracks."] + pub fn tracks( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { + ) -> ::subxt::constants::Address< + ::std::vec::Vec<( + ::core::primitive::u16, + runtime_types::pallet_referenda::types::TrackInfo< + ::core::primitive::u128, + ::core::primitive::u32, + >, + )>, + > { ::subxt::constants::Address::new_static( - "Bounties", - "MaximumReasonLength", + "Referenda", + "Tracks", [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 71u8, 253u8, 246u8, 54u8, 168u8, 190u8, 182u8, 15u8, 207u8, 26u8, 50u8, + 138u8, 212u8, 124u8, 13u8, 203u8, 27u8, 35u8, 224u8, 1u8, 176u8, 192u8, + 197u8, 220u8, 147u8, 94u8, 196u8, 150u8, 125u8, 23u8, 48u8, 255u8, ], ) } } } } - pub mod child_bounties { + pub mod whitelist { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_child_bounties::pallet::Error; + pub type Error = runtime_types::pallet_whitelist::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -21377,12 +18990,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub value: ::core::primitive::u128, - pub description: ::std::vec::Vec<::core::primitive::u8>, + pub struct WhitelistCall { + pub call_hash: ::subxt::utils::H256, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -21394,14 +19003,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeCurator { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub fee: ::core::primitive::u128, + pub struct RemoveWhitelistedCall { + pub call_hash: ::subxt::utils::H256, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -21413,60 +19016,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AcceptCurator { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnassignCurator { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AwardChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, + pub struct DispatchWhitelistedCall { + pub call_hash: ::subxt::utils::H256, + pub call_encoded_len: ::core::primitive::u32, + pub call_weight_witness: runtime_types::sp_weights::weight_v2::Weight, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -21478,306 +19031,87 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, + pub struct DispatchWhitelistedCallWithPreimage { + pub call: ::std::boxed::Box, } } pub struct TransactionApi; impl TransactionApi { - #[doc = "Add a new child-bounty."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be the curator of parent"] - #[doc = "bounty and the parent bounty must be in \"active\" state."] - #[doc = ""] - #[doc = "Child-bounty gets added successfully & fund gets transferred from"] - #[doc = "parent bounty to child-bounty account, if parent bounty has enough"] - #[doc = "funds, else the call fails."] - #[doc = ""] - #[doc = "Upper bound to maximum number of active child bounties that can be"] - #[doc = "added are managed via runtime trait config"] - #[doc = "[`Config::MaxActiveChildBountyCount`]."] - #[doc = ""] - #[doc = "If the call is success, the status of child-bounty is updated to"] - #[doc = "\"Added\"."] - #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty for which child-bounty is being added."] - #[doc = "- `value`: Value for executing the proposal."] - #[doc = "- `description`: Text description for the child-bounty."] - pub fn add_child_bounty( - &self, - parent_bounty_id: ::core::primitive::u32, - value: ::core::primitive::u128, - description: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ChildBounties", - "add_child_bounty", - types::AddChildBounty { - parent_bounty_id, - value, - description, - }, - [ - 210u8, 156u8, 242u8, 121u8, 28u8, 214u8, 212u8, 203u8, 46u8, 45u8, - 110u8, 25u8, 33u8, 138u8, 136u8, 71u8, 23u8, 102u8, 203u8, 122u8, 77u8, - 162u8, 112u8, 133u8, 43u8, 73u8, 201u8, 176u8, 102u8, 68u8, 188u8, 8u8, - ], - ) - } - #[doc = "Propose curator for funded child-bounty."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be curator of parent bounty."] - #[doc = ""] - #[doc = "Parent bounty must be in active state, for this child-bounty call to"] - #[doc = "work."] - #[doc = ""] - #[doc = "Child-bounty must be in \"Added\" state, for processing the call. And"] - #[doc = "state of child-bounty is moved to \"CuratorProposed\" on successful"] - #[doc = "call completion."] - #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty."] - #[doc = "- `child_bounty_id`: Index of child bounty."] - #[doc = "- `curator`: Address of child-bounty curator."] - #[doc = "- `fee`: payment fee to child-bounty curator for execution."] - pub fn propose_curator( - &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ChildBounties", - "propose_curator", - types::ProposeCurator { - parent_bounty_id, - child_bounty_id, - curator, - fee, - }, - [ - 37u8, 101u8, 96u8, 75u8, 254u8, 212u8, 42u8, 140u8, 72u8, 107u8, 157u8, - 110u8, 147u8, 236u8, 17u8, 138u8, 161u8, 153u8, 119u8, 177u8, 225u8, - 22u8, 83u8, 5u8, 123u8, 38u8, 30u8, 240u8, 134u8, 208u8, 183u8, 247u8, - ], - ) - } - #[doc = "Accept the curator role for the child-bounty."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be the curator of this"] - #[doc = "child-bounty."] - #[doc = ""] - #[doc = "A deposit will be reserved from the curator and refund upon"] - #[doc = "successful payout or cancellation."] - #[doc = ""] - #[doc = "Fee for curator is deducted from curator fee of parent bounty."] - #[doc = ""] - #[doc = "Parent bounty must be in active state, for this child-bounty call to"] - #[doc = "work."] - #[doc = ""] - #[doc = "Child-bounty must be in \"CuratorProposed\" state, for processing the"] - #[doc = "call. And state of child-bounty is moved to \"Active\" on successful"] - #[doc = "call completion."] - #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty."] - #[doc = "- `child_bounty_id`: Index of child bounty."] - pub fn accept_curator( - &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ChildBounties", - "accept_curator", - types::AcceptCurator { - parent_bounty_id, - child_bounty_id, - }, - [ - 112u8, 175u8, 238u8, 54u8, 132u8, 20u8, 206u8, 59u8, 220u8, 228u8, - 207u8, 222u8, 132u8, 240u8, 188u8, 0u8, 210u8, 225u8, 234u8, 142u8, - 232u8, 53u8, 64u8, 89u8, 220u8, 29u8, 28u8, 123u8, 125u8, 207u8, 10u8, - 52u8, - ], - ) - } - #[doc = "Unassign curator from a child-bounty."] - #[doc = ""] - #[doc = "The dispatch origin for this call can be either `RejectOrigin`, or"] - #[doc = "the curator of the parent bounty, or any signed origin."] - #[doc = ""] - #[doc = "For the origin other than T::RejectOrigin and the child-bounty"] - #[doc = "curator, parent bounty must be in active state, for this call to"] - #[doc = "work. We allow child-bounty curator and T::RejectOrigin to execute"] - #[doc = "this call irrespective of the parent bounty state."] - #[doc = ""] - #[doc = "If this function is called by the `RejectOrigin` or the"] - #[doc = "parent bounty curator, we assume that the child-bounty curator is"] - #[doc = "malicious or inactive. As a result, child-bounty curator deposit is"] - #[doc = "slashed."] - #[doc = ""] - #[doc = "If the origin is the child-bounty curator, we take this as a sign"] - #[doc = "that they are unable to do their job, and are willingly giving up."] - #[doc = "We could slash the deposit, but for now we allow them to unreserve"] - #[doc = "their deposit and exit without issue. (We may want to change this if"] - #[doc = "it is abused.)"] - #[doc = ""] - #[doc = "Finally, the origin can be anyone iff the child-bounty curator is"] - #[doc = "\"inactive\". Expiry update due of parent bounty is used to estimate"] - #[doc = "inactive state of child-bounty curator."] - #[doc = ""] - #[doc = "This allows anyone in the community to call out that a child-bounty"] - #[doc = "curator is not doing their due diligence, and we should pick a new"] - #[doc = "one. In this case the child-bounty curator deposit is slashed."] - #[doc = ""] - #[doc = "State of child-bounty is moved to Added state on successful call"] - #[doc = "completion."] - #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty."] - #[doc = "- `child_bounty_id`: Index of child bounty."] - pub fn unassign_curator( + pub fn whitelist_call( &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + call_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ChildBounties", - "unassign_curator", - types::UnassignCurator { - parent_bounty_id, - child_bounty_id, - }, + "Whitelist", + "whitelist_call", + types::WhitelistCall { call_hash }, [ - 228u8, 189u8, 46u8, 75u8, 121u8, 161u8, 150u8, 87u8, 207u8, 86u8, - 192u8, 50u8, 52u8, 61u8, 49u8, 88u8, 178u8, 182u8, 89u8, 72u8, 203u8, - 45u8, 41u8, 26u8, 149u8, 114u8, 154u8, 169u8, 118u8, 128u8, 13u8, - 211u8, + 21u8, 246u8, 244u8, 176u8, 163u8, 80u8, 45u8, 191u8, 3u8, 180u8, 150u8, + 66u8, 168u8, 3u8, 196u8, 129u8, 177u8, 104u8, 48u8, 5u8, 201u8, 208u8, + 226u8, 76u8, 148u8, 116u8, 206u8, 119u8, 145u8, 78u8, 86u8, 41u8, ], ) } - #[doc = "Award child-bounty to a beneficiary."] - #[doc = ""] - #[doc = "The beneficiary will be able to claim the funds after a delay."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be the parent curator or"] - #[doc = "curator of this child-bounty."] - #[doc = ""] - #[doc = "Parent bounty must be in active state, for this child-bounty call to"] - #[doc = "work."] - #[doc = ""] - #[doc = "Child-bounty must be in active state, for processing the call. And"] - #[doc = "state of child-bounty is moved to \"PendingPayout\" on successful call"] - #[doc = "completion."] - #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty."] - #[doc = "- `child_bounty_id`: Index of child bounty."] - #[doc = "- `beneficiary`: Beneficiary account."] - pub fn award_child_bounty( + pub fn remove_whitelisted_call( &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + call_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ChildBounties", - "award_child_bounty", - types::AwardChildBounty { - parent_bounty_id, - child_bounty_id, - beneficiary, - }, + "Whitelist", + "remove_whitelisted_call", + types::RemoveWhitelistedCall { call_hash }, [ - 231u8, 185u8, 73u8, 232u8, 92u8, 116u8, 204u8, 165u8, 216u8, 194u8, - 151u8, 21u8, 127u8, 239u8, 78u8, 45u8, 27u8, 252u8, 119u8, 23u8, 71u8, - 140u8, 137u8, 209u8, 189u8, 128u8, 126u8, 247u8, 13u8, 42u8, 68u8, - 134u8, + 142u8, 227u8, 198u8, 110u8, 90u8, 127u8, 218u8, 117u8, 181u8, 209u8, + 210u8, 86u8, 133u8, 95u8, 244u8, 64u8, 50u8, 240u8, 220u8, 50u8, 212u8, + 106u8, 4u8, 189u8, 2u8, 72u8, 96u8, 52u8, 187u8, 140u8, 144u8, 76u8, ], ) } - #[doc = "Claim the payout from an awarded child-bounty after payout delay."] - #[doc = ""] - #[doc = "The dispatch origin for this call may be any signed origin."] - #[doc = ""] - #[doc = "Call works independent of parent bounty state, No need for parent"] - #[doc = "bounty to be in active state."] - #[doc = ""] - #[doc = "The Beneficiary is paid out with agreed bounty value. Curator fee is"] - #[doc = "paid & curator deposit is unreserved."] - #[doc = ""] - #[doc = "Child-bounty must be in \"PendingPayout\" state, for processing the"] - #[doc = "call. And instance of child-bounty is removed from the state on"] - #[doc = "successful call completion."] - #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty."] - #[doc = "- `child_bounty_id`: Index of child bounty."] - pub fn claim_child_bounty( + pub fn dispatch_whitelisted_call( &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + call_hash: ::subxt::utils::H256, + call_encoded_len: ::core::primitive::u32, + call_weight_witness: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ChildBounties", - "claim_child_bounty", - types::ClaimChildBounty { - parent_bounty_id, - child_bounty_id, + "Whitelist", + "dispatch_whitelisted_call", + types::DispatchWhitelistedCall { + call_hash, + call_encoded_len, + call_weight_witness, }, [ - 134u8, 243u8, 151u8, 228u8, 38u8, 174u8, 96u8, 140u8, 104u8, 124u8, - 166u8, 206u8, 126u8, 211u8, 17u8, 100u8, 172u8, 5u8, 234u8, 171u8, - 125u8, 2u8, 191u8, 163u8, 72u8, 29u8, 163u8, 107u8, 65u8, 92u8, 41u8, - 45u8, + 243u8, 130u8, 216u8, 251u8, 131u8, 220u8, 75u8, 210u8, 203u8, 137u8, + 174u8, 95u8, 134u8, 252u8, 76u8, 33u8, 230u8, 185u8, 125u8, 15u8, + 200u8, 85u8, 46u8, 43u8, 34u8, 205u8, 245u8, 85u8, 46u8, 78u8, 245u8, + 135u8, ], ) } - #[doc = "Cancel a proposed or active child-bounty. Child-bounty account funds"] - #[doc = "are transferred to parent bounty account. The child-bounty curator"] - #[doc = "deposit may be unreserved if possible."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be either parent curator or"] - #[doc = "`T::RejectOrigin`."] - #[doc = ""] - #[doc = "If the state of child-bounty is `Active`, curator deposit is"] - #[doc = "unreserved."] - #[doc = ""] - #[doc = "If the state of child-bounty is `PendingPayout`, call fails &"] - #[doc = "returns `PendingPayout` error."] - #[doc = ""] - #[doc = "For the origin other than T::RejectOrigin, parent bounty must be in"] - #[doc = "active state, for this child-bounty call to work. For origin"] - #[doc = "T::RejectOrigin execution is forced."] - #[doc = ""] - #[doc = "Instance of child-bounty is removed from the state on successful"] - #[doc = "call completion."] - #[doc = ""] - #[doc = "- `parent_bounty_id`: Index of parent bounty."] - #[doc = "- `child_bounty_id`: Index of child bounty."] - pub fn close_child_bounty( + pub fn dispatch_whitelisted_call_with_preimage( &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload + { ::subxt::tx::Payload::new_static( - "ChildBounties", - "close_child_bounty", - types::CloseChildBounty { - parent_bounty_id, - child_bounty_id, + "Whitelist", + "dispatch_whitelisted_call_with_preimage", + types::DispatchWhitelistedCallWithPreimage { + call: ::std::boxed::Box::new(call), }, [ - 40u8, 0u8, 235u8, 75u8, 36u8, 196u8, 29u8, 26u8, 30u8, 172u8, 240u8, - 44u8, 129u8, 243u8, 55u8, 211u8, 96u8, 159u8, 72u8, 96u8, 142u8, 68u8, - 41u8, 238u8, 157u8, 167u8, 90u8, 141u8, 213u8, 249u8, 222u8, 22u8, + 97u8, 254u8, 134u8, 138u8, 68u8, 168u8, 207u8, 37u8, 107u8, 232u8, + 197u8, 219u8, 22u8, 91u8, 16u8, 162u8, 159u8, 99u8, 232u8, 92u8, 187u8, + 182u8, 231u8, 220u8, 235u8, 215u8, 186u8, 185u8, 40u8, 131u8, 191u8, + 37u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_child_bounties::pallet::Event; + pub type Event = runtime_types::pallet_whitelist::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -21790,34 +19124,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A child-bounty is added."] - pub struct Added { - pub index: ::core::primitive::u32, - pub child_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Added { - const PALLET: &'static str = "ChildBounties"; - const EVENT: &'static str = "Added"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A child-bounty is awarded to a beneficiary."] - pub struct Awarded { - pub index: ::core::primitive::u32, - pub child_index: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::AccountId32, + pub struct CallWhitelisted { + pub call_hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for Awarded { - const PALLET: &'static str = "ChildBounties"; - const EVENT: &'static str = "Awarded"; + impl ::subxt::events::StaticEvent for CallWhitelisted { + const PALLET: &'static str = "Whitelist"; + const EVENT: &'static str = "CallWhitelisted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -21829,16 +19141,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A child-bounty is claimed by beneficiary."] - pub struct Claimed { - pub index: ::core::primitive::u32, - pub child_index: ::core::primitive::u32, - pub payout: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::AccountId32, + pub struct WhitelistedCallRemoved { + pub call_hash: ::subxt::utils::H256, } - impl ::subxt::events::StaticEvent for Claimed { - const PALLET: &'static str = "ChildBounties"; - const EVENT: &'static str = "Claimed"; + impl ::subxt::events::StaticEvent for WhitelistedCallRemoved { + const PALLET: &'static str = "Whitelist"; + const EVENT: &'static str = "WhitelistedCallRemoved"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -21850,286 +19158,75 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A child-bounty is cancelled."] - pub struct Canceled { - pub index: ::core::primitive::u32, - pub child_index: ::core::primitive::u32, + pub struct WhitelistedCallDispatched { + pub call_hash: ::subxt::utils::H256, + pub result: ::core::result::Result< + runtime_types::frame_support::dispatch::PostDispatchInfo, + runtime_types::sp_runtime::DispatchErrorWithPostInfo< + runtime_types::frame_support::dispatch::PostDispatchInfo, + >, + >, } - impl ::subxt::events::StaticEvent for Canceled { - const PALLET: &'static str = "ChildBounties"; - const EVENT: &'static str = "Canceled"; + impl ::subxt::events::StaticEvent for WhitelistedCallDispatched { + const PALLET: &'static str = "Whitelist"; + const EVENT: &'static str = "WhitelistedCallDispatched"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " Number of total child bounties."] - pub fn child_bounty_count( + pub fn whitelisted_call( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, (), - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBountyCount", - vec![], - [ - 46u8, 10u8, 183u8, 160u8, 98u8, 215u8, 39u8, 253u8, 81u8, 94u8, 114u8, - 147u8, 115u8, 162u8, 33u8, 117u8, 160u8, 214u8, 167u8, 7u8, 109u8, - 143u8, 158u8, 1u8, 200u8, 205u8, 17u8, 93u8, 89u8, 26u8, 30u8, 95u8, - ], - ) - } - #[doc = " Number of child bounties per parent bounty."] - #[doc = " Map of parent bounty index to number of child bounties."] - pub fn parent_child_bounties( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, + (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ParentChildBounties", + "Whitelist", + "WhitelistedCall", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 127u8, 161u8, 181u8, 79u8, 235u8, 196u8, 252u8, 162u8, 39u8, 15u8, - 251u8, 49u8, 125u8, 80u8, 101u8, 24u8, 234u8, 88u8, 212u8, 126u8, 63u8, - 63u8, 19u8, 75u8, 137u8, 125u8, 38u8, 250u8, 77u8, 49u8, 76u8, 188u8, + 251u8, 179u8, 58u8, 232u8, 231u8, 121u8, 89u8, 218u8, 90u8, 70u8, 96u8, + 132u8, 54u8, 41u8, 18u8, 129u8, 197u8, 122u8, 221u8, 206u8, 41u8, + 100u8, 200u8, 141u8, 71u8, 98u8, 3u8, 3u8, 112u8, 167u8, 196u8, 77u8, ], ) } - #[doc = " Number of child bounties per parent bounty."] - #[doc = " Map of parent bounty index to number of child bounties."] - pub fn parent_child_bounties_root( + pub fn whitelisted_call_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ParentChildBounties", - Vec::new(), - [ - 127u8, 161u8, 181u8, 79u8, 235u8, 196u8, 252u8, 162u8, 39u8, 15u8, - 251u8, 49u8, 125u8, 80u8, 101u8, 24u8, 234u8, 88u8, 212u8, 126u8, 63u8, - 63u8, 19u8, 75u8, 137u8, 125u8, 38u8, 250u8, 77u8, 49u8, 76u8, 188u8, - ], - ) - } - #[doc = " Child bounties that have been added."] - pub fn child_bounties( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_child_bounties::ChildBounty< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, + (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBounties", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], + "Whitelist", + "WhitelistedCall", + Vec::new(), [ - 66u8, 132u8, 251u8, 223u8, 216u8, 52u8, 162u8, 150u8, 229u8, 239u8, - 219u8, 182u8, 211u8, 228u8, 181u8, 46u8, 243u8, 151u8, 111u8, 235u8, - 105u8, 40u8, 39u8, 10u8, 245u8, 113u8, 78u8, 116u8, 219u8, 186u8, - 165u8, 91u8, - ], - ) - } - #[doc = " Child bounties that have been added."] - pub fn child_bounties_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_child_bounties::ChildBounty< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBounties", - Vec::new(), - [ - 66u8, 132u8, 251u8, 223u8, 216u8, 52u8, 162u8, 150u8, 229u8, 239u8, - 219u8, 182u8, 211u8, 228u8, 181u8, 46u8, 243u8, 151u8, 111u8, 235u8, - 105u8, 40u8, 39u8, 10u8, 245u8, 113u8, 78u8, 116u8, 219u8, 186u8, - 165u8, 91u8, - ], - ) - } - #[doc = " The description of each child-bounty."] - pub fn child_bounty_descriptions( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBountyDescriptions", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 193u8, 200u8, 40u8, 30u8, 14u8, 71u8, 90u8, 42u8, 58u8, 253u8, 225u8, - 158u8, 172u8, 10u8, 45u8, 238u8, 36u8, 144u8, 184u8, 153u8, 11u8, - 157u8, 125u8, 220u8, 175u8, 31u8, 28u8, 93u8, 207u8, 212u8, 141u8, - 74u8, - ], - ) - } - #[doc = " The description of each child-bounty."] - pub fn child_bounty_descriptions_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBountyDescriptions", - Vec::new(), - [ - 193u8, 200u8, 40u8, 30u8, 14u8, 71u8, 90u8, 42u8, 58u8, 253u8, 225u8, - 158u8, 172u8, 10u8, 45u8, 238u8, 36u8, 144u8, 184u8, 153u8, 11u8, - 157u8, 125u8, 220u8, 175u8, 31u8, 28u8, 93u8, 207u8, 212u8, 141u8, - 74u8, - ], - ) - } - #[doc = " The cumulative child-bounty curator fee for each parent bounty."] - pub fn children_curator_fees( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildrenCuratorFees", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 174u8, 128u8, 86u8, 179u8, 133u8, 76u8, 98u8, 169u8, 234u8, 166u8, - 249u8, 214u8, 172u8, 171u8, 8u8, 161u8, 105u8, 69u8, 148u8, 151u8, - 35u8, 174u8, 118u8, 139u8, 101u8, 56u8, 85u8, 211u8, 121u8, 168u8, 0u8, - 216u8, - ], - ) - } - #[doc = " The cumulative child-bounty curator fee for each parent bounty."] - pub fn children_curator_fees_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildrenCuratorFees", - Vec::new(), - [ - 174u8, 128u8, 86u8, 179u8, 133u8, 76u8, 98u8, 169u8, 234u8, 166u8, - 249u8, 214u8, 172u8, 171u8, 8u8, 161u8, 105u8, 69u8, 148u8, 151u8, - 35u8, 174u8, 118u8, 139u8, 101u8, 56u8, 85u8, 211u8, 121u8, 168u8, 0u8, - 216u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Maximum number of child bounties that can be added to a parent bounty."] - pub fn max_active_child_bounty_count( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ChildBounties", - "MaxActiveChildBountyCount", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Minimum value for a child-bounty."] - pub fn child_bounty_value_minimum( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "ChildBounties", - "ChildBountyValueMinimum", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 251u8, 179u8, 58u8, 232u8, 231u8, 121u8, 89u8, 218u8, 90u8, 70u8, 96u8, + 132u8, 54u8, 41u8, 18u8, 129u8, 197u8, 122u8, 221u8, 206u8, 41u8, + 100u8, 200u8, 141u8, 71u8, 98u8, 3u8, 3u8, 112u8, 167u8, 196u8, 77u8, ], ) } } } } - pub mod tips { + pub mod claims { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_tips::pallet::Error; + pub type Error = runtime_types::polkadot_runtime_common::claims::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -22147,22 +19244,10 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportAwesome { - pub reason: ::std::vec::Vec<::core::primitive::u8>, - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RetractTip { - pub hash: ::subxt::utils::H256, + pub struct Claim { + pub dest: ::subxt::utils::AccountId32, + pub ethereum_signature: + runtime_types::polkadot_runtime_common::claims::EcdsaSignature, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -22174,11 +19259,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TipNew { - pub reason: ::std::vec::Vec<::core::primitive::u8>, - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub tip_value: ::core::primitive::u128, + pub struct MintClaim { + pub who: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + pub value: ::core::primitive::u128, + pub vesting_schedule: ::core::option::Option<( + ::core::primitive::u128, + ::core::primitive::u128, + ::core::primitive::u32, + )>, + pub statement: ::core::option::Option< + runtime_types::polkadot_runtime_common::claims::StatementKind, + >, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -22190,10 +19281,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Tip { - pub hash: ::subxt::utils::H256, - #[codec(compact)] - pub tip_value: ::core::primitive::u128, + pub struct ClaimAttest { + pub dest: ::subxt::utils::AccountId32, + pub ethereum_signature: + runtime_types::polkadot_runtime_common::claims::EcdsaSignature, + pub statement: ::std::vec::Vec<::core::primitive::u8>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -22205,8 +19297,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseTip { - pub hash: ::subxt::utils::H256, + pub struct Attest { + pub statement: ::std::vec::Vec<::core::primitive::u8>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -22218,211 +19310,207 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SlashTip { - pub hash: ::subxt::utils::H256, + pub struct MoveClaim { + pub old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + pub new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + pub maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, } } pub struct TransactionApi; impl TransactionApi { - #[doc = "Report something `reason` that deserves a tip and claim any eventual the finder's fee."] - #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] - #[doc = ""] - #[doc = "Payment: `TipReportDepositBase` will be reserved from the origin account, as well as"] - #[doc = "`DataDepositPerByte` for each byte in `reason`."] - #[doc = ""] - #[doc = "- `reason`: The reason for, or the thing that deserves, the tip; generally this will be"] - #[doc = " a UTF-8-encoded URL."] - #[doc = "- `who`: The account which should be credited for the tip."] + #[doc = "Make a claim to collect your DOTs."] #[doc = ""] - #[doc = "Emits `NewTip` if successful."] + #[doc = "The dispatch origin for this call must be _None_."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(R)` where `R` length of `reason`."] - #[doc = " - encoding and hashing of 'reason'"] - pub fn report_awesome( - &self, - reason: ::std::vec::Vec<::core::primitive::u8>, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Tips", - "report_awesome", - types::ReportAwesome { reason, who }, - [ - 126u8, 68u8, 2u8, 54u8, 195u8, 15u8, 43u8, 27u8, 183u8, 254u8, 157u8, - 163u8, 252u8, 14u8, 207u8, 251u8, 215u8, 111u8, 98u8, 209u8, 150u8, - 11u8, 240u8, 177u8, 106u8, 93u8, 191u8, 31u8, 62u8, 11u8, 223u8, 79u8, - ], - ) - } - #[doc = "Retract a prior tip-report from `report_awesome`, and cancel the process of tipping."] + #[doc = "Unsigned Validation:"] + #[doc = "A call to claim is deemed valid if the signature provided matches"] + #[doc = "the expected signed message of:"] #[doc = ""] - #[doc = "If successful, the original deposit will be unreserved."] + #[doc = "> Ethereum Signed Message:"] + #[doc = "> (configured prefix string)(address)"] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the tip identified by `hash`"] - #[doc = "must have been reported by the signing account through `report_awesome` (and not"] - #[doc = "through `tip_new`)."] + #[doc = "and `address` matches the `dest` account."] #[doc = ""] - #[doc = "- `hash`: The identity of the open tip for which a tip value is declared. This is formed"] - #[doc = " as the hash of the tuple of the original tip `reason` and the beneficiary account ID."] + #[doc = "Parameters:"] + #[doc = "- `dest`: The destination account to payout the claim."] + #[doc = "- `ethereum_signature`: The signature of an ethereum signed message"] + #[doc = " matching the format described above."] #[doc = ""] - #[doc = "Emits `TipRetracted` if successful."] + #[doc = ""] + #[doc = "The weight of this call is invariant over the input parameters."] + #[doc = "Weight includes logic to validate unsigned `claim` call."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(1)`"] - #[doc = " - Depends on the length of `T::Hash` which is fixed."] - pub fn retract_tip( + #[doc = "Total Complexity: O(1)"] + #[doc = ""] + pub fn claim( &self, - hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + dest: ::subxt::utils::AccountId32, + ethereum_signature : runtime_types :: polkadot_runtime_common :: claims :: EcdsaSignature, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Tips", - "retract_tip", - types::RetractTip { hash }, + "Claims", + "claim", + types::Claim { + dest, + ethereum_signature, + }, [ - 137u8, 42u8, 229u8, 188u8, 157u8, 195u8, 184u8, 176u8, 64u8, 142u8, - 67u8, 175u8, 185u8, 207u8, 214u8, 71u8, 165u8, 29u8, 137u8, 227u8, - 132u8, 195u8, 255u8, 66u8, 186u8, 57u8, 34u8, 184u8, 187u8, 65u8, - 129u8, 131u8, + 33u8, 63u8, 71u8, 104u8, 200u8, 179u8, 248u8, 38u8, 193u8, 198u8, + 250u8, 49u8, 106u8, 26u8, 109u8, 183u8, 33u8, 50u8, 217u8, 28u8, 50u8, + 107u8, 249u8, 80u8, 199u8, 10u8, 192u8, 1u8, 54u8, 41u8, 146u8, 11u8, ], ) } - #[doc = "Give a tip for something new; no finder's fee will be taken."] + #[doc = "Mint a new claim to collect DOTs."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the signing account must be a"] - #[doc = "member of the `Tippers` set."] + #[doc = "The dispatch origin for this call must be _Root_."] #[doc = ""] - #[doc = "- `reason`: The reason for, or the thing that deserves, the tip; generally this will be"] - #[doc = " a UTF-8-encoded URL."] - #[doc = "- `who`: The account which should be credited for the tip."] - #[doc = "- `tip_value`: The amount of tip that the sender would like to give. The median tip"] - #[doc = " value of active tippers will be given to the `who`."] + #[doc = "Parameters:"] + #[doc = "- `who`: The Ethereum address allowed to collect this claim."] + #[doc = "- `value`: The number of DOTs that will be claimed."] + #[doc = "- `vesting_schedule`: An optional vesting schedule for these DOTs."] #[doc = ""] - #[doc = "Emits `NewTip` if successful."] + #[doc = ""] + #[doc = "The weight of this call is invariant over the input parameters."] + #[doc = "We assume worst case that both vesting and statement is being inserted."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(R + T)` where `R` length of `reason`, `T` is the number of tippers."] - #[doc = " - `O(T)`: decoding `Tipper` vec of length `T`. `T` is charged as upper bound given by"] - #[doc = " `ContainsLengthBound`. The actual cost depends on the implementation of"] - #[doc = " `T::Tippers`."] - #[doc = " - `O(R)`: hashing and encoding of reason of length `R`"] - pub fn tip_new( + #[doc = "Total Complexity: O(1)"] + #[doc = ""] + pub fn mint_claim( &self, - reason: ::std::vec::Vec<::core::primitive::u8>, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - tip_value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + who: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + value: ::core::primitive::u128, + vesting_schedule: ::core::option::Option<( + ::core::primitive::u128, + ::core::primitive::u128, + ::core::primitive::u32, + )>, + statement: ::core::option::Option< + runtime_types::polkadot_runtime_common::claims::StatementKind, + >, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Tips", - "tip_new", - types::TipNew { - reason, + "Claims", + "mint_claim", + types::MintClaim { who, - tip_value, + value, + vesting_schedule, + statement, }, [ - 217u8, 15u8, 70u8, 80u8, 193u8, 110u8, 212u8, 110u8, 212u8, 45u8, - 197u8, 150u8, 43u8, 116u8, 115u8, 231u8, 148u8, 102u8, 202u8, 28u8, - 55u8, 88u8, 166u8, 238u8, 11u8, 238u8, 229u8, 189u8, 89u8, 115u8, - 196u8, 95u8, + 213u8, 79u8, 204u8, 40u8, 104u8, 84u8, 82u8, 62u8, 193u8, 93u8, 246u8, + 21u8, 37u8, 244u8, 166u8, 132u8, 208u8, 18u8, 86u8, 195u8, 156u8, 9u8, + 220u8, 120u8, 40u8, 183u8, 28u8, 103u8, 84u8, 163u8, 153u8, 110u8, ], ) } - #[doc = "Declare a tip value for an already-open tip."] + #[doc = "Make a claim to collect your DOTs by signing a statement."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and the signing account must be a"] - #[doc = "member of the `Tippers` set."] + #[doc = "The dispatch origin for this call must be _None_."] #[doc = ""] - #[doc = "- `hash`: The identity of the open tip for which a tip value is declared. This is formed"] - #[doc = " as the hash of the tuple of the hash of the original tip `reason` and the beneficiary"] - #[doc = " account ID."] - #[doc = "- `tip_value`: The amount of tip that the sender would like to give. The median tip"] - #[doc = " value of active tippers will be given to the `who`."] + #[doc = "Unsigned Validation:"] + #[doc = "A call to `claim_attest` is deemed valid if the signature provided matches"] + #[doc = "the expected signed message of:"] #[doc = ""] - #[doc = "Emits `TipClosing` if the threshold of tippers has been reached and the countdown period"] - #[doc = "has started."] + #[doc = "> Ethereum Signed Message:"] + #[doc = "> (configured prefix string)(address)(statement)"] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- `O(T)` where `T` is the number of tippers. decoding `Tipper` vec of length `T`, insert"] - #[doc = " tip and check closing, `T` is charged as upper bound given by `ContainsLengthBound`."] - #[doc = " The actual cost depends on the implementation of `T::Tippers`."] + #[doc = "and `address` matches the `dest` account; the `statement` must match that which is"] + #[doc = "expected according to your purchase arrangement."] #[doc = ""] - #[doc = " Actually weight could be lower as it depends on how many tips are in `OpenTip` but it"] - #[doc = " is weighted as if almost full i.e of length `T-1`."] - pub fn tip( + #[doc = "Parameters:"] + #[doc = "- `dest`: The destination account to payout the claim."] + #[doc = "- `ethereum_signature`: The signature of an ethereum signed message"] + #[doc = " matching the format described above."] + #[doc = "- `statement`: The identity of the statement which is being attested to in the signature."] + #[doc = ""] + #[doc = ""] + #[doc = "The weight of this call is invariant over the input parameters."] + #[doc = "Weight includes logic to validate unsigned `claim_attest` call."] + #[doc = ""] + #[doc = "Total Complexity: O(1)"] + #[doc = ""] + pub fn claim_attest( &self, - hash: ::subxt::utils::H256, - tip_value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + dest: ::subxt::utils::AccountId32, + ethereum_signature : runtime_types :: polkadot_runtime_common :: claims :: EcdsaSignature, + statement: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Tips", - "tip", - types::Tip { hash, tip_value }, + "Claims", + "claim_attest", + types::ClaimAttest { + dest, + ethereum_signature, + statement, + }, [ - 133u8, 52u8, 131u8, 14u8, 71u8, 232u8, 254u8, 31u8, 33u8, 206u8, 50u8, - 76u8, 56u8, 167u8, 228u8, 202u8, 195u8, 0u8, 164u8, 107u8, 170u8, 98u8, - 192u8, 37u8, 209u8, 199u8, 130u8, 15u8, 168u8, 63u8, 181u8, 134u8, + 255u8, 10u8, 87u8, 106u8, 101u8, 195u8, 249u8, 25u8, 109u8, 82u8, + 213u8, 95u8, 203u8, 145u8, 224u8, 113u8, 92u8, 141u8, 31u8, 54u8, + 218u8, 47u8, 218u8, 239u8, 211u8, 206u8, 77u8, 176u8, 19u8, 176u8, + 175u8, 135u8, ], ) } - #[doc = "Close and payout a tip."] + #[doc = "Attest to a statement, needed to finalize the claims process."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = "WARNING: Insecure unless your chain includes `PrevalidateAttests` as a `SignedExtension`."] #[doc = ""] - #[doc = "The tip identified by `hash` must have finished its countdown period."] + #[doc = "Unsigned Validation:"] + #[doc = "A call to attest is deemed valid if the sender has a `Preclaim` registered"] + #[doc = "and provides a `statement` which is expected for the account."] #[doc = ""] - #[doc = "- `hash`: The identity of the open tip for which a tip value is declared. This is formed"] - #[doc = " as the hash of the tuple of the original tip `reason` and the beneficiary account ID."] + #[doc = "Parameters:"] + #[doc = "- `statement`: The identity of the statement which is being attested to in the signature."] #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- : `O(T)` where `T` is the number of tippers. decoding `Tipper` vec of length `T`. `T`"] - #[doc = " is charged as upper bound given by `ContainsLengthBound`. The actual cost depends on"] - #[doc = " the implementation of `T::Tippers`."] - pub fn close_tip( + #[doc = ""] + #[doc = "The weight of this call is invariant over the input parameters."] + #[doc = "Weight includes logic to do pre-validation on `attest` call."] + #[doc = ""] + #[doc = "Total Complexity: O(1)"] + #[doc = ""] + pub fn attest( &self, - hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + statement: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Tips", - "close_tip", - types::CloseTip { hash }, + "Claims", + "attest", + types::Attest { statement }, [ - 32u8, 53u8, 0u8, 222u8, 45u8, 157u8, 107u8, 174u8, 203u8, 50u8, 81u8, - 230u8, 6u8, 111u8, 79u8, 55u8, 49u8, 151u8, 107u8, 114u8, 81u8, 200u8, - 144u8, 175u8, 29u8, 142u8, 115u8, 184u8, 102u8, 116u8, 156u8, 173u8, + 8u8, 218u8, 97u8, 237u8, 185u8, 61u8, 55u8, 4u8, 134u8, 18u8, 244u8, + 226u8, 40u8, 97u8, 222u8, 246u8, 221u8, 74u8, 253u8, 22u8, 52u8, 223u8, + 224u8, 83u8, 21u8, 218u8, 248u8, 100u8, 107u8, 58u8, 247u8, 10u8, ], ) } - #[doc = "Remove and slash an already-open tip."] - #[doc = ""] - #[doc = "May only be called from `T::RejectOrigin`."] - #[doc = ""] - #[doc = "As a result, the finder is slashed and the deposits are lost."] - #[doc = ""] - #[doc = "Emits `TipSlashed` if successful."] - #[doc = ""] - #[doc = "## Complexity"] - #[doc = "- O(1)."] - pub fn slash_tip( + pub fn move_claim( &self, - hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { + old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, + maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "Tips", - "slash_tip", - types::SlashTip { hash }, + "Claims", + "move_claim", + types::MoveClaim { + old, + new, + maybe_preclaim, + }, [ - 222u8, 209u8, 22u8, 47u8, 114u8, 230u8, 81u8, 200u8, 131u8, 0u8, 209u8, - 54u8, 17u8, 200u8, 175u8, 125u8, 100u8, 254u8, 41u8, 178u8, 20u8, 27u8, - 9u8, 184u8, 79u8, 93u8, 208u8, 148u8, 27u8, 190u8, 176u8, 169u8, + 63u8, 48u8, 217u8, 16u8, 161u8, 102u8, 165u8, 241u8, 57u8, 185u8, + 230u8, 161u8, 202u8, 11u8, 223u8, 15u8, 57u8, 181u8, 34u8, 131u8, + 235u8, 168u8, 227u8, 152u8, 157u8, 4u8, 192u8, 243u8, 194u8, 120u8, + 130u8, 202u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_tips::pallet::Event; + pub type Event = runtime_types::polkadot_runtime_common::claims::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -22435,289 +19523,272 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new tip suggestion has been opened."] - pub struct NewTip { - pub tip_hash: ::subxt::utils::H256, + #[doc = "Someone claimed some DOTs."] + pub struct Claimed { + pub who: ::subxt::utils::AccountId32, + pub ethereum_address: + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + pub amount: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for NewTip { - const PALLET: &'static str = "Tips"; - const EVENT: &'static str = "NewTip"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A tip suggestion has reached threshold and is closing."] - pub struct TipClosing { - pub tip_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for TipClosing { - const PALLET: &'static str = "Tips"; - const EVENT: &'static str = "TipClosing"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A tip suggestion has been closed."] - pub struct TipClosed { - pub tip_hash: ::subxt::utils::H256, - pub who: ::subxt::utils::AccountId32, - pub payout: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for TipClosed { - const PALLET: &'static str = "Tips"; - const EVENT: &'static str = "TipClosed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A tip suggestion has been retracted."] - pub struct TipRetracted { - pub tip_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for TipRetracted { - const PALLET: &'static str = "Tips"; - const EVENT: &'static str = "TipRetracted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A tip suggestion has been slashed."] - pub struct TipSlashed { - pub tip_hash: ::subxt::utils::H256, - pub finder: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for TipSlashed { - const PALLET: &'static str = "Tips"; - const EVENT: &'static str = "TipSlashed"; + impl ::subxt::events::StaticEvent for Claimed { + const PALLET: &'static str = "Claims"; + const EVENT: &'static str = "Claimed"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " TipsMap that are not yet completed. Keyed by the hash of `(reason, who)` from the value."] - #[doc = " This has the insecure enumerable hash function since the key itself is already"] - #[doc = " guaranteed to be a secure hash."] - pub fn tips( + pub fn claims( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + >, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_tips::OpenTip< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - ::subxt::utils::H256, - >, + ::core::primitive::u128, ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Tips", - "Tips", + "Claims", + "Claims", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 241u8, 196u8, 105u8, 248u8, 29u8, 66u8, 86u8, 98u8, 6u8, 159u8, 191u8, - 0u8, 227u8, 232u8, 147u8, 248u8, 173u8, 20u8, 225u8, 12u8, 232u8, 5u8, - 93u8, 78u8, 18u8, 154u8, 130u8, 38u8, 142u8, 36u8, 66u8, 0u8, + 36u8, 247u8, 169u8, 171u8, 103u8, 176u8, 70u8, 213u8, 255u8, 175u8, + 97u8, 142u8, 231u8, 70u8, 90u8, 213u8, 128u8, 67u8, 50u8, 37u8, 51u8, + 184u8, 72u8, 27u8, 193u8, 254u8, 12u8, 253u8, 91u8, 60u8, 88u8, 182u8, ], ) } - #[doc = " TipsMap that are not yet completed. Keyed by the hash of `(reason, who)` from the value."] - #[doc = " This has the insecure enumerable hash function since the key itself is already"] - #[doc = " guaranteed to be a secure hash."] - pub fn tips_root( + pub fn claims_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_tips::OpenTip< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - ::subxt::utils::H256, - >, + ::core::primitive::u128, (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Tips", - "Tips", + "Claims", + "Claims", Vec::new(), [ - 241u8, 196u8, 105u8, 248u8, 29u8, 66u8, 86u8, 98u8, 6u8, 159u8, 191u8, - 0u8, 227u8, 232u8, 147u8, 248u8, 173u8, 20u8, 225u8, 12u8, 232u8, 5u8, - 93u8, 78u8, 18u8, 154u8, 130u8, 38u8, 142u8, 36u8, 66u8, 0u8, + 36u8, 247u8, 169u8, 171u8, 103u8, 176u8, 70u8, 213u8, 255u8, 175u8, + 97u8, 142u8, 231u8, 70u8, 90u8, 213u8, 128u8, 67u8, 50u8, 37u8, 51u8, + 184u8, 72u8, 27u8, 193u8, 254u8, 12u8, 253u8, 91u8, 60u8, 88u8, 182u8, ], ) } - #[doc = " Simple preimage lookup from the reason's hash to the original data. Again, has an"] - #[doc = " insecure enumerable hash since the key is guaranteed to be the result of a secure hash."] - pub fn reasons( + pub fn total( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Claims", + "Total", + vec![], + [ + 162u8, 59u8, 237u8, 63u8, 23u8, 44u8, 74u8, 169u8, 131u8, 166u8, 174u8, + 61u8, 127u8, 165u8, 32u8, 115u8, 73u8, 171u8, 36u8, 10u8, 6u8, 23u8, + 19u8, 202u8, 3u8, 189u8, 29u8, 169u8, 144u8, 187u8, 235u8, 77u8, + ], + ) + } + #[doc = " Vesting schedule for a claim."] + #[doc = " First balance is the total amount that should be held for vesting."] + #[doc = " Second balance is how much should be unlocked per block."] + #[doc = " The block number is when the vesting should start."] + pub fn vesting( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ( + ::core::primitive::u128, + ::core::primitive::u128, + ::core::primitive::u32, + ), ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Tips", - "Reasons", + "Claims", + "Vesting", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 202u8, 191u8, 36u8, 162u8, 156u8, 102u8, 115u8, 10u8, 203u8, 35u8, - 201u8, 70u8, 195u8, 151u8, 89u8, 82u8, 202u8, 35u8, 210u8, 176u8, 82u8, - 1u8, 77u8, 94u8, 31u8, 70u8, 252u8, 194u8, 166u8, 91u8, 189u8, 134u8, + 112u8, 174u8, 151u8, 185u8, 225u8, 170u8, 63u8, 147u8, 100u8, 23u8, + 102u8, 148u8, 244u8, 47u8, 87u8, 99u8, 28u8, 59u8, 48u8, 205u8, 43u8, + 41u8, 87u8, 225u8, 191u8, 164u8, 31u8, 208u8, 80u8, 53u8, 25u8, 205u8, ], ) } - #[doc = " Simple preimage lookup from the reason's hash to the original data. Again, has an"] - #[doc = " insecure enumerable hash since the key is guaranteed to be the result of a secure hash."] - pub fn reasons_root( + #[doc = " Vesting schedule for a claim."] + #[doc = " First balance is the total amount that should be held for vesting."] + #[doc = " Second balance is how much should be unlocked per block."] + #[doc = " The block number is when the vesting should start."] + pub fn vesting_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, + ( + ::core::primitive::u128, + ::core::primitive::u128, + ::core::primitive::u32, + ), (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "Tips", - "Reasons", + "Claims", + "Vesting", Vec::new(), [ - 202u8, 191u8, 36u8, 162u8, 156u8, 102u8, 115u8, 10u8, 203u8, 35u8, - 201u8, 70u8, 195u8, 151u8, 89u8, 82u8, 202u8, 35u8, 210u8, 176u8, 82u8, - 1u8, 77u8, 94u8, 31u8, 70u8, 252u8, 194u8, 166u8, 91u8, 189u8, 134u8, + 112u8, 174u8, 151u8, 185u8, 225u8, 170u8, 63u8, 147u8, 100u8, 23u8, + 102u8, 148u8, 244u8, 47u8, 87u8, 99u8, 28u8, 59u8, 48u8, 205u8, 43u8, + 41u8, 87u8, 225u8, 191u8, 164u8, 31u8, 208u8, 80u8, 53u8, 25u8, 205u8, ], ) } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Maximum acceptable reason length."] - #[doc = ""] - #[doc = " Benchmarks depend on this value, be sure to update weights file when changing this value"] - pub fn maximum_reason_length( + #[doc = " The statement kind that must be signed, if any."] + pub fn signing( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Tips", - "MaximumReasonLength", + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_common::claims::StatementKind, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Claims", + "Signing", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 51u8, 184u8, 211u8, 207u8, 13u8, 194u8, 181u8, 153u8, 25u8, 212u8, + 106u8, 189u8, 149u8, 14u8, 19u8, 61u8, 210u8, 109u8, 23u8, 168u8, + 191u8, 74u8, 112u8, 190u8, 242u8, 112u8, 183u8, 17u8, 30u8, 125u8, + 85u8, 107u8, ], ) } - #[doc = " The amount held on deposit per byte within the tip report reason or bounty description."] - pub fn data_deposit_per_byte( + #[doc = " The statement kind that must be signed, if any."] + pub fn signing_root( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Tips", - "DataDepositPerByte", + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_common::claims::StatementKind, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Claims", + "Signing", + Vec::new(), [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 51u8, 184u8, 211u8, 207u8, 13u8, 194u8, 181u8, 153u8, 25u8, 212u8, + 106u8, 189u8, 149u8, 14u8, 19u8, 61u8, 210u8, 109u8, 23u8, 168u8, + 191u8, 74u8, 112u8, 190u8, 242u8, 112u8, 183u8, 17u8, 30u8, 125u8, + 85u8, 107u8, ], ) } - #[doc = " The period for which a tip remains open after is has achieved threshold tippers."] - pub fn tip_countdown(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Tips", - "TipCountdown", + #[doc = " Pre-claimed Ethereum accounts, by the Account ID that they are claimed to."] + pub fn preclaims( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Claims", + "Preclaims", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 149u8, 61u8, 170u8, 170u8, 60u8, 212u8, 29u8, 214u8, 141u8, 136u8, + 207u8, 248u8, 51u8, 135u8, 242u8, 105u8, 121u8, 91u8, 186u8, 30u8, 0u8, + 173u8, 154u8, 133u8, 20u8, 244u8, 58u8, 184u8, 133u8, 214u8, 67u8, + 95u8, ], ) } - #[doc = " The percent of the final tip which goes to the original reporter of the tip."] - pub fn tip_finders_fee( + #[doc = " Pre-claimed Ethereum accounts, by the Account ID that they are claimed to."] + pub fn preclaims_root( &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "Tips", - "TipFindersFee", + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Claims", + "Preclaims", + Vec::new(), [ - 99u8, 121u8, 176u8, 172u8, 235u8, 159u8, 116u8, 114u8, 179u8, 91u8, - 129u8, 117u8, 204u8, 135u8, 53u8, 7u8, 151u8, 26u8, 124u8, 151u8, - 202u8, 171u8, 171u8, 207u8, 183u8, 177u8, 24u8, 53u8, 109u8, 185u8, - 71u8, 183u8, + 149u8, 61u8, 170u8, 170u8, 60u8, 212u8, 29u8, 214u8, 141u8, 136u8, + 207u8, 248u8, 51u8, 135u8, 242u8, 105u8, 121u8, 91u8, 186u8, 30u8, 0u8, + 173u8, 154u8, 133u8, 20u8, 244u8, 58u8, 184u8, 133u8, 214u8, 67u8, + 95u8, ], ) } - #[doc = " The amount held on deposit for placing a tip report."] - pub fn tip_report_deposit_base( + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + pub fn prefix( &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { + ) -> ::subxt::constants::Address<::std::vec::Vec<::core::primitive::u8>> + { ::subxt::constants::Address::new_static( - "Tips", - "TipReportDepositBase", + "Claims", + "Prefix", [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + 106u8, 50u8, 57u8, 116u8, 43u8, 202u8, 37u8, 248u8, 102u8, 22u8, 62u8, + 22u8, 242u8, 54u8, 152u8, 168u8, 107u8, 64u8, 72u8, 172u8, 124u8, 40u8, + 42u8, 110u8, 104u8, 145u8, 31u8, 144u8, 242u8, 189u8, 145u8, 208u8, ], ) } } } } - pub mod election_provider_multi_phase { + pub mod vesting { use super::root_mod; use super::runtime_types; - #[doc = "Error of the pallet that can be returned in response to dispatches."] - pub type Error = runtime_types::pallet_election_provider_multi_phase::pallet::Error; + #[doc = "Error for the vesting pallet."] + pub type Error = runtime_types::pallet_vesting::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -22735,15 +19806,7 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SubmitUnsigned { - pub raw_solution: ::std::boxed::Box< - runtime_types::pallet_election_provider_multi_phase::RawSolution< - runtime_types::polkadot_runtime::NposCompactSolution16, - >, - >, - pub witness: - runtime_types::pallet_election_provider_multi_phase::SolutionOrSnapshotSize, - } + pub struct Vest; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -22754,9 +19817,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMinimumUntrustedScore { - pub maybe_next_score: - ::core::option::Option, + pub struct VestOther { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -22768,11 +19830,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetEmergencyElectionResult { - pub supports: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::sp_npos_elections::Support<::subxt::utils::AccountId32>, - )>, + pub struct VestedTransfer { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, + >, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -22784,11 +19847,12 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Submit { - pub raw_solution: ::std::boxed::Box< - runtime_types::pallet_election_provider_multi_phase::RawSolution< - runtime_types::polkadot_runtime::NposCompactSolution16, - >, + pub struct ForceVestedTransfer { + pub source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, >, } #[derive( @@ -22801,152 +19865,176 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct GovernanceFallback { - pub maybe_max_voters: ::core::option::Option<::core::primitive::u32>, - pub maybe_max_targets: ::core::option::Option<::core::primitive::u32>, + pub struct MergeSchedules { + pub schedule1_index: ::core::primitive::u32, + pub schedule2_index: ::core::primitive::u32, } } pub struct TransactionApi; impl TransactionApi { - #[doc = "Submit a solution for the unsigned phase."] - #[doc = ""] - #[doc = "The dispatch origin fo this call must be __none__."] + #[doc = "Unlock any vested funds of the sender account."] #[doc = ""] - #[doc = "This submission is checked on the fly. Moreover, this unsigned solution is only"] - #[doc = "validated when submitted to the pool from the **local** node. Effectively, this means"] - #[doc = "that only active validators can submit this transaction when authoring a block (similar"] - #[doc = "to an inherent)."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have funds still"] + #[doc = "locked under this pallet."] #[doc = ""] - #[doc = "To prevent any incorrect solution (and thus wasted time/weight), this transaction will"] - #[doc = "panic if the solution submitted by the validator is invalid in any way, effectively"] - #[doc = "putting their authoring reward at risk."] + #[doc = "Emits either `VestingCompleted` or `VestingUpdated`."] #[doc = ""] - #[doc = "No deposit or reward is associated with this submission."] - pub fn submit_unsigned( - &self, - raw_solution: runtime_types::pallet_election_provider_multi_phase::RawSolution< - runtime_types::polkadot_runtime::NposCompactSolution16, - >, - witness : runtime_types :: pallet_election_provider_multi_phase :: SolutionOrSnapshotSize, - ) -> ::subxt::tx::Payload { + #[doc = "## Complexity"] + #[doc = "- `O(1)`."] + pub fn vest(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ElectionProviderMultiPhase", - "submit_unsigned", - types::SubmitUnsigned { - raw_solution: ::std::boxed::Box::new(raw_solution), - witness, - }, + "Vesting", + "vest", + types::Vest {}, [ - 100u8, 240u8, 31u8, 34u8, 93u8, 98u8, 93u8, 57u8, 41u8, 197u8, 97u8, - 58u8, 242u8, 10u8, 69u8, 250u8, 185u8, 169u8, 21u8, 8u8, 202u8, 61u8, - 36u8, 25u8, 4u8, 148u8, 82u8, 56u8, 242u8, 18u8, 27u8, 219u8, + 123u8, 54u8, 10u8, 208u8, 154u8, 24u8, 39u8, 166u8, 64u8, 27u8, 74u8, + 29u8, 243u8, 97u8, 155u8, 5u8, 130u8, 155u8, 65u8, 181u8, 196u8, 125u8, + 45u8, 133u8, 25u8, 33u8, 3u8, 34u8, 21u8, 167u8, 172u8, 54u8, ], ) } - #[doc = "Set a new value for `MinimumUntrustedScore`."] + #[doc = "Unlock any vested funds of a `target` account."] #[doc = ""] - #[doc = "Dispatch origin must be aligned with `T::ForceOrigin`."] + #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] - #[doc = "This check can be turned off by setting the value to `None`."] - pub fn set_minimum_untrusted_score( + #[doc = "- `target`: The account whose vested funds should be unlocked. Must have funds still"] + #[doc = "locked under this pallet."] + #[doc = ""] + #[doc = "Emits either `VestingCompleted` or `VestingUpdated`."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(1)`."] + pub fn vest_other( &self, - maybe_next_score: ::core::option::Option< - runtime_types::sp_npos_elections::ElectionScore, - >, - ) -> ::subxt::tx::Payload { + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ElectionProviderMultiPhase", - "set_minimum_untrusted_score", - types::SetMinimumUntrustedScore { maybe_next_score }, + "Vesting", + "vest_other", + types::VestOther { target }, [ - 63u8, 101u8, 105u8, 146u8, 133u8, 162u8, 149u8, 112u8, 150u8, 219u8, - 183u8, 213u8, 234u8, 211u8, 144u8, 74u8, 106u8, 15u8, 62u8, 196u8, - 247u8, 49u8, 20u8, 48u8, 3u8, 105u8, 85u8, 46u8, 76u8, 4u8, 67u8, 81u8, + 164u8, 19u8, 93u8, 81u8, 235u8, 101u8, 18u8, 52u8, 187u8, 81u8, 243u8, + 216u8, 116u8, 84u8, 188u8, 135u8, 1u8, 241u8, 128u8, 90u8, 117u8, + 164u8, 111u8, 0u8, 251u8, 148u8, 250u8, 248u8, 102u8, 79u8, 165u8, + 175u8, ], ) } - #[doc = "Set a solution in the queue, to be handed out to the client of this pallet in the next"] - #[doc = "call to `ElectionProvider::elect`."] + #[doc = "Create a vested transfer."] #[doc = ""] - #[doc = "This can only be set by `T::ForceOrigin`, and only when the phase is `Emergency`."] + #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] - #[doc = "The solution is not checked for any feasibility and is assumed to be trustworthy, as any"] - #[doc = "feasibility check itself can in principle cause the election process to fail (due to"] - #[doc = "memory/weight constrains)."] - pub fn set_emergency_election_result( + #[doc = "- `target`: The account receiving the vested funds."] + #[doc = "- `schedule`: The vesting schedule attached to the transfer."] + #[doc = ""] + #[doc = "Emits `VestingCreated`."] + #[doc = ""] + #[doc = "NOTE: This will unlock all schedules through the current block."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(1)`."] + pub fn vested_transfer( &self, - supports: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::sp_npos_elections::Support<::subxt::utils::AccountId32>, - )>, - ) -> ::subxt::tx::Payload { + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, + >, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ElectionProviderMultiPhase", - "set_emergency_election_result", - types::SetEmergencyElectionResult { supports }, + "Vesting", + "vested_transfer", + types::VestedTransfer { target, schedule }, [ - 115u8, 255u8, 205u8, 58u8, 153u8, 1u8, 246u8, 8u8, 225u8, 36u8, 66u8, - 144u8, 250u8, 145u8, 70u8, 76u8, 54u8, 63u8, 251u8, 51u8, 214u8, 204u8, - 55u8, 112u8, 46u8, 228u8, 255u8, 250u8, 151u8, 5u8, 44u8, 133u8, + 135u8, 172u8, 56u8, 97u8, 45u8, 141u8, 93u8, 173u8, 111u8, 252u8, 75u8, + 246u8, 92u8, 181u8, 138u8, 87u8, 145u8, 174u8, 71u8, 108u8, 126u8, + 118u8, 49u8, 122u8, 249u8, 132u8, 19u8, 2u8, 132u8, 160u8, 247u8, + 195u8, ], ) } - #[doc = "Submit a solution for the signed phase."] + #[doc = "Force a vested transfer."] #[doc = ""] - #[doc = "The dispatch origin fo this call must be __signed__."] + #[doc = "The dispatch origin for this call must be _Root_."] #[doc = ""] - #[doc = "The solution is potentially queued, based on the claimed score and processed at the end"] - #[doc = "of the signed phase."] + #[doc = "- `source`: The account whose funds should be transferred."] + #[doc = "- `target`: The account that should be transferred the vested funds."] + #[doc = "- `schedule`: The vesting schedule attached to the transfer."] #[doc = ""] - #[doc = "A deposit is reserved and recorded for the solution. Based on the outcome, the solution"] - #[doc = "might be rewarded, slashed, or get all or a part of the deposit back."] - pub fn submit( + #[doc = "Emits `VestingCreated`."] + #[doc = ""] + #[doc = "NOTE: This will unlock all schedules through the current block."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(1)`."] + pub fn force_vested_transfer( &self, - raw_solution: runtime_types::pallet_election_provider_multi_phase::RawSolution< - runtime_types::polkadot_runtime::NposCompactSolution16, + source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, >, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ElectionProviderMultiPhase", - "submit", - types::Submit { - raw_solution: ::std::boxed::Box::new(raw_solution), + "Vesting", + "force_vested_transfer", + types::ForceVestedTransfer { + source, + target, + schedule, }, [ - 220u8, 167u8, 40u8, 47u8, 253u8, 244u8, 72u8, 124u8, 30u8, 123u8, - 127u8, 227u8, 2u8, 66u8, 119u8, 64u8, 211u8, 200u8, 210u8, 98u8, 248u8, - 132u8, 68u8, 25u8, 34u8, 182u8, 230u8, 225u8, 241u8, 58u8, 193u8, - 134u8, + 110u8, 142u8, 63u8, 148u8, 90u8, 229u8, 237u8, 183u8, 240u8, 237u8, + 242u8, 32u8, 88u8, 48u8, 220u8, 101u8, 210u8, 212u8, 27u8, 7u8, 186u8, + 98u8, 28u8, 197u8, 148u8, 140u8, 77u8, 59u8, 202u8, 166u8, 63u8, 97u8, ], ) } - #[doc = "Trigger the governance fallback."] + #[doc = "Merge two vesting schedules together, creating a new vesting schedule that unlocks over"] + #[doc = "the highest possible start and end blocks. If both schedules have already started the"] + #[doc = "current block will be used as the schedule start; with the caveat that if one schedule"] + #[doc = "is finished by the current block, the other will be treated as the new merged schedule,"] + #[doc = "unmodified."] #[doc = ""] - #[doc = "This can only be called when [`Phase::Emergency`] is enabled, as an alternative to"] - #[doc = "calling [`Call::set_emergency_election_result`]."] - pub fn governance_fallback( + #[doc = "NOTE: If `schedule1_index == schedule2_index` this is a no-op."] + #[doc = "NOTE: This will unlock all schedules through the current block prior to merging."] + #[doc = "NOTE: If both schedules have ended by the current block, no new schedule will be created"] + #[doc = "and both will be removed."] + #[doc = ""] + #[doc = "Merged schedule attributes:"] + #[doc = "- `starting_block`: `MAX(schedule1.starting_block, scheduled2.starting_block,"] + #[doc = " current_block)`."] + #[doc = "- `ending_block`: `MAX(schedule1.ending_block, schedule2.ending_block)`."] + #[doc = "- `locked`: `schedule1.locked_at(current_block) + schedule2.locked_at(current_block)`."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "- `schedule1_index`: index of the first schedule to merge."] + #[doc = "- `schedule2_index`: index of the second schedule to merge."] + pub fn merge_schedules( &self, - maybe_max_voters: ::core::option::Option<::core::primitive::u32>, - maybe_max_targets: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { + schedule1_index: ::core::primitive::u32, + schedule2_index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "ElectionProviderMultiPhase", - "governance_fallback", - types::GovernanceFallback { - maybe_max_voters, - maybe_max_targets, + "Vesting", + "merge_schedules", + types::MergeSchedules { + schedule1_index, + schedule2_index, }, [ - 206u8, 247u8, 76u8, 85u8, 7u8, 24u8, 231u8, 226u8, 192u8, 143u8, 43u8, - 67u8, 91u8, 202u8, 88u8, 176u8, 130u8, 1u8, 83u8, 229u8, 227u8, 200u8, - 179u8, 4u8, 113u8, 60u8, 99u8, 190u8, 53u8, 226u8, 142u8, 182u8, + 95u8, 255u8, 147u8, 12u8, 49u8, 25u8, 70u8, 112u8, 55u8, 154u8, 183u8, + 97u8, 56u8, 244u8, 148u8, 61u8, 107u8, 163u8, 220u8, 31u8, 153u8, 25u8, + 193u8, 251u8, 131u8, 26u8, 166u8, 157u8, 75u8, 4u8, 110u8, 125u8, ], ) } } } #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_election_provider_multi_phase::pallet::Event; + pub type Event = runtime_types::pallet_vesting::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -22959,77 +20047,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A solution was stored with the given compute."] - #[doc = ""] - #[doc = "The `origin` indicates the origin of the solution. If `origin` is `Some(AccountId)`,"] - #[doc = "the stored solution was submited in the signed phase by a miner with the `AccountId`."] - #[doc = "Otherwise, the solution was stored either during the unsigned phase or by"] - #[doc = "`T::ForceOrigin`. The `bool` is `true` when a previous solution was ejected to make"] - #[doc = "room for this one."] - pub struct SolutionStored { - pub compute: runtime_types::pallet_election_provider_multi_phase::ElectionCompute, - pub origin: ::core::option::Option<::subxt::utils::AccountId32>, - pub prev_ejected: ::core::primitive::bool, - } - impl ::subxt::events::StaticEvent for SolutionStored { - const PALLET: &'static str = "ElectionProviderMultiPhase"; - const EVENT: &'static str = "SolutionStored"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The election has been finalized, with the given computation and score."] - pub struct ElectionFinalized { - pub compute: runtime_types::pallet_election_provider_multi_phase::ElectionCompute, - pub score: runtime_types::sp_npos_elections::ElectionScore, - } - impl ::subxt::events::StaticEvent for ElectionFinalized { - const PALLET: &'static str = "ElectionProviderMultiPhase"; - const EVENT: &'static str = "ElectionFinalized"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An election failed."] - #[doc = ""] - #[doc = "Not much can be said about which computes failed in the process."] - pub struct ElectionFailed; - impl ::subxt::events::StaticEvent for ElectionFailed { - const PALLET: &'static str = "ElectionProviderMultiPhase"; - const EVENT: &'static str = "ElectionFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has been rewarded for their signed submission being finalized."] - pub struct Rewarded { + #[doc = "The amount vested has been updated. This could indicate a change in funds available."] + #[doc = "The balance given is the amount which is left unvested (and thus locked)."] + pub struct VestingUpdated { pub account: ::subxt::utils::AccountId32, - pub value: ::core::primitive::u128, + pub unvested: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for Rewarded { - const PALLET: &'static str = "ElectionProviderMultiPhase"; - const EVENT: &'static str = "Rewarded"; + impl ::subxt::events::StaticEvent for VestingUpdated { + const PALLET: &'static str = "Vesting"; + const EVENT: &'static str = "VestingUpdated"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -23041,342 +20067,94 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has been slashed for submitting an invalid signed submission."] - pub struct Slashed { + #[doc = "An \\[account\\] has become fully vested."] + pub struct VestingCompleted { pub account: ::subxt::utils::AccountId32, - pub value: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Slashed { - const PALLET: &'static str = "ElectionProviderMultiPhase"; - const EVENT: &'static str = "Slashed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "There was a phase transition in a given round."] - pub struct PhaseTransitioned { - pub from: runtime_types::pallet_election_provider_multi_phase::Phase< - ::core::primitive::u32, - >, - pub to: runtime_types::pallet_election_provider_multi_phase::Phase< - ::core::primitive::u32, - >, - pub round: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for PhaseTransitioned { - const PALLET: &'static str = "ElectionProviderMultiPhase"; - const EVENT: &'static str = "PhaseTransitioned"; + impl ::subxt::events::StaticEvent for VestingCompleted { + const PALLET: &'static str = "Vesting"; + const EVENT: &'static str = "VestingCompleted"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " Internal counter for the number of rounds."] - #[doc = ""] - #[doc = " This is useful for de-duplication of transactions submitted to the pool, and general"] - #[doc = " diagnostics of the pallet."] - #[doc = ""] - #[doc = " This is merely incremented once per every time that an upstream `elect` is called."] - pub fn round( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "Round", - vec![], - [ - 16u8, 49u8, 176u8, 52u8, 202u8, 111u8, 120u8, 8u8, 217u8, 96u8, 35u8, - 14u8, 233u8, 130u8, 47u8, 98u8, 34u8, 44u8, 166u8, 188u8, 199u8, 210u8, - 21u8, 19u8, 70u8, 96u8, 139u8, 8u8, 53u8, 82u8, 165u8, 239u8, - ], - ) - } - #[doc = " Current phase."] - pub fn current_phase( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_election_provider_multi_phase::Phase< - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "CurrentPhase", - vec![], - [ - 236u8, 101u8, 8u8, 52u8, 68u8, 240u8, 74u8, 159u8, 181u8, 53u8, 153u8, - 101u8, 228u8, 81u8, 96u8, 161u8, 34u8, 67u8, 35u8, 28u8, 121u8, 44u8, - 229u8, 45u8, 196u8, 87u8, 73u8, 125u8, 216u8, 245u8, 255u8, 15u8, - ], - ) - } - #[doc = " Current best solution, signed or unsigned, queued to be returned upon `elect`."] - pub fn queued_solution( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_election_provider_multi_phase::ReadySolution, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "QueuedSolution", - vec![], - [ - 11u8, 152u8, 13u8, 167u8, 204u8, 209u8, 171u8, 249u8, 59u8, 250u8, - 58u8, 152u8, 164u8, 121u8, 146u8, 112u8, 241u8, 16u8, 159u8, 251u8, - 209u8, 251u8, 114u8, 29u8, 188u8, 30u8, 84u8, 71u8, 136u8, 173u8, - 145u8, 236u8, - ], - ) - } - #[doc = " Snapshot data of the round."] - #[doc = ""] - #[doc = " This is created at the beginning of the signed phase and cleared upon calling `elect`."] - pub fn snapshot( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_election_provider_multi_phase::RoundSnapshot< - ::subxt::utils::AccountId32, - ( - ::subxt::utils::AccountId32, - ::core::primitive::u64, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - ), - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "Snapshot", - vec![], - [ - 239u8, 56u8, 191u8, 77u8, 150u8, 224u8, 248u8, 88u8, 132u8, 224u8, - 164u8, 83u8, 253u8, 36u8, 46u8, 156u8, 72u8, 152u8, 36u8, 206u8, 72u8, - 27u8, 226u8, 87u8, 146u8, 220u8, 93u8, 178u8, 26u8, 115u8, 232u8, 71u8, - ], - ) - } - #[doc = " Desired number of targets to elect for this round."] - #[doc = ""] - #[doc = " Only exists when [`Snapshot`] is present."] - pub fn desired_targets( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "DesiredTargets", - vec![], - [ - 16u8, 247u8, 4u8, 181u8, 93u8, 79u8, 12u8, 212u8, 146u8, 167u8, 80u8, - 58u8, 118u8, 52u8, 68u8, 87u8, 90u8, 140u8, 31u8, 210u8, 2u8, 116u8, - 220u8, 231u8, 115u8, 112u8, 118u8, 118u8, 68u8, 34u8, 151u8, 165u8, - ], - ) - } - #[doc = " The metadata of the [`RoundSnapshot`]"] - #[doc = ""] - #[doc = " Only exists when [`Snapshot`] is present."] - pub fn snapshot_metadata( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_election_provider_multi_phase::SolutionOrSnapshotSize, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "SnapshotMetadata", - vec![], - [ - 135u8, 122u8, 60u8, 75u8, 194u8, 240u8, 187u8, 96u8, 240u8, 203u8, - 192u8, 22u8, 117u8, 148u8, 118u8, 24u8, 240u8, 213u8, 94u8, 22u8, - 194u8, 47u8, 181u8, 245u8, 77u8, 149u8, 11u8, 251u8, 117u8, 220u8, - 205u8, 78u8, - ], - ) - } - #[doc = " The next index to be assigned to an incoming signed submission."] - #[doc = ""] - #[doc = " Every accepted submission is assigned a unique index; that index is bound to that particular"] - #[doc = " submission for the duration of the election. On election finalization, the next index is"] - #[doc = " reset to 0."] - #[doc = ""] - #[doc = " We can't just use `SignedSubmissionIndices.len()`, because that's a bounded set; past its"] - #[doc = " capacity, it will simply saturate. We can't just iterate over `SignedSubmissionsMap`,"] - #[doc = " because iteration is slow. Instead, we store the value here."] - pub fn signed_submission_next_index( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "SignedSubmissionNextIndex", - vec![], - [ - 242u8, 11u8, 157u8, 105u8, 96u8, 7u8, 31u8, 20u8, 51u8, 141u8, 182u8, - 180u8, 13u8, 172u8, 155u8, 59u8, 42u8, 238u8, 115u8, 8u8, 6u8, 137u8, - 45u8, 2u8, 123u8, 187u8, 53u8, 215u8, 19u8, 129u8, 54u8, 22u8, - ], - ) - } - #[doc = " A sorted, bounded vector of `(score, block_number, index)`, where each `index` points to a"] - #[doc = " value in `SignedSubmissions`."] - #[doc = ""] - #[doc = " We never need to process more than a single signed submission at a time. Signed submissions"] - #[doc = " can be quite large, so we're willing to pay the cost of multiple database accesses to access"] - #[doc = " them one at a time instead of reading and decoding all of them at once."] - pub fn signed_submission_indices( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - runtime_types::sp_npos_elections::ElectionScore, - ::core::primitive::u32, - ::core::primitive::u32, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "SignedSubmissionIndices", - vec![], - [ - 228u8, 166u8, 94u8, 248u8, 71u8, 26u8, 125u8, 81u8, 32u8, 22u8, 46u8, - 185u8, 209u8, 123u8, 46u8, 17u8, 152u8, 149u8, 222u8, 125u8, 112u8, - 230u8, 29u8, 177u8, 162u8, 214u8, 66u8, 38u8, 170u8, 121u8, 129u8, - 100u8, - ], - ) - } - #[doc = " Unchecked, signed solutions."] - #[doc = ""] - #[doc = " Together with `SubmissionIndices`, this stores a bounded set of `SignedSubmissions` while"] - #[doc = " allowing us to keep only a single one in memory at a time."] - #[doc = ""] - #[doc = " Twox note: the key of the map is an auto-incrementing index which users cannot inspect or"] - #[doc = " affect; we shouldn't need a cryptographically secure hasher."] - pub fn signed_submissions_map( + #[doc = " Information regarding the vesting of a given account."] + pub fn vesting( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_election_provider_multi_phase::signed::SignedSubmission< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - runtime_types::polkadot_runtime::NposCompactSolution16, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, + >, >, ::subxt::storage::address::Yes, (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "SignedSubmissionsMap", + "Vesting", + "Vesting", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 84u8, 65u8, 205u8, 191u8, 143u8, 246u8, 239u8, 27u8, 243u8, 54u8, - 250u8, 8u8, 125u8, 32u8, 241u8, 141u8, 210u8, 225u8, 56u8, 101u8, - 241u8, 52u8, 157u8, 29u8, 13u8, 155u8, 73u8, 132u8, 118u8, 53u8, 2u8, - 135u8, + 23u8, 209u8, 233u8, 126u8, 89u8, 156u8, 193u8, 204u8, 100u8, 90u8, + 14u8, 120u8, 36u8, 167u8, 148u8, 239u8, 179u8, 74u8, 207u8, 83u8, 54u8, + 77u8, 27u8, 135u8, 74u8, 31u8, 33u8, 11u8, 168u8, 239u8, 212u8, 36u8, ], ) } - #[doc = " Unchecked, signed solutions."] - #[doc = ""] - #[doc = " Together with `SubmissionIndices`, this stores a bounded set of `SignedSubmissions` while"] - #[doc = " allowing us to keep only a single one in memory at a time."] - #[doc = ""] - #[doc = " Twox note: the key of the map is an auto-incrementing index which users cannot inspect or"] - #[doc = " affect; we shouldn't need a cryptographically secure hasher."] - pub fn signed_submissions_map_root( + #[doc = " Information regarding the vesting of a given account."] + pub fn vesting_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_election_provider_multi_phase::signed::SignedSubmission< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - runtime_types::polkadot_runtime::NposCompactSolution16, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_vesting::vesting_info::VestingInfo< + ::core::primitive::u128, + ::core::primitive::u32, + >, >, (), (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "SignedSubmissionsMap", + "Vesting", + "Vesting", Vec::new(), [ - 84u8, 65u8, 205u8, 191u8, 143u8, 246u8, 239u8, 27u8, 243u8, 54u8, - 250u8, 8u8, 125u8, 32u8, 241u8, 141u8, 210u8, 225u8, 56u8, 101u8, - 241u8, 52u8, 157u8, 29u8, 13u8, 155u8, 73u8, 132u8, 118u8, 53u8, 2u8, - 135u8, + 23u8, 209u8, 233u8, 126u8, 89u8, 156u8, 193u8, 204u8, 100u8, 90u8, + 14u8, 120u8, 36u8, 167u8, 148u8, 239u8, 179u8, 74u8, 207u8, 83u8, 54u8, + 77u8, 27u8, 135u8, 74u8, 31u8, 33u8, 11u8, 168u8, 239u8, 212u8, 36u8, ], ) } - #[doc = " The minimum score that each 'untrusted' solution must attain in order to be considered"] - #[doc = " feasible."] + #[doc = " Storage version of the pallet."] #[doc = ""] - #[doc = " Can be set via `set_minimum_untrusted_score`."] - pub fn minimum_untrusted_score( + #[doc = " New networks start with latest version, as determined by the genesis build."] + pub fn storage_version( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_npos_elections::ElectionScore, + runtime_types::pallet_vesting::Releases, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), (), > { ::subxt::storage::address::Address::new_static( - "ElectionProviderMultiPhase", - "MinimumUntrustedScore", + "Vesting", + "StorageVersion", vec![], [ - 77u8, 235u8, 181u8, 45u8, 230u8, 12u8, 0u8, 179u8, 152u8, 38u8, 74u8, - 199u8, 47u8, 84u8, 85u8, 55u8, 171u8, 226u8, 217u8, 125u8, 17u8, 194u8, - 95u8, 157u8, 73u8, 245u8, 75u8, 130u8, 248u8, 7u8, 53u8, 226u8, + 50u8, 143u8, 26u8, 88u8, 129u8, 31u8, 61u8, 118u8, 19u8, 202u8, 119u8, + 160u8, 34u8, 219u8, 60u8, 57u8, 189u8, 66u8, 93u8, 239u8, 121u8, 114u8, + 241u8, 116u8, 0u8, 122u8, 232u8, 94u8, 189u8, 23u8, 45u8, 191u8, ], ) } @@ -23386,307 +20164,26 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " Duration of the unsigned phase."] - pub fn unsigned_phase( + #[doc = " The minimum amount transferred to call `vested_transfer`."] + pub fn min_vested_transfer( &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { + ) -> ::subxt::constants::Address<::core::primitive::u128> { ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "UnsignedPhase", + "Vesting", + "MinVestedTransfer", [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = " Duration of the signed phase."] - pub fn signed_phase(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedPhase", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The minimum amount of improvement to the solution score that defines a solution as"] - #[doc = " \"better\" in the Signed phase."] - pub fn better_signed_threshold( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "BetterSignedThreshold", - [ - 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, - 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, - 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, - ], - ) - } - #[doc = " The minimum amount of improvement to the solution score that defines a solution as"] - #[doc = " \"better\" in the Unsigned phase."] - pub fn better_unsigned_threshold( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "BetterUnsignedThreshold", - [ - 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, - 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, - 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, - ], - ) - } - #[doc = " The repeat threshold of the offchain worker."] - #[doc = ""] - #[doc = " For example, if it is 5, that means that at least 5 blocks will elapse between attempts"] - #[doc = " to submit the worker's solution."] - pub fn offchain_repeat( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "OffchainRepeat", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The priority of the unsigned transaction submitted in the unsigned-phase"] - pub fn miner_tx_priority( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MinerTxPriority", - [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, - ], - ) - } - #[doc = " Maximum number of signed submissions that can be queued."] - #[doc = ""] - #[doc = " It is best to avoid adjusting this during an election, as it impacts downstream data"] - #[doc = " structures. In particular, `SignedSubmissionIndices` is bounded on this value. If you"] - #[doc = " update this value during an election, you _must_ ensure that"] - #[doc = " `SignedSubmissionIndices.len()` is less than or equal to the new value. Otherwise,"] - #[doc = " attempts to submit new solutions may cause a runtime panic."] - pub fn signed_max_submissions( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedMaxSubmissions", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Maximum weight of a signed solution."] - #[doc = ""] - #[doc = " If [`Config::MinerConfig`] is being implemented to submit signed solutions (outside of"] - #[doc = " this pallet), then [`MinerConfig::solution_weight`] is used to compare against"] - #[doc = " this value."] - pub fn signed_max_weight( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedMaxWeight", - [ - 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, - 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, - 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, - 106u8, 76u8, - ], - ) - } - #[doc = " The maximum amount of unchecked solutions to refund the call fee for."] - pub fn signed_max_refunds( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedMaxRefunds", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Base reward for a signed solution"] - pub fn signed_reward_base( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedRewardBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Base deposit for a signed solution."] - pub fn signed_deposit_base( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedDepositBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Per-byte deposit for a signed solution."] - pub fn signed_deposit_byte( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedDepositByte", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Per-weight deposit for a signed solution."] - pub fn signed_deposit_weight( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "SignedDepositWeight", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum number of electing voters to put in the snapshot. At the moment, snapshots"] - #[doc = " are only over a single block, but once multi-block elections are introduced they will"] - #[doc = " take place over multiple blocks."] - pub fn max_electing_voters( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MaxElectingVoters", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of electable targets to put in the snapshot."] - pub fn max_electable_targets( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u16> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MaxElectableTargets", - [ - 116u8, 33u8, 2u8, 170u8, 181u8, 147u8, 171u8, 169u8, 167u8, 227u8, - 41u8, 144u8, 11u8, 236u8, 82u8, 100u8, 74u8, 60u8, 184u8, 72u8, 169u8, - 90u8, 208u8, 135u8, 15u8, 117u8, 10u8, 123u8, 128u8, 193u8, 29u8, 70u8, - ], - ) - } - #[doc = " The maximum number of winners that can be elected by this `ElectionProvider`"] - #[doc = " implementation."] - #[doc = ""] - #[doc = " Note: This must always be greater or equal to `T::DataProvider::desired_targets()`."] - pub fn max_winners(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MaxWinners", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - pub fn miner_max_length( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MinerMaxLength", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - pub fn miner_max_weight( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MinerMaxWeight", - [ - 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, - 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, - 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, - 106u8, 76u8, - ], - ) - } - pub fn miner_max_votes_per_voter( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MinerMaxVotesPerVoter", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - pub fn miner_max_winners( + pub fn max_vesting_schedules( &self, ) -> ::subxt::constants::Address<::core::primitive::u32> { ::subxt::constants::Address::new_static( - "ElectionProviderMultiPhase", - "MinerMaxWinners", + "Vesting", + "MaxVestingSchedules", [ 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, @@ -23698,11 +20195,11 @@ pub mod api { } } } - pub mod voter_list { + pub mod utility { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_bags_list::pallet::Error; + pub type Error = runtime_types::pallet_utility::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; @@ -23720,8 +20217,8 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Rebag { - pub dislocated: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub struct Batch { + pub calls: ::std::vec::Vec, } #[derive( :: subxt :: ext :: codec :: Decode, @@ -23733,347 +20230,246 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PutInFrontOf { - pub lighter: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub struct AsDerivative { + pub index: ::core::primitive::u16, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BatchAll { + pub calls: ::std::vec::Vec, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DispatchAs { + pub as_origin: ::std::boxed::Box, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceBatch { + pub calls: ::std::vec::Vec, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct WithWeight { + pub call: ::std::boxed::Box, + pub weight: runtime_types::sp_weights::weight_v2::Weight, } } pub struct TransactionApi; impl TransactionApi { - #[doc = "Declare that some `dislocated` account has, through rewards or penalties, sufficiently"] - #[doc = "changed its score that it should properly fall into a different bag than its current"] - #[doc = "one."] + #[doc = "Send a batch of dispatch calls."] #[doc = ""] - #[doc = "Anyone can call this function about any potentially dislocated account."] + #[doc = "May be called from any origin except `None`."] #[doc = ""] - #[doc = "Will always update the stored score of `dislocated` to the correct score, based on"] - #[doc = "`ScoreProvider`."] + #[doc = "- `calls`: The calls to be dispatched from the same origin. The number of call must not"] + #[doc = " exceed the constant: `batched_calls_limit` (available in constant metadata)."] #[doc = ""] - #[doc = "If `dislocated` does not exists, it returns an error."] - pub fn rebag( + #[doc = "If origin is root then the calls are dispatched without checking origin filter. (This"] + #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(C) where C is the number of calls to be batched."] + #[doc = ""] + #[doc = "This will return `Ok` in all circumstances. To determine the success of the batch, an"] + #[doc = "event is deposited. If a call failed and the batch was interrupted, then the"] + #[doc = "`BatchInterrupted` event is deposited, along with the number of successful calls made"] + #[doc = "and the error of the failed call. If all were successful, then the `BatchCompleted`"] + #[doc = "event is deposited."] + pub fn batch( &self, - dislocated: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + calls: ::std::vec::Vec, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "VoterList", - "rebag", - types::Rebag { dislocated }, + "Utility", + "batch", + types::Batch { calls }, [ - 35u8, 182u8, 31u8, 22u8, 190u8, 187u8, 31u8, 138u8, 60u8, 48u8, 236u8, - 16u8, 191u8, 143u8, 52u8, 110u8, 228u8, 43u8, 116u8, 13u8, 171u8, - 108u8, 112u8, 123u8, 252u8, 231u8, 132u8, 97u8, 195u8, 148u8, 252u8, - 241u8, + 221u8, 151u8, 56u8, 10u8, 237u8, 176u8, 153u8, 88u8, 29u8, 225u8, 27u8, + 231u8, 98u8, 222u8, 51u8, 94u8, 88u8, 16u8, 40u8, 253u8, 61u8, 35u8, + 70u8, 110u8, 15u8, 75u8, 102u8, 140u8, 125u8, 54u8, 223u8, 231u8, ], ) } - #[doc = "Move the caller's Id directly in front of `lighter`."] + #[doc = "Send a call through an indexed pseudonym of the sender."] #[doc = ""] - #[doc = "The dispatch origin for this call must be _Signed_ and can only be called by the Id of"] - #[doc = "the account going in front of `lighter`."] + #[doc = "Filter from origin are passed along. The call will be dispatched with an origin which"] + #[doc = "use the same filter as the origin of this call."] #[doc = ""] - #[doc = "Only works if"] - #[doc = "- both nodes are within the same bag,"] - #[doc = "- and `origin` has a greater `Score` than `lighter`."] - pub fn put_in_front_of( + #[doc = "NOTE: If you need to ensure that any account-based filtering is not honored (i.e."] + #[doc = "because you expect `proxy` to have been used prior in the call stack and you do not want"] + #[doc = "the call restrictions to apply to any sub-accounts), then use `as_multi_threshold_1`"] + #[doc = "in the Multisig pallet instead."] + #[doc = ""] + #[doc = "NOTE: Prior to version *12, this was called `as_limited_sub`."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + pub fn as_derivative( &self, - lighter: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + index: ::core::primitive::u16, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "VoterList", - "put_in_front_of", - types::PutInFrontOf { lighter }, + "Utility", + "as_derivative", + types::AsDerivative { + index, + call: ::std::boxed::Box::new(call), + }, [ - 184u8, 194u8, 39u8, 91u8, 28u8, 220u8, 76u8, 199u8, 64u8, 252u8, 233u8, - 241u8, 74u8, 19u8, 246u8, 190u8, 108u8, 227u8, 77u8, 162u8, 225u8, - 230u8, 101u8, 72u8, 159u8, 217u8, 133u8, 107u8, 84u8, 83u8, 81u8, - 227u8, + 154u8, 209u8, 156u8, 16u8, 183u8, 67u8, 69u8, 4u8, 187u8, 100u8, 27u8, + 221u8, 195u8, 187u8, 165u8, 6u8, 121u8, 94u8, 27u8, 111u8, 214u8, 91u8, + 83u8, 160u8, 242u8, 13u8, 236u8, 70u8, 155u8, 94u8, 78u8, 71u8, ], ) } - } - } - #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] - pub type Event = runtime_types::pallet_bags_list::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Moved an account from one bag to another."] - pub struct Rebagged { - pub who: ::subxt::utils::AccountId32, - pub from: ::core::primitive::u64, - pub to: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for Rebagged { - const PALLET: &'static str = "VoterList"; - const EVENT: &'static str = "Rebagged"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Updated the score of some account to the given amount."] - pub struct ScoreUpdated { - pub who: ::subxt::utils::AccountId32, - pub new_score: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for ScoreUpdated { - const PALLET: &'static str = "VoterList"; - const EVENT: &'static str = "ScoreUpdated"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " A single node, within some bag."] + #[doc = "Send a batch of dispatch calls and atomically execute them."] + #[doc = "The whole transaction will rollback and fail if any of the calls failed."] #[doc = ""] - #[doc = " Nodes store links forward and back within their respective bags."] - pub fn list_nodes( + #[doc = "May be called from any origin except `None`."] + #[doc = ""] + #[doc = "- `calls`: The calls to be dispatched from the same origin. The number of call must not"] + #[doc = " exceed the constant: `batched_calls_limit` (available in constant metadata)."] + #[doc = ""] + #[doc = "If origin is root then the calls are dispatched without checking origin filter. (This"] + #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(C) where C is the number of calls to be batched."] + pub fn batch_all( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bags_list::list::Node, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "VoterList", - "ListNodes", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + calls: ::std::vec::Vec, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Utility", + "batch_all", + types::BatchAll { calls }, [ - 176u8, 186u8, 93u8, 51u8, 100u8, 184u8, 240u8, 29u8, 70u8, 3u8, 117u8, - 47u8, 23u8, 66u8, 231u8, 234u8, 53u8, 8u8, 234u8, 175u8, 181u8, 8u8, - 161u8, 154u8, 48u8, 178u8, 147u8, 227u8, 122u8, 115u8, 57u8, 97u8, + 255u8, 107u8, 81u8, 108u8, 78u8, 19u8, 231u8, 220u8, 177u8, 177u8, + 28u8, 24u8, 100u8, 228u8, 227u8, 45u8, 3u8, 51u8, 132u8, 12u8, 48u8, + 158u8, 67u8, 201u8, 193u8, 126u8, 251u8, 177u8, 102u8, 251u8, 90u8, + 81u8, ], ) } - #[doc = " A single node, within some bag."] + #[doc = "Dispatches a function call with a provided origin."] #[doc = ""] - #[doc = " Nodes store links forward and back within their respective bags."] - pub fn list_nodes_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bags_list::list::Node, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "VoterList", - "ListNodes", - Vec::new(), - [ - 176u8, 186u8, 93u8, 51u8, 100u8, 184u8, 240u8, 29u8, 70u8, 3u8, 117u8, - 47u8, 23u8, 66u8, 231u8, 234u8, 53u8, 8u8, 234u8, 175u8, 181u8, 8u8, - 161u8, 154u8, 48u8, 178u8, 147u8, 227u8, 122u8, 115u8, 57u8, 97u8, - ], - ) - } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_list_nodes( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "VoterList", - "CounterForListNodes", - vec![], - [ - 156u8, 168u8, 97u8, 33u8, 84u8, 117u8, 220u8, 89u8, 62u8, 182u8, 24u8, - 88u8, 231u8, 244u8, 41u8, 19u8, 210u8, 131u8, 87u8, 0u8, 241u8, 230u8, - 160u8, 142u8, 128u8, 153u8, 83u8, 36u8, 88u8, 247u8, 70u8, 130u8, - ], - ) - } - #[doc = " A bag stored in storage."] + #[doc = "The dispatch origin for this call must be _Root_."] #[doc = ""] - #[doc = " Stores a `Bag` struct, which stores head and tail pointers to itself."] - pub fn list_bags( + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn dispatch_as( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u64>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bags_list::list::Bag, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "VoterList", - "ListBags", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + as_origin: runtime_types::polkadot_runtime::OriginCaller, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Utility", + "dispatch_as", + types::DispatchAs { + as_origin: ::std::boxed::Box::new(as_origin), + call: ::std::boxed::Box::new(call), + }, [ - 38u8, 86u8, 63u8, 92u8, 85u8, 59u8, 225u8, 244u8, 14u8, 155u8, 76u8, - 249u8, 153u8, 140u8, 179u8, 7u8, 96u8, 170u8, 236u8, 179u8, 4u8, 18u8, - 232u8, 146u8, 216u8, 51u8, 135u8, 116u8, 196u8, 117u8, 143u8, 153u8, + 74u8, 215u8, 136u8, 17u8, 87u8, 74u8, 107u8, 176u8, 229u8, 23u8, 109u8, + 233u8, 84u8, 229u8, 27u8, 35u8, 154u8, 93u8, 104u8, 222u8, 71u8, 167u8, + 39u8, 12u8, 235u8, 46u8, 204u8, 125u8, 67u8, 96u8, 236u8, 91u8, ], ) } - #[doc = " A bag stored in storage."] + #[doc = "Send a batch of dispatch calls."] + #[doc = "Unlike `batch`, it allows errors and won't interrupt."] #[doc = ""] - #[doc = " Stores a `Bag` struct, which stores head and tail pointers to itself."] - pub fn list_bags_root( + #[doc = "May be called from any origin except `None`."] + #[doc = ""] + #[doc = "- `calls`: The calls to be dispatched from the same origin. The number of call must not"] + #[doc = " exceed the constant: `batched_calls_limit` (available in constant metadata)."] + #[doc = ""] + #[doc = "If origin is root then the calls are dispatch without checking origin filter. (This"] + #[doc = "includes bypassing `frame_system::Config::BaseCallFilter`)."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(C) where C is the number of calls to be batched."] + pub fn force_batch( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bags_list::list::Bag, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "VoterList", - "ListBags", - Vec::new(), + calls: ::std::vec::Vec, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Utility", + "force_batch", + types::ForceBatch { calls }, [ - 38u8, 86u8, 63u8, 92u8, 85u8, 59u8, 225u8, 244u8, 14u8, 155u8, 76u8, - 249u8, 153u8, 140u8, 179u8, 7u8, 96u8, 170u8, 236u8, 179u8, 4u8, 18u8, - 232u8, 146u8, 216u8, 51u8, 135u8, 116u8, 196u8, 117u8, 143u8, 153u8, + 183u8, 158u8, 12u8, 76u8, 9u8, 251u8, 54u8, 89u8, 139u8, 70u8, 51u8, + 72u8, 181u8, 28u8, 110u8, 207u8, 211u8, 236u8, 224u8, 44u8, 104u8, + 231u8, 238u8, 141u8, 176u8, 194u8, 100u8, 217u8, 63u8, 127u8, 166u8, + 24u8, ], ) } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The list of thresholds separating the various bags."] - #[doc = ""] - #[doc = " Ids are separated into unsorted bags according to their score. This specifies the"] - #[doc = " thresholds separating the bags. An id's bag is the largest bag for which the id's score"] - #[doc = " is less than or equal to its upper threshold."] - #[doc = ""] - #[doc = " When ids are iterated, higher bags are iterated completely before lower bags. This means"] - #[doc = " that iteration is _semi-sorted_: ids of higher score tend to come before ids of lower"] - #[doc = " score, but peer ids within a particular bag are sorted in insertion order."] - #[doc = ""] - #[doc = " # Expressing the constant"] - #[doc = ""] - #[doc = " This constant must be sorted in strictly increasing order. Duplicate items are not"] - #[doc = " permitted."] - #[doc = ""] - #[doc = " There is an implied upper limit of `Score::MAX`; that value does not need to be"] - #[doc = " specified within the bag. For any two threshold lists, if one ends with"] - #[doc = " `Score::MAX`, the other one does not, and they are otherwise equal, the two"] - #[doc = " lists will behave identically."] - #[doc = ""] - #[doc = " # Calculation"] - #[doc = ""] - #[doc = " It is recommended to generate the set of thresholds in a geometric series, such that"] - #[doc = " there exists some constant ratio such that `threshold[k + 1] == (threshold[k] *"] - #[doc = " constant_ratio).max(threshold[k] + 1)` for all `k`."] - #[doc = ""] - #[doc = " The helpers in the `/utils/frame/generate-bags` module can simplify this calculation."] - #[doc = ""] - #[doc = " # Examples"] - #[doc = ""] - #[doc = " - If `BagThresholds::get().is_empty()`, then all ids are put into the same bag, and"] - #[doc = " iteration is strictly in insertion order."] - #[doc = " - If `BagThresholds::get().len() == 64`, and the thresholds are determined according to"] - #[doc = " the procedure given above, then the constant ratio is equal to 2."] - #[doc = " - If `BagThresholds::get().len() == 200`, and the thresholds are determined according to"] - #[doc = " the procedure given above, then the constant ratio is approximately equal to 1.248."] - #[doc = " - If the threshold list begins `[1, 2, 3, ...]`, then an id with score 0 or 1 will fall"] - #[doc = " into bag 0, an id with score 2 will fall into bag 1, etc."] + #[doc = "Dispatch a function call with a specified weight."] #[doc = ""] - #[doc = " # Migration"] + #[doc = "This function does not check the weight of the call, and instead allows the"] + #[doc = "Root origin to specify the weight of the call."] #[doc = ""] - #[doc = " In the event that this list ever changes, a copy of the old bags list must be retained."] - #[doc = " With that `List::migrate` can be called, which will perform the appropriate migration."] - pub fn bag_thresholds( + #[doc = "The dispatch origin for this call must be _Root_."] + pub fn with_weight( &self, - ) -> ::subxt::constants::Address<::std::vec::Vec<::core::primitive::u64>> - { - ::subxt::constants::Address::new_static( - "VoterList", - "BagThresholds", + call: runtime_types::polkadot_runtime::RuntimeCall, + weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Utility", + "with_weight", + types::WithWeight { + call: ::std::boxed::Box::new(call), + weight, + }, [ - 103u8, 102u8, 255u8, 165u8, 124u8, 54u8, 5u8, 172u8, 112u8, 234u8, - 25u8, 175u8, 178u8, 19u8, 251u8, 73u8, 91u8, 192u8, 227u8, 81u8, 249u8, - 45u8, 126u8, 116u8, 7u8, 37u8, 9u8, 200u8, 167u8, 182u8, 12u8, 131u8, + 206u8, 4u8, 190u8, 61u8, 107u8, 61u8, 249u8, 88u8, 255u8, 170u8, 65u8, + 96u8, 12u8, 54u8, 149u8, 75u8, 250u8, 153u8, 103u8, 142u8, 117u8, 64u8, + 45u8, 189u8, 129u8, 28u8, 143u8, 78u8, 53u8, 188u8, 178u8, 19u8, ], ) } } } - } - pub mod nomination_pools { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_nomination_pools::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_utility::pallet::Event; + pub mod events { use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Join { - #[codec(compact)] - pub amount: ::core::primitive::u128, - pub pool_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BondExtra { - pub extra: - runtime_types::pallet_nomination_pools::BondExtra<::core::primitive::u128>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimPayout; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -24084,201 +20480,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Unbond { - pub member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub unbonding_points: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PoolWithdrawUnbonded { - pub pool_id: ::core::primitive::u32, - pub num_slashing_spans: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WithdrawUnbonded { - pub member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub num_slashing_spans: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Create { - #[codec(compact)] - pub amount: ::core::primitive::u128, - pub root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CreateWithPoolId { - #[codec(compact)] - pub amount: ::core::primitive::u128, - pub root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub pool_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Nominate { - pub pool_id: ::core::primitive::u32, - pub validators: ::std::vec::Vec<::subxt::utils::AccountId32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetState { - pub pool_id: ::core::primitive::u32, - pub state: runtime_types::pallet_nomination_pools::PoolState, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMetadata { - pub pool_id: ::core::primitive::u32, - pub metadata: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetConfigs { - pub min_join_bond: - runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u128>, - pub min_create_bond: - runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u128>, - pub max_pools: - runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u32>, - pub max_members: - runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u32>, - pub max_members_per_pool: - runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u32>, - pub global_max_commission: runtime_types::pallet_nomination_pools::ConfigOp< - runtime_types::sp_arithmetic::per_things::Perbill, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UpdateRoles { - pub pool_id: ::core::primitive::u32, - pub new_root: - runtime_types::pallet_nomination_pools::ConfigOp<::subxt::utils::AccountId32>, - pub new_nominator: - runtime_types::pallet_nomination_pools::ConfigOp<::subxt::utils::AccountId32>, - pub new_bouncer: - runtime_types::pallet_nomination_pools::ConfigOp<::subxt::utils::AccountId32>, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Chill { - pub pool_id: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BondExtraOther { - pub member: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub extra: - runtime_types::pallet_nomination_pools::BondExtra<::core::primitive::u128>, + #[doc = "Batch of dispatches did not complete fully. Index of first failing dispatch given, as"] + #[doc = "well as the error."] + pub struct BatchInterrupted { + pub index: ::core::primitive::u32, + pub error: runtime_types::sp_runtime::DispatchError, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetClaimPermission { - pub permission: runtime_types::pallet_nomination_pools::ClaimPermission, + impl ::subxt::events::StaticEvent for BatchInterrupted { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "BatchInterrupted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -24290,8 +20500,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimPayoutOther { - pub other: ::subxt::utils::AccountId32, + #[doc = "Batch of dispatches completed fully with no error."] + pub struct BatchCompleted; + impl ::subxt::events::StaticEvent for BatchCompleted { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "BatchCompleted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -24303,12 +20516,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCommission { - pub pool_id: ::core::primitive::u32, - pub new_commission: ::core::option::Option<( - runtime_types::sp_arithmetic::per_things::Perbill, - ::subxt::utils::AccountId32, - )>, + #[doc = "Batch of dispatches completed but has errors."] + pub struct BatchCompletedWithErrors; + impl ::subxt::events::StaticEvent for BatchCompletedWithErrors { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "BatchCompletedWithErrors"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -24320,9 +20532,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCommissionMax { - pub pool_id: ::core::primitive::u32, - pub max_commission: runtime_types::sp_arithmetic::per_things::Perbill, + #[doc = "A single item within a Batch of dispatches has completed with no error."] + pub struct ItemCompleted; + impl ::subxt::events::StaticEvent for ItemCompleted { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "ItemCompleted"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -24334,25 +20548,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCommissionChangeRate { - pub pool_id: ::core::primitive::u32, - pub change_rate: runtime_types::pallet_nomination_pools::CommissionChangeRate< - ::core::primitive::u32, - >, + #[doc = "A single item within a Batch of dispatches has completed with error."] + pub struct ItemFailed { + pub error: runtime_types::sp_runtime::DispatchError, } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimCommission { - pub pool_id: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for ItemFailed { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "ItemFailed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -24364,717 +20566,704 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BondExtraOther { - pub member: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub extra: - runtime_types::pallet_nomination_pools::BondExtra<::core::primitive::u128>, + #[doc = "A call was dispatched."] + pub struct DispatchedAs { + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetClaimPermission { - pub permission: runtime_types::pallet_nomination_pools::ClaimPermission, + impl ::subxt::events::StaticEvent for DispatchedAs { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "DispatchedAs"; } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimPayoutOther { - pub other: ::subxt::utils::AccountId32, + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The limit on the number of batched calls."] + pub fn batched_calls_limit( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Utility", + "batched_calls_limit", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCommission { - pub pool_id: ::core::primitive::u32, - pub new_commission: ::core::option::Option<( - runtime_types::sp_arithmetic::per_things::Perbill, - ::subxt::utils::AccountId32, - )>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCommissionMax { - pub pool_id: ::core::primitive::u32, - pub max_commission: runtime_types::sp_arithmetic::per_things::Perbill, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCommissionChangeRate { - pub pool_id: ::core::primitive::u32, - pub change_rate: runtime_types::pallet_nomination_pools::CommissionChangeRate< - ::core::primitive::u32, - >, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimCommission { - pub pool_id: ::core::primitive::u32, + } + } + pub mod identity { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_identity::pallet::Error; + #[doc = "Identity pallet declaration."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddRegistrar { + pub account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetIdentity { + pub info: + ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetSubs { + pub subs: ::std::vec::Vec<( + ::subxt::utils::AccountId32, + runtime_types::pallet_identity::types::Data, + )>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClearIdentity; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RequestJudgement { + #[codec(compact)] + pub reg_index: ::core::primitive::u32, + #[codec(compact)] + pub max_fee: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelRequest { + pub reg_index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetFee { + #[codec(compact)] + pub index: ::core::primitive::u32, + #[codec(compact)] + pub fee: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetAccountId { + #[codec(compact)] + pub index: ::core::primitive::u32, + pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetFields { + #[codec(compact)] + pub index: ::core::primitive::u32, + pub fields: runtime_types::pallet_identity::types::BitFlags< + runtime_types::pallet_identity::types::IdentityField, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProvideJudgement { + #[codec(compact)] + pub reg_index: ::core::primitive::u32, + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub judgement: + runtime_types::pallet_identity::types::Judgement<::core::primitive::u128>, + pub identity: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct KillIdentity { + pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddSub { + pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub data: runtime_types::pallet_identity::types::Data, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RenameSub { + pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub data: runtime_types::pallet_identity::types::Data, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveSub { + pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QuitSub; } pub struct TransactionApi; impl TransactionApi { - #[doc = "Stake funds with a pool. The amount to bond is transferred from the member to the"] - #[doc = "pools account and immediately increases the pools bond."] + #[doc = "Add a registrar to the system."] #[doc = ""] - #[doc = "# Note"] + #[doc = "The dispatch origin for this call must be `T::RegistrarOrigin`."] #[doc = ""] - #[doc = "* An account can only be a member of a single pool."] - #[doc = "* An account cannot join the same pool multiple times."] - #[doc = "* This call will *not* dust the member account, so the member must have at least"] - #[doc = " `existential deposit + amount` in their account."] - #[doc = "* Only a pool with [`PoolState::Open`] can be joined"] - pub fn join( + #[doc = "- `account`: the account of the registrar."] + #[doc = ""] + #[doc = "Emits `RegistrarAdded` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(R)` where `R` registrar-count (governance-bounded and code-bounded)."] + pub fn add_registrar( &self, - amount: ::core::primitive::u128, - pool_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "join", - types::Join { amount, pool_id }, + "Identity", + "add_registrar", + types::AddRegistrar { account }, [ - 205u8, 66u8, 42u8, 72u8, 146u8, 148u8, 119u8, 162u8, 101u8, 183u8, - 46u8, 176u8, 221u8, 204u8, 197u8, 20u8, 75u8, 226u8, 29u8, 118u8, - 208u8, 60u8, 192u8, 247u8, 222u8, 100u8, 69u8, 80u8, 172u8, 13u8, 69u8, - 250u8, + 157u8, 232u8, 252u8, 190u8, 203u8, 233u8, 127u8, 63u8, 111u8, 16u8, + 118u8, 200u8, 31u8, 234u8, 144u8, 111u8, 161u8, 224u8, 217u8, 86u8, + 179u8, 254u8, 162u8, 212u8, 248u8, 8u8, 125u8, 89u8, 23u8, 195u8, 4u8, + 231u8, ], ) } - #[doc = "Bond `extra` more funds from `origin` into the pool to which they already belong."] + #[doc = "Set an account's identity information and reserve the appropriate deposit."] #[doc = ""] - #[doc = "Additional funds can come from either the free balance of the account, of from the"] - #[doc = "accumulated rewards, see [`BondExtra`]."] + #[doc = "If the account already has identity information, the deposit is taken as part payment"] + #[doc = "for the new deposit."] #[doc = ""] - #[doc = "Bonding extra funds implies an automatic payout of all pending rewards as well."] - #[doc = "See `bond_extra_other` to bond pending rewards of `other` members."] - pub fn bond_extra( + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "- `info`: The identity information."] + #[doc = ""] + #[doc = "Emits `IdentitySet` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(X + X' + R)`"] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)"] + #[doc = " - where `R` judgements-count (registrar-count-bounded)"] + pub fn set_identity( &self, - extra: runtime_types::pallet_nomination_pools::BondExtra< - ::core::primitive::u128, - >, - ) -> ::subxt::tx::Payload { + info: runtime_types::pallet_identity::types::IdentityInfo, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "bond_extra", - types::BondExtra { extra }, + "Identity", + "set_identity", + types::SetIdentity { + info: ::std::boxed::Box::new(info), + }, [ - 50u8, 72u8, 181u8, 216u8, 249u8, 27u8, 250u8, 177u8, 253u8, 22u8, - 240u8, 100u8, 184u8, 202u8, 197u8, 34u8, 21u8, 188u8, 248u8, 191u8, - 11u8, 10u8, 236u8, 161u8, 168u8, 37u8, 38u8, 238u8, 61u8, 183u8, 86u8, - 55u8, + 130u8, 89u8, 118u8, 6u8, 134u8, 166u8, 35u8, 192u8, 73u8, 6u8, 171u8, + 20u8, 225u8, 255u8, 152u8, 142u8, 111u8, 8u8, 206u8, 200u8, 64u8, 52u8, + 110u8, 123u8, 42u8, 101u8, 191u8, 242u8, 133u8, 139u8, 154u8, 205u8, ], ) } - #[doc = "A bonded member can use this to claim their payout based on the rewards that the pool"] - #[doc = "has accumulated since their last claimed payout (OR since joining if this is their first"] - #[doc = "time claiming rewards). The payout will be transferred to the member's account."] + #[doc = "Set the sub-accounts of the sender."] #[doc = ""] - #[doc = "The member will earn rewards pro rata based on the members stake vs the sum of the"] - #[doc = "members in the pools stake. Rewards do not \"expire\"."] + #[doc = "Payment: Any aggregate balance reserved by previous `set_subs` calls will be returned"] + #[doc = "and an amount `SubAccountDeposit` will be reserved for each item in `subs`."] #[doc = ""] - #[doc = "See `claim_payout_other` to caim rewards on bahalf of some `other` pool member."] - pub fn claim_payout(&self) -> ::subxt::tx::Payload { + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] + #[doc = "identity."] + #[doc = ""] + #[doc = "- `subs`: The identity's (new) sub-accounts."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(P + S)`"] + #[doc = " - where `P` old-subs-count (hard- and deposit-bounded)."] + #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] + pub fn set_subs( + &self, + subs: ::std::vec::Vec<( + ::subxt::utils::AccountId32, + runtime_types::pallet_identity::types::Data, + )>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "claim_payout", - types::ClaimPayout {}, + "Identity", + "set_subs", + types::SetSubs { subs }, [ - 128u8, 58u8, 138u8, 55u8, 64u8, 16u8, 129u8, 25u8, 211u8, 229u8, 193u8, - 115u8, 47u8, 45u8, 155u8, 221u8, 218u8, 1u8, 222u8, 5u8, 236u8, 32u8, - 88u8, 0u8, 198u8, 72u8, 196u8, 181u8, 104u8, 16u8, 212u8, 29u8, + 177u8, 219u8, 84u8, 183u8, 5u8, 32u8, 192u8, 82u8, 174u8, 68u8, 198u8, + 224u8, 56u8, 85u8, 134u8, 171u8, 30u8, 132u8, 140u8, 236u8, 117u8, + 24u8, 150u8, 218u8, 146u8, 194u8, 144u8, 92u8, 103u8, 206u8, 46u8, + 90u8, ], ) } - #[doc = "Unbond up to `unbonding_points` of the `member_account`'s funds from the pool. It"] - #[doc = "implicitly collects the rewards one last time, since not doing so would mean some"] - #[doc = "rewards would be forfeited."] - #[doc = ""] - #[doc = "Under certain conditions, this call can be dispatched permissionlessly (i.e. by any"] - #[doc = "account)."] - #[doc = ""] - #[doc = "# Conditions for a permissionless dispatch."] - #[doc = ""] - #[doc = "* The pool is blocked and the caller is either the root or bouncer. This is refereed to"] - #[doc = " as a kick."] - #[doc = "* The pool is destroying and the member is not the depositor."] - #[doc = "* The pool is destroying, the member is the depositor and no other members are in the"] - #[doc = " pool."] + #[doc = "Clear an account's identity info and all sub-accounts and return all deposits."] #[doc = ""] - #[doc = "## Conditions for permissioned dispatch (i.e. the caller is also the"] - #[doc = "`member_account`):"] + #[doc = "Payment: All reserved balances on the account are returned."] #[doc = ""] - #[doc = "* The caller is not the depositor."] - #[doc = "* The caller is the depositor, the pool is destroying and no other members are in the"] - #[doc = " pool."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] + #[doc = "identity."] #[doc = ""] - #[doc = "# Note"] + #[doc = "Emits `IdentityCleared` if successful."] #[doc = ""] - #[doc = "If there are too many unlocking chunks to unbond with the pool account,"] - #[doc = "[`Call::pool_withdraw_unbonded`] can be called to try and minimize unlocking chunks."] - #[doc = "The [`StakingInterface::unbond`] will implicitly call [`Call::pool_withdraw_unbonded`]"] - #[doc = "to try to free chunks if necessary (ie. if unbound was called and no unlocking chunks"] - #[doc = "are available). However, it may not be possible to release the current unlocking chunks,"] - #[doc = "in which case, the result of this call will likely be the `NoMoreChunks` error from the"] - #[doc = "staking system."] - pub fn unbond( - &self, - member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - unbonding_points: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { + #[doc = "## Complexity"] + #[doc = "- `O(R + S + X)`"] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] + pub fn clear_identity(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "unbond", - types::Unbond { - member_account, - unbonding_points, - }, + "Identity", + "clear_identity", + types::ClearIdentity {}, [ - 78u8, 15u8, 37u8, 18u8, 129u8, 63u8, 31u8, 3u8, 68u8, 10u8, 12u8, 12u8, - 166u8, 179u8, 38u8, 232u8, 97u8, 1u8, 83u8, 53u8, 26u8, 59u8, 42u8, - 219u8, 176u8, 246u8, 169u8, 28u8, 35u8, 67u8, 139u8, 81u8, + 75u8, 44u8, 74u8, 122u8, 149u8, 202u8, 114u8, 230u8, 0u8, 255u8, 140u8, + 122u8, 14u8, 196u8, 205u8, 249u8, 220u8, 94u8, 216u8, 34u8, 63u8, 14u8, + 8u8, 205u8, 74u8, 23u8, 181u8, 129u8, 252u8, 110u8, 231u8, 114u8, ], ) } - #[doc = "Call `withdraw_unbonded` for the pools account. This call can be made by any account."] + #[doc = "Request a judgement from a registrar."] #[doc = ""] - #[doc = "This is useful if their are too many unlocking chunks to call `unbond`, and some"] - #[doc = "can be cleared by withdrawing. In the case there are too many unlocking chunks, the user"] - #[doc = "would probably see an error like `NoMoreChunks` emitted from the staking system when"] - #[doc = "they attempt to unbond."] - pub fn pool_withdraw_unbonded( + #[doc = "Payment: At most `max_fee` will be reserved for payment to the registrar if judgement"] + #[doc = "given."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a"] + #[doc = "registered identity."] + #[doc = ""] + #[doc = "- `reg_index`: The index of the registrar whose judgement is requested."] + #[doc = "- `max_fee`: The maximum fee that may be paid. This should just be auto-populated as:"] + #[doc = ""] + #[doc = "```nocompile"] + #[doc = "Self::registrars().get(reg_index).unwrap().fee"] + #[doc = "```"] + #[doc = ""] + #[doc = "Emits `JudgementRequested` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(R + X)`."] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] + pub fn request_judgement( &self, - pool_id: ::core::primitive::u32, - num_slashing_spans: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + reg_index: ::core::primitive::u32, + max_fee: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "pool_withdraw_unbonded", - types::PoolWithdrawUnbonded { - pool_id, - num_slashing_spans, - }, + "Identity", + "request_judgement", + types::RequestJudgement { reg_index, max_fee }, [ - 152u8, 245u8, 131u8, 247u8, 106u8, 214u8, 154u8, 8u8, 7u8, 210u8, - 149u8, 218u8, 118u8, 46u8, 242u8, 182u8, 191u8, 119u8, 28u8, 199u8, - 36u8, 49u8, 219u8, 123u8, 58u8, 203u8, 211u8, 226u8, 217u8, 36u8, 56u8, - 0u8, + 186u8, 149u8, 61u8, 54u8, 159u8, 194u8, 77u8, 161u8, 220u8, 157u8, 3u8, + 216u8, 23u8, 105u8, 119u8, 76u8, 144u8, 198u8, 157u8, 45u8, 235u8, + 139u8, 87u8, 82u8, 81u8, 12u8, 25u8, 134u8, 225u8, 92u8, 182u8, 101u8, ], ) } - #[doc = "Withdraw unbonded funds from `member_account`. If no bonded funds can be unbonded, an"] - #[doc = "error is returned."] - #[doc = ""] - #[doc = "Under certain conditions, this call can be dispatched permissionlessly (i.e. by any"] - #[doc = "account)."] + #[doc = "Cancel a previous request."] #[doc = ""] - #[doc = "# Conditions for a permissionless dispatch"] + #[doc = "Payment: A previously reserved deposit is returned on success."] #[doc = ""] - #[doc = "* The pool is in destroy mode and the target is not the depositor."] - #[doc = "* The target is the depositor and they are the only member in the sub pools."] - #[doc = "* The pool is blocked and the caller is either the root or bouncer."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a"] + #[doc = "registered identity."] #[doc = ""] - #[doc = "# Conditions for permissioned dispatch"] + #[doc = "- `reg_index`: The index of the registrar whose judgement is no longer requested."] #[doc = ""] - #[doc = "* The caller is the target and they are not the depositor."] + #[doc = "Emits `JudgementUnrequested` if successful."] #[doc = ""] - #[doc = "# Note"] - #[doc = ""] - #[doc = "If the target is the depositor, the pool will be destroyed."] - pub fn withdraw_unbonded( + #[doc = "## Complexity"] + #[doc = "- `O(R + X)`."] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] + pub fn cancel_request( &self, - member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - num_slashing_spans: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { + reg_index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "withdraw_unbonded", - types::WithdrawUnbonded { - member_account, - num_slashing_spans, - }, + "Identity", + "cancel_request", + types::CancelRequest { reg_index }, [ - 61u8, 216u8, 214u8, 166u8, 59u8, 42u8, 186u8, 141u8, 47u8, 50u8, 135u8, - 236u8, 166u8, 88u8, 90u8, 244u8, 57u8, 106u8, 193u8, 211u8, 215u8, - 131u8, 203u8, 33u8, 195u8, 120u8, 213u8, 94u8, 213u8, 66u8, 79u8, - 140u8, + 83u8, 180u8, 239u8, 126u8, 32u8, 51u8, 17u8, 20u8, 180u8, 3u8, 59u8, + 96u8, 24u8, 32u8, 136u8, 92u8, 58u8, 254u8, 68u8, 70u8, 50u8, 11u8, + 51u8, 91u8, 180u8, 79u8, 81u8, 84u8, 216u8, 138u8, 6u8, 215u8, ], ) } - #[doc = "Create a new delegation pool."] - #[doc = ""] - #[doc = "# Arguments"] + #[doc = "Set the fee required for a judgement to be requested from a registrar."] #[doc = ""] - #[doc = "* `amount` - The amount of funds to delegate to the pool. This also acts of a sort of"] - #[doc = " deposit since the pools creator cannot fully unbond funds until the pool is being"] - #[doc = " destroyed."] - #[doc = "* `index` - A disambiguation index for creating the account. Likely only useful when"] - #[doc = " creating multiple pools in the same extrinsic."] - #[doc = "* `root` - The account to set as [`PoolRoles::root`]."] - #[doc = "* `nominator` - The account to set as the [`PoolRoles::nominator`]."] - #[doc = "* `bouncer` - The account to set as the [`PoolRoles::bouncer`]."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] + #[doc = "of the registrar whose index is `index`."] #[doc = ""] - #[doc = "# Note"] + #[doc = "- `index`: the index of the registrar whose fee is to be set."] + #[doc = "- `fee`: the new fee."] #[doc = ""] - #[doc = "In addition to `amount`, the caller will transfer the existential deposit; so the caller"] - #[doc = "needs at have at least `amount + existential_deposit` transferrable."] - pub fn create( + #[doc = "## Complexity"] + #[doc = "- `O(R)`."] + #[doc = " - where `R` registrar-count (governance-bounded)."] + pub fn set_fee( &self, - amount: ::core::primitive::u128, - root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { + index: ::core::primitive::u32, + fee: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "create", - types::Create { - amount, - root, - nominator, - bouncer, - }, + "Identity", + "set_fee", + types::SetFee { index, fee }, [ - 182u8, 114u8, 123u8, 215u8, 240u8, 217u8, 208u8, 165u8, 237u8, 1u8, - 215u8, 183u8, 218u8, 125u8, 71u8, 229u8, 68u8, 142u8, 60u8, 76u8, - 101u8, 242u8, 218u8, 61u8, 165u8, 203u8, 233u8, 241u8, 130u8, 13u8, - 76u8, 214u8, + 21u8, 157u8, 123u8, 182u8, 160u8, 190u8, 117u8, 37u8, 136u8, 133u8, + 104u8, 234u8, 31u8, 145u8, 115u8, 154u8, 125u8, 40u8, 2u8, 87u8, 118u8, + 56u8, 247u8, 73u8, 89u8, 0u8, 251u8, 3u8, 58u8, 105u8, 239u8, 211u8, ], ) } - #[doc = "Create a new delegation pool with a previously used pool id"] - #[doc = ""] - #[doc = "# Arguments"] + #[doc = "Change the account associated with a registrar."] #[doc = ""] - #[doc = "same as `create` with the inclusion of"] - #[doc = "* `pool_id` - `A valid PoolId."] - pub fn create_with_pool_id( - &self, - amount: ::core::primitive::u128, - root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pool_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NominationPools", - "create_with_pool_id", - types::CreateWithPoolId { - amount, - root, - nominator, - bouncer, - pool_id, - }, - [ - 76u8, 77u8, 158u8, 172u8, 4u8, 68u8, 53u8, 249u8, 156u8, 91u8, 19u8, - 151u8, 58u8, 199u8, 179u8, 0u8, 186u8, 152u8, 157u8, 28u8, 65u8, 227u8, - 133u8, 101u8, 102u8, 205u8, 68u8, 245u8, 104u8, 151u8, 146u8, 76u8, - ], - ) - } - #[doc = "Nominate on behalf of the pool."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] + #[doc = "of the registrar whose index is `index`."] #[doc = ""] - #[doc = "The dispatch origin of this call must be signed by the pool nominator or the pool"] - #[doc = "root role."] + #[doc = "- `index`: the index of the registrar whose fee is to be set."] + #[doc = "- `new`: the new account ID."] #[doc = ""] - #[doc = "This directly forward the call to the staking pallet, on behalf of the pool bonded"] - #[doc = "account."] - pub fn nominate( + #[doc = "## Complexity"] + #[doc = "- `O(R)`."] + #[doc = " - where `R` registrar-count (governance-bounded)."] + pub fn set_account_id( &self, - pool_id: ::core::primitive::u32, - validators: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { + index: ::core::primitive::u32, + new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "nominate", - types::Nominate { - pool_id, - validators, - }, + "Identity", + "set_account_id", + types::SetAccountId { index, new }, [ - 10u8, 235u8, 64u8, 157u8, 36u8, 249u8, 186u8, 27u8, 79u8, 172u8, 25u8, - 3u8, 203u8, 19u8, 192u8, 182u8, 36u8, 103u8, 13u8, 20u8, 89u8, 140u8, - 159u8, 4u8, 132u8, 242u8, 192u8, 146u8, 55u8, 251u8, 216u8, 255u8, + 13u8, 91u8, 36u8, 7u8, 88u8, 64u8, 151u8, 104u8, 94u8, 174u8, 195u8, + 99u8, 97u8, 181u8, 236u8, 251u8, 26u8, 236u8, 234u8, 40u8, 183u8, 38u8, + 220u8, 216u8, 48u8, 115u8, 7u8, 230u8, 216u8, 28u8, 123u8, 11u8, ], ) } - #[doc = "Set a new state for the pool."] + #[doc = "Set the field information for a registrar."] #[doc = ""] - #[doc = "If a pool is already in the `Destroying` state, then under no condition can its state"] - #[doc = "change again."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] + #[doc = "of the registrar whose index is `index`."] #[doc = ""] - #[doc = "The dispatch origin of this call must be either:"] + #[doc = "- `index`: the index of the registrar whose fee is to be set."] + #[doc = "- `fields`: the fields that the registrar concerns themselves with."] #[doc = ""] - #[doc = "1. signed by the bouncer, or the root role of the pool,"] - #[doc = "2. if the pool conditions to be open are NOT met (as described by `ok_to_be_open`), and"] - #[doc = " then the state of the pool can be permissionlessly changed to `Destroying`."] - pub fn set_state( + #[doc = "## Complexity"] + #[doc = "- `O(R)`."] + #[doc = " - where `R` registrar-count (governance-bounded)."] + pub fn set_fields( &self, - pool_id: ::core::primitive::u32, - state: runtime_types::pallet_nomination_pools::PoolState, - ) -> ::subxt::tx::Payload { + index: ::core::primitive::u32, + fields: runtime_types::pallet_identity::types::BitFlags< + runtime_types::pallet_identity::types::IdentityField, + >, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "set_state", - types::SetState { pool_id, state }, + "Identity", + "set_fields", + types::SetFields { index, fields }, [ - 104u8, 40u8, 213u8, 88u8, 159u8, 115u8, 35u8, 249u8, 78u8, 180u8, 99u8, - 1u8, 225u8, 218u8, 192u8, 151u8, 25u8, 194u8, 192u8, 187u8, 39u8, - 170u8, 212u8, 125u8, 75u8, 250u8, 248u8, 175u8, 159u8, 161u8, 151u8, - 162u8, + 50u8, 196u8, 179u8, 71u8, 66u8, 65u8, 235u8, 7u8, 51u8, 14u8, 81u8, + 173u8, 201u8, 58u8, 6u8, 151u8, 174u8, 245u8, 102u8, 184u8, 28u8, 84u8, + 125u8, 93u8, 126u8, 134u8, 92u8, 203u8, 200u8, 129u8, 240u8, 252u8, ], ) } - #[doc = "Set a new metadata for the pool."] + #[doc = "Provide a judgement for an account's identity."] #[doc = ""] - #[doc = "The dispatch origin of this call must be signed by the bouncer, or the root role of the"] - #[doc = "pool."] - pub fn set_metadata( - &self, - pool_id: ::core::primitive::u32, - metadata: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NominationPools", - "set_metadata", - types::SetMetadata { pool_id, metadata }, - [ - 156u8, 81u8, 170u8, 161u8, 34u8, 100u8, 183u8, 174u8, 5u8, 81u8, 31u8, - 76u8, 12u8, 42u8, 77u8, 1u8, 6u8, 26u8, 168u8, 7u8, 8u8, 115u8, 158u8, - 151u8, 30u8, 211u8, 52u8, 177u8, 234u8, 87u8, 125u8, 127u8, - ], - ) - } - #[doc = "Update configurations for the nomination pools. The origin for this call must be"] - #[doc = "Root."] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must be the account"] + #[doc = "of the registrar whose index is `reg_index`."] #[doc = ""] - #[doc = "# Arguments"] + #[doc = "- `reg_index`: the index of the registrar whose judgement is being made."] + #[doc = "- `target`: the account whose identity the judgement is upon. This must be an account"] + #[doc = " with a registered identity."] + #[doc = "- `judgement`: the judgement of the registrar of index `reg_index` about `target`."] + #[doc = "- `identity`: The hash of the [`IdentityInfo`] for that the judgement is provided."] #[doc = ""] - #[doc = "* `min_join_bond` - Set [`MinJoinBond`]."] - #[doc = "* `min_create_bond` - Set [`MinCreateBond`]."] - #[doc = "* `max_pools` - Set [`MaxPools`]."] - #[doc = "* `max_members` - Set [`MaxPoolMembers`]."] - #[doc = "* `max_members_per_pool` - Set [`MaxPoolMembersPerPool`]."] - #[doc = "* `global_max_commission` - Set [`GlobalMaxCommission`]."] - pub fn set_configs( + #[doc = "Emits `JudgementGiven` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(R + X)`."] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] + pub fn provide_judgement( &self, - min_join_bond: runtime_types::pallet_nomination_pools::ConfigOp< - ::core::primitive::u128, - >, - min_create_bond: runtime_types::pallet_nomination_pools::ConfigOp< + reg_index: ::core::primitive::u32, + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + judgement: runtime_types::pallet_identity::types::Judgement< ::core::primitive::u128, >, - max_pools: runtime_types::pallet_nomination_pools::ConfigOp< - ::core::primitive::u32, - >, - max_members: runtime_types::pallet_nomination_pools::ConfigOp< - ::core::primitive::u32, - >, - max_members_per_pool: runtime_types::pallet_nomination_pools::ConfigOp< - ::core::primitive::u32, - >, - global_max_commission: runtime_types::pallet_nomination_pools::ConfigOp< - runtime_types::sp_arithmetic::per_things::Perbill, - >, - ) -> ::subxt::tx::Payload { + identity: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "set_configs", - types::SetConfigs { - min_join_bond, - min_create_bond, - max_pools, - max_members, - max_members_per_pool, - global_max_commission, + "Identity", + "provide_judgement", + types::ProvideJudgement { + reg_index, + target, + judgement, + identity, }, [ - 20u8, 66u8, 112u8, 172u8, 143u8, 78u8, 60u8, 159u8, 240u8, 102u8, - 245u8, 10u8, 207u8, 27u8, 99u8, 138u8, 217u8, 239u8, 101u8, 190u8, - 222u8, 253u8, 53u8, 77u8, 230u8, 225u8, 101u8, 109u8, 50u8, 144u8, - 31u8, 121u8, + 147u8, 66u8, 29u8, 90u8, 149u8, 65u8, 161u8, 115u8, 12u8, 254u8, 188u8, + 248u8, 165u8, 115u8, 191u8, 2u8, 167u8, 223u8, 199u8, 169u8, 203u8, + 64u8, 101u8, 217u8, 73u8, 185u8, 93u8, 109u8, 22u8, 184u8, 146u8, 73u8, ], ) } - #[doc = "Update the roles of the pool."] - #[doc = ""] - #[doc = "The root is the only entity that can change any of the roles, including itself,"] - #[doc = "excluding the depositor, who can never change."] + #[doc = "Remove an account's identity and sub-account information and slash the deposits."] #[doc = ""] - #[doc = "It emits an event, notifying UIs of the role change. This event is quite relevant to"] - #[doc = "most pool members and they should be informed of changes to pool roles."] - pub fn update_roles( - &self, - pool_id: ::core::primitive::u32, - new_root: runtime_types::pallet_nomination_pools::ConfigOp< - ::subxt::utils::AccountId32, - >, - new_nominator: runtime_types::pallet_nomination_pools::ConfigOp< - ::subxt::utils::AccountId32, - >, - new_bouncer: runtime_types::pallet_nomination_pools::ConfigOp< - ::subxt::utils::AccountId32, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NominationPools", - "update_roles", - types::UpdateRoles { - pool_id, - new_root, - new_nominator, - new_bouncer, - }, - [ - 15u8, 154u8, 204u8, 28u8, 204u8, 120u8, 174u8, 203u8, 186u8, 33u8, - 123u8, 201u8, 143u8, 120u8, 193u8, 49u8, 164u8, 178u8, 55u8, 234u8, - 126u8, 247u8, 123u8, 73u8, 147u8, 107u8, 43u8, 72u8, 217u8, 4u8, 199u8, - 253u8, - ], - ) - } - #[doc = "Chill on behalf of the pool."] + #[doc = "Payment: Reserved balances from `set_subs` and `set_identity` are slashed and handled by"] + #[doc = "`Slash`. Verification request deposits are not returned; they should be cancelled"] + #[doc = "manually using `cancel_request`."] #[doc = ""] - #[doc = "The dispatch origin of this call must be signed by the pool nominator or the pool"] - #[doc = "root role, same as [`Pallet::nominate`]."] + #[doc = "The dispatch origin for this call must match `T::ForceOrigin`."] #[doc = ""] - #[doc = "This directly forward the call to the staking pallet, on behalf of the pool bonded"] - #[doc = "account."] - pub fn chill( - &self, - pool_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NominationPools", - "chill", - types::Chill { pool_id }, - [ - 41u8, 114u8, 128u8, 121u8, 244u8, 15u8, 15u8, 52u8, 129u8, 88u8, 239u8, - 167u8, 216u8, 38u8, 123u8, 240u8, 172u8, 229u8, 132u8, 64u8, 175u8, - 87u8, 217u8, 27u8, 11u8, 124u8, 1u8, 140u8, 40u8, 191u8, 187u8, 36u8, - ], - ) - } - #[doc = "`origin` bonds funds from `extra` for some pool member `member` into their respective"] - #[doc = "pools."] + #[doc = "- `target`: the account whose identity the judgement is upon. This must be an account"] + #[doc = " with a registered identity."] #[doc = ""] - #[doc = "`origin` can bond extra funds from free balance or pending rewards when `origin =="] - #[doc = "other`."] + #[doc = "Emits `IdentityKilled` if successful."] #[doc = ""] - #[doc = "In the case of `origin != other`, `origin` can only bond extra pending rewards of"] - #[doc = "`other` members assuming set_claim_permission for the given member is"] - #[doc = "`PermissionlessAll` or `PermissionlessCompound`."] - pub fn bond_extra_other( + #[doc = "## Complexity"] + #[doc = "- `O(R + S + X)`"] + #[doc = " - where `R` registrar-count (governance-bounded)."] + #[doc = " - where `S` subs-count (hard- and deposit-bounded)."] + #[doc = " - where `X` additional-field-count (deposit-bounded and code-bounded)."] + pub fn kill_identity( &self, - member: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - extra: runtime_types::pallet_nomination_pools::BondExtra< - ::core::primitive::u128, - >, - ) -> ::subxt::tx::Payload { + target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "bond_extra_other", - BondExtraOther { member, extra }, + "Identity", + "kill_identity", + types::KillIdentity { target }, [ - 13u8, 60u8, 161u8, 6u8, 191u8, 248u8, 61u8, 226u8, 192u8, 37u8, 44u8, - 146u8, 250u8, 213u8, 235u8, 147u8, 0u8, 14u8, 147u8, 11u8, 14u8, 126u8, - 70u8, 240u8, 83u8, 26u8, 95u8, 49u8, 52u8, 15u8, 185u8, 162u8, + 76u8, 13u8, 158u8, 219u8, 221u8, 0u8, 151u8, 241u8, 137u8, 136u8, + 179u8, 194u8, 188u8, 230u8, 56u8, 16u8, 254u8, 28u8, 127u8, 216u8, + 205u8, 117u8, 224u8, 121u8, 240u8, 231u8, 126u8, 181u8, 230u8, 68u8, + 13u8, 174u8, ], ) } - #[doc = "Allows a pool member to set a claim permission to allow or disallow permissionless"] - #[doc = "bonding and withdrawing."] - #[doc = ""] - #[doc = "By default, this is `Permissioned`, which implies only the pool member themselves can"] - #[doc = "claim their pending rewards. If a pool member wishes so, they can set this to"] - #[doc = "`PermissionlessAll` to allow any account to claim their rewards and bond extra to the"] - #[doc = "pool."] + #[doc = "Add the given account to the sender's subs."] #[doc = ""] - #[doc = "# Arguments"] + #[doc = "Payment: Balance reserved by a previous `set_subs` call for one sub will be repatriated"] + #[doc = "to the sender."] #[doc = ""] - #[doc = "* `origin` - Member of a pool."] - #[doc = "* `actor` - Account to claim reward. // improve this"] - pub fn set_claim_permission( + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] + #[doc = "sub identity of `sub`."] + pub fn add_sub( &self, - permission: runtime_types::pallet_nomination_pools::ClaimPermission, - ) -> ::subxt::tx::Payload { + sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + data: runtime_types::pallet_identity::types::Data, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "set_claim_permission", - SetClaimPermission { permission }, + "Identity", + "add_sub", + types::AddSub { sub, data }, [ - 23u8, 253u8, 135u8, 53u8, 83u8, 71u8, 182u8, 223u8, 123u8, 57u8, 93u8, - 154u8, 110u8, 91u8, 63u8, 241u8, 144u8, 218u8, 129u8, 238u8, 169u8, - 9u8, 215u8, 76u8, 65u8, 168u8, 103u8, 44u8, 40u8, 39u8, 34u8, 16u8, + 122u8, 218u8, 25u8, 93u8, 33u8, 176u8, 191u8, 254u8, 223u8, 147u8, + 100u8, 135u8, 86u8, 71u8, 47u8, 163u8, 105u8, 222u8, 162u8, 173u8, + 207u8, 182u8, 130u8, 128u8, 214u8, 242u8, 101u8, 250u8, 242u8, 24u8, + 17u8, 84u8, ], ) } - #[doc = "`origin` can claim payouts on some pool member `other`'s behalf."] + #[doc = "Alter the associated name of the given sub-account."] #[doc = ""] - #[doc = "Pool member `other` must have a `PermissionlessAll` or `PermissionlessWithdraw` in order"] - #[doc = "for this call to be successful."] - pub fn claim_payout_other( + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] + #[doc = "sub identity of `sub`."] + pub fn rename_sub( &self, - other: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { + sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + data: runtime_types::pallet_identity::types::Data, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "claim_payout_other", - ClaimPayoutOther { other }, + "Identity", + "rename_sub", + types::RenameSub { sub, data }, [ - 52u8, 165u8, 191u8, 125u8, 180u8, 54u8, 27u8, 235u8, 195u8, 22u8, 55u8, - 183u8, 209u8, 63u8, 116u8, 88u8, 154u8, 74u8, 100u8, 103u8, 88u8, 76u8, - 35u8, 14u8, 39u8, 156u8, 219u8, 253u8, 123u8, 104u8, 168u8, 76u8, + 166u8, 167u8, 49u8, 114u8, 199u8, 168u8, 187u8, 221u8, 100u8, 85u8, + 147u8, 211u8, 157u8, 31u8, 109u8, 135u8, 194u8, 135u8, 15u8, 89u8, + 59u8, 57u8, 252u8, 163u8, 9u8, 138u8, 216u8, 189u8, 177u8, 42u8, 96u8, + 34u8, ], ) } - #[doc = "Set the commission of a pool."] - #[doc = "Both a commission percentage and a commission payee must be provided in the `current`"] - #[doc = "tuple. Where a `current` of `None` is provided, any current commission will be removed."] + #[doc = "Remove the given account from the sender's subs."] #[doc = ""] - #[doc = "- If a `None` is supplied to `new_commission`, existing commission will be removed."] - pub fn set_commission( - &self, - pool_id: ::core::primitive::u32, - new_commission: ::core::option::Option<( - runtime_types::sp_arithmetic::per_things::Perbill, - ::subxt::utils::AccountId32, - )>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NominationPools", - "set_commission", - SetCommission { - pool_id, - new_commission, - }, - [ - 118u8, 240u8, 166u8, 40u8, 247u8, 44u8, 23u8, 92u8, 4u8, 78u8, 156u8, - 21u8, 178u8, 97u8, 197u8, 148u8, 61u8, 234u8, 15u8, 94u8, 248u8, 188u8, - 211u8, 13u8, 134u8, 10u8, 75u8, 59u8, 218u8, 13u8, 104u8, 115u8, - ], - ) - } - #[doc = "Set the maximum commission of a pool."] + #[doc = "Payment: Balance reserved by a previous `set_subs` call for one sub will be repatriated"] + #[doc = "to the sender."] #[doc = ""] - #[doc = "- Initial max can be set to any `Perbill`, and only smaller values thereafter."] - #[doc = "- Current commission will be lowered in the event it is higher than a new max"] - #[doc = " commission."] - pub fn set_commission_max( + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] + #[doc = "sub identity of `sub`."] + pub fn remove_sub( &self, - pool_id: ::core::primitive::u32, - max_commission: runtime_types::sp_arithmetic::per_things::Perbill, - ) -> ::subxt::tx::Payload { + sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "set_commission_max", - SetCommissionMax { - pool_id, - max_commission, - }, + "Identity", + "remove_sub", + types::RemoveSub { sub }, [ - 115u8, 90u8, 156u8, 35u8, 7u8, 125u8, 184u8, 123u8, 149u8, 232u8, 59u8, - 21u8, 42u8, 120u8, 14u8, 152u8, 184u8, 167u8, 18u8, 22u8, 148u8, 83u8, - 16u8, 81u8, 93u8, 182u8, 154u8, 182u8, 46u8, 40u8, 179u8, 187u8, + 106u8, 223u8, 210u8, 67u8, 54u8, 11u8, 144u8, 222u8, 42u8, 46u8, 157u8, + 33u8, 13u8, 245u8, 166u8, 195u8, 227u8, 81u8, 224u8, 149u8, 154u8, + 158u8, 187u8, 203u8, 215u8, 91u8, 43u8, 105u8, 69u8, 213u8, 141u8, + 124u8, ], ) } - #[doc = "Set the commission change rate for a pool."] + #[doc = "Remove the sender as a sub-account."] #[doc = ""] - #[doc = "Initial change rate is not bounded, whereas subsequent updates can only be more"] - #[doc = "restrictive than the current."] - pub fn set_commission_change_rate( - &self, - pool_id: ::core::primitive::u32, - change_rate: runtime_types::pallet_nomination_pools::CommissionChangeRate< - ::core::primitive::u32, - >, - ) -> ::subxt::tx::Payload { + #[doc = "Payment: Balance reserved by a previous `set_subs` call for one sub will be repatriated"] + #[doc = "to the sender (*not* the original depositor)."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the sender must have a registered"] + #[doc = "super-identity."] + #[doc = ""] + #[doc = "NOTE: This should not normally be used, but is provided in the case that the non-"] + #[doc = "controller of an account is maliciously registered as a sub-account."] + pub fn quit_sub(&self) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( - "NominationPools", - "set_commission_change_rate", - SetCommissionChangeRate { - pool_id, - change_rate, - }, + "Identity", + "quit_sub", + types::QuitSub {}, [ - 118u8, 194u8, 114u8, 197u8, 214u8, 246u8, 23u8, 237u8, 10u8, 90u8, - 230u8, 123u8, 172u8, 174u8, 98u8, 198u8, 160u8, 71u8, 113u8, 76u8, - 201u8, 201u8, 153u8, 92u8, 222u8, 252u8, 7u8, 184u8, 236u8, 235u8, - 126u8, 201u8, - ], - ) - } - #[doc = "Claim pending commission."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be signed by the `root` role of the pool. Pending"] - #[doc = "commission is paid out and added to total claimed commission`. Total pending commission"] - #[doc = "is reset to zero. the current."] - pub fn claim_commission( - &self, - pool_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NominationPools", - "claim_commission", - ClaimCommission { pool_id }, - [ - 139u8, 126u8, 219u8, 117u8, 140u8, 51u8, 163u8, 32u8, 83u8, 60u8, - 250u8, 44u8, 186u8, 194u8, 225u8, 84u8, 61u8, 181u8, 212u8, 160u8, - 156u8, 93u8, 16u8, 255u8, 165u8, 178u8, 25u8, 64u8, 187u8, 29u8, 169u8, - 174u8, + 62u8, 57u8, 73u8, 72u8, 119u8, 216u8, 250u8, 155u8, 57u8, 169u8, 157u8, + 44u8, 87u8, 51u8, 63u8, 231u8, 77u8, 7u8, 0u8, 119u8, 244u8, 42u8, + 179u8, 51u8, 254u8, 240u8, 55u8, 25u8, 142u8, 38u8, 87u8, 44u8, ], ) } } } - #[doc = "Events of this pallet."] - pub type Event = runtime_types::pallet_nomination_pools::pallet::Event; + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_identity::pallet::Event; pub mod events { use super::runtime_types; #[derive( @@ -25087,132 +21276,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A pool has been created."] - pub struct Created { - pub depositor: ::subxt::utils::AccountId32, - pub pool_id: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Created { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "Created"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A member has became bonded in a pool."] - pub struct Bonded { - pub member: ::subxt::utils::AccountId32, - pub pool_id: ::core::primitive::u32, - pub bonded: ::core::primitive::u128, - pub joined: ::core::primitive::bool, - } - impl ::subxt::events::StaticEvent for Bonded { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "Bonded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A payout has been made to a member."] - pub struct PaidOut { - pub member: ::subxt::utils::AccountId32, - pub pool_id: ::core::primitive::u32, - pub payout: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for PaidOut { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "PaidOut"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A member has unbonded from their pool."] - #[doc = ""] - #[doc = "- `balance` is the corresponding balance of the number of points that has been"] - #[doc = " requested to be unbonded (the argument of the `unbond` transaction) from the bonded"] - #[doc = " pool."] - #[doc = "- `points` is the number of points that are issued as a result of `balance` being"] - #[doc = "dissolved into the corresponding unbonding pool."] - #[doc = "- `era` is the era in which the balance will be unbonded."] - #[doc = "In the absence of slashing, these values will match. In the presence of slashing, the"] - #[doc = "number of points that are issued in the unbonding pool will be less than the amount"] - #[doc = "requested to be unbonded."] - pub struct Unbonded { - pub member: ::subxt::utils::AccountId32, - pub pool_id: ::core::primitive::u32, - pub balance: ::core::primitive::u128, - pub points: ::core::primitive::u128, - pub era: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Unbonded { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "Unbonded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A member has withdrawn from their pool."] - #[doc = ""] - #[doc = "The given number of `points` have been dissolved in return of `balance`."] - #[doc = ""] - #[doc = "Similar to `Unbonded` event, in the absence of slashing, the ratio of point to balance"] - #[doc = "will be 1."] - pub struct Withdrawn { - pub member: ::subxt::utils::AccountId32, - pub pool_id: ::core::primitive::u32, - pub balance: ::core::primitive::u128, - pub points: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Withdrawn { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "Withdrawn"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A pool has been destroyed."] - pub struct Destroyed { - pub pool_id: ::core::primitive::u32, + #[doc = "A name was set or reset (which will remove all judgements)."] + pub struct IdentitySet { + pub who: ::subxt::utils::AccountId32, } - impl ::subxt::events::StaticEvent for Destroyed { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "Destroyed"; + impl ::subxt::events::StaticEvent for IdentitySet { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "IdentitySet"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25224,14 +21294,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The state of a pool has changed"] - pub struct StateChanged { - pub pool_id: ::core::primitive::u32, - pub new_state: runtime_types::pallet_nomination_pools::PoolState, + #[doc = "A name was cleared, and the given balance returned."] + pub struct IdentityCleared { + pub who: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for StateChanged { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "StateChanged"; + impl ::subxt::events::StaticEvent for IdentityCleared { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "IdentityCleared"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25243,16 +21313,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A member has been removed from a pool."] - #[doc = ""] - #[doc = "The removal can be voluntary (withdrawn all unbonded funds) or involuntary (kicked)."] - pub struct MemberRemoved { - pub pool_id: ::core::primitive::u32, - pub member: ::subxt::utils::AccountId32, + #[doc = "A name was removed and the given balance slashed."] + pub struct IdentityKilled { + pub who: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for MemberRemoved { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "MemberRemoved"; + impl ::subxt::events::StaticEvent for IdentityKilled { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "IdentityKilled"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25264,16 +21332,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The roles of a pool have been updated to the given new roles. Note that the depositor"] - #[doc = "can never change."] - pub struct RolesUpdated { - pub root: ::core::option::Option<::subxt::utils::AccountId32>, - pub bouncer: ::core::option::Option<::subxt::utils::AccountId32>, - pub nominator: ::core::option::Option<::subxt::utils::AccountId32>, + #[doc = "A judgement was asked from a registrar."] + pub struct JudgementRequested { + pub who: ::subxt::utils::AccountId32, + pub registrar_index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for RolesUpdated { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "RolesUpdated"; + impl ::subxt::events::StaticEvent for JudgementRequested { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "JudgementRequested"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25285,14 +21351,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The active balance of pool `pool_id` has been slashed to `balance`."] - pub struct PoolSlashed { - pub pool_id: ::core::primitive::u32, - pub balance: ::core::primitive::u128, + #[doc = "A judgement request was retracted."] + pub struct JudgementUnrequested { + pub who: ::subxt::utils::AccountId32, + pub registrar_index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for PoolSlashed { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "PoolSlashed"; + impl ::subxt::events::StaticEvent for JudgementUnrequested { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "JudgementUnrequested"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25304,17 +21370,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The unbond pool at `era` of pool `pool_id` has been slashed to `balance`."] - pub struct UnbondingPoolSlashed { - pub pool_id: ::core::primitive::u32, - pub era: ::core::primitive::u32, - pub balance: ::core::primitive::u128, + #[doc = "A judgement was given by a registrar."] + pub struct JudgementGiven { + pub target: ::subxt::utils::AccountId32, + pub registrar_index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for UnbondingPoolSlashed { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "UnbondingPoolSlashed"; + impl ::subxt::events::StaticEvent for JudgementGiven { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "JudgementGiven"; } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -25324,17 +21390,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A pool's commission setting has been changed."] - pub struct PoolCommissionUpdated { - pub pool_id: ::core::primitive::u32, - pub current: ::core::option::Option<( - runtime_types::sp_arithmetic::per_things::Perbill, - ::subxt::utils::AccountId32, - )>, + #[doc = "A registrar was added."] + pub struct RegistrarAdded { + pub registrar_index: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for PoolCommissionUpdated { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "PoolCommissionUpdated"; + impl ::subxt::events::StaticEvent for RegistrarAdded { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "RegistrarAdded"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25346,14 +21408,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A pool's maximum commission setting has been changed."] - pub struct PoolMaxCommissionUpdated { - pub pool_id: ::core::primitive::u32, - pub max_commission: runtime_types::sp_arithmetic::per_things::Perbill, + #[doc = "A sub-identity was added to an identity and the deposit paid."] + pub struct SubIdentityAdded { + pub sub: ::subxt::utils::AccountId32, + pub main: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for PoolMaxCommissionUpdated { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "PoolMaxCommissionUpdated"; + impl ::subxt::events::StaticEvent for SubIdentityAdded { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "SubIdentityAdded"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25365,16 +21428,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A pool's commission `change_rate` has been changed."] - pub struct PoolCommissionChangeRateUpdated { - pub pool_id: ::core::primitive::u32, - pub change_rate: runtime_types::pallet_nomination_pools::CommissionChangeRate< - ::core::primitive::u32, - >, + #[doc = "A sub-identity was removed from an identity and the deposit freed."] + pub struct SubIdentityRemoved { + pub sub: ::subxt::utils::AccountId32, + pub main: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for PoolCommissionChangeRateUpdated { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "PoolCommissionChangeRateUpdated"; + impl ::subxt::events::StaticEvent for SubIdentityRemoved { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "SubIdentityRemoved"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -25386,717 +21448,809 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Pool commission has been claimed."] - pub struct PoolCommissionClaimed { - pub pool_id: ::core::primitive::u32, - pub commission: ::core::primitive::u128, + #[doc = "A sub-identity was cleared, and the given deposit repatriated from the"] + #[doc = "main identity account to the sub-identity account."] + pub struct SubIdentityRevoked { + pub sub: ::subxt::utils::AccountId32, + pub main: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, } - impl ::subxt::events::StaticEvent for PoolCommissionClaimed { - const PALLET: &'static str = "NominationPools"; - const EVENT: &'static str = "PoolCommissionClaimed"; + impl ::subxt::events::StaticEvent for SubIdentityRevoked { + const PALLET: &'static str = "Identity"; + const EVENT: &'static str = "SubIdentityRevoked"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " Minimum amount to bond to join a pool."] - pub fn min_join_bond( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "MinJoinBond", - vec![], - [ - 125u8, 239u8, 45u8, 225u8, 74u8, 129u8, 247u8, 184u8, 205u8, 58u8, - 45u8, 186u8, 126u8, 170u8, 112u8, 120u8, 23u8, 190u8, 247u8, 97u8, - 131u8, 126u8, 215u8, 44u8, 147u8, 122u8, 132u8, 212u8, 217u8, 84u8, - 240u8, 91u8, - ], - ) - } - #[doc = " Minimum bond required to create a pool."] - #[doc = ""] - #[doc = " This is the amount that the depositor must put as their initial stake in the pool, as an"] - #[doc = " indication of \"skin in the game\"."] + #[doc = " Information that is pertinent to identify the entity behind an account."] #[doc = ""] - #[doc = " This is the value that will always exist in the staking ledger of the pool bonded account"] - #[doc = " while all other accounts leave."] - pub fn min_create_bond( + #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] + pub fn identity_of( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, + runtime_types::pallet_identity::types::Registration<::core::primitive::u128>, ::subxt::storage::address::Yes, (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "MinCreateBond", - vec![], - [ - 31u8, 208u8, 240u8, 158u8, 23u8, 218u8, 212u8, 138u8, 92u8, 210u8, - 207u8, 170u8, 32u8, 60u8, 5u8, 21u8, 84u8, 162u8, 1u8, 111u8, 181u8, - 243u8, 24u8, 148u8, 193u8, 253u8, 248u8, 190u8, 16u8, 222u8, 219u8, - 67u8, - ], - ) - } - #[doc = " Maximum number of nomination pools that can exist. If `None`, then an unbounded number of"] - #[doc = " pools can exist."] - pub fn max_pools( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, ::subxt::storage::address::Yes, - (), - (), > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "MaxPools", - vec![], + "Identity", + "IdentityOf", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 216u8, 111u8, 68u8, 103u8, 33u8, 50u8, 109u8, 3u8, 176u8, 195u8, 23u8, - 73u8, 112u8, 138u8, 9u8, 194u8, 233u8, 73u8, 68u8, 215u8, 162u8, 255u8, - 217u8, 173u8, 141u8, 27u8, 72u8, 199u8, 7u8, 240u8, 25u8, 34u8, + 193u8, 195u8, 180u8, 188u8, 129u8, 250u8, 180u8, 219u8, 22u8, 95u8, + 175u8, 170u8, 143u8, 188u8, 80u8, 124u8, 234u8, 228u8, 245u8, 39u8, + 72u8, 153u8, 107u8, 199u8, 23u8, 75u8, 47u8, 247u8, 104u8, 208u8, + 171u8, 82u8, ], ) } - #[doc = " Maximum number of members that can exist in the system. If `None`, then the count"] - #[doc = " members are not bound on a system wide basis."] - pub fn max_pool_members( + #[doc = " Information that is pertinent to identify the entity behind an account."] + #[doc = ""] + #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] + pub fn identity_of_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, + runtime_types::pallet_identity::types::Registration<::core::primitive::u128>, (), (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "MaxPoolMembers", - vec![], + "Identity", + "IdentityOf", + Vec::new(), [ - 82u8, 217u8, 26u8, 234u8, 223u8, 241u8, 66u8, 182u8, 43u8, 233u8, 59u8, - 242u8, 202u8, 254u8, 69u8, 50u8, 254u8, 196u8, 166u8, 89u8, 120u8, - 87u8, 76u8, 148u8, 31u8, 197u8, 49u8, 88u8, 206u8, 41u8, 242u8, 62u8, + 193u8, 195u8, 180u8, 188u8, 129u8, 250u8, 180u8, 219u8, 22u8, 95u8, + 175u8, 170u8, 143u8, 188u8, 80u8, 124u8, 234u8, 228u8, 245u8, 39u8, + 72u8, 153u8, 107u8, 199u8, 23u8, 75u8, 47u8, 247u8, 104u8, 208u8, + 171u8, 82u8, ], ) } - #[doc = " Maximum number of members that may belong to pool. If `None`, then the count of"] - #[doc = " members is not bound on a per pool basis."] - pub fn max_pool_members_per_pool( + #[doc = " The super-identity of an alternative \"sub\" identity together with its name, within that"] + #[doc = " context. If the account is not some other account's sub-identity, then just `None`."] + pub fn super_of( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + ( + ::subxt::utils::AccountId32, + runtime_types::pallet_identity::types::Data, + ), ::subxt::storage::address::Yes, (), - (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "MaxPoolMembersPerPool", - vec![], + "Identity", + "SuperOf", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 93u8, 241u8, 16u8, 169u8, 138u8, 199u8, 128u8, 149u8, 65u8, 30u8, 55u8, - 11u8, 41u8, 252u8, 83u8, 250u8, 9u8, 33u8, 152u8, 239u8, 195u8, 147u8, - 16u8, 248u8, 180u8, 153u8, 88u8, 231u8, 248u8, 169u8, 186u8, 48u8, + 170u8, 249u8, 112u8, 249u8, 75u8, 176u8, 21u8, 29u8, 152u8, 149u8, + 69u8, 113u8, 20u8, 92u8, 113u8, 130u8, 135u8, 62u8, 18u8, 204u8, 166u8, + 193u8, 133u8, 167u8, 248u8, 117u8, 80u8, 137u8, 158u8, 111u8, 100u8, + 137u8, ], ) } - #[doc = " The maximum commission that can be charged by a pool. Used on commission payouts to bound"] - #[doc = " pool commissions that are > `GlobalMaxCommission`, necessary if a future"] - #[doc = " `GlobalMaxCommission` is lower than some current pool commissions."] - pub fn global_max_commission( + #[doc = " The super-identity of an alternative \"sub\" identity together with its name, within that"] + #[doc = " context. If the account is not some other account's sub-identity, then just `None`."] + pub fn super_of_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::per_things::Perbill, - ::subxt::storage::address::Yes, + ( + ::subxt::utils::AccountId32, + runtime_types::pallet_identity::types::Data, + ), (), (), + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "GlobalMaxCommission", - vec![], + "Identity", + "SuperOf", + Vec::new(), [ - 142u8, 252u8, 92u8, 128u8, 162u8, 4u8, 216u8, 39u8, 118u8, 201u8, - 138u8, 171u8, 76u8, 90u8, 133u8, 176u8, 161u8, 138u8, 214u8, 183u8, - 193u8, 115u8, 245u8, 151u8, 216u8, 84u8, 99u8, 175u8, 144u8, 196u8, - 103u8, 190u8, + 170u8, 249u8, 112u8, 249u8, 75u8, 176u8, 21u8, 29u8, 152u8, 149u8, + 69u8, 113u8, 20u8, 92u8, 113u8, 130u8, 135u8, 62u8, 18u8, 204u8, 166u8, + 193u8, 133u8, 167u8, 248u8, 117u8, 80u8, 137u8, 158u8, 111u8, 100u8, + 137u8, ], ) } - #[doc = " Active members."] + #[doc = " Alternative \"sub\" identities of this account."] #[doc = ""] - #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] - pub fn pool_members( + #[doc = " The first item is the deposit, the second is a vector of the accounts."] + #[doc = ""] + #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] + pub fn subs_of( &self, _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::PoolMember, + ( + ::core::primitive::u128, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::AccountId32, + >, + ), + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "PoolMembers", + "Identity", + "SubsOf", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 252u8, 236u8, 201u8, 127u8, 219u8, 1u8, 19u8, 144u8, 5u8, 108u8, 70u8, - 30u8, 177u8, 232u8, 253u8, 237u8, 211u8, 91u8, 63u8, 62u8, 155u8, - 151u8, 153u8, 165u8, 206u8, 53u8, 111u8, 31u8, 60u8, 120u8, 100u8, - 249u8, + 128u8, 15u8, 175u8, 155u8, 216u8, 225u8, 200u8, 169u8, 215u8, 206u8, + 110u8, 22u8, 204u8, 89u8, 212u8, 210u8, 159u8, 169u8, 53u8, 7u8, 44u8, + 164u8, 91u8, 151u8, 7u8, 227u8, 38u8, 230u8, 175u8, 84u8, 6u8, 4u8, ], ) } - #[doc = " Active members."] + #[doc = " Alternative \"sub\" identities of this account."] #[doc = ""] - #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] - pub fn pool_members_root( + #[doc = " The first item is the deposit, the second is a vector of the accounts."] + #[doc = ""] + #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] + pub fn subs_of_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::PoolMember, - (), + ( + ::core::primitive::u128, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::AccountId32, + >, + ), (), ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "PoolMembers", + "Identity", + "SubsOf", Vec::new(), [ - 252u8, 236u8, 201u8, 127u8, 219u8, 1u8, 19u8, 144u8, 5u8, 108u8, 70u8, - 30u8, 177u8, 232u8, 253u8, 237u8, 211u8, 91u8, 63u8, 62u8, 155u8, - 151u8, 153u8, 165u8, 206u8, 53u8, 111u8, 31u8, 60u8, 120u8, 100u8, - 249u8, + 128u8, 15u8, 175u8, 155u8, 216u8, 225u8, 200u8, 169u8, 215u8, 206u8, + 110u8, 22u8, 204u8, 89u8, 212u8, 210u8, 159u8, 169u8, 53u8, 7u8, 44u8, + 164u8, 91u8, 151u8, 7u8, 227u8, 38u8, 230u8, 175u8, 84u8, 6u8, 4u8, ], ) } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_pool_members( + #[doc = " The set of registrars. Not expected to get very big as can only be added through a"] + #[doc = " special origin (likely a council motion)."] + #[doc = ""] + #[doc = " The index into this can be cast to `RegistrarIndex` to get a valid value."] + pub fn registrars( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::option::Option< + runtime_types::pallet_identity::types::RegistrarInfo< + ::core::primitive::u128, + ::subxt::utils::AccountId32, + >, + >, + >, + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, (), > { ::subxt::storage::address::Address::new_static( - "NominationPools", - "CounterForPoolMembers", + "Identity", + "Registrars", vec![], [ - 114u8, 126u8, 27u8, 138u8, 119u8, 44u8, 45u8, 129u8, 84u8, 107u8, - 171u8, 206u8, 117u8, 141u8, 20u8, 75u8, 229u8, 237u8, 31u8, 229u8, - 124u8, 190u8, 27u8, 124u8, 63u8, 59u8, 167u8, 42u8, 62u8, 212u8, 160u8, - 2u8, + 157u8, 87u8, 39u8, 240u8, 154u8, 54u8, 241u8, 229u8, 76u8, 9u8, 62u8, + 252u8, 40u8, 143u8, 186u8, 182u8, 233u8, 187u8, 251u8, 61u8, 236u8, + 229u8, 19u8, 55u8, 42u8, 36u8, 82u8, 173u8, 215u8, 155u8, 229u8, 111u8, ], ) } - #[doc = " Storage for bonded pools."] - pub fn bonded_pools( + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The amount held on deposit for a registered identity"] + pub fn basic_deposit( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::BondedPoolInner, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "BondedPools", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Identity", + "BasicDeposit", [ - 3u8, 183u8, 140u8, 154u8, 74u8, 225u8, 69u8, 243u8, 150u8, 132u8, - 163u8, 26u8, 101u8, 45u8, 231u8, 178u8, 85u8, 144u8, 9u8, 112u8, 212u8, - 167u8, 131u8, 188u8, 203u8, 50u8, 177u8, 218u8, 154u8, 182u8, 80u8, - 232u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = " Storage for bonded pools."] - pub fn bonded_pools_root( + #[doc = " The amount held on deposit per additional field for a registered identity."] + pub fn field_deposit( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::BondedPoolInner, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "BondedPools", - Vec::new(), + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Identity", + "FieldDeposit", [ - 3u8, 183u8, 140u8, 154u8, 74u8, 225u8, 69u8, 243u8, 150u8, 132u8, - 163u8, 26u8, 101u8, 45u8, 231u8, 178u8, 85u8, 144u8, 9u8, 112u8, 212u8, - 167u8, 131u8, 188u8, 203u8, 50u8, 177u8, 218u8, 154u8, 182u8, 80u8, - 232u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_bonded_pools( + #[doc = " The amount held on deposit for a registered subaccount. This should account for the fact"] + #[doc = " that one storage item's value will increase by the size of an account ID, and there will"] + #[doc = " be another trie item whose value is the size of an account ID plus 32 bytes."] + pub fn sub_account_deposit( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "CounterForBondedPools", - vec![], + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Identity", + "SubAccountDeposit", [ - 134u8, 94u8, 199u8, 73u8, 174u8, 253u8, 66u8, 242u8, 233u8, 244u8, - 140u8, 170u8, 242u8, 40u8, 41u8, 185u8, 183u8, 151u8, 58u8, 111u8, - 221u8, 225u8, 81u8, 71u8, 169u8, 219u8, 223u8, 135u8, 8u8, 171u8, - 180u8, 236u8, + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, ], ) } - #[doc = " Reward pools. This is where there rewards for each pool accumulate. When a members payout is"] - #[doc = " claimed, the balance comes out fo the reward pool. Keyed by the bonded pools account."] - pub fn reward_pools( + #[doc = " The maximum number of sub-accounts allowed per identified account."] + pub fn max_sub_accounts( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::RewardPool, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "RewardPools", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Identity", + "MaxSubAccounts", [ - 235u8, 6u8, 2u8, 103u8, 137u8, 31u8, 109u8, 165u8, 129u8, 48u8, 154u8, - 219u8, 110u8, 198u8, 241u8, 31u8, 174u8, 10u8, 92u8, 233u8, 161u8, - 76u8, 53u8, 136u8, 172u8, 214u8, 192u8, 12u8, 239u8, 165u8, 195u8, - 96u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = " Reward pools. This is where there rewards for each pool accumulate. When a members payout is"] - #[doc = " claimed, the balance comes out fo the reward pool. Keyed by the bonded pools account."] - pub fn reward_pools_root( + #[doc = " Maximum number of additional fields that may be stored in an ID. Needed to bound the I/O"] + #[doc = " required to access an identity, but can be pretty high."] + pub fn max_additional_fields( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::RewardPool, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "RewardPools", - Vec::new(), + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Identity", + "MaxAdditionalFields", [ - 235u8, 6u8, 2u8, 103u8, 137u8, 31u8, 109u8, 165u8, 129u8, 48u8, 154u8, - 219u8, 110u8, 198u8, 241u8, 31u8, 174u8, 10u8, 92u8, 233u8, 161u8, - 76u8, 53u8, 136u8, 172u8, 214u8, 192u8, 12u8, 239u8, 165u8, 195u8, - 96u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_reward_pools( + #[doc = " Maxmimum number of registrars allowed in the system. Needed to bound the complexity"] + #[doc = " of, e.g., updating judgements."] + pub fn max_registrars( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "CounterForRewardPools", - vec![], + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Identity", + "MaxRegistrars", [ - 209u8, 139u8, 212u8, 116u8, 210u8, 178u8, 213u8, 38u8, 75u8, 23u8, - 188u8, 57u8, 253u8, 213u8, 95u8, 118u8, 182u8, 250u8, 45u8, 205u8, - 17u8, 175u8, 17u8, 201u8, 234u8, 14u8, 98u8, 49u8, 143u8, 135u8, 201u8, - 81u8, + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, ], ) } - #[doc = " Groups of unbonding pools. Each group of unbonding pools belongs to a"] - #[doc = " bonded pool, hence the name sub-pools. Keyed by the bonded pools account."] - pub fn sub_pools_storage( + } + } + } + pub mod proxy { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_proxy::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Proxy { + pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub force_proxy_type: + ::core::option::Option, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddProxy { + pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub delay: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveProxy { + pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub delay: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveProxies; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CreatePure { + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub delay: ::core::primitive::u32, + pub index: ::core::primitive::u16, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct KillPure { + pub spawner: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub index: ::core::primitive::u16, + #[codec(compact)] + pub height: ::core::primitive::u32, + #[codec(compact)] + pub ext_index: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Announce { + pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub call_hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveAnnouncement { + pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub call_hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RejectAnnouncement { + pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub call_hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProxyAnnounced { + pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub force_proxy_type: + ::core::option::Option, + pub call: ::std::boxed::Box, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Dispatch the given `call` from an account that the sender is authorised for through"] + #[doc = "`add_proxy`."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `real`: The account that the proxy will make a call on behalf of."] + #[doc = "- `force_proxy_type`: Specify the exact proxy type to be used and checked for this call."] + #[doc = "- `call`: The call to be made by the `real` account."] + pub fn proxy( &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::SubPools, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "SubPoolsStorage", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + force_proxy_type: ::core::option::Option< + runtime_types::polkadot_runtime::ProxyType, + >, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "proxy", + types::Proxy { + real, + force_proxy_type, + call: ::std::boxed::Box::new(call), + }, [ - 231u8, 13u8, 111u8, 248u8, 1u8, 208u8, 179u8, 134u8, 224u8, 196u8, - 94u8, 201u8, 229u8, 29u8, 155u8, 211u8, 163u8, 150u8, 157u8, 34u8, - 68u8, 238u8, 55u8, 4u8, 222u8, 96u8, 186u8, 29u8, 205u8, 237u8, 80u8, - 42u8, + 29u8, 33u8, 67u8, 179u8, 234u8, 241u8, 45u8, 167u8, 110u8, 23u8, 85u8, + 27u8, 1u8, 184u8, 223u8, 187u8, 129u8, 206u8, 75u8, 237u8, 235u8, + 207u8, 43u8, 201u8, 194u8, 145u8, 149u8, 184u8, 95u8, 185u8, 205u8, + 248u8, ], ) } - #[doc = " Groups of unbonding pools. Each group of unbonding pools belongs to a"] - #[doc = " bonded pool, hence the name sub-pools. Keyed by the bonded pools account."] - pub fn sub_pools_storage_root( + #[doc = "Register a proxy account for the sender that is able to make calls on its behalf."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `proxy`: The account that the `caller` would like to make a proxy."] + #[doc = "- `proxy_type`: The permissions allowed for this proxy account."] + #[doc = "- `delay`: The announcement period required of the initial proxy. Will generally be"] + #[doc = "zero."] + pub fn add_proxy( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::SubPools, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "SubPoolsStorage", - Vec::new(), + delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + proxy_type: runtime_types::polkadot_runtime::ProxyType, + delay: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "add_proxy", + types::AddProxy { + delegate, + proxy_type, + delay, + }, [ - 231u8, 13u8, 111u8, 248u8, 1u8, 208u8, 179u8, 134u8, 224u8, 196u8, - 94u8, 201u8, 229u8, 29u8, 155u8, 211u8, 163u8, 150u8, 157u8, 34u8, - 68u8, 238u8, 55u8, 4u8, 222u8, 96u8, 186u8, 29u8, 205u8, 237u8, 80u8, - 42u8, + 76u8, 227u8, 139u8, 167u8, 131u8, 37u8, 104u8, 137u8, 224u8, 66u8, + 37u8, 1u8, 89u8, 113u8, 232u8, 199u8, 79u8, 187u8, 176u8, 106u8, 168u8, + 144u8, 68u8, 32u8, 0u8, 227u8, 188u8, 28u8, 218u8, 84u8, 82u8, 96u8, ], ) } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_sub_pools_storage( + #[doc = "Unregister a proxy account for the sender."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `proxy`: The account that the `caller` would like to remove as a proxy."] + #[doc = "- `proxy_type`: The permissions currently enabled for the removed proxy account."] + pub fn remove_proxy( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "CounterForSubPoolsStorage", - vec![], + delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + proxy_type: runtime_types::polkadot_runtime::ProxyType, + delay: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "remove_proxy", + types::RemoveProxy { + delegate, + proxy_type, + delay, + }, [ - 212u8, 145u8, 212u8, 226u8, 234u8, 31u8, 26u8, 240u8, 107u8, 91u8, - 171u8, 120u8, 41u8, 195u8, 16u8, 86u8, 55u8, 127u8, 103u8, 93u8, 128u8, - 48u8, 69u8, 104u8, 168u8, 236u8, 81u8, 54u8, 2u8, 184u8, 215u8, 51u8, + 46u8, 235u8, 142u8, 33u8, 21u8, 200u8, 243u8, 213u8, 62u8, 162u8, 70u8, + 132u8, 204u8, 76u8, 156u8, 66u8, 83u8, 95u8, 13u8, 208u8, 241u8, 242u8, + 219u8, 39u8, 229u8, 238u8, 221u8, 135u8, 66u8, 159u8, 38u8, 50u8, ], ) } - #[doc = " Metadata for the pool."] - pub fn metadata( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "Metadata", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], - [ - 108u8, 250u8, 163u8, 54u8, 192u8, 143u8, 239u8, 62u8, 97u8, 163u8, - 161u8, 215u8, 171u8, 225u8, 49u8, 18u8, 37u8, 200u8, 143u8, 254u8, - 136u8, 26u8, 54u8, 187u8, 39u8, 3u8, 216u8, 24u8, 188u8, 25u8, 243u8, - 251u8, - ], - ) - } - #[doc = " Metadata for the pool."] - pub fn metadata_root( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "Metadata", - Vec::new(), - [ - 108u8, 250u8, 163u8, 54u8, 192u8, 143u8, 239u8, 62u8, 97u8, 163u8, - 161u8, 215u8, 171u8, 225u8, 49u8, 18u8, 37u8, 200u8, 143u8, 254u8, - 136u8, 26u8, 54u8, 187u8, 39u8, 3u8, 216u8, 24u8, 188u8, 25u8, 243u8, - 251u8, - ], - ) - } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_metadata( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "CounterForMetadata", - vec![], - [ - 190u8, 232u8, 77u8, 134u8, 245u8, 89u8, 160u8, 187u8, 163u8, 68u8, - 188u8, 204u8, 31u8, 145u8, 219u8, 165u8, 213u8, 1u8, 167u8, 90u8, - 175u8, 218u8, 147u8, 144u8, 158u8, 226u8, 23u8, 233u8, 55u8, 168u8, - 161u8, 237u8, - ], - ) - } - #[doc = " Ever increasing number of all pools created so far."] - pub fn last_pool_id( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "LastPoolId", - vec![], - [ - 50u8, 254u8, 218u8, 41u8, 213u8, 184u8, 170u8, 166u8, 31u8, 29u8, - 196u8, 57u8, 215u8, 20u8, 40u8, 40u8, 19u8, 22u8, 9u8, 184u8, 11u8, - 21u8, 21u8, 125u8, 97u8, 38u8, 219u8, 209u8, 2u8, 238u8, 247u8, 51u8, - ], - ) - } - #[doc = " A reverse lookup from the pool's account id to its id."] + #[doc = "Unregister all proxy accounts for the sender."] #[doc = ""] - #[doc = " This is only used for slashing. In all other instances, the pool id is used, and the"] - #[doc = " accounts are deterministically derived from it."] - pub fn reverse_pool_id_lookup( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "ReversePoolIdLookup", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "WARNING: This may be called on accounts created by `pure`, however if done, then"] + #[doc = "the unreserved fees will be inaccessible. **All access to this account will be lost.**"] + pub fn remove_proxies(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "remove_proxies", + types::RemoveProxies {}, [ - 178u8, 161u8, 51u8, 220u8, 128u8, 1u8, 135u8, 83u8, 236u8, 159u8, 36u8, - 237u8, 120u8, 128u8, 6u8, 191u8, 41u8, 159u8, 94u8, 178u8, 174u8, - 235u8, 221u8, 173u8, 44u8, 81u8, 211u8, 255u8, 231u8, 81u8, 16u8, 87u8, + 15u8, 237u8, 27u8, 166u8, 254u8, 218u8, 92u8, 5u8, 213u8, 239u8, 99u8, + 59u8, 1u8, 26u8, 73u8, 252u8, 81u8, 94u8, 214u8, 227u8, 169u8, 58u8, + 40u8, 253u8, 187u8, 225u8, 192u8, 26u8, 19u8, 23u8, 121u8, 129u8, ], ) } - #[doc = " A reverse lookup from the pool's account id to its id."] + #[doc = "Spawn a fresh new account that is guaranteed to be otherwise inaccessible, and"] + #[doc = "initialize it with a proxy of `proxy_type` for `origin` sender."] #[doc = ""] - #[doc = " This is only used for slashing. In all other instances, the pool id is used, and the"] - #[doc = " accounts are deterministically derived from it."] - pub fn reverse_pool_id_lookup_root( + #[doc = "Requires a `Signed` origin."] + #[doc = ""] + #[doc = "- `proxy_type`: The type of the proxy that the sender will be registered as over the"] + #[doc = "new account. This will almost always be the most permissive `ProxyType` possible to"] + #[doc = "allow for maximum flexibility."] + #[doc = "- `index`: A disambiguation index, in case this is called multiple times in the same"] + #[doc = "transaction (e.g. with `utility::batch`). Unless you're using `batch` you probably just"] + #[doc = "want to use `0`."] + #[doc = "- `delay`: The announcement period required of the initial proxy. Will generally be"] + #[doc = "zero."] + #[doc = ""] + #[doc = "Fails with `Duplicate` if this has already been called in this transaction, from the"] + #[doc = "same sender, with the same parameters."] + #[doc = ""] + #[doc = "Fails if there are insufficient funds to pay for deposit."] + pub fn create_pure( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "ReversePoolIdLookup", - Vec::new(), + proxy_type: runtime_types::polkadot_runtime::ProxyType, + delay: ::core::primitive::u32, + index: ::core::primitive::u16, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "create_pure", + types::CreatePure { + proxy_type, + delay, + index, + }, [ - 178u8, 161u8, 51u8, 220u8, 128u8, 1u8, 135u8, 83u8, 236u8, 159u8, 36u8, - 237u8, 120u8, 128u8, 6u8, 191u8, 41u8, 159u8, 94u8, 178u8, 174u8, - 235u8, 221u8, 173u8, 44u8, 81u8, 211u8, 255u8, 231u8, 81u8, 16u8, 87u8, + 184u8, 127u8, 177u8, 255u8, 195u8, 192u8, 136u8, 114u8, 249u8, 70u8, + 222u8, 77u8, 10u8, 213u8, 209u8, 6u8, 238u8, 173u8, 47u8, 182u8, 129u8, + 69u8, 74u8, 249u8, 25u8, 170u8, 119u8, 106u8, 54u8, 165u8, 0u8, 100u8, ], ) } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_reverse_pool_id_lookup( + #[doc = "Removes a previously spawned pure proxy."] + #[doc = ""] + #[doc = "WARNING: **All access to this account will be lost.** Any funds held in it will be"] + #[doc = "inaccessible."] + #[doc = ""] + #[doc = "Requires a `Signed` origin, and the sender account must have been created by a call to"] + #[doc = "`pure` with corresponding parameters."] + #[doc = ""] + #[doc = "- `spawner`: The account that originally called `pure` to create this account."] + #[doc = "- `index`: The disambiguation index originally passed to `pure`. Probably `0`."] + #[doc = "- `proxy_type`: The proxy type originally passed to `pure`."] + #[doc = "- `height`: The height of the chain when the call to `pure` was processed."] + #[doc = "- `ext_index`: The extrinsic index in which the call to `pure` was processed."] + #[doc = ""] + #[doc = "Fails with `NoPermission` in case the caller is not a previously created pure"] + #[doc = "account whose `pure` call has corresponding parameters."] + pub fn kill_pure( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "CounterForReversePoolIdLookup", - vec![], + spawner: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + proxy_type: runtime_types::polkadot_runtime::ProxyType, + index: ::core::primitive::u16, + height: ::core::primitive::u32, + ext_index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "kill_pure", + types::KillPure { + spawner, + proxy_type, + index, + height, + ext_index, + }, [ - 148u8, 83u8, 81u8, 33u8, 188u8, 72u8, 148u8, 208u8, 245u8, 178u8, 52u8, - 245u8, 229u8, 140u8, 100u8, 152u8, 8u8, 217u8, 161u8, 80u8, 226u8, - 42u8, 15u8, 252u8, 90u8, 197u8, 120u8, 114u8, 144u8, 90u8, 199u8, - 123u8, + 134u8, 133u8, 203u8, 194u8, 12u8, 188u8, 59u8, 222u8, 83u8, 30u8, + 217u8, 181u8, 224u8, 194u8, 81u8, 206u8, 30u8, 116u8, 94u8, 36u8, 87u8, + 227u8, 157u8, 129u8, 198u8, 115u8, 208u8, 105u8, 143u8, 175u8, 145u8, + 18u8, ], ) } - #[doc = " Map from a pool member account to their opted claim permission."] - pub fn claim_permissions( + #[doc = "Publish the hash of a proxy-call that will be made in the future."] + #[doc = ""] + #[doc = "This must be called some number of blocks before the corresponding `proxy` is attempted"] + #[doc = "if the delay associated with the proxy relationship is greater than zero."] + #[doc = ""] + #[doc = "No more than `MaxPending` announcements may be made at any one time."] + #[doc = ""] + #[doc = "This will take a deposit of `AnnouncementDepositFactor` as well as"] + #[doc = "`AnnouncementDepositBase` if there are no other pending announcements."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and a proxy of `real`."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `real`: The account that the proxy will make a call on behalf of."] + #[doc = "- `call_hash`: The hash of the call to be made by the `real` account."] + pub fn announce( &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::ClaimPermission, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "ClaimPermissions", - vec![::subxt::storage::address::make_static_storage_map_key( - _0.borrow(), - )], + real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + call_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "announce", + types::Announce { real, call_hash }, [ - 23u8, 124u8, 83u8, 109u8, 174u8, 228u8, 170u8, 25u8, 124u8, 91u8, - 224u8, 66u8, 55u8, 127u8, 190u8, 226u8, 163u8, 16u8, 81u8, 231u8, - 241u8, 214u8, 209u8, 137u8, 101u8, 206u8, 104u8, 138u8, 49u8, 56u8, - 152u8, 228u8, + 235u8, 116u8, 208u8, 53u8, 128u8, 91u8, 100u8, 68u8, 255u8, 254u8, + 119u8, 253u8, 108u8, 130u8, 88u8, 56u8, 113u8, 99u8, 105u8, 179u8, + 16u8, 143u8, 131u8, 203u8, 234u8, 76u8, 199u8, 191u8, 35u8, 158u8, + 130u8, 209u8, ], ) } - #[doc = " Map from a pool member account to their opted claim permission."] - pub fn claim_permissions_root( + #[doc = "Remove a given announcement."] + #[doc = ""] + #[doc = "May be called by a proxy account to remove a call they previously announced and return"] + #[doc = "the deposit."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `real`: The account that the proxy will make a call on behalf of."] + #[doc = "- `call_hash`: The hash of the call to be made by the `real` account."] + pub fn remove_announcement( &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nomination_pools::ClaimPermission, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NominationPools", - "ClaimPermissions", - Vec::new(), + real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + call_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "remove_announcement", + types::RemoveAnnouncement { real, call_hash }, [ - 23u8, 124u8, 83u8, 109u8, 174u8, 228u8, 170u8, 25u8, 124u8, 91u8, - 224u8, 66u8, 55u8, 127u8, 190u8, 226u8, 163u8, 16u8, 81u8, 231u8, - 241u8, 214u8, 209u8, 137u8, 101u8, 206u8, 104u8, 138u8, 49u8, 56u8, - 152u8, 228u8, + 140u8, 186u8, 140u8, 129u8, 40u8, 124u8, 57u8, 61u8, 84u8, 247u8, + 123u8, 241u8, 148u8, 15u8, 94u8, 146u8, 121u8, 78u8, 190u8, 68u8, + 185u8, 125u8, 62u8, 49u8, 108u8, 131u8, 229u8, 82u8, 68u8, 37u8, 184u8, + 223u8, ], ) } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The nomination pool's pallet id."] - pub fn pallet_id( + #[doc = "Remove the given announcement of a delegate."] + #[doc = ""] + #[doc = "May be called by a target (proxied) account to remove a call that one of their delegates"] + #[doc = "(`delegate`) has announced they want to execute. The deposit is returned."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "Parameters:"] + #[doc = "- `delegate`: The account that previously announced the call."] + #[doc = "- `call_hash`: The hash of the call to be made."] + pub fn reject_announcement( &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "NominationPools", - "PalletId", + delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + call_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "reject_announcement", + types::RejectAnnouncement { + delegate, + call_hash, + }, [ - 139u8, 109u8, 228u8, 151u8, 252u8, 32u8, 130u8, 69u8, 112u8, 154u8, - 174u8, 45u8, 83u8, 245u8, 51u8, 132u8, 173u8, 5u8, 186u8, 24u8, 243u8, - 9u8, 12u8, 214u8, 80u8, 74u8, 69u8, 189u8, 30u8, 94u8, 22u8, 39u8, + 225u8, 198u8, 31u8, 173u8, 157u8, 141u8, 121u8, 51u8, 226u8, 170u8, + 219u8, 86u8, 14u8, 131u8, 122u8, 157u8, 161u8, 200u8, 157u8, 37u8, + 43u8, 97u8, 143u8, 97u8, 46u8, 206u8, 204u8, 42u8, 78u8, 33u8, 85u8, + 127u8, ], ) } - #[doc = " The maximum pool points-to-balance ratio that an `open` pool can have."] + #[doc = "Dispatch the given `call` from an account that the sender is authorized for through"] + #[doc = "`add_proxy`."] #[doc = ""] - #[doc = " This is important in the event slashing takes place and the pool's points-to-balance"] - #[doc = " ratio becomes disproportional."] + #[doc = "Removes any corresponding announcement(s)."] #[doc = ""] - #[doc = " Moreover, this relates to the `RewardCounter` type as well, as the arithmetic operations"] - #[doc = " are a function of number of points, and by setting this value to e.g. 10, you ensure"] - #[doc = " that the total number of points in the system are at most 10 times the total_issuance of"] - #[doc = " the chain, in the absolute worse case."] + #[doc = "The dispatch origin for this call must be _Signed_."] #[doc = ""] - #[doc = " For a value of 10, the threshold would be a pool points-to-balance ratio of 10:1."] - #[doc = " Such a scenario would also be the equivalent of the pool being 90% slashed."] - pub fn max_points_to_balance( + #[doc = "Parameters:"] + #[doc = "- `real`: The account that the proxy will make a call on behalf of."] + #[doc = "- `force_proxy_type`: Specify the exact proxy type to be used and checked for this call."] + #[doc = "- `call`: The call to be made by the `real` account."] + pub fn proxy_announced( &self, - ) -> ::subxt::constants::Address<::core::primitive::u8> { - ::subxt::constants::Address::new_static( - "NominationPools", - "MaxPointsToBalance", + delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + force_proxy_type: ::core::option::Option< + runtime_types::polkadot_runtime::ProxyType, + >, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Proxy", + "proxy_announced", + types::ProxyAnnounced { + delegate, + real, + force_proxy_type, + call: ::std::boxed::Box::new(call), + }, [ - 141u8, 130u8, 11u8, 35u8, 226u8, 114u8, 92u8, 179u8, 168u8, 110u8, - 28u8, 91u8, 221u8, 64u8, 4u8, 148u8, 201u8, 193u8, 185u8, 66u8, 226u8, - 114u8, 97u8, 79u8, 62u8, 212u8, 202u8, 114u8, 237u8, 228u8, 183u8, - 165u8, + 144u8, 103u8, 250u8, 31u8, 18u8, 158u8, 175u8, 139u8, 73u8, 56u8, + 178u8, 80u8, 164u8, 100u8, 162u8, 163u8, 119u8, 102u8, 177u8, 28u8, + 229u8, 128u8, 250u8, 242u8, 26u8, 223u8, 74u8, 180u8, 127u8, 124u8, + 134u8, 123u8, ], ) } } } - } - pub mod fast_unstake { - use super::root_mod; - use super::runtime_types; - #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::pallet_fast_unstake::pallet::Error; - #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] - pub mod calls { - use super::root_mod; + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_proxy::pallet::Event; + pub mod events { use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -26107,7 +22261,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RegisterFastUnstake; + #[doc = "A proxy was executed correctly, with the given."] + pub struct ProxyExecuted { + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + } + impl ::subxt::events::StaticEvent for ProxyExecuted { + const PALLET: &'static str = "Proxy"; + const EVENT: &'static str = "ProxyExecuted"; + } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -26118,9 +22279,19 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Deregister; + #[doc = "A pure account has been created by new proxy with given"] + #[doc = "disambiguation index and proxy type."] + pub struct PureCreated { + pub pure: ::subxt::utils::AccountId32, + pub who: ::subxt::utils::AccountId32, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub disambiguation_index: ::core::primitive::u16, + } + impl ::subxt::events::StaticEvent for PureCreated { + const PALLET: &'static str = "Proxy"; + const EVENT: &'static str = "PureCreated"; + } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -26130,88 +22301,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Control { - pub eras_to_check: ::core::primitive::u32, + #[doc = "An announcement was placed to make a call in the future."] + pub struct Announced { + pub real: ::subxt::utils::AccountId32, + pub proxy: ::subxt::utils::AccountId32, + pub call_hash: ::subxt::utils::H256, } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "Register oneself for fast-unstake."] - #[doc = ""] - #[doc = "The dispatch origin of this call must be signed by the controller account, similar to"] - #[doc = "`staking::unbond`."] - #[doc = ""] - #[doc = "The stash associated with the origin must have no ongoing unlocking chunks. If"] - #[doc = "successful, this will fully unbond and chill the stash. Then, it will enqueue the stash"] - #[doc = "to be checked in further blocks."] - #[doc = ""] - #[doc = "If by the time this is called, the stash is actually eligible for fast-unstake, then"] - #[doc = "they are guaranteed to remain eligible, because the call will chill them as well."] - #[doc = ""] - #[doc = "If the check works, the entire staking data is removed, i.e. the stash is fully"] - #[doc = "unstaked."] - #[doc = ""] - #[doc = "If the check fails, the stash remains chilled and waiting for being unbonded as in with"] - #[doc = "the normal staking system, but they lose part of their unbonding chunks due to consuming"] - #[doc = "the chain's resources."] - pub fn register_fast_unstake( - &self, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FastUnstake", - "register_fast_unstake", - types::RegisterFastUnstake {}, - [ - 254u8, 85u8, 128u8, 135u8, 172u8, 170u8, 34u8, 145u8, 79u8, 117u8, - 234u8, 90u8, 16u8, 174u8, 159u8, 197u8, 27u8, 239u8, 180u8, 85u8, - 116u8, 23u8, 254u8, 30u8, 197u8, 110u8, 48u8, 184u8, 177u8, 129u8, - 42u8, 122u8, - ], - ) - } - #[doc = "Deregister oneself from the fast-unstake."] - #[doc = ""] - #[doc = "This is useful if one is registered, they are still waiting, and they change their mind."] - #[doc = ""] - #[doc = "Note that the associated stash is still fully unbonded and chilled as a consequence of"] - #[doc = "calling `register_fast_unstake`. This should probably be followed by a call to"] - #[doc = "`Staking::rebond`."] - pub fn deregister(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FastUnstake", - "deregister", - types::Deregister {}, - [ - 198u8, 180u8, 253u8, 148u8, 124u8, 145u8, 175u8, 121u8, 42u8, 181u8, - 41u8, 155u8, 229u8, 181u8, 66u8, 140u8, 103u8, 86u8, 242u8, 155u8, - 192u8, 34u8, 157u8, 107u8, 211u8, 162u8, 1u8, 144u8, 35u8, 252u8, 88u8, - 21u8, - ], - ) - } - #[doc = "Control the operation of this pallet."] - #[doc = ""] - #[doc = "Dispatch origin must be signed by the [`Config::ControlOrigin`]."] - pub fn control( - &self, - eras_to_check: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FastUnstake", - "control", - Control { eras_to_check }, - [ - 92u8, 241u8, 123u8, 251u8, 82u8, 36u8, 209u8, 87u8, 238u8, 56u8, 32u8, - 54u8, 190u8, 89u8, 167u8, 2u8, 36u8, 249u8, 131u8, 54u8, 217u8, 217u8, - 231u8, 167u8, 232u8, 35u8, 108u8, 193u8, 70u8, 224u8, 47u8, 142u8, - ], - ) - } + impl ::subxt::events::StaticEvent for Announced { + const PALLET: &'static str = "Proxy"; + const EVENT: &'static str = "Announced"; } - } - #[doc = "The events of this pallet."] - pub type Event = runtime_types::pallet_fast_unstake::pallet::Event; - pub mod events { - use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -26222,70 +22321,18 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A staker was unstaked."] - pub struct Unstaked { - pub stash: ::subxt::utils::AccountId32, - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for Unstaked { - const PALLET: &'static str = "FastUnstake"; - const EVENT: &'static str = "Unstaked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A staker was slashed for requesting fast-unstake whilst being exposed."] - pub struct Slashed { - pub stash: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Slashed { - const PALLET: &'static str = "FastUnstake"; - const EVENT: &'static str = "Slashed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An internal error happened. Operations will be paused now."] - pub struct InternalError; - impl ::subxt::events::StaticEvent for InternalError { - const PALLET: &'static str = "FastUnstake"; - const EVENT: &'static str = "InternalError"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A batch was partially checked for the given eras, but the process did not finish."] - pub struct BatchChecked { - pub eras: ::std::vec::Vec<::core::primitive::u32>, + #[doc = "A proxy was added."] + pub struct ProxyAdded { + pub delegator: ::subxt::utils::AccountId32, + pub delegatee: ::subxt::utils::AccountId32, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub delay: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for BatchChecked { - const PALLET: &'static str = "FastUnstake"; - const EVENT: &'static str = "BatchChecked"; + impl ::subxt::events::StaticEvent for ProxyAdded { + const PALLET: &'static str = "Proxy"; + const EVENT: &'static str = "ProxyAdded"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -26295,140 +22342,149 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A batch of a given size was terminated."] - #[doc = ""] - #[doc = "This is always follows by a number of `Unstaked` or `Slashed` events, marking the end"] - #[doc = "of the batch. A new batch will be created upon next block."] - pub struct BatchFinished { - pub size: ::core::primitive::u32, + #[doc = "A proxy was removed."] + pub struct ProxyRemoved { + pub delegator: ::subxt::utils::AccountId32, + pub delegatee: ::subxt::utils::AccountId32, + pub proxy_type: runtime_types::polkadot_runtime::ProxyType, + pub delay: ::core::primitive::u32, } - impl ::subxt::events::StaticEvent for BatchFinished { - const PALLET: &'static str = "FastUnstake"; - const EVENT: &'static str = "BatchFinished"; + impl ::subxt::events::StaticEvent for ProxyRemoved { + const PALLET: &'static str = "Proxy"; + const EVENT: &'static str = "ProxyRemoved"; } } pub mod storage { use super::runtime_types; pub struct StorageApi; impl StorageApi { - #[doc = " The current \"head of the queue\" being unstaked."] - pub fn head( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_fast_unstake::types::UnstakeRequest, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "FastUnstake", - "Head", - vec![], - [ - 206u8, 19u8, 169u8, 239u8, 214u8, 136u8, 16u8, 102u8, 82u8, 110u8, - 128u8, 205u8, 102u8, 96u8, 148u8, 190u8, 67u8, 75u8, 2u8, 213u8, 134u8, - 143u8, 40u8, 57u8, 54u8, 66u8, 170u8, 42u8, 135u8, 212u8, 108u8, 177u8, - ], - ) - } - #[doc = " The map of all accounts wishing to be unstaked."] - #[doc = ""] - #[doc = " Keeps track of `AccountId` wishing to unstake and it's corresponding deposit."] - #[doc = ""] - #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] - pub fn queue( + #[doc = " The set of account proxies. Maps the account which has delegated to the accounts"] + #[doc = " which are being delegated to, together with the amount held on deposit."] + pub fn proxies( &self, _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, + ( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_proxy::ProxyDefinition< + ::subxt::utils::AccountId32, + runtime_types::polkadot_runtime::ProxyType, + ::core::primitive::u32, + >, + >, + ::core::primitive::u128, + ), + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "FastUnstake", - "Queue", + "Proxy", + "Proxies", vec![::subxt::storage::address::make_static_storage_map_key( _0.borrow(), )], [ - 250u8, 208u8, 88u8, 68u8, 8u8, 87u8, 27u8, 59u8, 120u8, 242u8, 79u8, - 54u8, 108u8, 15u8, 62u8, 143u8, 126u8, 66u8, 159u8, 159u8, 55u8, 212u8, - 190u8, 26u8, 171u8, 90u8, 156u8, 205u8, 173u8, 189u8, 230u8, 71u8, + 80u8, 71u8, 244u8, 42u8, 237u8, 5u8, 46u8, 156u8, 84u8, 213u8, 84u8, + 212u8, 157u8, 221u8, 174u8, 97u8, 157u8, 218u8, 166u8, 127u8, 162u8, + 139u8, 110u8, 98u8, 229u8, 166u8, 49u8, 172u8, 48u8, 237u8, 240u8, + 42u8, ], ) } - #[doc = " The map of all accounts wishing to be unstaked."] - #[doc = ""] - #[doc = " Keeps track of `AccountId` wishing to unstake and it's corresponding deposit."] - #[doc = ""] - #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] - pub fn queue_root( + #[doc = " The set of account proxies. Maps the account which has delegated to the accounts"] + #[doc = " which are being delegated to, together with the amount held on deposit."] + pub fn proxies_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - (), + ( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_proxy::ProxyDefinition< + ::subxt::utils::AccountId32, + runtime_types::polkadot_runtime::ProxyType, + ::core::primitive::u32, + >, + >, + ::core::primitive::u128, + ), (), ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, > { ::subxt::storage::address::Address::new_static( - "FastUnstake", - "Queue", + "Proxy", + "Proxies", Vec::new(), [ - 250u8, 208u8, 88u8, 68u8, 8u8, 87u8, 27u8, 59u8, 120u8, 242u8, 79u8, - 54u8, 108u8, 15u8, 62u8, 143u8, 126u8, 66u8, 159u8, 159u8, 55u8, 212u8, - 190u8, 26u8, 171u8, 90u8, 156u8, 205u8, 173u8, 189u8, 230u8, 71u8, + 80u8, 71u8, 244u8, 42u8, 237u8, 5u8, 46u8, 156u8, 84u8, 213u8, 84u8, + 212u8, 157u8, 221u8, 174u8, 97u8, 157u8, 218u8, 166u8, 127u8, 162u8, + 139u8, 110u8, 98u8, 229u8, 166u8, 49u8, 172u8, 48u8, 237u8, 240u8, + 42u8, ], ) } - #[doc = "Counter for the related counted storage map"] - pub fn counter_for_queue( + #[doc = " The announcements made by the proxy (key)."] + pub fn announcements( &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + ( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_proxy::Announcement< + ::subxt::utils::AccountId32, + ::subxt::utils::H256, + ::core::primitive::u32, + >, + >, + ::core::primitive::u128, + ), + ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), > { ::subxt::storage::address::Address::new_static( - "FastUnstake", - "CounterForQueue", - vec![], + "Proxy", + "Announcements", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], [ - 241u8, 174u8, 224u8, 214u8, 204u8, 37u8, 117u8, 62u8, 114u8, 63u8, - 123u8, 121u8, 201u8, 128u8, 26u8, 60u8, 170u8, 24u8, 112u8, 5u8, 248u8, - 7u8, 143u8, 17u8, 150u8, 91u8, 23u8, 90u8, 237u8, 4u8, 138u8, 210u8, + 233u8, 38u8, 249u8, 89u8, 103u8, 87u8, 64u8, 52u8, 140u8, 228u8, 110u8, + 37u8, 8u8, 92u8, 48u8, 7u8, 46u8, 99u8, 179u8, 83u8, 232u8, 171u8, + 160u8, 45u8, 37u8, 23u8, 151u8, 198u8, 237u8, 103u8, 217u8, 53u8, ], ) } - #[doc = " Number of eras to check per block."] - #[doc = ""] - #[doc = " If set to 0, this pallet does absolutely nothing."] - #[doc = ""] - #[doc = " Based on the amount of weight available at `on_idle`, up to this many eras of a single"] - #[doc = " nominator might be checked."] - pub fn eras_to_check_per_block( + #[doc = " The announcements made by the proxy (key)."] + pub fn announcements_root( &self, ) -> ::subxt::storage::address::Address< ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, + ( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_proxy::Announcement< + ::subxt::utils::AccountId32, + ::subxt::utils::H256, + ::core::primitive::u32, + >, + >, + ::core::primitive::u128, + ), + (), ::subxt::storage::address::Yes, ::subxt::storage::address::Yes, - (), > { ::subxt::storage::address::Address::new_static( - "FastUnstake", - "ErasToCheckPerBlock", - vec![], + "Proxy", + "Announcements", + Vec::new(), [ - 85u8, 55u8, 18u8, 11u8, 75u8, 176u8, 36u8, 253u8, 183u8, 250u8, 203u8, - 178u8, 201u8, 79u8, 101u8, 89u8, 51u8, 142u8, 254u8, 23u8, 49u8, 140u8, - 195u8, 116u8, 66u8, 124u8, 165u8, 161u8, 151u8, 174u8, 37u8, 51u8, + 233u8, 38u8, 249u8, 89u8, 103u8, 87u8, 64u8, 52u8, 140u8, 228u8, 110u8, + 37u8, 8u8, 92u8, 48u8, 7u8, 46u8, 99u8, 179u8, 83u8, 232u8, 171u8, + 160u8, 45u8, 37u8, 23u8, 151u8, 198u8, 237u8, 103u8, 217u8, 53u8, ], ) } @@ -26438,12 +22494,94 @@ pub mod api { use super::runtime_types; pub struct ConstantsApi; impl ConstantsApi { - #[doc = " Deposit to take for unstaking, to make sure we're able to slash the it in order to cover"] - #[doc = " the costs of resources on unsuccessful unstake."] - pub fn deposit(&self) -> ::subxt::constants::Address<::core::primitive::u128> { + #[doc = " The base amount of currency needed to reserve for creating a proxy."] + #[doc = ""] + #[doc = " This is held for an additional storage item whose value size is"] + #[doc = " `sizeof(Balance)` bytes and whose key size is `sizeof(AccountId)` bytes."] + pub fn proxy_deposit_base( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { ::subxt::constants::Address::new_static( - "FastUnstake", - "Deposit", + "Proxy", + "ProxyDepositBase", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The amount of currency needed per proxy added."] + #[doc = ""] + #[doc = " This is held for adding 32 bytes plus an instance of `ProxyType` more into a"] + #[doc = " pre-existing storage value. Thus, when configuring `ProxyDepositFactor` one should take"] + #[doc = " into account `32 + proxy_type.encode().len()` bytes of data."] + pub fn proxy_deposit_factor( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Proxy", + "ProxyDepositFactor", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The maximum amount of proxies allowed for a single account."] + pub fn max_proxies(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Proxy", + "MaxProxies", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The maximum amount of time-delayed announcements that are allowed to be pending."] + pub fn max_pending(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Proxy", + "MaxPending", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The base amount of currency needed to reserve for creating an announcement."] + #[doc = ""] + #[doc = " This is held when a new storage item holding a `Balance` is created (typically 16"] + #[doc = " bytes)."] + pub fn announcement_deposit_base( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Proxy", + "AnnouncementDepositBase", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The amount of currency needed per announcement made."] + #[doc = ""] + #[doc = " This is held for adding an `AccountId`, `Hash` and `BlockNumber` (typically 68 bytes)"] + #[doc = " into a pre-existing storage value."] + pub fn announcement_deposit_factor( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Proxy", + "AnnouncementDepositFactor", [ 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, @@ -26454,244 +22592,298 @@ pub mod api { } } } - pub mod parachains_origin { - use super::root_mod; - use super::runtime_types; - } - pub mod configuration { + pub mod multisig { use super::root_mod; use super::runtime_types; #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] - pub type Error = runtime_types::polkadot_runtime_parachains::configuration::pallet::Error; + pub type Error = runtime_types::pallet_multisig::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] pub mod calls { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetValidationUpgradeCooldown { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetValidationUpgradeDelay { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCodeRetentionPeriod { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxCodeSize { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxPovSize { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxHeadDataSize { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetParathreadCores { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetParathreadRetries { - pub new: ::core::primitive::u32, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AsMultiThreshold1 { + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub call: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AsMulti { + pub threshold: ::core::primitive::u16, + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + >, + pub call: ::std::boxed::Box, + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ApproveAsMulti { + pub threshold: ::core::primitive::u16, + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + >, + pub call_hash: [::core::primitive::u8; 32usize], + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelAsMulti { + pub threshold: ::core::primitive::u16, + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub timepoint: + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub call_hash: [::core::primitive::u8; 32usize], + } } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetGroupRotationFrequency { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetChainAvailabilityPeriod { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetThreadAvailabilityPeriod { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetSchedulingLookahead { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxValidatorsPerCore { - pub new: ::core::option::Option<::core::primitive::u32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxValidators { - pub new: ::core::option::Option<::core::primitive::u32>, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetDisputePeriod { - pub new: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetDisputePostConclusionAcceptancePeriod { - pub new: ::core::primitive::u32, + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Immediately dispatch a multi-signature call using a single approval from the caller."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "- `other_signatories`: The accounts (other than the sender) who are part of the"] + #[doc = "multi-signature, but do not participate in the approval process."] + #[doc = "- `call`: The call to be executed."] + #[doc = ""] + #[doc = "Result is equivalent to the dispatched result."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "O(Z + C) where Z is the length of the call and C its execution weight."] + pub fn as_multi_threshold_1( + &self, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + call: runtime_types::polkadot_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Multisig", + "as_multi_threshold_1", + types::AsMultiThreshold1 { + other_signatories, + call: ::std::boxed::Box::new(call), + }, + [ + 113u8, 140u8, 77u8, 180u8, 170u8, 232u8, 85u8, 229u8, 218u8, 187u8, + 62u8, 64u8, 168u8, 186u8, 173u8, 27u8, 125u8, 216u8, 54u8, 167u8, + 225u8, 241u8, 10u8, 226u8, 138u8, 151u8, 242u8, 255u8, 212u8, 160u8, + 106u8, 69u8, + ], + ) + } + #[doc = "Register approval for a dispatch to be made from a deterministic composite account if"] + #[doc = "approved by a total of `threshold - 1` of `other_signatories`."] + #[doc = ""] + #[doc = "If there are enough, then dispatch the call."] + #[doc = ""] + #[doc = "Payment: `DepositBase` will be reserved if this is the first approval, plus"] + #[doc = "`threshold` times `DepositFactor`. It is returned once this dispatch happens or"] + #[doc = "is cancelled."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "- `threshold`: The total number of approvals for this dispatch before it is executed."] + #[doc = "- `other_signatories`: The accounts (other than the sender) who can approve this"] + #[doc = "dispatch. May not be empty."] + #[doc = "- `maybe_timepoint`: If this is the first approval, then this must be `None`. If it is"] + #[doc = "not the first approval, then it must be `Some`, with the timepoint (block number and"] + #[doc = "transaction index) of the first approval transaction."] + #[doc = "- `call`: The call to be executed."] + #[doc = ""] + #[doc = "NOTE: Unless this is the final approval, you will generally want to use"] + #[doc = "`approve_as_multi` instead, since it only requires a hash of the call."] + #[doc = ""] + #[doc = "Result is equivalent to the dispatched result if `threshold` is exactly `1`. Otherwise"] + #[doc = "on success, result is `Ok` and the result from the interior call, if it was executed,"] + #[doc = "may be found in the deposited `MultisigExecuted` event."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(S + Z + Call)`."] + #[doc = "- Up to one balance-reserve or unreserve operation."] + #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] + #[doc = " signatories. `S` is capped by `MaxSignatories`, with weight being proportional."] + #[doc = "- One call encode & hash, both of complexity `O(Z)` where `Z` is tx-len."] + #[doc = "- One encode & hash, both of complexity `O(S)`."] + #[doc = "- Up to one binary search and insert (`O(logS + S)`)."] + #[doc = "- I/O: 1 read `O(S)`, up to 1 mutate `O(S)`. Up to one remove."] + #[doc = "- One event."] + #[doc = "- The weight of the `call`."] + #[doc = "- Storage: inserts one item, value size bounded by `MaxSignatories`, with a deposit"] + #[doc = " taken for its lifetime of `DepositBase + threshold * DepositFactor`."] + pub fn as_multi( + &self, + threshold: ::core::primitive::u16, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + >, + call: runtime_types::polkadot_runtime::RuntimeCall, + max_weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Multisig", + "as_multi", + types::AsMulti { + threshold, + other_signatories, + maybe_timepoint, + call: ::std::boxed::Box::new(call), + max_weight, + }, + [ + 167u8, 155u8, 31u8, 18u8, 196u8, 45u8, 139u8, 126u8, 185u8, 246u8, + 31u8, 88u8, 200u8, 228u8, 82u8, 139u8, 123u8, 239u8, 169u8, 185u8, + 227u8, 160u8, 71u8, 242u8, 152u8, 146u8, 87u8, 243u8, 170u8, 237u8, + 11u8, 6u8, + ], + ) + } + #[doc = "Register approval for a dispatch to be made from a deterministic composite account if"] + #[doc = "approved by a total of `threshold - 1` of `other_signatories`."] + #[doc = ""] + #[doc = "Payment: `DepositBase` will be reserved if this is the first approval, plus"] + #[doc = "`threshold` times `DepositFactor`. It is returned once this dispatch happens or"] + #[doc = "is cancelled."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "- `threshold`: The total number of approvals for this dispatch before it is executed."] + #[doc = "- `other_signatories`: The accounts (other than the sender) who can approve this"] + #[doc = "dispatch. May not be empty."] + #[doc = "- `maybe_timepoint`: If this is the first approval, then this must be `None`. If it is"] + #[doc = "not the first approval, then it must be `Some`, with the timepoint (block number and"] + #[doc = "transaction index) of the first approval transaction."] + #[doc = "- `call_hash`: The hash of the call to be executed."] + #[doc = ""] + #[doc = "NOTE: If this is the final approval, you will want to use `as_multi` instead."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(S)`."] + #[doc = "- Up to one balance-reserve or unreserve operation."] + #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] + #[doc = " signatories. `S` is capped by `MaxSignatories`, with weight being proportional."] + #[doc = "- One encode & hash, both of complexity `O(S)`."] + #[doc = "- Up to one binary search and insert (`O(logS + S)`)."] + #[doc = "- I/O: 1 read `O(S)`, up to 1 mutate `O(S)`. Up to one remove."] + #[doc = "- One event."] + #[doc = "- Storage: inserts one item, value size bounded by `MaxSignatories`, with a deposit"] + #[doc = " taken for its lifetime of `DepositBase + threshold * DepositFactor`."] + pub fn approve_as_multi( + &self, + threshold: ::core::primitive::u16, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + >, + call_hash: [::core::primitive::u8; 32usize], + max_weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Multisig", + "approve_as_multi", + types::ApproveAsMulti { + threshold, + other_signatories, + maybe_timepoint, + call_hash, + max_weight, + }, + [ + 133u8, 113u8, 121u8, 66u8, 218u8, 219u8, 48u8, 64u8, 211u8, 114u8, + 163u8, 193u8, 164u8, 21u8, 140u8, 218u8, 253u8, 237u8, 240u8, 126u8, + 200u8, 213u8, 184u8, 50u8, 187u8, 182u8, 30u8, 52u8, 142u8, 72u8, + 210u8, 101u8, + ], + ) + } + #[doc = "Cancel a pre-existing, on-going multisig transaction. Any deposit reserved previously"] + #[doc = "for this operation will be unreserved on success."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "- `threshold`: The total number of approvals for this dispatch before it is executed."] + #[doc = "- `other_signatories`: The accounts (other than the sender) who can approve this"] + #[doc = "dispatch. May not be empty."] + #[doc = "- `timepoint`: The timepoint (block number and transaction index) of the first approval"] + #[doc = "transaction for this dispatch."] + #[doc = "- `call_hash`: The hash of the call to be executed."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(S)`."] + #[doc = "- Up to one balance-reserve or unreserve operation."] + #[doc = "- One passthrough operation, one insert, both `O(S)` where `S` is the number of"] + #[doc = " signatories. `S` is capped by `MaxSignatories`, with weight being proportional."] + #[doc = "- One encode & hash, both of complexity `O(S)`."] + #[doc = "- One event."] + #[doc = "- I/O: 1 read `O(S)`, one remove."] + #[doc = "- Storage: removes one item."] + pub fn cancel_as_multi( + &self, + threshold: ::core::primitive::u16, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + call_hash: [::core::primitive::u8; 32usize], + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Multisig", + "cancel_as_multi", + types::CancelAsMulti { + threshold, + other_signatories, + timepoint, + call_hash, + }, + [ + 30u8, 25u8, 186u8, 142u8, 168u8, 81u8, 235u8, 164u8, 82u8, 209u8, 66u8, + 129u8, 209u8, 78u8, 172u8, 9u8, 163u8, 222u8, 125u8, 57u8, 2u8, 43u8, + 169u8, 174u8, 159u8, 167u8, 25u8, 226u8, 254u8, 110u8, 80u8, 216u8, + ], + ) + } } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_multisig::pallet::Event; + pub mod events { + use super::runtime_types; #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -26701,25 +22893,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetNoShowSlots { - pub new: ::core::primitive::u32, + #[doc = "A new multisig operation has begun."] + pub struct NewMultisig { + pub approving: ::subxt::utils::AccountId32, + pub multisig: ::subxt::utils::AccountId32, + pub call_hash: [::core::primitive::u8; 32usize], } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetNDelayTranches { - pub new: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for NewMultisig { + const PALLET: &'static str = "Multisig"; + const EVENT: &'static str = "NewMultisig"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -26729,25 +22913,18 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetZerothDelayTrancheWidth { - pub new: ::core::primitive::u32, + #[doc = "A multisig operation has been approved by someone."] + pub struct MultisigApproval { + pub approving: ::subxt::utils::AccountId32, + pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub multisig: ::subxt::utils::AccountId32, + pub call_hash: [::core::primitive::u8; 32usize], } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetNeededApprovals { - pub new: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for MultisigApproval { + const PALLET: &'static str = "Multisig"; + const EVENT: &'static str = "MultisigApproval"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -26757,25 +22934,19 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetRelayVrfModuloSamples { - pub new: ::core::primitive::u32, + #[doc = "A multisig operation has been executed."] + pub struct MultisigExecuted { + pub approving: ::subxt::utils::AccountId32, + pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub multisig: ::subxt::utils::AccountId32, + pub call_hash: [::core::primitive::u8; 32usize], + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxUpwardQueueCount { - pub new: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for MultisigExecuted { + const PALLET: &'static str = "Multisig"; + const EVENT: &'static str = "MultisigExecuted"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -26785,78 +22956,524 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxUpwardQueueSize { - pub new: ::core::primitive::u32, + #[doc = "A multisig operation has been cancelled."] + pub struct MultisigCancelled { + pub cancelling: ::subxt::utils::AccountId32, + pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub multisig: ::subxt::utils::AccountId32, + pub call_hash: [::core::primitive::u8; 32usize], } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxDownwardMessageSize { - pub new: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for MultisigCancelled { + const PALLET: &'static str = "Multisig"; + const EVENT: &'static str = "MultisigCancelled"; } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetUmpServiceTotalWeight { - pub new: runtime_types::sp_weights::weight_v2::Weight, + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The set of open multisig operations."] + pub fn multisigs( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _1: impl ::std::borrow::Borrow<[::core::primitive::u8; 32usize]>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_multisig::Multisig< + ::core::primitive::u32, + ::core::primitive::u128, + ::subxt::utils::AccountId32, + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Multisig", + "Multisigs", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 69u8, 153u8, 186u8, 204u8, 117u8, 95u8, 119u8, 182u8, 220u8, 87u8, 8u8, + 15u8, 123u8, 83u8, 5u8, 188u8, 115u8, 121u8, 163u8, 96u8, 218u8, 3u8, + 106u8, 44u8, 44u8, 187u8, 46u8, 238u8, 80u8, 203u8, 175u8, 155u8, + ], + ) + } + #[doc = " The set of open multisig operations."] + pub fn multisigs_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_multisig::Multisig< + ::core::primitive::u32, + ::core::primitive::u128, + ::subxt::utils::AccountId32, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Multisig", + "Multisigs", + Vec::new(), + [ + 69u8, 153u8, 186u8, 204u8, 117u8, 95u8, 119u8, 182u8, 220u8, 87u8, 8u8, + 15u8, 123u8, 83u8, 5u8, 188u8, 115u8, 121u8, 163u8, 96u8, 218u8, 3u8, + 106u8, 44u8, 44u8, 187u8, 46u8, 238u8, 80u8, 203u8, 175u8, 155u8, + ], + ) + } } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxUpwardMessageSize { - pub new: ::core::primitive::u32, + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The base amount of currency needed to reserve for creating a multisig execution or to"] + #[doc = " store a dispatch call for later."] + #[doc = ""] + #[doc = " This is held for an additional storage item whose value size is"] + #[doc = " `4 + sizeof((BlockNumber, Balance, AccountId))` bytes and whose key size is"] + #[doc = " `32 + sizeof(AccountId)` bytes."] + pub fn deposit_base(&self) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Multisig", + "DepositBase", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The amount of currency needed per unit threshold when creating a multisig execution."] + #[doc = ""] + #[doc = " This is held for adding 32 bytes more into a pre-existing storage value."] + pub fn deposit_factor( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Multisig", + "DepositFactor", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The maximum amount of signatories allowed in the multisig."] + pub fn max_signatories( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Multisig", + "MaxSignatories", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxUpwardMessageNumPerCandidate { - pub new: ::core::primitive::u32, + } + } + pub mod bounties { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_bounties::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProposeBounty { + #[codec(compact)] + pub value: ::core::primitive::u128, + pub description: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ApproveBounty { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProposeCurator { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub fee: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UnassignCurator { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AcceptCurator { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AwardBounty { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClaimBounty { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CloseBounty { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ExtendBountyExpiry { + #[codec(compact)] + pub bounty_id: ::core::primitive::u32, + pub remark: ::std::vec::Vec<::core::primitive::u8>, + } } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpOpenRequestTtl { - pub new: ::core::primitive::u32, + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Propose a new bounty."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "Payment: `TipReportDepositBase` will be reserved from the origin account, as well as"] + #[doc = "`DataDepositPerByte` for each byte in `reason`. It will be unreserved upon approval,"] + #[doc = "or slashed when rejected."] + #[doc = ""] + #[doc = "- `curator`: The curator account whom will manage this bounty."] + #[doc = "- `fee`: The curator fee."] + #[doc = "- `value`: The total payment amount of this bounty, curator fee included."] + #[doc = "- `description`: The description of this bounty."] + pub fn propose_bounty( + &self, + value: ::core::primitive::u128, + description: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "propose_bounty", + types::ProposeBounty { value, description }, + [ + 99u8, 160u8, 94u8, 74u8, 105u8, 161u8, 123u8, 239u8, 241u8, 117u8, + 97u8, 99u8, 84u8, 101u8, 87u8, 3u8, 88u8, 175u8, 75u8, 59u8, 114u8, + 87u8, 18u8, 113u8, 126u8, 26u8, 42u8, 104u8, 201u8, 128u8, 102u8, + 219u8, + ], + ) + } + #[doc = "Approve a bounty proposal. At a later time, the bounty will be funded and become active"] + #[doc = "and the original deposit will be returned."] + #[doc = ""] + #[doc = "May only be called from `T::SpendOrigin`."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn approve_bounty( + &self, + bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "approve_bounty", + types::ApproveBounty { bounty_id }, + [ + 82u8, 228u8, 232u8, 103u8, 198u8, 173u8, 190u8, 148u8, 159u8, 86u8, + 48u8, 4u8, 32u8, 169u8, 1u8, 129u8, 96u8, 145u8, 235u8, 68u8, 48u8, + 34u8, 5u8, 1u8, 76u8, 26u8, 100u8, 228u8, 92u8, 198u8, 183u8, 173u8, + ], + ) + } + #[doc = "Assign a curator to a funded bounty."] + #[doc = ""] + #[doc = "May only be called from `T::SpendOrigin`."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn propose_curator( + &self, + bounty_id: ::core::primitive::u32, + curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + fee: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "propose_curator", + types::ProposeCurator { + bounty_id, + curator, + fee, + }, + [ + 123u8, 148u8, 21u8, 204u8, 216u8, 6u8, 47u8, 83u8, 182u8, 30u8, 171u8, + 48u8, 193u8, 200u8, 197u8, 147u8, 111u8, 88u8, 14u8, 242u8, 66u8, + 175u8, 241u8, 208u8, 95u8, 151u8, 41u8, 46u8, 213u8, 188u8, 65u8, + 196u8, + ], + ) + } + #[doc = "Unassign curator from a bounty."] + #[doc = ""] + #[doc = "This function can only be called by the `RejectOrigin` a signed origin."] + #[doc = ""] + #[doc = "If this function is called by the `RejectOrigin`, we assume that the curator is"] + #[doc = "malicious or inactive. As a result, we will slash the curator when possible."] + #[doc = ""] + #[doc = "If the origin is the curator, we take this as a sign they are unable to do their job and"] + #[doc = "they willingly give up. We could slash them, but for now we allow them to recover their"] + #[doc = "deposit and exit without issue. (We may want to change this if it is abused.)"] + #[doc = ""] + #[doc = "Finally, the origin can be anyone if and only if the curator is \"inactive\". This allows"] + #[doc = "anyone in the community to call out that a curator is not doing their due diligence, and"] + #[doc = "we should pick a new curator. In this case the curator should also be slashed."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn unassign_curator( + &self, + bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "unassign_curator", + types::UnassignCurator { bounty_id }, + [ + 218u8, 241u8, 247u8, 89u8, 95u8, 120u8, 93u8, 18u8, 85u8, 114u8, 158u8, + 254u8, 68u8, 77u8, 230u8, 186u8, 230u8, 201u8, 63u8, 223u8, 28u8, + 173u8, 244u8, 82u8, 113u8, 177u8, 99u8, 27u8, 207u8, 247u8, 207u8, + 213u8, + ], + ) + } + #[doc = "Accept the curator role for a bounty."] + #[doc = "A deposit will be reserved from curator and refund upon successful payout."] + #[doc = ""] + #[doc = "May only be called from the curator."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn accept_curator( + &self, + bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "accept_curator", + types::AcceptCurator { bounty_id }, + [ + 106u8, 96u8, 22u8, 67u8, 52u8, 109u8, 180u8, 225u8, 122u8, 253u8, + 209u8, 214u8, 132u8, 131u8, 247u8, 131u8, 162u8, 51u8, 144u8, 30u8, + 12u8, 126u8, 50u8, 152u8, 229u8, 119u8, 54u8, 116u8, 112u8, 235u8, + 34u8, 166u8, + ], + ) + } + #[doc = "Award bounty to a beneficiary account. The beneficiary will be able to claim the funds"] + #[doc = "after a delay."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be the curator of this bounty."] + #[doc = ""] + #[doc = "- `bounty_id`: Bounty ID to award."] + #[doc = "- `beneficiary`: The beneficiary account whom will receive the payout."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn award_bounty( + &self, + bounty_id: ::core::primitive::u32, + beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "award_bounty", + types::AwardBounty { + bounty_id, + beneficiary, + }, + [ + 203u8, 164u8, 214u8, 242u8, 1u8, 11u8, 217u8, 32u8, 189u8, 136u8, 29u8, + 230u8, 88u8, 17u8, 134u8, 189u8, 15u8, 204u8, 223u8, 20u8, 168u8, + 182u8, 129u8, 48u8, 83u8, 25u8, 125u8, 25u8, 209u8, 155u8, 170u8, 68u8, + ], + ) + } + #[doc = "Claim the payout from an awarded bounty after payout delay."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be the beneficiary of this bounty."] + #[doc = ""] + #[doc = "- `bounty_id`: Bounty ID to claim."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn claim_bounty( + &self, + bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "claim_bounty", + types::ClaimBounty { bounty_id }, + [ + 102u8, 95u8, 8u8, 89u8, 4u8, 126u8, 189u8, 28u8, 241u8, 16u8, 125u8, + 218u8, 42u8, 92u8, 177u8, 91u8, 8u8, 235u8, 33u8, 48u8, 64u8, 115u8, + 177u8, 95u8, 242u8, 97u8, 181u8, 50u8, 68u8, 37u8, 59u8, 85u8, + ], + ) + } + #[doc = "Cancel a proposed or active bounty. All the funds will be sent to treasury and"] + #[doc = "the curator deposit will be unreserved if possible."] + #[doc = ""] + #[doc = "Only `T::RejectOrigin` is able to cancel a bounty."] + #[doc = ""] + #[doc = "- `bounty_id`: Bounty ID to cancel."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn close_bounty( + &self, + bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "close_bounty", + types::CloseBounty { bounty_id }, + [ + 64u8, 113u8, 151u8, 228u8, 90u8, 55u8, 251u8, 63u8, 27u8, 211u8, 119u8, + 229u8, 137u8, 137u8, 183u8, 240u8, 241u8, 146u8, 69u8, 169u8, 124u8, + 220u8, 236u8, 111u8, 98u8, 188u8, 100u8, 52u8, 127u8, 245u8, 244u8, + 92u8, + ], + ) + } + #[doc = "Extend the expiry time of an active bounty."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be the curator of this bounty."] + #[doc = ""] + #[doc = "- `bounty_id`: Bounty ID to extend."] + #[doc = "- `remark`: additional information."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn extend_bounty_expiry( + &self, + bounty_id: ::core::primitive::u32, + remark: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Bounties", + "extend_bounty_expiry", + types::ExtendBountyExpiry { bounty_id, remark }, + [ + 97u8, 69u8, 157u8, 39u8, 59u8, 72u8, 79u8, 88u8, 104u8, 119u8, 91u8, + 26u8, 73u8, 216u8, 174u8, 95u8, 254u8, 214u8, 63u8, 138u8, 100u8, + 112u8, 185u8, 81u8, 159u8, 247u8, 221u8, 60u8, 87u8, 40u8, 80u8, 202u8, + ], + ) + } } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_bounties::pallet::Event; + pub mod events { + use super::runtime_types; #[derive( :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, @@ -26868,25 +23485,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpSenderDeposit { - pub new: ::core::primitive::u128, + #[doc = "New bounty proposal."] + pub struct BountyProposed { + pub index: ::core::primitive::u32, } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpRecipientDeposit { - pub new: ::core::primitive::u128, + impl ::subxt::events::StaticEvent for BountyProposed { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyProposed"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -26896,22 +23503,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpChannelMaxCapacity { - pub new: ::core::primitive::u32, + #[doc = "A bounty proposal was rejected; funds were slashed."] + pub struct BountyRejected { + pub index: ::core::primitive::u32, + pub bond: ::core::primitive::u128, } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpChannelMaxTotalSize { - pub new: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for BountyRejected { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyRejected"; } #[derive( :: subxt :: ext :: codec :: CompactAs, @@ -26924,25 +23523,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpMaxParachainInboundChannels { - pub new: ::core::primitive::u32, + #[doc = "A bounty proposal is funded and became active."] + pub struct BountyBecameActive { + pub index: ::core::primitive::u32, } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpMaxParathreadInboundChannels { - pub new: ::core::primitive::u32, + impl ::subxt::events::StaticEvent for BountyBecameActive { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyBecameActive"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -26952,11 +23541,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpChannelMaxMessageSize { - pub new: ::core::primitive::u32, + #[doc = "A bounty is awarded to a beneficiary."] + pub struct BountyAwarded { + pub index: ::core::primitive::u32, + pub beneficiary: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for BountyAwarded { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyAwarded"; } #[derive( - :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -26966,8 +23560,15 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpMaxParachainOutboundChannels { - pub new: ::core::primitive::u32, + #[doc = "A bounty is claimed by beneficiary."] + pub struct BountyClaimed { + pub index: ::core::primitive::u32, + pub payout: ::core::primitive::u128, + pub beneficiary: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for BountyClaimed { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyClaimed"; } #[derive( :: subxt :: ext :: codec :: CompactAs, @@ -26980,8 +23581,13 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpMaxParathreadOutboundChannels { - pub new: ::core::primitive::u32, + #[doc = "A bounty is cancelled."] + pub struct BountyCanceled { + pub index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for BountyCanceled { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyCanceled"; } #[derive( :: subxt :: ext :: codec :: CompactAs, @@ -26994,63 +23600,5081 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpMaxMessageNumPerCandidate { - pub new: ::core::primitive::u32, + #[doc = "A bounty expiry is extended."] + pub struct BountyExtended { + pub index: ::core::primitive::u32, } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetUmpMaxIndividualWeight { - pub new: runtime_types::sp_weights::weight_v2::Weight, + impl ::subxt::events::StaticEvent for BountyExtended { + const PALLET: &'static str = "Bounties"; + const EVENT: &'static str = "BountyExtended"; } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Number of bounty proposals that have been made."] + pub fn bounty_count( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Bounties", + "BountyCount", + vec![], + [ + 5u8, 188u8, 134u8, 220u8, 64u8, 49u8, 188u8, 98u8, 185u8, 186u8, 230u8, + 65u8, 247u8, 199u8, 28u8, 178u8, 202u8, 193u8, 41u8, 83u8, 115u8, + 253u8, 182u8, 123u8, 92u8, 138u8, 12u8, 31u8, 31u8, 213u8, 23u8, 118u8, + ], + ) + } + #[doc = " Bounties that have been made."] + pub fn bounties( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_bounties::Bounty< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Bounties", + "Bounties", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 111u8, 149u8, 33u8, 54u8, 172u8, 143u8, 41u8, 231u8, 184u8, 255u8, + 238u8, 206u8, 87u8, 142u8, 84u8, 10u8, 236u8, 141u8, 190u8, 193u8, + 72u8, 170u8, 19u8, 110u8, 135u8, 136u8, 220u8, 11u8, 99u8, 126u8, + 225u8, 208u8, + ], + ) + } + #[doc = " Bounties that have been made."] + pub fn bounties_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_bounties::Bounty< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Bounties", + "Bounties", + Vec::new(), + [ + 111u8, 149u8, 33u8, 54u8, 172u8, 143u8, 41u8, 231u8, 184u8, 255u8, + 238u8, 206u8, 87u8, 142u8, 84u8, 10u8, 236u8, 141u8, 190u8, 193u8, + 72u8, 170u8, 19u8, 110u8, 135u8, 136u8, 220u8, 11u8, 99u8, 126u8, + 225u8, 208u8, + ], + ) + } + #[doc = " The description of each bounty."] + pub fn bounty_descriptions( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Bounties", + "BountyDescriptions", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 252u8, 0u8, 9u8, 225u8, 13u8, 135u8, 7u8, 121u8, 154u8, 155u8, 116u8, + 83u8, 160u8, 37u8, 72u8, 11u8, 72u8, 0u8, 248u8, 73u8, 158u8, 84u8, + 125u8, 221u8, 176u8, 231u8, 100u8, 239u8, 111u8, 22u8, 29u8, 13u8, + ], + ) + } + #[doc = " The description of each bounty."] + pub fn bounty_descriptions_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Bounties", + "BountyDescriptions", + Vec::new(), + [ + 252u8, 0u8, 9u8, 225u8, 13u8, 135u8, 7u8, 121u8, 154u8, 155u8, 116u8, + 83u8, 160u8, 37u8, 72u8, 11u8, 72u8, 0u8, 248u8, 73u8, 158u8, 84u8, + 125u8, 221u8, 176u8, 231u8, 100u8, 239u8, 111u8, 22u8, 29u8, 13u8, + ], + ) + } + #[doc = " Bounty indices that have been approved but not yet funded."] + pub fn bounty_approvals( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Bounties", + "BountyApprovals", + vec![], + [ + 64u8, 93u8, 54u8, 94u8, 122u8, 9u8, 246u8, 86u8, 234u8, 30u8, 125u8, + 132u8, 49u8, 128u8, 1u8, 219u8, 241u8, 13u8, 217u8, 186u8, 48u8, 21u8, + 5u8, 227u8, 71u8, 157u8, 128u8, 226u8, 214u8, 49u8, 249u8, 183u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The amount held on deposit for placing a bounty proposal."] + pub fn bounty_deposit_base( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Bounties", + "BountyDepositBase", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The delay period for which a bounty beneficiary need to wait before claim the payout."] + pub fn bounty_deposit_payout_delay( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Bounties", + "BountyDepositPayoutDelay", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " Bounty duration in blocks."] + pub fn bounty_update_period( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Bounties", + "BountyUpdatePeriod", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The curator deposit is calculated as a percentage of the curator fee."] + #[doc = ""] + #[doc = " This deposit has optional upper and lower bounds with `CuratorDepositMax` and"] + #[doc = " `CuratorDepositMin`."] + pub fn curator_deposit_multiplier( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "Bounties", + "CuratorDepositMultiplier", + [ + 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, + 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, + 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, + ], + ) + } + #[doc = " Maximum amount of funds that should be placed in a deposit for making a proposal."] + pub fn curator_deposit_max( + &self, + ) -> ::subxt::constants::Address<::core::option::Option<::core::primitive::u128>> + { + ::subxt::constants::Address::new_static( + "Bounties", + "CuratorDepositMax", + [ + 84u8, 154u8, 218u8, 83u8, 84u8, 189u8, 32u8, 20u8, 120u8, 194u8, 88u8, + 205u8, 109u8, 216u8, 114u8, 193u8, 120u8, 198u8, 154u8, 237u8, 134u8, + 204u8, 102u8, 247u8, 52u8, 103u8, 231u8, 43u8, 243u8, 122u8, 60u8, + 216u8, + ], + ) + } + #[doc = " Minimum amount of funds that should be placed in a deposit for making a proposal."] + pub fn curator_deposit_min( + &self, + ) -> ::subxt::constants::Address<::core::option::Option<::core::primitive::u128>> + { + ::subxt::constants::Address::new_static( + "Bounties", + "CuratorDepositMin", + [ + 84u8, 154u8, 218u8, 83u8, 84u8, 189u8, 32u8, 20u8, 120u8, 194u8, 88u8, + 205u8, 109u8, 216u8, 114u8, 193u8, 120u8, 198u8, 154u8, 237u8, 134u8, + 204u8, 102u8, 247u8, 52u8, 103u8, 231u8, 43u8, 243u8, 122u8, 60u8, + 216u8, + ], + ) + } + #[doc = " Minimum value for a bounty."] + pub fn bounty_value_minimum( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Bounties", + "BountyValueMinimum", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The amount held on deposit per byte within the tip report reason or bounty description."] + pub fn data_deposit_per_byte( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Bounties", + "DataDepositPerByte", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " Maximum acceptable reason length."] + #[doc = ""] + #[doc = " Benchmarks depend on this value, be sure to update weights file when changing this value"] + pub fn maximum_reason_length( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Bounties", + "MaximumReasonLength", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod child_bounties { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_child_bounties::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddChildBounty { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub value: ::core::primitive::u128, + pub description: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ProposeCurator { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, + pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub fee: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AcceptCurator { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UnassignCurator { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AwardChildBounty { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, + pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClaimChildBounty { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CloseChildBounty { + #[codec(compact)] + pub parent_bounty_id: ::core::primitive::u32, + #[codec(compact)] + pub child_bounty_id: ::core::primitive::u32, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Add a new child-bounty."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be the curator of parent"] + #[doc = "bounty and the parent bounty must be in \"active\" state."] + #[doc = ""] + #[doc = "Child-bounty gets added successfully & fund gets transferred from"] + #[doc = "parent bounty to child-bounty account, if parent bounty has enough"] + #[doc = "funds, else the call fails."] + #[doc = ""] + #[doc = "Upper bound to maximum number of active child bounties that can be"] + #[doc = "added are managed via runtime trait config"] + #[doc = "[`Config::MaxActiveChildBountyCount`]."] + #[doc = ""] + #[doc = "If the call is success, the status of child-bounty is updated to"] + #[doc = "\"Added\"."] + #[doc = ""] + #[doc = "- `parent_bounty_id`: Index of parent bounty for which child-bounty is being added."] + #[doc = "- `value`: Value for executing the proposal."] + #[doc = "- `description`: Text description for the child-bounty."] + pub fn add_child_bounty( + &self, + parent_bounty_id: ::core::primitive::u32, + value: ::core::primitive::u128, + description: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ChildBounties", + "add_child_bounty", + types::AddChildBounty { + parent_bounty_id, + value, + description, + }, + [ + 210u8, 156u8, 242u8, 121u8, 28u8, 214u8, 212u8, 203u8, 46u8, 45u8, + 110u8, 25u8, 33u8, 138u8, 136u8, 71u8, 23u8, 102u8, 203u8, 122u8, 77u8, + 162u8, 112u8, 133u8, 43u8, 73u8, 201u8, 176u8, 102u8, 68u8, 188u8, 8u8, + ], + ) + } + #[doc = "Propose curator for funded child-bounty."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be curator of parent bounty."] + #[doc = ""] + #[doc = "Parent bounty must be in active state, for this child-bounty call to"] + #[doc = "work."] + #[doc = ""] + #[doc = "Child-bounty must be in \"Added\" state, for processing the call. And"] + #[doc = "state of child-bounty is moved to \"CuratorProposed\" on successful"] + #[doc = "call completion."] + #[doc = ""] + #[doc = "- `parent_bounty_id`: Index of parent bounty."] + #[doc = "- `child_bounty_id`: Index of child bounty."] + #[doc = "- `curator`: Address of child-bounty curator."] + #[doc = "- `fee`: payment fee to child-bounty curator for execution."] + pub fn propose_curator( + &self, + parent_bounty_id: ::core::primitive::u32, + child_bounty_id: ::core::primitive::u32, + curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + fee: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ChildBounties", + "propose_curator", + types::ProposeCurator { + parent_bounty_id, + child_bounty_id, + curator, + fee, + }, + [ + 37u8, 101u8, 96u8, 75u8, 254u8, 212u8, 42u8, 140u8, 72u8, 107u8, 157u8, + 110u8, 147u8, 236u8, 17u8, 138u8, 161u8, 153u8, 119u8, 177u8, 225u8, + 22u8, 83u8, 5u8, 123u8, 38u8, 30u8, 240u8, 134u8, 208u8, 183u8, 247u8, + ], + ) + } + #[doc = "Accept the curator role for the child-bounty."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be the curator of this"] + #[doc = "child-bounty."] + #[doc = ""] + #[doc = "A deposit will be reserved from the curator and refund upon"] + #[doc = "successful payout or cancellation."] + #[doc = ""] + #[doc = "Fee for curator is deducted from curator fee of parent bounty."] + #[doc = ""] + #[doc = "Parent bounty must be in active state, for this child-bounty call to"] + #[doc = "work."] + #[doc = ""] + #[doc = "Child-bounty must be in \"CuratorProposed\" state, for processing the"] + #[doc = "call. And state of child-bounty is moved to \"Active\" on successful"] + #[doc = "call completion."] + #[doc = ""] + #[doc = "- `parent_bounty_id`: Index of parent bounty."] + #[doc = "- `child_bounty_id`: Index of child bounty."] + pub fn accept_curator( + &self, + parent_bounty_id: ::core::primitive::u32, + child_bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ChildBounties", + "accept_curator", + types::AcceptCurator { + parent_bounty_id, + child_bounty_id, + }, + [ + 112u8, 175u8, 238u8, 54u8, 132u8, 20u8, 206u8, 59u8, 220u8, 228u8, + 207u8, 222u8, 132u8, 240u8, 188u8, 0u8, 210u8, 225u8, 234u8, 142u8, + 232u8, 53u8, 64u8, 89u8, 220u8, 29u8, 28u8, 123u8, 125u8, 207u8, 10u8, + 52u8, + ], + ) + } + #[doc = "Unassign curator from a child-bounty."] + #[doc = ""] + #[doc = "The dispatch origin for this call can be either `RejectOrigin`, or"] + #[doc = "the curator of the parent bounty, or any signed origin."] + #[doc = ""] + #[doc = "For the origin other than T::RejectOrigin and the child-bounty"] + #[doc = "curator, parent bounty must be in active state, for this call to"] + #[doc = "work. We allow child-bounty curator and T::RejectOrigin to execute"] + #[doc = "this call irrespective of the parent bounty state."] + #[doc = ""] + #[doc = "If this function is called by the `RejectOrigin` or the"] + #[doc = "parent bounty curator, we assume that the child-bounty curator is"] + #[doc = "malicious or inactive. As a result, child-bounty curator deposit is"] + #[doc = "slashed."] + #[doc = ""] + #[doc = "If the origin is the child-bounty curator, we take this as a sign"] + #[doc = "that they are unable to do their job, and are willingly giving up."] + #[doc = "We could slash the deposit, but for now we allow them to unreserve"] + #[doc = "their deposit and exit without issue. (We may want to change this if"] + #[doc = "it is abused.)"] + #[doc = ""] + #[doc = "Finally, the origin can be anyone iff the child-bounty curator is"] + #[doc = "\"inactive\". Expiry update due of parent bounty is used to estimate"] + #[doc = "inactive state of child-bounty curator."] + #[doc = ""] + #[doc = "This allows anyone in the community to call out that a child-bounty"] + #[doc = "curator is not doing their due diligence, and we should pick a new"] + #[doc = "one. In this case the child-bounty curator deposit is slashed."] + #[doc = ""] + #[doc = "State of child-bounty is moved to Added state on successful call"] + #[doc = "completion."] + #[doc = ""] + #[doc = "- `parent_bounty_id`: Index of parent bounty."] + #[doc = "- `child_bounty_id`: Index of child bounty."] + pub fn unassign_curator( + &self, + parent_bounty_id: ::core::primitive::u32, + child_bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ChildBounties", + "unassign_curator", + types::UnassignCurator { + parent_bounty_id, + child_bounty_id, + }, + [ + 228u8, 189u8, 46u8, 75u8, 121u8, 161u8, 150u8, 87u8, 207u8, 86u8, + 192u8, 50u8, 52u8, 61u8, 49u8, 88u8, 178u8, 182u8, 89u8, 72u8, 203u8, + 45u8, 41u8, 26u8, 149u8, 114u8, 154u8, 169u8, 118u8, 128u8, 13u8, + 211u8, + ], + ) + } + #[doc = "Award child-bounty to a beneficiary."] + #[doc = ""] + #[doc = "The beneficiary will be able to claim the funds after a delay."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be the parent curator or"] + #[doc = "curator of this child-bounty."] + #[doc = ""] + #[doc = "Parent bounty must be in active state, for this child-bounty call to"] + #[doc = "work."] + #[doc = ""] + #[doc = "Child-bounty must be in active state, for processing the call. And"] + #[doc = "state of child-bounty is moved to \"PendingPayout\" on successful call"] + #[doc = "completion."] + #[doc = ""] + #[doc = "- `parent_bounty_id`: Index of parent bounty."] + #[doc = "- `child_bounty_id`: Index of child bounty."] + #[doc = "- `beneficiary`: Beneficiary account."] + pub fn award_child_bounty( + &self, + parent_bounty_id: ::core::primitive::u32, + child_bounty_id: ::core::primitive::u32, + beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ChildBounties", + "award_child_bounty", + types::AwardChildBounty { + parent_bounty_id, + child_bounty_id, + beneficiary, + }, + [ + 231u8, 185u8, 73u8, 232u8, 92u8, 116u8, 204u8, 165u8, 216u8, 194u8, + 151u8, 21u8, 127u8, 239u8, 78u8, 45u8, 27u8, 252u8, 119u8, 23u8, 71u8, + 140u8, 137u8, 209u8, 189u8, 128u8, 126u8, 247u8, 13u8, 42u8, 68u8, + 134u8, + ], + ) + } + #[doc = "Claim the payout from an awarded child-bounty after payout delay."] + #[doc = ""] + #[doc = "The dispatch origin for this call may be any signed origin."] + #[doc = ""] + #[doc = "Call works independent of parent bounty state, No need for parent"] + #[doc = "bounty to be in active state."] + #[doc = ""] + #[doc = "The Beneficiary is paid out with agreed bounty value. Curator fee is"] + #[doc = "paid & curator deposit is unreserved."] + #[doc = ""] + #[doc = "Child-bounty must be in \"PendingPayout\" state, for processing the"] + #[doc = "call. And instance of child-bounty is removed from the state on"] + #[doc = "successful call completion."] + #[doc = ""] + #[doc = "- `parent_bounty_id`: Index of parent bounty."] + #[doc = "- `child_bounty_id`: Index of child bounty."] + pub fn claim_child_bounty( + &self, + parent_bounty_id: ::core::primitive::u32, + child_bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ChildBounties", + "claim_child_bounty", + types::ClaimChildBounty { + parent_bounty_id, + child_bounty_id, + }, + [ + 134u8, 243u8, 151u8, 228u8, 38u8, 174u8, 96u8, 140u8, 104u8, 124u8, + 166u8, 206u8, 126u8, 211u8, 17u8, 100u8, 172u8, 5u8, 234u8, 171u8, + 125u8, 2u8, 191u8, 163u8, 72u8, 29u8, 163u8, 107u8, 65u8, 92u8, 41u8, + 45u8, + ], + ) + } + #[doc = "Cancel a proposed or active child-bounty. Child-bounty account funds"] + #[doc = "are transferred to parent bounty account. The child-bounty curator"] + #[doc = "deposit may be unreserved if possible."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be either parent curator or"] + #[doc = "`T::RejectOrigin`."] + #[doc = ""] + #[doc = "If the state of child-bounty is `Active`, curator deposit is"] + #[doc = "unreserved."] + #[doc = ""] + #[doc = "If the state of child-bounty is `PendingPayout`, call fails &"] + #[doc = "returns `PendingPayout` error."] + #[doc = ""] + #[doc = "For the origin other than T::RejectOrigin, parent bounty must be in"] + #[doc = "active state, for this child-bounty call to work. For origin"] + #[doc = "T::RejectOrigin execution is forced."] + #[doc = ""] + #[doc = "Instance of child-bounty is removed from the state on successful"] + #[doc = "call completion."] + #[doc = ""] + #[doc = "- `parent_bounty_id`: Index of parent bounty."] + #[doc = "- `child_bounty_id`: Index of child bounty."] + pub fn close_child_bounty( + &self, + parent_bounty_id: ::core::primitive::u32, + child_bounty_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ChildBounties", + "close_child_bounty", + types::CloseChildBounty { + parent_bounty_id, + child_bounty_id, + }, + [ + 40u8, 0u8, 235u8, 75u8, 36u8, 196u8, 29u8, 26u8, 30u8, 172u8, 240u8, + 44u8, 129u8, 243u8, 55u8, 211u8, 96u8, 159u8, 72u8, 96u8, 142u8, 68u8, + 41u8, 238u8, 157u8, 167u8, 90u8, 141u8, 213u8, 249u8, 222u8, 22u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_child_bounties::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A child-bounty is added."] + pub struct Added { + pub index: ::core::primitive::u32, + pub child_index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Added { + const PALLET: &'static str = "ChildBounties"; + const EVENT: &'static str = "Added"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A child-bounty is awarded to a beneficiary."] + pub struct Awarded { + pub index: ::core::primitive::u32, + pub child_index: ::core::primitive::u32, + pub beneficiary: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for Awarded { + const PALLET: &'static str = "ChildBounties"; + const EVENT: &'static str = "Awarded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A child-bounty is claimed by beneficiary."] + pub struct Claimed { + pub index: ::core::primitive::u32, + pub child_index: ::core::primitive::u32, + pub payout: ::core::primitive::u128, + pub beneficiary: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for Claimed { + const PALLET: &'static str = "ChildBounties"; + const EVENT: &'static str = "Claimed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A child-bounty is cancelled."] + pub struct Canceled { + pub index: ::core::primitive::u32, + pub child_index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Canceled { + const PALLET: &'static str = "ChildBounties"; + const EVENT: &'static str = "Canceled"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Number of total child bounties."] + pub fn child_bounty_count( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ChildBounties", + "ChildBountyCount", + vec![], + [ + 46u8, 10u8, 183u8, 160u8, 98u8, 215u8, 39u8, 253u8, 81u8, 94u8, 114u8, + 147u8, 115u8, 162u8, 33u8, 117u8, 160u8, 214u8, 167u8, 7u8, 109u8, + 143u8, 158u8, 1u8, 200u8, 205u8, 17u8, 93u8, 89u8, 26u8, 30u8, 95u8, + ], + ) + } + #[doc = " Number of child bounties per parent bounty."] + #[doc = " Map of parent bounty index to number of child bounties."] + pub fn parent_child_bounties( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ChildBounties", + "ParentChildBounties", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 127u8, 161u8, 181u8, 79u8, 235u8, 196u8, 252u8, 162u8, 39u8, 15u8, + 251u8, 49u8, 125u8, 80u8, 101u8, 24u8, 234u8, 88u8, 212u8, 126u8, 63u8, + 63u8, 19u8, 75u8, 137u8, 125u8, 38u8, 250u8, 77u8, 49u8, 76u8, 188u8, + ], + ) + } + #[doc = " Number of child bounties per parent bounty."] + #[doc = " Map of parent bounty index to number of child bounties."] + pub fn parent_child_bounties_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ChildBounties", + "ParentChildBounties", + Vec::new(), + [ + 127u8, 161u8, 181u8, 79u8, 235u8, 196u8, 252u8, 162u8, 39u8, 15u8, + 251u8, 49u8, 125u8, 80u8, 101u8, 24u8, 234u8, 88u8, 212u8, 126u8, 63u8, + 63u8, 19u8, 75u8, 137u8, 125u8, 38u8, 250u8, 77u8, 49u8, 76u8, 188u8, + ], + ) + } + #[doc = " Child bounties that have been added."] + pub fn child_bounties( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_child_bounties::ChildBounty< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ChildBounties", + "ChildBounties", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 66u8, 132u8, 251u8, 223u8, 216u8, 52u8, 162u8, 150u8, 229u8, 239u8, + 219u8, 182u8, 211u8, 228u8, 181u8, 46u8, 243u8, 151u8, 111u8, 235u8, + 105u8, 40u8, 39u8, 10u8, 245u8, 113u8, 78u8, 116u8, 219u8, 186u8, + 165u8, 91u8, + ], + ) + } + #[doc = " Child bounties that have been added."] + pub fn child_bounties_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_child_bounties::ChildBounty< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ChildBounties", + "ChildBounties", + Vec::new(), + [ + 66u8, 132u8, 251u8, 223u8, 216u8, 52u8, 162u8, 150u8, 229u8, 239u8, + 219u8, 182u8, 211u8, 228u8, 181u8, 46u8, 243u8, 151u8, 111u8, 235u8, + 105u8, 40u8, 39u8, 10u8, 245u8, 113u8, 78u8, 116u8, 219u8, 186u8, + 165u8, 91u8, + ], + ) + } + #[doc = " The description of each child-bounty."] + pub fn child_bounty_descriptions( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ChildBounties", + "ChildBountyDescriptions", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 193u8, 200u8, 40u8, 30u8, 14u8, 71u8, 90u8, 42u8, 58u8, 253u8, 225u8, + 158u8, 172u8, 10u8, 45u8, 238u8, 36u8, 144u8, 184u8, 153u8, 11u8, + 157u8, 125u8, 220u8, 175u8, 31u8, 28u8, 93u8, 207u8, 212u8, 141u8, + 74u8, + ], + ) + } + #[doc = " The description of each child-bounty."] + pub fn child_bounty_descriptions_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ChildBounties", + "ChildBountyDescriptions", + Vec::new(), + [ + 193u8, 200u8, 40u8, 30u8, 14u8, 71u8, 90u8, 42u8, 58u8, 253u8, 225u8, + 158u8, 172u8, 10u8, 45u8, 238u8, 36u8, 144u8, 184u8, 153u8, 11u8, + 157u8, 125u8, 220u8, 175u8, 31u8, 28u8, 93u8, 207u8, 212u8, 141u8, + 74u8, + ], + ) + } + #[doc = " The cumulative child-bounty curator fee for each parent bounty."] + pub fn children_curator_fees( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ChildBounties", + "ChildrenCuratorFees", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 174u8, 128u8, 86u8, 179u8, 133u8, 76u8, 98u8, 169u8, 234u8, 166u8, + 249u8, 214u8, 172u8, 171u8, 8u8, 161u8, 105u8, 69u8, 148u8, 151u8, + 35u8, 174u8, 118u8, 139u8, 101u8, 56u8, 85u8, 211u8, 121u8, 168u8, 0u8, + 216u8, + ], + ) + } + #[doc = " The cumulative child-bounty curator fee for each parent bounty."] + pub fn children_curator_fees_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ChildBounties", + "ChildrenCuratorFees", + Vec::new(), + [ + 174u8, 128u8, 86u8, 179u8, 133u8, 76u8, 98u8, 169u8, 234u8, 166u8, + 249u8, 214u8, 172u8, 171u8, 8u8, 161u8, 105u8, 69u8, 148u8, 151u8, + 35u8, 174u8, 118u8, 139u8, 101u8, 56u8, 85u8, 211u8, 121u8, 168u8, 0u8, + 216u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " Maximum number of child bounties that can be added to a parent bounty."] + pub fn max_active_child_bounty_count( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ChildBounties", + "MaxActiveChildBountyCount", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " Minimum value for a child-bounty."] + pub fn child_bounty_value_minimum( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "ChildBounties", + "ChildBountyValueMinimum", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + } + } + } + pub mod tips { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_tips::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReportAwesome { + pub reason: ::std::vec::Vec<::core::primitive::u8>, + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RetractTip { + pub hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TipNew { + pub reason: ::std::vec::Vec<::core::primitive::u8>, + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub tip_value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Tip { + pub hash: ::subxt::utils::H256, + #[codec(compact)] + pub tip_value: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CloseTip { + pub hash: ::subxt::utils::H256, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SlashTip { + pub hash: ::subxt::utils::H256, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Report something `reason` that deserves a tip and claim any eventual the finder's fee."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "Payment: `TipReportDepositBase` will be reserved from the origin account, as well as"] + #[doc = "`DataDepositPerByte` for each byte in `reason`."] + #[doc = ""] + #[doc = "- `reason`: The reason for, or the thing that deserves, the tip; generally this will be"] + #[doc = " a UTF-8-encoded URL."] + #[doc = "- `who`: The account which should be credited for the tip."] + #[doc = ""] + #[doc = "Emits `NewTip` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(R)` where `R` length of `reason`."] + #[doc = " - encoding and hashing of 'reason'"] + pub fn report_awesome( + &self, + reason: ::std::vec::Vec<::core::primitive::u8>, + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Tips", + "report_awesome", + types::ReportAwesome { reason, who }, + [ + 126u8, 68u8, 2u8, 54u8, 195u8, 15u8, 43u8, 27u8, 183u8, 254u8, 157u8, + 163u8, 252u8, 14u8, 207u8, 251u8, 215u8, 111u8, 98u8, 209u8, 150u8, + 11u8, 240u8, 177u8, 106u8, 93u8, 191u8, 31u8, 62u8, 11u8, 223u8, 79u8, + ], + ) + } + #[doc = "Retract a prior tip-report from `report_awesome`, and cancel the process of tipping."] + #[doc = ""] + #[doc = "If successful, the original deposit will be unreserved."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the tip identified by `hash`"] + #[doc = "must have been reported by the signing account through `report_awesome` (and not"] + #[doc = "through `tip_new`)."] + #[doc = ""] + #[doc = "- `hash`: The identity of the open tip for which a tip value is declared. This is formed"] + #[doc = " as the hash of the tuple of the original tip `reason` and the beneficiary account ID."] + #[doc = ""] + #[doc = "Emits `TipRetracted` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(1)`"] + #[doc = " - Depends on the length of `T::Hash` which is fixed."] + pub fn retract_tip( + &self, + hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Tips", + "retract_tip", + types::RetractTip { hash }, + [ + 137u8, 42u8, 229u8, 188u8, 157u8, 195u8, 184u8, 176u8, 64u8, 142u8, + 67u8, 175u8, 185u8, 207u8, 214u8, 71u8, 165u8, 29u8, 137u8, 227u8, + 132u8, 195u8, 255u8, 66u8, 186u8, 57u8, 34u8, 184u8, 187u8, 65u8, + 129u8, 131u8, + ], + ) + } + #[doc = "Give a tip for something new; no finder's fee will be taken."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the signing account must be a"] + #[doc = "member of the `Tippers` set."] + #[doc = ""] + #[doc = "- `reason`: The reason for, or the thing that deserves, the tip; generally this will be"] + #[doc = " a UTF-8-encoded URL."] + #[doc = "- `who`: The account which should be credited for the tip."] + #[doc = "- `tip_value`: The amount of tip that the sender would like to give. The median tip"] + #[doc = " value of active tippers will be given to the `who`."] + #[doc = ""] + #[doc = "Emits `NewTip` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(R + T)` where `R` length of `reason`, `T` is the number of tippers."] + #[doc = " - `O(T)`: decoding `Tipper` vec of length `T`. `T` is charged as upper bound given by"] + #[doc = " `ContainsLengthBound`. The actual cost depends on the implementation of"] + #[doc = " `T::Tippers`."] + #[doc = " - `O(R)`: hashing and encoding of reason of length `R`"] + pub fn tip_new( + &self, + reason: ::std::vec::Vec<::core::primitive::u8>, + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + tip_value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Tips", + "tip_new", + types::TipNew { + reason, + who, + tip_value, + }, + [ + 217u8, 15u8, 70u8, 80u8, 193u8, 110u8, 212u8, 110u8, 212u8, 45u8, + 197u8, 150u8, 43u8, 116u8, 115u8, 231u8, 148u8, 102u8, 202u8, 28u8, + 55u8, 88u8, 166u8, 238u8, 11u8, 238u8, 229u8, 189u8, 89u8, 115u8, + 196u8, 95u8, + ], + ) + } + #[doc = "Declare a tip value for an already-open tip."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and the signing account must be a"] + #[doc = "member of the `Tippers` set."] + #[doc = ""] + #[doc = "- `hash`: The identity of the open tip for which a tip value is declared. This is formed"] + #[doc = " as the hash of the tuple of the hash of the original tip `reason` and the beneficiary"] + #[doc = " account ID."] + #[doc = "- `tip_value`: The amount of tip that the sender would like to give. The median tip"] + #[doc = " value of active tippers will be given to the `who`."] + #[doc = ""] + #[doc = "Emits `TipClosing` if the threshold of tippers has been reached and the countdown period"] + #[doc = "has started."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- `O(T)` where `T` is the number of tippers. decoding `Tipper` vec of length `T`, insert"] + #[doc = " tip and check closing, `T` is charged as upper bound given by `ContainsLengthBound`."] + #[doc = " The actual cost depends on the implementation of `T::Tippers`."] + #[doc = ""] + #[doc = " Actually weight could be lower as it depends on how many tips are in `OpenTip` but it"] + #[doc = " is weighted as if almost full i.e of length `T-1`."] + pub fn tip( + &self, + hash: ::subxt::utils::H256, + tip_value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Tips", + "tip", + types::Tip { hash, tip_value }, + [ + 133u8, 52u8, 131u8, 14u8, 71u8, 232u8, 254u8, 31u8, 33u8, 206u8, 50u8, + 76u8, 56u8, 167u8, 228u8, 202u8, 195u8, 0u8, 164u8, 107u8, 170u8, 98u8, + 192u8, 37u8, 209u8, 199u8, 130u8, 15u8, 168u8, 63u8, 181u8, 134u8, + ], + ) + } + #[doc = "Close and payout a tip."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_."] + #[doc = ""] + #[doc = "The tip identified by `hash` must have finished its countdown period."] + #[doc = ""] + #[doc = "- `hash`: The identity of the open tip for which a tip value is declared. This is formed"] + #[doc = " as the hash of the tuple of the original tip `reason` and the beneficiary account ID."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- : `O(T)` where `T` is the number of tippers. decoding `Tipper` vec of length `T`. `T`"] + #[doc = " is charged as upper bound given by `ContainsLengthBound`. The actual cost depends on"] + #[doc = " the implementation of `T::Tippers`."] + pub fn close_tip( + &self, + hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Tips", + "close_tip", + types::CloseTip { hash }, + [ + 32u8, 53u8, 0u8, 222u8, 45u8, 157u8, 107u8, 174u8, 203u8, 50u8, 81u8, + 230u8, 6u8, 111u8, 79u8, 55u8, 49u8, 151u8, 107u8, 114u8, 81u8, 200u8, + 144u8, 175u8, 29u8, 142u8, 115u8, 184u8, 102u8, 116u8, 156u8, 173u8, + ], + ) + } + #[doc = "Remove and slash an already-open tip."] + #[doc = ""] + #[doc = "May only be called from `T::RejectOrigin`."] + #[doc = ""] + #[doc = "As a result, the finder is slashed and the deposits are lost."] + #[doc = ""] + #[doc = "Emits `TipSlashed` if successful."] + #[doc = ""] + #[doc = "## Complexity"] + #[doc = "- O(1)."] + pub fn slash_tip( + &self, + hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Tips", + "slash_tip", + types::SlashTip { hash }, + [ + 222u8, 209u8, 22u8, 47u8, 114u8, 230u8, 81u8, 200u8, 131u8, 0u8, 209u8, + 54u8, 17u8, 200u8, 175u8, 125u8, 100u8, 254u8, 41u8, 178u8, 20u8, 27u8, + 9u8, 184u8, 79u8, 93u8, 208u8, 148u8, 27u8, 190u8, 176u8, 169u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_tips::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new tip suggestion has been opened."] + pub struct NewTip { + pub tip_hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for NewTip { + const PALLET: &'static str = "Tips"; + const EVENT: &'static str = "NewTip"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A tip suggestion has reached threshold and is closing."] + pub struct TipClosing { + pub tip_hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for TipClosing { + const PALLET: &'static str = "Tips"; + const EVENT: &'static str = "TipClosing"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A tip suggestion has been closed."] + pub struct TipClosed { + pub tip_hash: ::subxt::utils::H256, + pub who: ::subxt::utils::AccountId32, + pub payout: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for TipClosed { + const PALLET: &'static str = "Tips"; + const EVENT: &'static str = "TipClosed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A tip suggestion has been retracted."] + pub struct TipRetracted { + pub tip_hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for TipRetracted { + const PALLET: &'static str = "Tips"; + const EVENT: &'static str = "TipRetracted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A tip suggestion has been slashed."] + pub struct TipSlashed { + pub tip_hash: ::subxt::utils::H256, + pub finder: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for TipSlashed { + const PALLET: &'static str = "Tips"; + const EVENT: &'static str = "TipSlashed"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " TipsMap that are not yet completed. Keyed by the hash of `(reason, who)` from the value."] + #[doc = " This has the insecure enumerable hash function since the key itself is already"] + #[doc = " guaranteed to be a secure hash."] + pub fn tips( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_tips::OpenTip< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + ::subxt::utils::H256, + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Tips", + "Tips", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 241u8, 196u8, 105u8, 248u8, 29u8, 66u8, 86u8, 98u8, 6u8, 159u8, 191u8, + 0u8, 227u8, 232u8, 147u8, 248u8, 173u8, 20u8, 225u8, 12u8, 232u8, 5u8, + 93u8, 78u8, 18u8, 154u8, 130u8, 38u8, 142u8, 36u8, 66u8, 0u8, + ], + ) + } + #[doc = " TipsMap that are not yet completed. Keyed by the hash of `(reason, who)` from the value."] + #[doc = " This has the insecure enumerable hash function since the key itself is already"] + #[doc = " guaranteed to be a secure hash."] + pub fn tips_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_tips::OpenTip< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + ::core::primitive::u32, + ::subxt::utils::H256, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Tips", + "Tips", + Vec::new(), + [ + 241u8, 196u8, 105u8, 248u8, 29u8, 66u8, 86u8, 98u8, 6u8, 159u8, 191u8, + 0u8, 227u8, 232u8, 147u8, 248u8, 173u8, 20u8, 225u8, 12u8, 232u8, 5u8, + 93u8, 78u8, 18u8, 154u8, 130u8, 38u8, 142u8, 36u8, 66u8, 0u8, + ], + ) + } + #[doc = " Simple preimage lookup from the reason's hash to the original data. Again, has an"] + #[doc = " insecure enumerable hash since the key is guaranteed to be the result of a secure hash."] + pub fn reasons( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Tips", + "Reasons", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 202u8, 191u8, 36u8, 162u8, 156u8, 102u8, 115u8, 10u8, 203u8, 35u8, + 201u8, 70u8, 195u8, 151u8, 89u8, 82u8, 202u8, 35u8, 210u8, 176u8, 82u8, + 1u8, 77u8, 94u8, 31u8, 70u8, 252u8, 194u8, 166u8, 91u8, 189u8, 134u8, + ], + ) + } + #[doc = " Simple preimage lookup from the reason's hash to the original data. Again, has an"] + #[doc = " insecure enumerable hash since the key is guaranteed to be the result of a secure hash."] + pub fn reasons_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Tips", + "Reasons", + Vec::new(), + [ + 202u8, 191u8, 36u8, 162u8, 156u8, 102u8, 115u8, 10u8, 203u8, 35u8, + 201u8, 70u8, 195u8, 151u8, 89u8, 82u8, 202u8, 35u8, 210u8, 176u8, 82u8, + 1u8, 77u8, 94u8, 31u8, 70u8, 252u8, 194u8, 166u8, 91u8, 189u8, 134u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " Maximum acceptable reason length."] + #[doc = ""] + #[doc = " Benchmarks depend on this value, be sure to update weights file when changing this value"] + pub fn maximum_reason_length( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Tips", + "MaximumReasonLength", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The amount held on deposit per byte within the tip report reason or bounty description."] + pub fn data_deposit_per_byte( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Tips", + "DataDepositPerByte", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The period for which a tip remains open after is has achieved threshold tippers."] + pub fn tip_countdown(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Tips", + "TipCountdown", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The percent of the final tip which goes to the original reporter of the tip."] + pub fn tip_finders_fee( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "Tips", + "TipFindersFee", + [ + 99u8, 121u8, 176u8, 172u8, 235u8, 159u8, 116u8, 114u8, 179u8, 91u8, + 129u8, 117u8, 204u8, 135u8, 53u8, 7u8, 151u8, 26u8, 124u8, 151u8, + 202u8, 171u8, 171u8, 207u8, 183u8, 177u8, 24u8, 53u8, 109u8, 185u8, + 71u8, 183u8, + ], + ) + } + #[doc = " The amount held on deposit for placing a tip report."] + pub fn tip_report_deposit_base( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Tips", + "TipReportDepositBase", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + } + } + } + pub mod election_provider_multi_phase { + use super::root_mod; + use super::runtime_types; + #[doc = "Error of the pallet that can be returned in response to dispatches."] + pub type Error = runtime_types::pallet_election_provider_multi_phase::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SubmitUnsigned { + pub raw_solution: ::std::boxed::Box< + runtime_types::pallet_election_provider_multi_phase::RawSolution< + runtime_types::polkadot_runtime::NposCompactSolution16, + >, + >, + pub witness: + runtime_types::pallet_election_provider_multi_phase::SolutionOrSnapshotSize, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMinimumUntrustedScore { + pub maybe_next_score: + ::core::option::Option, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetEmergencyElectionResult { + pub supports: ::std::vec::Vec<( + ::subxt::utils::AccountId32, + runtime_types::sp_npos_elections::Support<::subxt::utils::AccountId32>, + )>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Submit { + pub raw_solution: ::std::boxed::Box< + runtime_types::pallet_election_provider_multi_phase::RawSolution< + runtime_types::polkadot_runtime::NposCompactSolution16, + >, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct GovernanceFallback { + pub maybe_max_voters: ::core::option::Option<::core::primitive::u32>, + pub maybe_max_targets: ::core::option::Option<::core::primitive::u32>, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Submit a solution for the unsigned phase."] + #[doc = ""] + #[doc = "The dispatch origin fo this call must be __none__."] + #[doc = ""] + #[doc = "This submission is checked on the fly. Moreover, this unsigned solution is only"] + #[doc = "validated when submitted to the pool from the **local** node. Effectively, this means"] + #[doc = "that only active validators can submit this transaction when authoring a block (similar"] + #[doc = "to an inherent)."] + #[doc = ""] + #[doc = "To prevent any incorrect solution (and thus wasted time/weight), this transaction will"] + #[doc = "panic if the solution submitted by the validator is invalid in any way, effectively"] + #[doc = "putting their authoring reward at risk."] + #[doc = ""] + #[doc = "No deposit or reward is associated with this submission."] + pub fn submit_unsigned( + &self, + raw_solution: runtime_types::pallet_election_provider_multi_phase::RawSolution< + runtime_types::polkadot_runtime::NposCompactSolution16, + >, + witness : runtime_types :: pallet_election_provider_multi_phase :: SolutionOrSnapshotSize, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ElectionProviderMultiPhase", + "submit_unsigned", + types::SubmitUnsigned { + raw_solution: ::std::boxed::Box::new(raw_solution), + witness, + }, + [ + 100u8, 240u8, 31u8, 34u8, 93u8, 98u8, 93u8, 57u8, 41u8, 197u8, 97u8, + 58u8, 242u8, 10u8, 69u8, 250u8, 185u8, 169u8, 21u8, 8u8, 202u8, 61u8, + 36u8, 25u8, 4u8, 148u8, 82u8, 56u8, 242u8, 18u8, 27u8, 219u8, + ], + ) + } + #[doc = "Set a new value for `MinimumUntrustedScore`."] + #[doc = ""] + #[doc = "Dispatch origin must be aligned with `T::ForceOrigin`."] + #[doc = ""] + #[doc = "This check can be turned off by setting the value to `None`."] + pub fn set_minimum_untrusted_score( + &self, + maybe_next_score: ::core::option::Option< + runtime_types::sp_npos_elections::ElectionScore, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ElectionProviderMultiPhase", + "set_minimum_untrusted_score", + types::SetMinimumUntrustedScore { maybe_next_score }, + [ + 63u8, 101u8, 105u8, 146u8, 133u8, 162u8, 149u8, 112u8, 150u8, 219u8, + 183u8, 213u8, 234u8, 211u8, 144u8, 74u8, 106u8, 15u8, 62u8, 196u8, + 247u8, 49u8, 20u8, 48u8, 3u8, 105u8, 85u8, 46u8, 76u8, 4u8, 67u8, 81u8, + ], + ) + } + #[doc = "Set a solution in the queue, to be handed out to the client of this pallet in the next"] + #[doc = "call to `ElectionProvider::elect`."] + #[doc = ""] + #[doc = "This can only be set by `T::ForceOrigin`, and only when the phase is `Emergency`."] + #[doc = ""] + #[doc = "The solution is not checked for any feasibility and is assumed to be trustworthy, as any"] + #[doc = "feasibility check itself can in principle cause the election process to fail (due to"] + #[doc = "memory/weight constrains)."] + pub fn set_emergency_election_result( + &self, + supports: ::std::vec::Vec<( + ::subxt::utils::AccountId32, + runtime_types::sp_npos_elections::Support<::subxt::utils::AccountId32>, + )>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ElectionProviderMultiPhase", + "set_emergency_election_result", + types::SetEmergencyElectionResult { supports }, + [ + 115u8, 255u8, 205u8, 58u8, 153u8, 1u8, 246u8, 8u8, 225u8, 36u8, 66u8, + 144u8, 250u8, 145u8, 70u8, 76u8, 54u8, 63u8, 251u8, 51u8, 214u8, 204u8, + 55u8, 112u8, 46u8, 228u8, 255u8, 250u8, 151u8, 5u8, 44u8, 133u8, + ], + ) + } + #[doc = "Submit a solution for the signed phase."] + #[doc = ""] + #[doc = "The dispatch origin fo this call must be __signed__."] + #[doc = ""] + #[doc = "The solution is potentially queued, based on the claimed score and processed at the end"] + #[doc = "of the signed phase."] + #[doc = ""] + #[doc = "A deposit is reserved and recorded for the solution. Based on the outcome, the solution"] + #[doc = "might be rewarded, slashed, or get all or a part of the deposit back."] + pub fn submit( + &self, + raw_solution: runtime_types::pallet_election_provider_multi_phase::RawSolution< + runtime_types::polkadot_runtime::NposCompactSolution16, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ElectionProviderMultiPhase", + "submit", + types::Submit { + raw_solution: ::std::boxed::Box::new(raw_solution), + }, + [ + 220u8, 167u8, 40u8, 47u8, 253u8, 244u8, 72u8, 124u8, 30u8, 123u8, + 127u8, 227u8, 2u8, 66u8, 119u8, 64u8, 211u8, 200u8, 210u8, 98u8, 248u8, + 132u8, 68u8, 25u8, 34u8, 182u8, 230u8, 225u8, 241u8, 58u8, 193u8, + 134u8, + ], + ) + } + #[doc = "Trigger the governance fallback."] + #[doc = ""] + #[doc = "This can only be called when [`Phase::Emergency`] is enabled, as an alternative to"] + #[doc = "calling [`Call::set_emergency_election_result`]."] + pub fn governance_fallback( + &self, + maybe_max_voters: ::core::option::Option<::core::primitive::u32>, + maybe_max_targets: ::core::option::Option<::core::primitive::u32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ElectionProviderMultiPhase", + "governance_fallback", + types::GovernanceFallback { + maybe_max_voters, + maybe_max_targets, + }, + [ + 206u8, 247u8, 76u8, 85u8, 7u8, 24u8, 231u8, 226u8, 192u8, 143u8, 43u8, + 67u8, 91u8, 202u8, 88u8, 176u8, 130u8, 1u8, 83u8, 229u8, 227u8, 200u8, + 179u8, 4u8, 113u8, 60u8, 99u8, 190u8, 53u8, 226u8, 142u8, 182u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_election_provider_multi_phase::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A solution was stored with the given compute."] + #[doc = ""] + #[doc = "The `origin` indicates the origin of the solution. If `origin` is `Some(AccountId)`,"] + #[doc = "the stored solution was submited in the signed phase by a miner with the `AccountId`."] + #[doc = "Otherwise, the solution was stored either during the unsigned phase or by"] + #[doc = "`T::ForceOrigin`. The `bool` is `true` when a previous solution was ejected to make"] + #[doc = "room for this one."] + pub struct SolutionStored { + pub compute: runtime_types::pallet_election_provider_multi_phase::ElectionCompute, + pub origin: ::core::option::Option<::subxt::utils::AccountId32>, + pub prev_ejected: ::core::primitive::bool, + } + impl ::subxt::events::StaticEvent for SolutionStored { + const PALLET: &'static str = "ElectionProviderMultiPhase"; + const EVENT: &'static str = "SolutionStored"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The election has been finalized, with the given computation and score."] + pub struct ElectionFinalized { + pub compute: runtime_types::pallet_election_provider_multi_phase::ElectionCompute, + pub score: runtime_types::sp_npos_elections::ElectionScore, + } + impl ::subxt::events::StaticEvent for ElectionFinalized { + const PALLET: &'static str = "ElectionProviderMultiPhase"; + const EVENT: &'static str = "ElectionFinalized"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An election failed."] + #[doc = ""] + #[doc = "Not much can be said about which computes failed in the process."] + pub struct ElectionFailed; + impl ::subxt::events::StaticEvent for ElectionFailed { + const PALLET: &'static str = "ElectionProviderMultiPhase"; + const EVENT: &'static str = "ElectionFailed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account has been rewarded for their signed submission being finalized."] + pub struct Rewarded { + pub account: ::subxt::utils::AccountId32, + pub value: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Rewarded { + const PALLET: &'static str = "ElectionProviderMultiPhase"; + const EVENT: &'static str = "Rewarded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account has been slashed for submitting an invalid signed submission."] + pub struct Slashed { + pub account: ::subxt::utils::AccountId32, + pub value: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Slashed { + const PALLET: &'static str = "ElectionProviderMultiPhase"; + const EVENT: &'static str = "Slashed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "There was a phase transition in a given round."] + pub struct PhaseTransitioned { + pub from: runtime_types::pallet_election_provider_multi_phase::Phase< + ::core::primitive::u32, + >, + pub to: runtime_types::pallet_election_provider_multi_phase::Phase< + ::core::primitive::u32, + >, + pub round: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for PhaseTransitioned { + const PALLET: &'static str = "ElectionProviderMultiPhase"; + const EVENT: &'static str = "PhaseTransitioned"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Internal counter for the number of rounds."] + #[doc = ""] + #[doc = " This is useful for de-duplication of transactions submitted to the pool, and general"] + #[doc = " diagnostics of the pallet."] + #[doc = ""] + #[doc = " This is merely incremented once per every time that an upstream `elect` is called."] + pub fn round( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "Round", + vec![], + [ + 16u8, 49u8, 176u8, 52u8, 202u8, 111u8, 120u8, 8u8, 217u8, 96u8, 35u8, + 14u8, 233u8, 130u8, 47u8, 98u8, 34u8, 44u8, 166u8, 188u8, 199u8, 210u8, + 21u8, 19u8, 70u8, 96u8, 139u8, 8u8, 53u8, 82u8, 165u8, 239u8, + ], + ) + } + #[doc = " Current phase."] + pub fn current_phase( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_election_provider_multi_phase::Phase< + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "CurrentPhase", + vec![], + [ + 236u8, 101u8, 8u8, 52u8, 68u8, 240u8, 74u8, 159u8, 181u8, 53u8, 153u8, + 101u8, 228u8, 81u8, 96u8, 161u8, 34u8, 67u8, 35u8, 28u8, 121u8, 44u8, + 229u8, 45u8, 196u8, 87u8, 73u8, 125u8, 216u8, 245u8, 255u8, 15u8, + ], + ) + } + #[doc = " Current best solution, signed or unsigned, queued to be returned upon `elect`."] + pub fn queued_solution( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_election_provider_multi_phase::ReadySolution, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "QueuedSolution", + vec![], + [ + 11u8, 152u8, 13u8, 167u8, 204u8, 209u8, 171u8, 249u8, 59u8, 250u8, + 58u8, 152u8, 164u8, 121u8, 146u8, 112u8, 241u8, 16u8, 159u8, 251u8, + 209u8, 251u8, 114u8, 29u8, 188u8, 30u8, 84u8, 71u8, 136u8, 173u8, + 145u8, 236u8, + ], + ) + } + #[doc = " Snapshot data of the round."] + #[doc = ""] + #[doc = " This is created at the beginning of the signed phase and cleared upon calling `elect`."] + pub fn snapshot( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_election_provider_multi_phase::RoundSnapshot< + ::subxt::utils::AccountId32, + ( + ::subxt::utils::AccountId32, + ::core::primitive::u64, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::AccountId32, + >, + ), + >, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "Snapshot", + vec![], + [ + 239u8, 56u8, 191u8, 77u8, 150u8, 224u8, 248u8, 88u8, 132u8, 224u8, + 164u8, 83u8, 253u8, 36u8, 46u8, 156u8, 72u8, 152u8, 36u8, 206u8, 72u8, + 27u8, 226u8, 87u8, 146u8, 220u8, 93u8, 178u8, 26u8, 115u8, 232u8, 71u8, + ], + ) + } + #[doc = " Desired number of targets to elect for this round."] + #[doc = ""] + #[doc = " Only exists when [`Snapshot`] is present."] + pub fn desired_targets( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "DesiredTargets", + vec![], + [ + 16u8, 247u8, 4u8, 181u8, 93u8, 79u8, 12u8, 212u8, 146u8, 167u8, 80u8, + 58u8, 118u8, 52u8, 68u8, 87u8, 90u8, 140u8, 31u8, 210u8, 2u8, 116u8, + 220u8, 231u8, 115u8, 112u8, 118u8, 118u8, 68u8, 34u8, 151u8, 165u8, + ], + ) + } + #[doc = " The metadata of the [`RoundSnapshot`]"] + #[doc = ""] + #[doc = " Only exists when [`Snapshot`] is present."] + pub fn snapshot_metadata( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_election_provider_multi_phase::SolutionOrSnapshotSize, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "SnapshotMetadata", + vec![], + [ + 135u8, 122u8, 60u8, 75u8, 194u8, 240u8, 187u8, 96u8, 240u8, 203u8, + 192u8, 22u8, 117u8, 148u8, 118u8, 24u8, 240u8, 213u8, 94u8, 22u8, + 194u8, 47u8, 181u8, 245u8, 77u8, 149u8, 11u8, 251u8, 117u8, 220u8, + 205u8, 78u8, + ], + ) + } + #[doc = " The next index to be assigned to an incoming signed submission."] + #[doc = ""] + #[doc = " Every accepted submission is assigned a unique index; that index is bound to that particular"] + #[doc = " submission for the duration of the election. On election finalization, the next index is"] + #[doc = " reset to 0."] + #[doc = ""] + #[doc = " We can't just use `SignedSubmissionIndices.len()`, because that's a bounded set; past its"] + #[doc = " capacity, it will simply saturate. We can't just iterate over `SignedSubmissionsMap`,"] + #[doc = " because iteration is slow. Instead, we store the value here."] + pub fn signed_submission_next_index( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "SignedSubmissionNextIndex", + vec![], + [ + 242u8, 11u8, 157u8, 105u8, 96u8, 7u8, 31u8, 20u8, 51u8, 141u8, 182u8, + 180u8, 13u8, 172u8, 155u8, 59u8, 42u8, 238u8, 115u8, 8u8, 6u8, 137u8, + 45u8, 2u8, 123u8, 187u8, 53u8, 215u8, 19u8, 129u8, 54u8, 22u8, + ], + ) + } + #[doc = " A sorted, bounded vector of `(score, block_number, index)`, where each `index` points to a"] + #[doc = " value in `SignedSubmissions`."] + #[doc = ""] + #[doc = " We never need to process more than a single signed submission at a time. Signed submissions"] + #[doc = " can be quite large, so we're willing to pay the cost of multiple database accesses to access"] + #[doc = " them one at a time instead of reading and decoding all of them at once."] + pub fn signed_submission_indices( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + runtime_types::sp_npos_elections::ElectionScore, + ::core::primitive::u32, + ::core::primitive::u32, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "SignedSubmissionIndices", + vec![], + [ + 228u8, 166u8, 94u8, 248u8, 71u8, 26u8, 125u8, 81u8, 32u8, 22u8, 46u8, + 185u8, 209u8, 123u8, 46u8, 17u8, 152u8, 149u8, 222u8, 125u8, 112u8, + 230u8, 29u8, 177u8, 162u8, 214u8, 66u8, 38u8, 170u8, 121u8, 129u8, + 100u8, + ], + ) + } + #[doc = " Unchecked, signed solutions."] + #[doc = ""] + #[doc = " Together with `SubmissionIndices`, this stores a bounded set of `SignedSubmissions` while"] + #[doc = " allowing us to keep only a single one in memory at a time."] + #[doc = ""] + #[doc = " Twox note: the key of the map is an auto-incrementing index which users cannot inspect or"] + #[doc = " affect; we shouldn't need a cryptographically secure hasher."] + pub fn signed_submissions_map( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_election_provider_multi_phase::signed::SignedSubmission< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + runtime_types::polkadot_runtime::NposCompactSolution16, + >, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "SignedSubmissionsMap", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 84u8, 65u8, 205u8, 191u8, 143u8, 246u8, 239u8, 27u8, 243u8, 54u8, + 250u8, 8u8, 125u8, 32u8, 241u8, 141u8, 210u8, 225u8, 56u8, 101u8, + 241u8, 52u8, 157u8, 29u8, 13u8, 155u8, 73u8, 132u8, 118u8, 53u8, 2u8, + 135u8, + ], + ) + } + #[doc = " Unchecked, signed solutions."] + #[doc = ""] + #[doc = " Together with `SubmissionIndices`, this stores a bounded set of `SignedSubmissions` while"] + #[doc = " allowing us to keep only a single one in memory at a time."] + #[doc = ""] + #[doc = " Twox note: the key of the map is an auto-incrementing index which users cannot inspect or"] + #[doc = " affect; we shouldn't need a cryptographically secure hasher."] + pub fn signed_submissions_map_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_election_provider_multi_phase::signed::SignedSubmission< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + runtime_types::polkadot_runtime::NposCompactSolution16, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "SignedSubmissionsMap", + Vec::new(), + [ + 84u8, 65u8, 205u8, 191u8, 143u8, 246u8, 239u8, 27u8, 243u8, 54u8, + 250u8, 8u8, 125u8, 32u8, 241u8, 141u8, 210u8, 225u8, 56u8, 101u8, + 241u8, 52u8, 157u8, 29u8, 13u8, 155u8, 73u8, 132u8, 118u8, 53u8, 2u8, + 135u8, + ], + ) + } + #[doc = " The minimum score that each 'untrusted' solution must attain in order to be considered"] + #[doc = " feasible."] + #[doc = ""] + #[doc = " Can be set via `set_minimum_untrusted_score`."] + pub fn minimum_untrusted_score( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_npos_elections::ElectionScore, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ElectionProviderMultiPhase", + "MinimumUntrustedScore", + vec![], + [ + 77u8, 235u8, 181u8, 45u8, 230u8, 12u8, 0u8, 179u8, 152u8, 38u8, 74u8, + 199u8, 47u8, 84u8, 85u8, 55u8, 171u8, 226u8, 217u8, 125u8, 17u8, 194u8, + 95u8, 157u8, 73u8, 245u8, 75u8, 130u8, 248u8, 7u8, 53u8, 226u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " Duration of the unsigned phase."] + pub fn unsigned_phase( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "UnsignedPhase", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " Duration of the signed phase."] + pub fn signed_phase(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedPhase", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The minimum amount of improvement to the solution score that defines a solution as"] + #[doc = " \"better\" in the Signed phase."] + pub fn better_signed_threshold( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "BetterSignedThreshold", + [ + 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, + 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, + 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, + ], + ) + } + #[doc = " The minimum amount of improvement to the solution score that defines a solution as"] + #[doc = " \"better\" in the Unsigned phase."] + pub fn better_unsigned_threshold( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "BetterUnsignedThreshold", + [ + 225u8, 236u8, 95u8, 157u8, 90u8, 94u8, 106u8, 192u8, 254u8, 19u8, 87u8, + 80u8, 16u8, 62u8, 42u8, 204u8, 136u8, 106u8, 225u8, 53u8, 212u8, 52u8, + 177u8, 79u8, 4u8, 116u8, 201u8, 104u8, 222u8, 75u8, 86u8, 227u8, + ], + ) + } + #[doc = " The repeat threshold of the offchain worker."] + #[doc = ""] + #[doc = " For example, if it is 5, that means that at least 5 blocks will elapse between attempts"] + #[doc = " to submit the worker's solution."] + pub fn offchain_repeat( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "OffchainRepeat", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The priority of the unsigned transaction submitted in the unsigned-phase"] + pub fn miner_tx_priority( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u64> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MinerTxPriority", + [ + 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, + 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, + 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, + 246u8, + ], + ) + } + #[doc = " Maximum number of signed submissions that can be queued."] + #[doc = ""] + #[doc = " It is best to avoid adjusting this during an election, as it impacts downstream data"] + #[doc = " structures. In particular, `SignedSubmissionIndices` is bounded on this value. If you"] + #[doc = " update this value during an election, you _must_ ensure that"] + #[doc = " `SignedSubmissionIndices.len()` is less than or equal to the new value. Otherwise,"] + #[doc = " attempts to submit new solutions may cause a runtime panic."] + pub fn signed_max_submissions( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedMaxSubmissions", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " Maximum weight of a signed solution."] + #[doc = ""] + #[doc = " If [`Config::MinerConfig`] is being implemented to submit signed solutions (outside of"] + #[doc = " this pallet), then [`MinerConfig::solution_weight`] is used to compare against"] + #[doc = " this value."] + pub fn signed_max_weight( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedMaxWeight", + [ + 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, + 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, + 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, + 106u8, 76u8, + ], + ) + } + #[doc = " The maximum amount of unchecked solutions to refund the call fee for."] + pub fn signed_max_refunds( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedMaxRefunds", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " Base reward for a signed solution"] + pub fn signed_reward_base( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedRewardBase", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " Base deposit for a signed solution."] + pub fn signed_deposit_base( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedDepositBase", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " Per-byte deposit for a signed solution."] + pub fn signed_deposit_byte( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedDepositByte", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " Per-weight deposit for a signed solution."] + pub fn signed_deposit_weight( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "SignedDepositWeight", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The maximum number of electing voters to put in the snapshot. At the moment, snapshots"] + #[doc = " are only over a single block, but once multi-block elections are introduced they will"] + #[doc = " take place over multiple blocks."] + pub fn max_electing_voters( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MaxElectingVoters", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The maximum number of electable targets to put in the snapshot."] + pub fn max_electable_targets( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u16> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MaxElectableTargets", + [ + 116u8, 33u8, 2u8, 170u8, 181u8, 147u8, 171u8, 169u8, 167u8, 227u8, + 41u8, 144u8, 11u8, 236u8, 82u8, 100u8, 74u8, 60u8, 184u8, 72u8, 169u8, + 90u8, 208u8, 135u8, 15u8, 117u8, 10u8, 123u8, 128u8, 193u8, 29u8, 70u8, + ], + ) + } + #[doc = " The maximum number of winners that can be elected by this `ElectionProvider`"] + #[doc = " implementation."] + #[doc = ""] + #[doc = " Note: This must always be greater or equal to `T::DataProvider::desired_targets()`."] + pub fn max_winners(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MaxWinners", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + pub fn miner_max_length( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MinerMaxLength", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + pub fn miner_max_weight( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MinerMaxWeight", + [ + 206u8, 61u8, 253u8, 247u8, 163u8, 40u8, 161u8, 52u8, 134u8, 140u8, + 206u8, 83u8, 44u8, 166u8, 226u8, 115u8, 181u8, 14u8, 227u8, 130u8, + 210u8, 32u8, 85u8, 29u8, 230u8, 97u8, 130u8, 165u8, 147u8, 134u8, + 106u8, 76u8, + ], + ) + } + pub fn miner_max_votes_per_voter( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MinerMaxVotesPerVoter", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + pub fn miner_max_winners( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "ElectionProviderMultiPhase", + "MinerMaxWinners", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod voter_list { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_bags_list::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Rebag { + pub dislocated: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PutInFrontOf { + pub lighter: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Declare that some `dislocated` account has, through rewards or penalties, sufficiently"] + #[doc = "changed its score that it should properly fall into a different bag than its current"] + #[doc = "one."] + #[doc = ""] + #[doc = "Anyone can call this function about any potentially dislocated account."] + #[doc = ""] + #[doc = "Will always update the stored score of `dislocated` to the correct score, based on"] + #[doc = "`ScoreProvider`."] + #[doc = ""] + #[doc = "If `dislocated` does not exists, it returns an error."] + pub fn rebag( + &self, + dislocated: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "VoterList", + "rebag", + types::Rebag { dislocated }, + [ + 35u8, 182u8, 31u8, 22u8, 190u8, 187u8, 31u8, 138u8, 60u8, 48u8, 236u8, + 16u8, 191u8, 143u8, 52u8, 110u8, 228u8, 43u8, 116u8, 13u8, 171u8, + 108u8, 112u8, 123u8, 252u8, 231u8, 132u8, 97u8, 195u8, 148u8, 252u8, + 241u8, + ], + ) + } + #[doc = "Move the caller's Id directly in front of `lighter`."] + #[doc = ""] + #[doc = "The dispatch origin for this call must be _Signed_ and can only be called by the Id of"] + #[doc = "the account going in front of `lighter`."] + #[doc = ""] + #[doc = "Only works if"] + #[doc = "- both nodes are within the same bag,"] + #[doc = "- and `origin` has a greater `Score` than `lighter`."] + pub fn put_in_front_of( + &self, + lighter: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "VoterList", + "put_in_front_of", + types::PutInFrontOf { lighter }, + [ + 184u8, 194u8, 39u8, 91u8, 28u8, 220u8, 76u8, 199u8, 64u8, 252u8, 233u8, + 241u8, 74u8, 19u8, 246u8, 190u8, 108u8, 227u8, 77u8, 162u8, 225u8, + 230u8, 101u8, 72u8, 159u8, 217u8, 133u8, 107u8, 84u8, 83u8, 81u8, + 227u8, + ], + ) + } + } + } + #[doc = "\n\t\t\tThe [event](https://docs.substrate.io/main-docs/build/events-errors/) emitted\n\t\t\tby this pallet.\n\t\t\t"] + pub type Event = runtime_types::pallet_bags_list::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Moved an account from one bag to another."] + pub struct Rebagged { + pub who: ::subxt::utils::AccountId32, + pub from: ::core::primitive::u64, + pub to: ::core::primitive::u64, + } + impl ::subxt::events::StaticEvent for Rebagged { + const PALLET: &'static str = "VoterList"; + const EVENT: &'static str = "Rebagged"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Updated the score of some account to the given amount."] + pub struct ScoreUpdated { + pub who: ::subxt::utils::AccountId32, + pub new_score: ::core::primitive::u64, + } + impl ::subxt::events::StaticEvent for ScoreUpdated { + const PALLET: &'static str = "VoterList"; + const EVENT: &'static str = "ScoreUpdated"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " A single node, within some bag."] + #[doc = ""] + #[doc = " Nodes store links forward and back within their respective bags."] + pub fn list_nodes( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_bags_list::list::Node, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "VoterList", + "ListNodes", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 176u8, 186u8, 93u8, 51u8, 100u8, 184u8, 240u8, 29u8, 70u8, 3u8, 117u8, + 47u8, 23u8, 66u8, 231u8, 234u8, 53u8, 8u8, 234u8, 175u8, 181u8, 8u8, + 161u8, 154u8, 48u8, 178u8, 147u8, 227u8, 122u8, 115u8, 57u8, 97u8, + ], + ) + } + #[doc = " A single node, within some bag."] + #[doc = ""] + #[doc = " Nodes store links forward and back within their respective bags."] + pub fn list_nodes_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_bags_list::list::Node, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "VoterList", + "ListNodes", + Vec::new(), + [ + 176u8, 186u8, 93u8, 51u8, 100u8, 184u8, 240u8, 29u8, 70u8, 3u8, 117u8, + 47u8, 23u8, 66u8, 231u8, 234u8, 53u8, 8u8, 234u8, 175u8, 181u8, 8u8, + 161u8, 154u8, 48u8, 178u8, 147u8, 227u8, 122u8, 115u8, 57u8, 97u8, + ], + ) + } + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_list_nodes( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "VoterList", + "CounterForListNodes", + vec![], + [ + 156u8, 168u8, 97u8, 33u8, 84u8, 117u8, 220u8, 89u8, 62u8, 182u8, 24u8, + 88u8, 231u8, 244u8, 41u8, 19u8, 210u8, 131u8, 87u8, 0u8, 241u8, 230u8, + 160u8, 142u8, 128u8, 153u8, 83u8, 36u8, 88u8, 247u8, 70u8, 130u8, + ], + ) + } + #[doc = " A bag stored in storage."] + #[doc = ""] + #[doc = " Stores a `Bag` struct, which stores head and tail pointers to itself."] + pub fn list_bags( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u64>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_bags_list::list::Bag, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "VoterList", + "ListBags", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 38u8, 86u8, 63u8, 92u8, 85u8, 59u8, 225u8, 244u8, 14u8, 155u8, 76u8, + 249u8, 153u8, 140u8, 179u8, 7u8, 96u8, 170u8, 236u8, 179u8, 4u8, 18u8, + 232u8, 146u8, 216u8, 51u8, 135u8, 116u8, 196u8, 117u8, 143u8, 153u8, + ], + ) + } + #[doc = " A bag stored in storage."] + #[doc = ""] + #[doc = " Stores a `Bag` struct, which stores head and tail pointers to itself."] + pub fn list_bags_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_bags_list::list::Bag, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "VoterList", + "ListBags", + Vec::new(), + [ + 38u8, 86u8, 63u8, 92u8, 85u8, 59u8, 225u8, 244u8, 14u8, 155u8, 76u8, + 249u8, 153u8, 140u8, 179u8, 7u8, 96u8, 170u8, 236u8, 179u8, 4u8, 18u8, + 232u8, 146u8, 216u8, 51u8, 135u8, 116u8, 196u8, 117u8, 143u8, 153u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The list of thresholds separating the various bags."] + #[doc = ""] + #[doc = " Ids are separated into unsorted bags according to their score. This specifies the"] + #[doc = " thresholds separating the bags. An id's bag is the largest bag for which the id's score"] + #[doc = " is less than or equal to its upper threshold."] + #[doc = ""] + #[doc = " When ids are iterated, higher bags are iterated completely before lower bags. This means"] + #[doc = " that iteration is _semi-sorted_: ids of higher score tend to come before ids of lower"] + #[doc = " score, but peer ids within a particular bag are sorted in insertion order."] + #[doc = ""] + #[doc = " # Expressing the constant"] + #[doc = ""] + #[doc = " This constant must be sorted in strictly increasing order. Duplicate items are not"] + #[doc = " permitted."] + #[doc = ""] + #[doc = " There is an implied upper limit of `Score::MAX`; that value does not need to be"] + #[doc = " specified within the bag. For any two threshold lists, if one ends with"] + #[doc = " `Score::MAX`, the other one does not, and they are otherwise equal, the two"] + #[doc = " lists will behave identically."] + #[doc = ""] + #[doc = " # Calculation"] + #[doc = ""] + #[doc = " It is recommended to generate the set of thresholds in a geometric series, such that"] + #[doc = " there exists some constant ratio such that `threshold[k + 1] == (threshold[k] *"] + #[doc = " constant_ratio).max(threshold[k] + 1)` for all `k`."] + #[doc = ""] + #[doc = " The helpers in the `/utils/frame/generate-bags` module can simplify this calculation."] + #[doc = ""] + #[doc = " # Examples"] + #[doc = ""] + #[doc = " - If `BagThresholds::get().is_empty()`, then all ids are put into the same bag, and"] + #[doc = " iteration is strictly in insertion order."] + #[doc = " - If `BagThresholds::get().len() == 64`, and the thresholds are determined according to"] + #[doc = " the procedure given above, then the constant ratio is equal to 2."] + #[doc = " - If `BagThresholds::get().len() == 200`, and the thresholds are determined according to"] + #[doc = " the procedure given above, then the constant ratio is approximately equal to 1.248."] + #[doc = " - If the threshold list begins `[1, 2, 3, ...]`, then an id with score 0 or 1 will fall"] + #[doc = " into bag 0, an id with score 2 will fall into bag 1, etc."] + #[doc = ""] + #[doc = " # Migration"] + #[doc = ""] + #[doc = " In the event that this list ever changes, a copy of the old bags list must be retained."] + #[doc = " With that `List::migrate` can be called, which will perform the appropriate migration."] + pub fn bag_thresholds( + &self, + ) -> ::subxt::constants::Address<::std::vec::Vec<::core::primitive::u64>> + { + ::subxt::constants::Address::new_static( + "VoterList", + "BagThresholds", + [ + 103u8, 102u8, 255u8, 165u8, 124u8, 54u8, 5u8, 172u8, 112u8, 234u8, + 25u8, 175u8, 178u8, 19u8, 251u8, 73u8, 91u8, 192u8, 227u8, 81u8, 249u8, + 45u8, 126u8, 116u8, 7u8, 37u8, 9u8, 200u8, 167u8, 182u8, 12u8, 131u8, + ], + ) + } + } + } + } + pub mod nomination_pools { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_nomination_pools::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Join { + #[codec(compact)] + pub amount: ::core::primitive::u128, + pub pool_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BondExtra { + pub extra: + runtime_types::pallet_nomination_pools::BondExtra<::core::primitive::u128>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClaimPayout; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Unbond { + pub member_account: + ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub unbonding_points: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PoolWithdrawUnbonded { + pub pool_id: ::core::primitive::u32, + pub num_slashing_spans: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct WithdrawUnbonded { + pub member_account: + ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub num_slashing_spans: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Create { + #[codec(compact)] + pub amount: ::core::primitive::u128, + pub root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CreateWithPoolId { + #[codec(compact)] + pub amount: ::core::primitive::u128, + pub root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub pool_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Nominate { + pub pool_id: ::core::primitive::u32, + pub validators: ::std::vec::Vec<::subxt::utils::AccountId32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetState { + pub pool_id: ::core::primitive::u32, + pub state: runtime_types::pallet_nomination_pools::PoolState, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMetadata { + pub pool_id: ::core::primitive::u32, + pub metadata: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetConfigs { + pub min_join_bond: + runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u128>, + pub min_create_bond: + runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u128>, + pub max_pools: + runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u32>, + pub max_members: + runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u32>, + pub max_members_per_pool: + runtime_types::pallet_nomination_pools::ConfigOp<::core::primitive::u32>, + pub global_max_commission: runtime_types::pallet_nomination_pools::ConfigOp< + runtime_types::sp_arithmetic::per_things::Perbill, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UpdateRoles { + pub pool_id: ::core::primitive::u32, + pub new_root: runtime_types::pallet_nomination_pools::ConfigOp< + ::subxt::utils::AccountId32, + >, + pub new_nominator: runtime_types::pallet_nomination_pools::ConfigOp< + ::subxt::utils::AccountId32, + >, + pub new_bouncer: runtime_types::pallet_nomination_pools::ConfigOp< + ::subxt::utils::AccountId32, + >, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Chill { + pub pool_id: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BondExtraOther { + pub member: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub extra: + runtime_types::pallet_nomination_pools::BondExtra<::core::primitive::u128>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetClaimPermission { + pub permission: runtime_types::pallet_nomination_pools::ClaimPermission, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClaimPayoutOther { + pub other: ::subxt::utils::AccountId32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetCommission { + pub pool_id: ::core::primitive::u32, + pub new_commission: ::core::option::Option<( + runtime_types::sp_arithmetic::per_things::Perbill, + ::subxt::utils::AccountId32, + )>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetCommissionMax { + pub pool_id: ::core::primitive::u32, + pub max_commission: runtime_types::sp_arithmetic::per_things::Perbill, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetCommissionChangeRate { + pub pool_id: ::core::primitive::u32, + pub change_rate: runtime_types::pallet_nomination_pools::CommissionChangeRate< + ::core::primitive::u32, + >, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClaimCommission { + pub pool_id: ::core::primitive::u32, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Stake funds with a pool. The amount to bond is transferred from the member to the"] + #[doc = "pools account and immediately increases the pools bond."] + #[doc = ""] + #[doc = "# Note"] + #[doc = ""] + #[doc = "* An account can only be a member of a single pool."] + #[doc = "* An account cannot join the same pool multiple times."] + #[doc = "* This call will *not* dust the member account, so the member must have at least"] + #[doc = " `existential deposit + amount` in their account."] + #[doc = "* Only a pool with [`PoolState::Open`] can be joined"] + pub fn join( + &self, + amount: ::core::primitive::u128, + pool_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "join", + types::Join { amount, pool_id }, + [ + 205u8, 66u8, 42u8, 72u8, 146u8, 148u8, 119u8, 162u8, 101u8, 183u8, + 46u8, 176u8, 221u8, 204u8, 197u8, 20u8, 75u8, 226u8, 29u8, 118u8, + 208u8, 60u8, 192u8, 247u8, 222u8, 100u8, 69u8, 80u8, 172u8, 13u8, 69u8, + 250u8, + ], + ) + } + #[doc = "Bond `extra` more funds from `origin` into the pool to which they already belong."] + #[doc = ""] + #[doc = "Additional funds can come from either the free balance of the account, of from the"] + #[doc = "accumulated rewards, see [`BondExtra`]."] + #[doc = ""] + #[doc = "Bonding extra funds implies an automatic payout of all pending rewards as well."] + #[doc = "See `bond_extra_other` to bond pending rewards of `other` members."] + pub fn bond_extra( + &self, + extra: runtime_types::pallet_nomination_pools::BondExtra< + ::core::primitive::u128, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "bond_extra", + types::BondExtra { extra }, + [ + 50u8, 72u8, 181u8, 216u8, 249u8, 27u8, 250u8, 177u8, 253u8, 22u8, + 240u8, 100u8, 184u8, 202u8, 197u8, 34u8, 21u8, 188u8, 248u8, 191u8, + 11u8, 10u8, 236u8, 161u8, 168u8, 37u8, 38u8, 238u8, 61u8, 183u8, 86u8, + 55u8, + ], + ) + } + #[doc = "A bonded member can use this to claim their payout based on the rewards that the pool"] + #[doc = "has accumulated since their last claimed payout (OR since joining if this is their first"] + #[doc = "time claiming rewards). The payout will be transferred to the member's account."] + #[doc = ""] + #[doc = "The member will earn rewards pro rata based on the members stake vs the sum of the"] + #[doc = "members in the pools stake. Rewards do not \"expire\"."] + #[doc = ""] + #[doc = "See `claim_payout_other` to caim rewards on bahalf of some `other` pool member."] + pub fn claim_payout(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "claim_payout", + types::ClaimPayout {}, + [ + 128u8, 58u8, 138u8, 55u8, 64u8, 16u8, 129u8, 25u8, 211u8, 229u8, 193u8, + 115u8, 47u8, 45u8, 155u8, 221u8, 218u8, 1u8, 222u8, 5u8, 236u8, 32u8, + 88u8, 0u8, 198u8, 72u8, 196u8, 181u8, 104u8, 16u8, 212u8, 29u8, + ], + ) + } + #[doc = "Unbond up to `unbonding_points` of the `member_account`'s funds from the pool. It"] + #[doc = "implicitly collects the rewards one last time, since not doing so would mean some"] + #[doc = "rewards would be forfeited."] + #[doc = ""] + #[doc = "Under certain conditions, this call can be dispatched permissionlessly (i.e. by any"] + #[doc = "account)."] + #[doc = ""] + #[doc = "# Conditions for a permissionless dispatch."] + #[doc = ""] + #[doc = "* The pool is blocked and the caller is either the root or bouncer. This is refereed to"] + #[doc = " as a kick."] + #[doc = "* The pool is destroying and the member is not the depositor."] + #[doc = "* The pool is destroying, the member is the depositor and no other members are in the"] + #[doc = " pool."] + #[doc = ""] + #[doc = "## Conditions for permissioned dispatch (i.e. the caller is also the"] + #[doc = "`member_account`):"] + #[doc = ""] + #[doc = "* The caller is not the depositor."] + #[doc = "* The caller is the depositor, the pool is destroying and no other members are in the"] + #[doc = " pool."] + #[doc = ""] + #[doc = "# Note"] + #[doc = ""] + #[doc = "If there are too many unlocking chunks to unbond with the pool account,"] + #[doc = "[`Call::pool_withdraw_unbonded`] can be called to try and minimize unlocking chunks."] + #[doc = "The [`StakingInterface::unbond`] will implicitly call [`Call::pool_withdraw_unbonded`]"] + #[doc = "to try to free chunks if necessary (ie. if unbound was called and no unlocking chunks"] + #[doc = "are available). However, it may not be possible to release the current unlocking chunks,"] + #[doc = "in which case, the result of this call will likely be the `NoMoreChunks` error from the"] + #[doc = "staking system."] + pub fn unbond( + &self, + member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + unbonding_points: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "unbond", + types::Unbond { + member_account, + unbonding_points, + }, + [ + 78u8, 15u8, 37u8, 18u8, 129u8, 63u8, 31u8, 3u8, 68u8, 10u8, 12u8, 12u8, + 166u8, 179u8, 38u8, 232u8, 97u8, 1u8, 83u8, 53u8, 26u8, 59u8, 42u8, + 219u8, 176u8, 246u8, 169u8, 28u8, 35u8, 67u8, 139u8, 81u8, + ], + ) + } + #[doc = "Call `withdraw_unbonded` for the pools account. This call can be made by any account."] + #[doc = ""] + #[doc = "This is useful if their are too many unlocking chunks to call `unbond`, and some"] + #[doc = "can be cleared by withdrawing. In the case there are too many unlocking chunks, the user"] + #[doc = "would probably see an error like `NoMoreChunks` emitted from the staking system when"] + #[doc = "they attempt to unbond."] + pub fn pool_withdraw_unbonded( + &self, + pool_id: ::core::primitive::u32, + num_slashing_spans: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "pool_withdraw_unbonded", + types::PoolWithdrawUnbonded { + pool_id, + num_slashing_spans, + }, + [ + 152u8, 245u8, 131u8, 247u8, 106u8, 214u8, 154u8, 8u8, 7u8, 210u8, + 149u8, 218u8, 118u8, 46u8, 242u8, 182u8, 191u8, 119u8, 28u8, 199u8, + 36u8, 49u8, 219u8, 123u8, 58u8, 203u8, 211u8, 226u8, 217u8, 36u8, 56u8, + 0u8, + ], + ) + } + #[doc = "Withdraw unbonded funds from `member_account`. If no bonded funds can be unbonded, an"] + #[doc = "error is returned."] + #[doc = ""] + #[doc = "Under certain conditions, this call can be dispatched permissionlessly (i.e. by any"] + #[doc = "account)."] + #[doc = ""] + #[doc = "# Conditions for a permissionless dispatch"] + #[doc = ""] + #[doc = "* The pool is in destroy mode and the target is not the depositor."] + #[doc = "* The target is the depositor and they are the only member in the sub pools."] + #[doc = "* The pool is blocked and the caller is either the root or bouncer."] + #[doc = ""] + #[doc = "# Conditions for permissioned dispatch"] + #[doc = ""] + #[doc = "* The caller is the target and they are not the depositor."] + #[doc = ""] + #[doc = "# Note"] + #[doc = ""] + #[doc = "If the target is the depositor, the pool will be destroyed."] + pub fn withdraw_unbonded( + &self, + member_account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + num_slashing_spans: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "withdraw_unbonded", + types::WithdrawUnbonded { + member_account, + num_slashing_spans, + }, + [ + 61u8, 216u8, 214u8, 166u8, 59u8, 42u8, 186u8, 141u8, 47u8, 50u8, 135u8, + 236u8, 166u8, 88u8, 90u8, 244u8, 57u8, 106u8, 193u8, 211u8, 215u8, + 131u8, 203u8, 33u8, 195u8, 120u8, 213u8, 94u8, 213u8, 66u8, 79u8, + 140u8, + ], + ) + } + #[doc = "Create a new delegation pool."] + #[doc = ""] + #[doc = "# Arguments"] + #[doc = ""] + #[doc = "* `amount` - The amount of funds to delegate to the pool. This also acts of a sort of"] + #[doc = " deposit since the pools creator cannot fully unbond funds until the pool is being"] + #[doc = " destroyed."] + #[doc = "* `index` - A disambiguation index for creating the account. Likely only useful when"] + #[doc = " creating multiple pools in the same extrinsic."] + #[doc = "* `root` - The account to set as [`PoolRoles::root`]."] + #[doc = "* `nominator` - The account to set as the [`PoolRoles::nominator`]."] + #[doc = "* `bouncer` - The account to set as the [`PoolRoles::bouncer`]."] + #[doc = ""] + #[doc = "# Note"] + #[doc = ""] + #[doc = "In addition to `amount`, the caller will transfer the existential deposit; so the caller"] + #[doc = "needs at have at least `amount + existential_deposit` transferrable."] + pub fn create( + &self, + amount: ::core::primitive::u128, + root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "create", + types::Create { + amount, + root, + nominator, + bouncer, + }, + [ + 182u8, 114u8, 123u8, 215u8, 240u8, 217u8, 208u8, 165u8, 237u8, 1u8, + 215u8, 183u8, 218u8, 125u8, 71u8, 229u8, 68u8, 142u8, 60u8, 76u8, + 101u8, 242u8, 218u8, 61u8, 165u8, 203u8, 233u8, 241u8, 130u8, 13u8, + 76u8, 214u8, + ], + ) + } + #[doc = "Create a new delegation pool with a previously used pool id"] + #[doc = ""] + #[doc = "# Arguments"] + #[doc = ""] + #[doc = "same as `create` with the inclusion of"] + #[doc = "* `pool_id` - `A valid PoolId."] + pub fn create_with_pool_id( + &self, + amount: ::core::primitive::u128, + root: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + nominator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + bouncer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pool_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "create_with_pool_id", + types::CreateWithPoolId { + amount, + root, + nominator, + bouncer, + pool_id, + }, + [ + 76u8, 77u8, 158u8, 172u8, 4u8, 68u8, 53u8, 249u8, 156u8, 91u8, 19u8, + 151u8, 58u8, 199u8, 179u8, 0u8, 186u8, 152u8, 157u8, 28u8, 65u8, 227u8, + 133u8, 101u8, 102u8, 205u8, 68u8, 245u8, 104u8, 151u8, 146u8, 76u8, + ], + ) + } + #[doc = "Nominate on behalf of the pool."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be signed by the pool nominator or the pool"] + #[doc = "root role."] + #[doc = ""] + #[doc = "This directly forward the call to the staking pallet, on behalf of the pool bonded"] + #[doc = "account."] + pub fn nominate( + &self, + pool_id: ::core::primitive::u32, + validators: ::std::vec::Vec<::subxt::utils::AccountId32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "nominate", + types::Nominate { + pool_id, + validators, + }, + [ + 10u8, 235u8, 64u8, 157u8, 36u8, 249u8, 186u8, 27u8, 79u8, 172u8, 25u8, + 3u8, 203u8, 19u8, 192u8, 182u8, 36u8, 103u8, 13u8, 20u8, 89u8, 140u8, + 159u8, 4u8, 132u8, 242u8, 192u8, 146u8, 55u8, 251u8, 216u8, 255u8, + ], + ) + } + #[doc = "Set a new state for the pool."] + #[doc = ""] + #[doc = "If a pool is already in the `Destroying` state, then under no condition can its state"] + #[doc = "change again."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be either:"] + #[doc = ""] + #[doc = "1. signed by the bouncer, or the root role of the pool,"] + #[doc = "2. if the pool conditions to be open are NOT met (as described by `ok_to_be_open`), and"] + #[doc = " then the state of the pool can be permissionlessly changed to `Destroying`."] + pub fn set_state( + &self, + pool_id: ::core::primitive::u32, + state: runtime_types::pallet_nomination_pools::PoolState, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_state", + types::SetState { pool_id, state }, + [ + 104u8, 40u8, 213u8, 88u8, 159u8, 115u8, 35u8, 249u8, 78u8, 180u8, 99u8, + 1u8, 225u8, 218u8, 192u8, 151u8, 25u8, 194u8, 192u8, 187u8, 39u8, + 170u8, 212u8, 125u8, 75u8, 250u8, 248u8, 175u8, 159u8, 161u8, 151u8, + 162u8, + ], + ) + } + #[doc = "Set a new metadata for the pool."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be signed by the bouncer, or the root role of the"] + #[doc = "pool."] + pub fn set_metadata( + &self, + pool_id: ::core::primitive::u32, + metadata: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_metadata", + types::SetMetadata { pool_id, metadata }, + [ + 156u8, 81u8, 170u8, 161u8, 34u8, 100u8, 183u8, 174u8, 5u8, 81u8, 31u8, + 76u8, 12u8, 42u8, 77u8, 1u8, 6u8, 26u8, 168u8, 7u8, 8u8, 115u8, 158u8, + 151u8, 30u8, 211u8, 52u8, 177u8, 234u8, 87u8, 125u8, 127u8, + ], + ) + } + #[doc = "Update configurations for the nomination pools. The origin for this call must be"] + #[doc = "Root."] + #[doc = ""] + #[doc = "# Arguments"] + #[doc = ""] + #[doc = "* `min_join_bond` - Set [`MinJoinBond`]."] + #[doc = "* `min_create_bond` - Set [`MinCreateBond`]."] + #[doc = "* `max_pools` - Set [`MaxPools`]."] + #[doc = "* `max_members` - Set [`MaxPoolMembers`]."] + #[doc = "* `max_members_per_pool` - Set [`MaxPoolMembersPerPool`]."] + #[doc = "* `global_max_commission` - Set [`GlobalMaxCommission`]."] + pub fn set_configs( + &self, + min_join_bond: runtime_types::pallet_nomination_pools::ConfigOp< + ::core::primitive::u128, + >, + min_create_bond: runtime_types::pallet_nomination_pools::ConfigOp< + ::core::primitive::u128, + >, + max_pools: runtime_types::pallet_nomination_pools::ConfigOp< + ::core::primitive::u32, + >, + max_members: runtime_types::pallet_nomination_pools::ConfigOp< + ::core::primitive::u32, + >, + max_members_per_pool: runtime_types::pallet_nomination_pools::ConfigOp< + ::core::primitive::u32, + >, + global_max_commission: runtime_types::pallet_nomination_pools::ConfigOp< + runtime_types::sp_arithmetic::per_things::Perbill, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_configs", + types::SetConfigs { + min_join_bond, + min_create_bond, + max_pools, + max_members, + max_members_per_pool, + global_max_commission, + }, + [ + 20u8, 66u8, 112u8, 172u8, 143u8, 78u8, 60u8, 159u8, 240u8, 102u8, + 245u8, 10u8, 207u8, 27u8, 99u8, 138u8, 217u8, 239u8, 101u8, 190u8, + 222u8, 253u8, 53u8, 77u8, 230u8, 225u8, 101u8, 109u8, 50u8, 144u8, + 31u8, 121u8, + ], + ) + } + #[doc = "Update the roles of the pool."] + #[doc = ""] + #[doc = "The root is the only entity that can change any of the roles, including itself,"] + #[doc = "excluding the depositor, who can never change."] + #[doc = ""] + #[doc = "It emits an event, notifying UIs of the role change. This event is quite relevant to"] + #[doc = "most pool members and they should be informed of changes to pool roles."] + pub fn update_roles( + &self, + pool_id: ::core::primitive::u32, + new_root: runtime_types::pallet_nomination_pools::ConfigOp< + ::subxt::utils::AccountId32, + >, + new_nominator: runtime_types::pallet_nomination_pools::ConfigOp< + ::subxt::utils::AccountId32, + >, + new_bouncer: runtime_types::pallet_nomination_pools::ConfigOp< + ::subxt::utils::AccountId32, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "update_roles", + types::UpdateRoles { + pool_id, + new_root, + new_nominator, + new_bouncer, + }, + [ + 15u8, 154u8, 204u8, 28u8, 204u8, 120u8, 174u8, 203u8, 186u8, 33u8, + 123u8, 201u8, 143u8, 120u8, 193u8, 49u8, 164u8, 178u8, 55u8, 234u8, + 126u8, 247u8, 123u8, 73u8, 147u8, 107u8, 43u8, 72u8, 217u8, 4u8, 199u8, + 253u8, + ], + ) + } + #[doc = "Chill on behalf of the pool."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be signed by the pool nominator or the pool"] + #[doc = "root role, same as [`Pallet::nominate`]."] + #[doc = ""] + #[doc = "This directly forward the call to the staking pallet, on behalf of the pool bonded"] + #[doc = "account."] + pub fn chill( + &self, + pool_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "chill", + types::Chill { pool_id }, + [ + 41u8, 114u8, 128u8, 121u8, 244u8, 15u8, 15u8, 52u8, 129u8, 88u8, 239u8, + 167u8, 216u8, 38u8, 123u8, 240u8, 172u8, 229u8, 132u8, 64u8, 175u8, + 87u8, 217u8, 27u8, 11u8, 124u8, 1u8, 140u8, 40u8, 191u8, 187u8, 36u8, + ], + ) + } + #[doc = "`origin` bonds funds from `extra` for some pool member `member` into their respective"] + #[doc = "pools."] + #[doc = ""] + #[doc = "`origin` can bond extra funds from free balance or pending rewards when `origin =="] + #[doc = "other`."] + #[doc = ""] + #[doc = "In the case of `origin != other`, `origin` can only bond extra pending rewards of"] + #[doc = "`other` members assuming set_claim_permission for the given member is"] + #[doc = "`PermissionlessAll` or `PermissionlessCompound`."] + pub fn bond_extra_other( + &self, + member: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + extra: runtime_types::pallet_nomination_pools::BondExtra< + ::core::primitive::u128, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "bond_extra_other", + types::BondExtraOther { member, extra }, + [ + 13u8, 60u8, 161u8, 6u8, 191u8, 248u8, 61u8, 226u8, 192u8, 37u8, 44u8, + 146u8, 250u8, 213u8, 235u8, 147u8, 0u8, 14u8, 147u8, 11u8, 14u8, 126u8, + 70u8, 240u8, 83u8, 26u8, 95u8, 49u8, 52u8, 15u8, 185u8, 162u8, + ], + ) + } + #[doc = "Allows a pool member to set a claim permission to allow or disallow permissionless"] + #[doc = "bonding and withdrawing."] + #[doc = ""] + #[doc = "By default, this is `Permissioned`, which implies only the pool member themselves can"] + #[doc = "claim their pending rewards. If a pool member wishes so, they can set this to"] + #[doc = "`PermissionlessAll` to allow any account to claim their rewards and bond extra to the"] + #[doc = "pool."] + #[doc = ""] + #[doc = "# Arguments"] + #[doc = ""] + #[doc = "* `origin` - Member of a pool."] + #[doc = "* `actor` - Account to claim reward. // improve this"] + pub fn set_claim_permission( + &self, + permission: runtime_types::pallet_nomination_pools::ClaimPermission, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_claim_permission", + types::SetClaimPermission { permission }, + [ + 23u8, 253u8, 135u8, 53u8, 83u8, 71u8, 182u8, 223u8, 123u8, 57u8, 93u8, + 154u8, 110u8, 91u8, 63u8, 241u8, 144u8, 218u8, 129u8, 238u8, 169u8, + 9u8, 215u8, 76u8, 65u8, 168u8, 103u8, 44u8, 40u8, 39u8, 34u8, 16u8, + ], + ) + } + #[doc = "`origin` can claim payouts on some pool member `other`'s behalf."] + #[doc = ""] + #[doc = "Pool member `other` must have a `PermissionlessAll` or `PermissionlessWithdraw` in order"] + #[doc = "for this call to be successful."] + pub fn claim_payout_other( + &self, + other: ::subxt::utils::AccountId32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "claim_payout_other", + types::ClaimPayoutOther { other }, + [ + 52u8, 165u8, 191u8, 125u8, 180u8, 54u8, 27u8, 235u8, 195u8, 22u8, 55u8, + 183u8, 209u8, 63u8, 116u8, 88u8, 154u8, 74u8, 100u8, 103u8, 88u8, 76u8, + 35u8, 14u8, 39u8, 156u8, 219u8, 253u8, 123u8, 104u8, 168u8, 76u8, + ], + ) + } + #[doc = "Set the commission of a pool."] + #[doc = "Both a commission percentage and a commission payee must be provided in the `current`"] + #[doc = "tuple. Where a `current` of `None` is provided, any current commission will be removed."] + #[doc = ""] + #[doc = "- If a `None` is supplied to `new_commission`, existing commission will be removed."] + pub fn set_commission( + &self, + pool_id: ::core::primitive::u32, + new_commission: ::core::option::Option<( + runtime_types::sp_arithmetic::per_things::Perbill, + ::subxt::utils::AccountId32, + )>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_commission", + types::SetCommission { + pool_id, + new_commission, + }, + [ + 118u8, 240u8, 166u8, 40u8, 247u8, 44u8, 23u8, 92u8, 4u8, 78u8, 156u8, + 21u8, 178u8, 97u8, 197u8, 148u8, 61u8, 234u8, 15u8, 94u8, 248u8, 188u8, + 211u8, 13u8, 134u8, 10u8, 75u8, 59u8, 218u8, 13u8, 104u8, 115u8, + ], + ) + } + #[doc = "Set the maximum commission of a pool."] + #[doc = ""] + #[doc = "- Initial max can be set to any `Perbill`, and only smaller values thereafter."] + #[doc = "- Current commission will be lowered in the event it is higher than a new max"] + #[doc = " commission."] + pub fn set_commission_max( + &self, + pool_id: ::core::primitive::u32, + max_commission: runtime_types::sp_arithmetic::per_things::Perbill, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_commission_max", + types::SetCommissionMax { + pool_id, + max_commission, + }, + [ + 115u8, 90u8, 156u8, 35u8, 7u8, 125u8, 184u8, 123u8, 149u8, 232u8, 59u8, + 21u8, 42u8, 120u8, 14u8, 152u8, 184u8, 167u8, 18u8, 22u8, 148u8, 83u8, + 16u8, 81u8, 93u8, 182u8, 154u8, 182u8, 46u8, 40u8, 179u8, 187u8, + ], + ) + } + #[doc = "Set the commission change rate for a pool."] + #[doc = ""] + #[doc = "Initial change rate is not bounded, whereas subsequent updates can only be more"] + #[doc = "restrictive than the current."] + pub fn set_commission_change_rate( + &self, + pool_id: ::core::primitive::u32, + change_rate: runtime_types::pallet_nomination_pools::CommissionChangeRate< + ::core::primitive::u32, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "set_commission_change_rate", + types::SetCommissionChangeRate { + pool_id, + change_rate, + }, + [ + 118u8, 194u8, 114u8, 197u8, 214u8, 246u8, 23u8, 237u8, 10u8, 90u8, + 230u8, 123u8, 172u8, 174u8, 98u8, 198u8, 160u8, 71u8, 113u8, 76u8, + 201u8, 201u8, 153u8, 92u8, 222u8, 252u8, 7u8, 184u8, 236u8, 235u8, + 126u8, 201u8, + ], + ) + } + #[doc = "Claim pending commission."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be signed by the `root` role of the pool. Pending"] + #[doc = "commission is paid out and added to total claimed commission`. Total pending commission"] + #[doc = "is reset to zero. the current."] + pub fn claim_commission( + &self, + pool_id: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "NominationPools", + "claim_commission", + types::ClaimCommission { pool_id }, + [ + 139u8, 126u8, 219u8, 117u8, 140u8, 51u8, 163u8, 32u8, 83u8, 60u8, + 250u8, 44u8, 186u8, 194u8, 225u8, 84u8, 61u8, 181u8, 212u8, 160u8, + 156u8, 93u8, 16u8, 255u8, 165u8, 178u8, 25u8, 64u8, 187u8, 29u8, 169u8, + 174u8, + ], + ) + } + } + } + #[doc = "Events of this pallet."] + pub type Event = runtime_types::pallet_nomination_pools::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A pool has been created."] + pub struct Created { + pub depositor: ::subxt::utils::AccountId32, + pub pool_id: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Created { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "Created"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A member has became bonded in a pool."] + pub struct Bonded { + pub member: ::subxt::utils::AccountId32, + pub pool_id: ::core::primitive::u32, + pub bonded: ::core::primitive::u128, + pub joined: ::core::primitive::bool, + } + impl ::subxt::events::StaticEvent for Bonded { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "Bonded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A payout has been made to a member."] + pub struct PaidOut { + pub member: ::subxt::utils::AccountId32, + pub pool_id: ::core::primitive::u32, + pub payout: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for PaidOut { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "PaidOut"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A member has unbonded from their pool."] + #[doc = ""] + #[doc = "- `balance` is the corresponding balance of the number of points that has been"] + #[doc = " requested to be unbonded (the argument of the `unbond` transaction) from the bonded"] + #[doc = " pool."] + #[doc = "- `points` is the number of points that are issued as a result of `balance` being"] + #[doc = "dissolved into the corresponding unbonding pool."] + #[doc = "- `era` is the era in which the balance will be unbonded."] + #[doc = "In the absence of slashing, these values will match. In the presence of slashing, the"] + #[doc = "number of points that are issued in the unbonding pool will be less than the amount"] + #[doc = "requested to be unbonded."] + pub struct Unbonded { + pub member: ::subxt::utils::AccountId32, + pub pool_id: ::core::primitive::u32, + pub balance: ::core::primitive::u128, + pub points: ::core::primitive::u128, + pub era: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Unbonded { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "Unbonded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A member has withdrawn from their pool."] + #[doc = ""] + #[doc = "The given number of `points` have been dissolved in return of `balance`."] + #[doc = ""] + #[doc = "Similar to `Unbonded` event, in the absence of slashing, the ratio of point to balance"] + #[doc = "will be 1."] + pub struct Withdrawn { + pub member: ::subxt::utils::AccountId32, + pub pool_id: ::core::primitive::u32, + pub balance: ::core::primitive::u128, + pub points: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Withdrawn { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "Withdrawn"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A pool has been destroyed."] + pub struct Destroyed { + pub pool_id: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Destroyed { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "Destroyed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The state of a pool has changed"] + pub struct StateChanged { + pub pool_id: ::core::primitive::u32, + pub new_state: runtime_types::pallet_nomination_pools::PoolState, + } + impl ::subxt::events::StaticEvent for StateChanged { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "StateChanged"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A member has been removed from a pool."] + #[doc = ""] + #[doc = "The removal can be voluntary (withdrawn all unbonded funds) or involuntary (kicked)."] + pub struct MemberRemoved { + pub pool_id: ::core::primitive::u32, + pub member: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for MemberRemoved { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "MemberRemoved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The roles of a pool have been updated to the given new roles. Note that the depositor"] + #[doc = "can never change."] + pub struct RolesUpdated { + pub root: ::core::option::Option<::subxt::utils::AccountId32>, + pub bouncer: ::core::option::Option<::subxt::utils::AccountId32>, + pub nominator: ::core::option::Option<::subxt::utils::AccountId32>, + } + impl ::subxt::events::StaticEvent for RolesUpdated { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "RolesUpdated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The active balance of pool `pool_id` has been slashed to `balance`."] + pub struct PoolSlashed { + pub pool_id: ::core::primitive::u32, + pub balance: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for PoolSlashed { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "PoolSlashed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The unbond pool at `era` of pool `pool_id` has been slashed to `balance`."] + pub struct UnbondingPoolSlashed { + pub pool_id: ::core::primitive::u32, + pub era: ::core::primitive::u32, + pub balance: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for UnbondingPoolSlashed { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "UnbondingPoolSlashed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A pool's commission setting has been changed."] + pub struct PoolCommissionUpdated { + pub pool_id: ::core::primitive::u32, + pub current: ::core::option::Option<( + runtime_types::sp_arithmetic::per_things::Perbill, + ::subxt::utils::AccountId32, + )>, + } + impl ::subxt::events::StaticEvent for PoolCommissionUpdated { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "PoolCommissionUpdated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A pool's maximum commission setting has been changed."] + pub struct PoolMaxCommissionUpdated { + pub pool_id: ::core::primitive::u32, + pub max_commission: runtime_types::sp_arithmetic::per_things::Perbill, + } + impl ::subxt::events::StaticEvent for PoolMaxCommissionUpdated { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "PoolMaxCommissionUpdated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A pool's commission `change_rate` has been changed."] + pub struct PoolCommissionChangeRateUpdated { + pub pool_id: ::core::primitive::u32, + pub change_rate: runtime_types::pallet_nomination_pools::CommissionChangeRate< + ::core::primitive::u32, + >, + } + impl ::subxt::events::StaticEvent for PoolCommissionChangeRateUpdated { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "PoolCommissionChangeRateUpdated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, Debug, )] # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetPvfCheckingEnabled { - pub new: ::core::primitive::bool, + #[doc = "Pool commission has been claimed."] + pub struct PoolCommissionClaimed { + pub pool_id: ::core::primitive::u32, + pub commission: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for PoolCommissionClaimed { + const PALLET: &'static str = "NominationPools"; + const EVENT: &'static str = "PoolCommissionClaimed"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Minimum amount to bond to join a pool."] + pub fn min_join_bond( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "MinJoinBond", + vec![], + [ + 125u8, 239u8, 45u8, 225u8, 74u8, 129u8, 247u8, 184u8, 205u8, 58u8, + 45u8, 186u8, 126u8, 170u8, 112u8, 120u8, 23u8, 190u8, 247u8, 97u8, + 131u8, 126u8, 215u8, 44u8, 147u8, 122u8, 132u8, 212u8, 217u8, 84u8, + 240u8, 91u8, + ], + ) + } + #[doc = " Minimum bond required to create a pool."] + #[doc = ""] + #[doc = " This is the amount that the depositor must put as their initial stake in the pool, as an"] + #[doc = " indication of \"skin in the game\"."] + #[doc = ""] + #[doc = " This is the value that will always exist in the staking ledger of the pool bonded account"] + #[doc = " while all other accounts leave."] + pub fn min_create_bond( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "MinCreateBond", + vec![], + [ + 31u8, 208u8, 240u8, 158u8, 23u8, 218u8, 212u8, 138u8, 92u8, 210u8, + 207u8, 170u8, 32u8, 60u8, 5u8, 21u8, 84u8, 162u8, 1u8, 111u8, 181u8, + 243u8, 24u8, 148u8, 193u8, 253u8, 248u8, 190u8, 16u8, 222u8, 219u8, + 67u8, + ], + ) + } + #[doc = " Maximum number of nomination pools that can exist. If `None`, then an unbounded number of"] + #[doc = " pools can exist."] + pub fn max_pools( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "MaxPools", + vec![], + [ + 216u8, 111u8, 68u8, 103u8, 33u8, 50u8, 109u8, 3u8, 176u8, 195u8, 23u8, + 73u8, 112u8, 138u8, 9u8, 194u8, 233u8, 73u8, 68u8, 215u8, 162u8, 255u8, + 217u8, 173u8, 141u8, 27u8, 72u8, 199u8, 7u8, 240u8, 25u8, 34u8, + ], + ) + } + #[doc = " Maximum number of members that can exist in the system. If `None`, then the count"] + #[doc = " members are not bound on a system wide basis."] + pub fn max_pool_members( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "MaxPoolMembers", + vec![], + [ + 82u8, 217u8, 26u8, 234u8, 223u8, 241u8, 66u8, 182u8, 43u8, 233u8, 59u8, + 242u8, 202u8, 254u8, 69u8, 50u8, 254u8, 196u8, 166u8, 89u8, 120u8, + 87u8, 76u8, 148u8, 31u8, 197u8, 49u8, 88u8, 206u8, 41u8, 242u8, 62u8, + ], + ) + } + #[doc = " Maximum number of members that may belong to pool. If `None`, then the count of"] + #[doc = " members is not bound on a per pool basis."] + pub fn max_pool_members_per_pool( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "MaxPoolMembersPerPool", + vec![], + [ + 93u8, 241u8, 16u8, 169u8, 138u8, 199u8, 128u8, 149u8, 65u8, 30u8, 55u8, + 11u8, 41u8, 252u8, 83u8, 250u8, 9u8, 33u8, 152u8, 239u8, 195u8, 147u8, + 16u8, 248u8, 180u8, 153u8, 88u8, 231u8, 248u8, 169u8, 186u8, 48u8, + ], + ) + } + #[doc = " The maximum commission that can be charged by a pool. Used on commission payouts to bound"] + #[doc = " pool commissions that are > `GlobalMaxCommission`, necessary if a future"] + #[doc = " `GlobalMaxCommission` is lower than some current pool commissions."] + pub fn global_max_commission( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_arithmetic::per_things::Perbill, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "GlobalMaxCommission", + vec![], + [ + 142u8, 252u8, 92u8, 128u8, 162u8, 4u8, 216u8, 39u8, 118u8, 201u8, + 138u8, 171u8, 76u8, 90u8, 133u8, 176u8, 161u8, 138u8, 214u8, 183u8, + 193u8, 115u8, 245u8, 151u8, 216u8, 84u8, 99u8, 175u8, 144u8, 196u8, + 103u8, 190u8, + ], + ) + } + #[doc = " Active members."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn pool_members( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::PoolMember, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "PoolMembers", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 252u8, 236u8, 201u8, 127u8, 219u8, 1u8, 19u8, 144u8, 5u8, 108u8, 70u8, + 30u8, 177u8, 232u8, 253u8, 237u8, 211u8, 91u8, 63u8, 62u8, 155u8, + 151u8, 153u8, 165u8, 206u8, 53u8, 111u8, 31u8, 60u8, 120u8, 100u8, + 249u8, + ], + ) + } + #[doc = " Active members."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn pool_members_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::PoolMember, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "PoolMembers", + Vec::new(), + [ + 252u8, 236u8, 201u8, 127u8, 219u8, 1u8, 19u8, 144u8, 5u8, 108u8, 70u8, + 30u8, 177u8, 232u8, 253u8, 237u8, 211u8, 91u8, 63u8, 62u8, 155u8, + 151u8, 153u8, 165u8, 206u8, 53u8, 111u8, 31u8, 60u8, 120u8, 100u8, + 249u8, + ], + ) + } + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_pool_members( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "CounterForPoolMembers", + vec![], + [ + 114u8, 126u8, 27u8, 138u8, 119u8, 44u8, 45u8, 129u8, 84u8, 107u8, + 171u8, 206u8, 117u8, 141u8, 20u8, 75u8, 229u8, 237u8, 31u8, 229u8, + 124u8, 190u8, 27u8, 124u8, 63u8, 59u8, 167u8, 42u8, 62u8, 212u8, 160u8, + 2u8, + ], + ) + } + #[doc = " Storage for bonded pools."] + pub fn bonded_pools( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::BondedPoolInner, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "BondedPools", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 3u8, 183u8, 140u8, 154u8, 74u8, 225u8, 69u8, 243u8, 150u8, 132u8, + 163u8, 26u8, 101u8, 45u8, 231u8, 178u8, 85u8, 144u8, 9u8, 112u8, 212u8, + 167u8, 131u8, 188u8, 203u8, 50u8, 177u8, 218u8, 154u8, 182u8, 80u8, + 232u8, + ], + ) + } + #[doc = " Storage for bonded pools."] + pub fn bonded_pools_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::BondedPoolInner, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "BondedPools", + Vec::new(), + [ + 3u8, 183u8, 140u8, 154u8, 74u8, 225u8, 69u8, 243u8, 150u8, 132u8, + 163u8, 26u8, 101u8, 45u8, 231u8, 178u8, 85u8, 144u8, 9u8, 112u8, 212u8, + 167u8, 131u8, 188u8, 203u8, 50u8, 177u8, 218u8, 154u8, 182u8, 80u8, + 232u8, + ], + ) + } + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_bonded_pools( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "CounterForBondedPools", + vec![], + [ + 134u8, 94u8, 199u8, 73u8, 174u8, 253u8, 66u8, 242u8, 233u8, 244u8, + 140u8, 170u8, 242u8, 40u8, 41u8, 185u8, 183u8, 151u8, 58u8, 111u8, + 221u8, 225u8, 81u8, 71u8, 169u8, 219u8, 223u8, 135u8, 8u8, 171u8, + 180u8, 236u8, + ], + ) + } + #[doc = " Reward pools. This is where there rewards for each pool accumulate. When a members payout is"] + #[doc = " claimed, the balance comes out fo the reward pool. Keyed by the bonded pools account."] + pub fn reward_pools( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::RewardPool, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "RewardPools", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 235u8, 6u8, 2u8, 103u8, 137u8, 31u8, 109u8, 165u8, 129u8, 48u8, 154u8, + 219u8, 110u8, 198u8, 241u8, 31u8, 174u8, 10u8, 92u8, 233u8, 161u8, + 76u8, 53u8, 136u8, 172u8, 214u8, 192u8, 12u8, 239u8, 165u8, 195u8, + 96u8, + ], + ) + } + #[doc = " Reward pools. This is where there rewards for each pool accumulate. When a members payout is"] + #[doc = " claimed, the balance comes out fo the reward pool. Keyed by the bonded pools account."] + pub fn reward_pools_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::RewardPool, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "RewardPools", + Vec::new(), + [ + 235u8, 6u8, 2u8, 103u8, 137u8, 31u8, 109u8, 165u8, 129u8, 48u8, 154u8, + 219u8, 110u8, 198u8, 241u8, 31u8, 174u8, 10u8, 92u8, 233u8, 161u8, + 76u8, 53u8, 136u8, 172u8, 214u8, 192u8, 12u8, 239u8, 165u8, 195u8, + 96u8, + ], + ) + } + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_reward_pools( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "CounterForRewardPools", + vec![], + [ + 209u8, 139u8, 212u8, 116u8, 210u8, 178u8, 213u8, 38u8, 75u8, 23u8, + 188u8, 57u8, 253u8, 213u8, 95u8, 118u8, 182u8, 250u8, 45u8, 205u8, + 17u8, 175u8, 17u8, 201u8, 234u8, 14u8, 98u8, 49u8, 143u8, 135u8, 201u8, + 81u8, + ], + ) + } + #[doc = " Groups of unbonding pools. Each group of unbonding pools belongs to a"] + #[doc = " bonded pool, hence the name sub-pools. Keyed by the bonded pools account."] + pub fn sub_pools_storage( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::SubPools, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "SubPoolsStorage", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 231u8, 13u8, 111u8, 248u8, 1u8, 208u8, 179u8, 134u8, 224u8, 196u8, + 94u8, 201u8, 229u8, 29u8, 155u8, 211u8, 163u8, 150u8, 157u8, 34u8, + 68u8, 238u8, 55u8, 4u8, 222u8, 96u8, 186u8, 29u8, 205u8, 237u8, 80u8, + 42u8, + ], + ) + } + #[doc = " Groups of unbonding pools. Each group of unbonding pools belongs to a"] + #[doc = " bonded pool, hence the name sub-pools. Keyed by the bonded pools account."] + pub fn sub_pools_storage_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::SubPools, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "SubPoolsStorage", + Vec::new(), + [ + 231u8, 13u8, 111u8, 248u8, 1u8, 208u8, 179u8, 134u8, 224u8, 196u8, + 94u8, 201u8, 229u8, 29u8, 155u8, 211u8, 163u8, 150u8, 157u8, 34u8, + 68u8, 238u8, 55u8, 4u8, 222u8, 96u8, 186u8, 29u8, 205u8, 237u8, 80u8, + 42u8, + ], + ) + } + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_sub_pools_storage( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "CounterForSubPoolsStorage", + vec![], + [ + 212u8, 145u8, 212u8, 226u8, 234u8, 31u8, 26u8, 240u8, 107u8, 91u8, + 171u8, 120u8, 41u8, 195u8, 16u8, 86u8, 55u8, 127u8, 103u8, 93u8, 128u8, + 48u8, 69u8, 104u8, 168u8, 236u8, 81u8, 54u8, 2u8, 184u8, 215u8, 51u8, + ], + ) + } + #[doc = " Metadata for the pool."] + pub fn metadata( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "Metadata", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 108u8, 250u8, 163u8, 54u8, 192u8, 143u8, 239u8, 62u8, 97u8, 163u8, + 161u8, 215u8, 171u8, 225u8, 49u8, 18u8, 37u8, 200u8, 143u8, 254u8, + 136u8, 26u8, 54u8, 187u8, 39u8, 3u8, 216u8, 24u8, 188u8, 25u8, 243u8, + 251u8, + ], + ) + } + #[doc = " Metadata for the pool."] + pub fn metadata_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "Metadata", + Vec::new(), + [ + 108u8, 250u8, 163u8, 54u8, 192u8, 143u8, 239u8, 62u8, 97u8, 163u8, + 161u8, 215u8, 171u8, 225u8, 49u8, 18u8, 37u8, 200u8, 143u8, 254u8, + 136u8, 26u8, 54u8, 187u8, 39u8, 3u8, 216u8, 24u8, 188u8, 25u8, 243u8, + 251u8, + ], + ) + } + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_metadata( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "CounterForMetadata", + vec![], + [ + 190u8, 232u8, 77u8, 134u8, 245u8, 89u8, 160u8, 187u8, 163u8, 68u8, + 188u8, 204u8, 31u8, 145u8, 219u8, 165u8, 213u8, 1u8, 167u8, 90u8, + 175u8, 218u8, 147u8, 144u8, 158u8, 226u8, 23u8, 233u8, 55u8, 168u8, + 161u8, 237u8, + ], + ) + } + #[doc = " Ever increasing number of all pools created so far."] + pub fn last_pool_id( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "LastPoolId", + vec![], + [ + 50u8, 254u8, 218u8, 41u8, 213u8, 184u8, 170u8, 166u8, 31u8, 29u8, + 196u8, 57u8, 215u8, 20u8, 40u8, 40u8, 19u8, 22u8, 9u8, 184u8, 11u8, + 21u8, 21u8, 125u8, 97u8, 38u8, 219u8, 209u8, 2u8, 238u8, 247u8, 51u8, + ], + ) + } + #[doc = " A reverse lookup from the pool's account id to its id."] + #[doc = ""] + #[doc = " This is only used for slashing. In all other instances, the pool id is used, and the"] + #[doc = " accounts are deterministically derived from it."] + pub fn reverse_pool_id_lookup( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "ReversePoolIdLookup", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 178u8, 161u8, 51u8, 220u8, 128u8, 1u8, 135u8, 83u8, 236u8, 159u8, 36u8, + 237u8, 120u8, 128u8, 6u8, 191u8, 41u8, 159u8, 94u8, 178u8, 174u8, + 235u8, 221u8, 173u8, 44u8, 81u8, 211u8, 255u8, 231u8, 81u8, 16u8, 87u8, + ], + ) + } + #[doc = " A reverse lookup from the pool's account id to its id."] + #[doc = ""] + #[doc = " This is only used for slashing. In all other instances, the pool id is used, and the"] + #[doc = " accounts are deterministically derived from it."] + pub fn reverse_pool_id_lookup_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "ReversePoolIdLookup", + Vec::new(), + [ + 178u8, 161u8, 51u8, 220u8, 128u8, 1u8, 135u8, 83u8, 236u8, 159u8, 36u8, + 237u8, 120u8, 128u8, 6u8, 191u8, 41u8, 159u8, 94u8, 178u8, 174u8, + 235u8, 221u8, 173u8, 44u8, 81u8, 211u8, 255u8, 231u8, 81u8, 16u8, 87u8, + ], + ) + } + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_reverse_pool_id_lookup( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "CounterForReversePoolIdLookup", + vec![], + [ + 148u8, 83u8, 81u8, 33u8, 188u8, 72u8, 148u8, 208u8, 245u8, 178u8, 52u8, + 245u8, 229u8, 140u8, 100u8, 152u8, 8u8, 217u8, 161u8, 80u8, 226u8, + 42u8, 15u8, 252u8, 90u8, 197u8, 120u8, 114u8, 144u8, 90u8, 199u8, + 123u8, + ], + ) + } + #[doc = " Map from a pool member account to their opted claim permission."] + pub fn claim_permissions( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::ClaimPermission, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "ClaimPermissions", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 23u8, 124u8, 83u8, 109u8, 174u8, 228u8, 170u8, 25u8, 124u8, 91u8, + 224u8, 66u8, 55u8, 127u8, 190u8, 226u8, 163u8, 16u8, 81u8, 231u8, + 241u8, 214u8, 209u8, 137u8, 101u8, 206u8, 104u8, 138u8, 49u8, 56u8, + 152u8, 228u8, + ], + ) + } + #[doc = " Map from a pool member account to their opted claim permission."] + pub fn claim_permissions_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_nomination_pools::ClaimPermission, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "NominationPools", + "ClaimPermissions", + Vec::new(), + [ + 23u8, 124u8, 83u8, 109u8, 174u8, 228u8, 170u8, 25u8, 124u8, 91u8, + 224u8, 66u8, 55u8, 127u8, 190u8, 226u8, 163u8, 16u8, 81u8, 231u8, + 241u8, 214u8, 209u8, 137u8, 101u8, 206u8, 104u8, 138u8, 49u8, 56u8, + 152u8, 228u8, + ], + ) + } } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetPvfVotingTtl { - pub new: ::core::primitive::u32, + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The nomination pool's pallet id."] + pub fn pallet_id( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "NominationPools", + "PalletId", + [ + 139u8, 109u8, 228u8, 151u8, 252u8, 32u8, 130u8, 69u8, 112u8, 154u8, + 174u8, 45u8, 83u8, 245u8, 51u8, 132u8, 173u8, 5u8, 186u8, 24u8, 243u8, + 9u8, 12u8, 214u8, 80u8, 74u8, 69u8, 189u8, 30u8, 94u8, 22u8, 39u8, + ], + ) + } + #[doc = " The maximum pool points-to-balance ratio that an `open` pool can have."] + #[doc = ""] + #[doc = " This is important in the event slashing takes place and the pool's points-to-balance"] + #[doc = " ratio becomes disproportional."] + #[doc = ""] + #[doc = " Moreover, this relates to the `RewardCounter` type as well, as the arithmetic operations"] + #[doc = " are a function of number of points, and by setting this value to e.g. 10, you ensure"] + #[doc = " that the total number of points in the system are at most 10 times the total_issuance of"] + #[doc = " the chain, in the absolute worse case."] + #[doc = ""] + #[doc = " For a value of 10, the threshold would be a pool points-to-balance ratio of 10:1."] + #[doc = " Such a scenario would also be the equivalent of the pool being 90% slashed."] + pub fn max_points_to_balance( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u8> { + ::subxt::constants::Address::new_static( + "NominationPools", + "MaxPointsToBalance", + [ + 141u8, 130u8, 11u8, 35u8, 226u8, 114u8, 92u8, 179u8, 168u8, 110u8, + 28u8, 91u8, 221u8, 64u8, 4u8, 148u8, 201u8, 193u8, 185u8, 66u8, 226u8, + 114u8, 97u8, 79u8, 62u8, 212u8, 202u8, 114u8, 237u8, 228u8, 183u8, + 165u8, + ], + ) + } } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMinimumValidationUpgradeDelay { - pub new: ::core::primitive::u32, + } + } + pub mod fast_unstake { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::pallet_fast_unstake::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RegisterFastUnstake; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Deregister; + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Control { + pub eras_to_check: ::core::primitive::u32, + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "Register oneself for fast-unstake."] + #[doc = ""] + #[doc = "The dispatch origin of this call must be signed by the controller account, similar to"] + #[doc = "`staking::unbond`."] + #[doc = ""] + #[doc = "The stash associated with the origin must have no ongoing unlocking chunks. If"] + #[doc = "successful, this will fully unbond and chill the stash. Then, it will enqueue the stash"] + #[doc = "to be checked in further blocks."] + #[doc = ""] + #[doc = "If by the time this is called, the stash is actually eligible for fast-unstake, then"] + #[doc = "they are guaranteed to remain eligible, because the call will chill them as well."] + #[doc = ""] + #[doc = "If the check works, the entire staking data is removed, i.e. the stash is fully"] + #[doc = "unstaked."] + #[doc = ""] + #[doc = "If the check fails, the stash remains chilled and waiting for being unbonded as in with"] + #[doc = "the normal staking system, but they lose part of their unbonding chunks due to consuming"] + #[doc = "the chain's resources."] + pub fn register_fast_unstake( + &self, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "FastUnstake", + "register_fast_unstake", + types::RegisterFastUnstake {}, + [ + 254u8, 85u8, 128u8, 135u8, 172u8, 170u8, 34u8, 145u8, 79u8, 117u8, + 234u8, 90u8, 16u8, 174u8, 159u8, 197u8, 27u8, 239u8, 180u8, 85u8, + 116u8, 23u8, 254u8, 30u8, 197u8, 110u8, 48u8, 184u8, 177u8, 129u8, + 42u8, 122u8, + ], + ) + } + #[doc = "Deregister oneself from the fast-unstake."] + #[doc = ""] + #[doc = "This is useful if one is registered, they are still waiting, and they change their mind."] + #[doc = ""] + #[doc = "Note that the associated stash is still fully unbonded and chilled as a consequence of"] + #[doc = "calling `register_fast_unstake`. This should probably be followed by a call to"] + #[doc = "`Staking::rebond`."] + pub fn deregister(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "FastUnstake", + "deregister", + types::Deregister {}, + [ + 198u8, 180u8, 253u8, 148u8, 124u8, 145u8, 175u8, 121u8, 42u8, 181u8, + 41u8, 155u8, 229u8, 181u8, 66u8, 140u8, 103u8, 86u8, 242u8, 155u8, + 192u8, 34u8, 157u8, 107u8, 211u8, 162u8, 1u8, 144u8, 35u8, 252u8, 88u8, + 21u8, + ], + ) + } + #[doc = "Control the operation of this pallet."] + #[doc = ""] + #[doc = "Dispatch origin must be signed by the [`Config::ControlOrigin`]."] + pub fn control( + &self, + eras_to_check: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "FastUnstake", + "control", + types::Control { eras_to_check }, + [ + 92u8, 241u8, 123u8, 251u8, 82u8, 36u8, 209u8, 87u8, 238u8, 56u8, 32u8, + 54u8, 190u8, 89u8, 167u8, 2u8, 36u8, 249u8, 131u8, 54u8, 217u8, 217u8, + 231u8, 167u8, 232u8, 35u8, 108u8, 193u8, 70u8, 224u8, 47u8, 142u8, + ], + ) + } } + } + #[doc = "The events of this pallet."] + pub type Event = runtime_types::pallet_fast_unstake::pallet::Event; + pub mod events { + use super::runtime_types; #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -27061,8 +28685,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetBypassConsistencyCheck { - pub new: ::core::primitive::bool, + #[doc = "A staker was unstaked."] + pub struct Unstaked { + pub stash: ::subxt::utils::AccountId32, + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + } + impl ::subxt::events::StaticEvent for Unstaked { + const PALLET: &'static str = "FastUnstake"; + const EVENT: &'static str = "Unstaked"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -27074,8 +28704,14 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetAsyncBackingParams { - pub new: runtime_types::polkadot_primitives::vstaging::AsyncBackingParams, + #[doc = "A staker was slashed for requesting fast-unstake whilst being exposed."] + pub struct Slashed { + pub stash: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Slashed { + const PALLET: &'static str = "FastUnstake"; + const EVENT: &'static str = "Slashed"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -27087,8 +28723,11 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetExecutorParams { - pub new: runtime_types::polkadot_primitives::v4::executor_params::ExecutorParams, + #[doc = "An internal error happened. Operations will be paused now."] + pub struct InternalError; + impl ::subxt::events::StaticEvent for InternalError { + const PALLET: &'static str = "FastUnstake"; + const EVENT: &'static str = "InternalError"; } #[derive( :: subxt :: ext :: codec :: Decode, @@ -27100,10 +28739,16 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetAsyncBackingParams { - pub new: runtime_types::polkadot_primitives::vstaging::AsyncBackingParams, + #[doc = "A batch was partially checked for the given eras, but the process did not finish."] + pub struct BatchChecked { + pub eras: ::std::vec::Vec<::core::primitive::u32>, + } + impl ::subxt::events::StaticEvent for BatchChecked { + const PALLET: &'static str = "FastUnstake"; + const EVENT: &'static str = "BatchChecked"; } #[derive( + :: subxt :: ext :: codec :: CompactAs, :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, :: subxt :: ext :: scale_decode :: DecodeAsType, @@ -27113,8 +28758,804 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetExecutorParams { - pub new: runtime_types::polkadot_primitives::v4::executor_params::ExecutorParams, + #[doc = "A batch of a given size was terminated."] + #[doc = ""] + #[doc = "This is always follows by a number of `Unstaked` or `Slashed` events, marking the end"] + #[doc = "of the batch. A new batch will be created upon next block."] + pub struct BatchFinished { + pub size: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for BatchFinished { + const PALLET: &'static str = "FastUnstake"; + const EVENT: &'static str = "BatchFinished"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The current \"head of the queue\" being unstaked."] + pub fn head( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_fast_unstake::types::UnstakeRequest, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "FastUnstake", + "Head", + vec![], + [ + 206u8, 19u8, 169u8, 239u8, 214u8, 136u8, 16u8, 102u8, 82u8, 110u8, + 128u8, 205u8, 102u8, 96u8, 148u8, 190u8, 67u8, 75u8, 2u8, 213u8, 134u8, + 143u8, 40u8, 57u8, 54u8, 66u8, 170u8, 42u8, 135u8, 212u8, 108u8, 177u8, + ], + ) + } + #[doc = " The map of all accounts wishing to be unstaked."] + #[doc = ""] + #[doc = " Keeps track of `AccountId` wishing to unstake and it's corresponding deposit."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn queue( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "FastUnstake", + "Queue", + vec![::subxt::storage::address::make_static_storage_map_key( + _0.borrow(), + )], + [ + 250u8, 208u8, 88u8, 68u8, 8u8, 87u8, 27u8, 59u8, 120u8, 242u8, 79u8, + 54u8, 108u8, 15u8, 62u8, 143u8, 126u8, 66u8, 159u8, 159u8, 55u8, 212u8, + 190u8, 26u8, 171u8, 90u8, 156u8, 205u8, 173u8, 189u8, 230u8, 71u8, + ], + ) + } + #[doc = " The map of all accounts wishing to be unstaked."] + #[doc = ""] + #[doc = " Keeps track of `AccountId` wishing to unstake and it's corresponding deposit."] + #[doc = ""] + #[doc = " TWOX-NOTE: SAFE since `AccountId` is a secure hash."] + pub fn queue_root( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "FastUnstake", + "Queue", + Vec::new(), + [ + 250u8, 208u8, 88u8, 68u8, 8u8, 87u8, 27u8, 59u8, 120u8, 242u8, 79u8, + 54u8, 108u8, 15u8, 62u8, 143u8, 126u8, 66u8, 159u8, 159u8, 55u8, 212u8, + 190u8, 26u8, 171u8, 90u8, 156u8, 205u8, 173u8, 189u8, 230u8, 71u8, + ], + ) + } + #[doc = "Counter for the related counted storage map"] + pub fn counter_for_queue( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "FastUnstake", + "CounterForQueue", + vec![], + [ + 241u8, 174u8, 224u8, 214u8, 204u8, 37u8, 117u8, 62u8, 114u8, 63u8, + 123u8, 121u8, 201u8, 128u8, 26u8, 60u8, 170u8, 24u8, 112u8, 5u8, 248u8, + 7u8, 143u8, 17u8, 150u8, 91u8, 23u8, 90u8, 237u8, 4u8, 138u8, 210u8, + ], + ) + } + #[doc = " Number of eras to check per block."] + #[doc = ""] + #[doc = " If set to 0, this pallet does absolutely nothing."] + #[doc = ""] + #[doc = " Based on the amount of weight available at `on_idle`, up to this many eras of a single"] + #[doc = " nominator might be checked."] + pub fn eras_to_check_per_block( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "FastUnstake", + "ErasToCheckPerBlock", + vec![], + [ + 85u8, 55u8, 18u8, 11u8, 75u8, 176u8, 36u8, 253u8, 183u8, 250u8, 203u8, + 178u8, 201u8, 79u8, 101u8, 89u8, 51u8, 142u8, 254u8, 23u8, 49u8, 140u8, + 195u8, 116u8, 66u8, 124u8, 165u8, 161u8, 151u8, 174u8, 37u8, 51u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " Deposit to take for unstaking, to make sure we're able to slash the it in order to cover"] + #[doc = " the costs of resources on unsuccessful unstake."] + pub fn deposit(&self) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "FastUnstake", + "Deposit", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + } + } + } + pub mod parachains_origin { + use super::root_mod; + use super::runtime_types; + } + pub mod configuration { + use super::root_mod; + use super::runtime_types; + #[doc = "\n\t\t\tCustom [dispatch errors](https://docs.substrate.io/main-docs/build/events-errors/)\n\t\t\tof this pallet.\n\t\t\t"] + pub type Error = runtime_types::polkadot_runtime_parachains::configuration::pallet::Error; + #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetValidationUpgradeCooldown { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetValidationUpgradeDelay { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetCodeRetentionPeriod { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMaxCodeSize { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMaxPovSize { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMaxHeadDataSize { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetParathreadCores { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetParathreadRetries { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetGroupRotationFrequency { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetChainAvailabilityPeriod { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetThreadAvailabilityPeriod { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetSchedulingLookahead { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMaxValidatorsPerCore { + pub new: ::core::option::Option<::core::primitive::u32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMaxValidators { + pub new: ::core::option::Option<::core::primitive::u32>, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetDisputePeriod { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetDisputePostConclusionAcceptancePeriod { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetNoShowSlots { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetNDelayTranches { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetZerothDelayTrancheWidth { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetNeededApprovals { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetRelayVrfModuloSamples { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMaxUpwardQueueCount { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMaxUpwardQueueSize { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMaxDownwardMessageSize { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetUmpServiceTotalWeight { + pub new: runtime_types::sp_weights::weight_v2::Weight, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMaxUpwardMessageSize { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMaxUpwardMessageNumPerCandidate { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetHrmpOpenRequestTtl { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetHrmpSenderDeposit { + pub new: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetHrmpRecipientDeposit { + pub new: ::core::primitive::u128, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetHrmpChannelMaxCapacity { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetHrmpChannelMaxTotalSize { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetHrmpMaxParachainInboundChannels { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetHrmpMaxParathreadInboundChannels { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetHrmpChannelMaxMessageSize { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetHrmpMaxParachainOutboundChannels { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetHrmpMaxParathreadOutboundChannels { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetHrmpMaxMessageNumPerCandidate { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetUmpMaxIndividualWeight { + pub new: runtime_types::sp_weights::weight_v2::Weight, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetPvfCheckingEnabled { + pub new: ::core::primitive::bool, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetPvfVotingTtl { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetMinimumValidationUpgradeDelay { + pub new: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetBypassConsistencyCheck { + pub new: ::core::primitive::bool, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetAsyncBackingParams { + pub new: runtime_types::polkadot_primitives::vstaging::AsyncBackingParams, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetExecutorParams { + pub new: + runtime_types::polkadot_primitives::v4::executor_params::ExecutorParams, + } } pub struct TransactionApi; impl TransactionApi { @@ -27842,11 +30283,11 @@ pub mod api { pub fn set_async_backing_params( &self, new: runtime_types::polkadot_primitives::vstaging::AsyncBackingParams, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_async_backing_params", - SetAsyncBackingParams { new }, + types::SetAsyncBackingParams { new }, [ 124u8, 182u8, 66u8, 138u8, 209u8, 54u8, 42u8, 232u8, 110u8, 67u8, 248u8, 16u8, 61u8, 38u8, 120u8, 242u8, 34u8, 240u8, 219u8, 169u8, @@ -27859,11 +30300,11 @@ pub mod api { pub fn set_executor_params( &self, new: runtime_types::polkadot_primitives::v4::executor_params::ExecutorParams, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Configuration", "set_executor_params", - SetExecutorParams { new }, + types::SetExecutorParams { new }, [ 193u8, 235u8, 143u8, 62u8, 34u8, 192u8, 162u8, 49u8, 224u8, 10u8, 189u8, 132u8, 70u8, 114u8, 50u8, 155u8, 39u8, 238u8, 238u8, 161u8, @@ -28236,21 +30677,24 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Enter { - pub data: runtime_types::polkadot_primitives::v4::InherentData< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - runtime_types::sp_runtime::traits::BlakeTwo256, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Enter { + pub data: runtime_types::polkadot_primitives::v4::InherentData< + runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + runtime_types::sp_runtime::traits::BlakeTwo256, + >, >, } } @@ -28522,116 +30966,120 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSetCurrentCode { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSetCurrentHead { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub new_head: runtime_types::polkadot_parachain::primitives::HeadData, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceScheduleCodeUpgrade { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - pub relay_parent_number: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceNoteNewHead { - pub para: runtime_types::polkadot_parachain::primitives::Id, - pub new_head: runtime_types::polkadot_parachain::primitives::HeadData, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceQueueAction { - pub para: runtime_types::polkadot_parachain::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddTrustedValidationCode { - pub validation_code: runtime_types::polkadot_parachain::primitives::ValidationCode, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PokeUnusedValidationCode { - pub validation_code_hash: - runtime_types::polkadot_parachain::primitives::ValidationCodeHash, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct IncludePvfCheckStatement { - pub stmt: runtime_types::polkadot_primitives::v4::PvfCheckStatement, - pub signature: runtime_types::polkadot_primitives::v4::validator_app::Signature, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceSetCurrentCode { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceSetCurrentHead { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub new_head: runtime_types::polkadot_parachain::primitives::HeadData, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceScheduleCodeUpgrade { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub new_code: runtime_types::polkadot_parachain::primitives::ValidationCode, + pub relay_parent_number: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceNoteNewHead { + pub para: runtime_types::polkadot_parachain::primitives::Id, + pub new_head: runtime_types::polkadot_parachain::primitives::HeadData, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceQueueAction { + pub para: runtime_types::polkadot_parachain::primitives::Id, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddTrustedValidationCode { + pub validation_code: + runtime_types::polkadot_parachain::primitives::ValidationCode, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PokeUnusedValidationCode { + pub validation_code_hash: + runtime_types::polkadot_parachain::primitives::ValidationCodeHash, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct IncludePvfCheckStatement { + pub stmt: runtime_types::polkadot_primitives::v4::PvfCheckStatement, + pub signature: runtime_types::polkadot_primitives::v4::validator_app::Signature, + } } pub struct TransactionApi; impl TransactionApi { @@ -28784,7 +31232,7 @@ pub mod api { &self, stmt: runtime_types::polkadot_primitives::v4::PvfCheckStatement, signature: runtime_types::polkadot_primitives::v4::validator_app::Signature, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "Paras", "include_pvf_check_statement", @@ -32159,21 +34607,19 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportDisputeLostUnsigned { - pub dispute_proof: ::std::boxed::Box< - runtime_types::polkadot_runtime_parachains::disputes::slashing::DisputeProof, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReportDisputeLostUnsigned { pub dispute_proof : :: std :: boxed :: Box < runtime_types :: polkadot_runtime_parachains :: disputes :: slashing :: DisputeProof > , pub key_owner_proof : runtime_types :: sp_session :: MembershipProof , } } pub struct TransactionApi; impl TransactionApi { @@ -32181,11 +34627,11 @@ pub mod api { &self, dispute_proof : runtime_types :: polkadot_runtime_parachains :: disputes :: slashing :: DisputeProof, key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "ParasSlashing", "report_dispute_lost_unsigned", - ReportDisputeLostUnsigned { + types::ReportDisputeLostUnsigned { dispute_proof: ::std::boxed::Box::new(dispute_proof), key_owner_proof, }, @@ -34482,166 +36928,169 @@ pub mod api { use super::root_mod; use super::runtime_types; type DispatchError = runtime_types::sp_runtime::DispatchError; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Send { - pub dest: ::std::boxed::Box, - pub message: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TeleportAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReserveTransferAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Execute { - pub message: ::std::boxed::Box, - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceXcmVersion { - pub location: - ::std::boxed::Box, - pub xcm_version: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceDefaultXcmVersion { - pub maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSubscribeVersionNotify { - pub location: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceUnsubscribeVersionNotify { - pub location: ::std::boxed::Box, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct LimitedReserveTransferAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - pub weight_limit: runtime_types::xcm::v3::WeightLimit, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct LimitedTeleportAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - pub weight_limit: runtime_types::xcm::v3::WeightLimit, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSuspension { - pub suspended: ::core::primitive::bool, + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Send { + pub dest: ::std::boxed::Box, + pub message: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TeleportAssets { + pub dest: ::std::boxed::Box, + pub beneficiary: ::std::boxed::Box, + pub assets: ::std::boxed::Box, + pub fee_asset_item: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReserveTransferAssets { + pub dest: ::std::boxed::Box, + pub beneficiary: ::std::boxed::Box, + pub assets: ::std::boxed::Box, + pub fee_asset_item: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Execute { + pub message: ::std::boxed::Box, + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceXcmVersion { + pub location: + ::std::boxed::Box, + pub xcm_version: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceDefaultXcmVersion { + pub maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceSubscribeVersionNotify { + pub location: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceUnsubscribeVersionNotify { + pub location: ::std::boxed::Box, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct LimitedReserveTransferAssets { + pub dest: ::std::boxed::Box, + pub beneficiary: ::std::boxed::Box, + pub assets: ::std::boxed::Box, + pub fee_asset_item: ::core::primitive::u32, + pub weight_limit: runtime_types::xcm::v3::WeightLimit, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct LimitedTeleportAssets { + pub dest: ::std::boxed::Box, + pub beneficiary: ::std::boxed::Box, + pub assets: ::std::boxed::Box, + pub fee_asset_item: ::core::primitive::u32, + pub weight_limit: runtime_types::xcm::v3::WeightLimit, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceSuspension { + pub suspended: ::core::primitive::bool, + } } pub struct TransactionApi; impl TransactionApi { @@ -34756,7 +37205,7 @@ pub mod api { &self, message: runtime_types::xcm::VersionedXcm, max_weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "XcmPallet", "execute", @@ -34885,7 +37334,7 @@ pub mod api { assets: runtime_types::xcm::VersionedMultiAssets, fee_asset_item: ::core::primitive::u32, weight_limit: runtime_types::xcm::v3::WeightLimit, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "XcmPallet", "limited_reserve_transfer_assets", @@ -34927,7 +37376,7 @@ pub mod api { assets: runtime_types::xcm::VersionedMultiAssets, fee_asset_item: ::core::primitive::u32, weight_limit: runtime_types::xcm::v3::WeightLimit, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "XcmPallet", "limited_teleport_assets", @@ -34953,11 +37402,11 @@ pub mod api { pub fn force_suspension( &self, suspended: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { + ) -> ::subxt::tx::Payload { ::subxt::tx::Payload::new_static( "XcmPallet", "force_suspension", - ForceSuspension { suspended }, + types::ForceSuspension { suspended }, [ 147u8, 1u8, 117u8, 148u8, 8u8, 14u8, 53u8, 167u8, 85u8, 184u8, 25u8, 183u8, 52u8, 197u8, 12u8, 135u8, 45u8, 88u8, 13u8, 27u8, 218u8, 31u8, @@ -44670,6 +47119,55 @@ pub mod api { }, } } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct FeeDetails<_0> { + pub inclusion_fee: ::core::option::Option< + runtime_types::pallet_transaction_payment::types::InclusionFee<_0>, + >, + pub tip: _0, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct InclusionFee<_0> { + pub base_fee: _0, + pub len_fee: _0, + pub adjusted_weight_fee: _0, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RuntimeDispatchInfo<_0, _1> { + pub weight: _1, + pub class: runtime_types::frame_support::dispatch::DispatchClass, + pub partial_fee: _0, + } + } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -46289,6 +48787,38 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum CandidateEvent<_0> { + #[codec(index = 0)] + CandidateBacked( + runtime_types::polkadot_primitives::v4::CandidateReceipt<_0>, + runtime_types::polkadot_parachain::primitives::HeadData, + runtime_types::polkadot_primitives::v4::CoreIndex, + runtime_types::polkadot_primitives::v4::GroupIndex, + ), + #[codec(index = 1)] + CandidateIncluded( + runtime_types::polkadot_primitives::v4::CandidateReceipt<_0>, + runtime_types::polkadot_parachain::primitives::HeadData, + runtime_types::polkadot_primitives::v4::CoreIndex, + runtime_types::polkadot_primitives::v4::GroupIndex, + ), + #[codec(index = 2)] + CandidateTimedOut( + runtime_types::polkadot_primitives::v4::CandidateReceipt<_0>, + runtime_types::polkadot_parachain::primitives::HeadData, + runtime_types::polkadot_primitives::v4::CoreIndex, + ), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct CandidateReceipt<_0> { pub descriptor: runtime_types::polkadot_primitives::v4::CandidateDescriptor<_0>, pub commitments_hash: _0, @@ -46347,6 +48877,24 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum CoreState<_0, _1> { + #[codec(index = 0)] + Occupied(runtime_types::polkadot_primitives::v4::OccupiedCore<_0, _1>), + #[codec(index = 1)] + Scheduled(runtime_types::polkadot_primitives::v4::ScheduledCore), + #[codec(index = 2)] + Free, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct DisputeState<_0> { pub validators_for: ::subxt::utils::bits::DecodedBits< ::core::primitive::u8, @@ -46416,6 +48964,21 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct GroupRotationInfo<_0> { + pub session_start_block: _0, + pub group_rotation_frequency: _0, + pub now: _0, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct IndexedVec<_0, _1>( pub ::std::vec::Vec<_1>, #[codec(skip)] pub ::core::marker::PhantomData<_0>, @@ -46471,6 +49034,52 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OccupiedCore<_0, _1> { + pub next_up_on_available: ::core::option::Option< + runtime_types::polkadot_primitives::v4::ScheduledCore, + >, + pub occupied_since: _1, + pub time_out_at: _1, + pub next_up_on_time_out: ::core::option::Option< + runtime_types::polkadot_primitives::v4::ScheduledCore, + >, + pub availability: ::subxt::utils::bits::DecodedBits< + ::core::primitive::u8, + ::subxt::utils::bits::Lsb0, + >, + pub group_responsible: runtime_types::polkadot_primitives::v4::GroupIndex, + pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, + pub candidate_descriptor: + runtime_types::polkadot_primitives::v4::CandidateDescriptor<_0>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum OccupiedCoreAssumption { + #[codec(index = 0)] + Included, + #[codec(index = 1)] + TimedOut, + #[codec(index = 2)] + Free, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ParathreadClaim( pub runtime_types::polkadot_parachain::primitives::Id, pub runtime_types::polkadot_primitives::v4::collator_app::Public, @@ -46499,6 +49108,22 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PersistedValidationData<_0, _1> { + pub parent_head: runtime_types::polkadot_parachain::primitives::HeadData, + pub relay_parent_number: _1, + pub relay_parent_storage_root: _0, + pub max_pov_size: _1, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct PvfCheckStatement { pub accept: ::core::primitive::bool, pub subject: runtime_types::polkadot_parachain::primitives::ValidationCodeHash, @@ -46547,6 +49172,22 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ScheduledCore { + pub para_id: runtime_types::polkadot_parachain::primitives::Id, + pub collator: ::core::option::Option< + runtime_types::polkadot_primitives::v4::collator_app::Public, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ScrapedOnChainVotes<_0> { pub session: ::core::primitive::u32, pub backing_validators_per_candidate: ::std::vec::Vec<( @@ -49928,10 +52569,182 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BabeConfiguration { + pub slot_duration: ::core::primitive::u64, + pub epoch_length: ::core::primitive::u64, + pub c: (::core::primitive::u64, ::core::primitive::u64), + pub authorities: ::std::vec::Vec<( + runtime_types::sp_consensus_babe::app::Public, + ::core::primitive::u64, + )>, + pub randomness: [::core::primitive::u8; 32usize], + pub allowed_slots: runtime_types::sp_consensus_babe::AllowedSlots, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BabeEpochConfiguration { pub c: (::core::primitive::u64, ::core::primitive::u64), pub allowed_slots: runtime_types::sp_consensus_babe::AllowedSlots, } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Epoch { + pub epoch_index: ::core::primitive::u64, + pub start_slot: runtime_types::sp_consensus_slots::Slot, + pub duration: ::core::primitive::u64, + pub authorities: ::std::vec::Vec<( + runtime_types::sp_consensus_babe::app::Public, + ::core::primitive::u64, + )>, + pub randomness: [::core::primitive::u8; 32usize], + pub config: runtime_types::sp_consensus_babe::BabeEpochConfiguration, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OpaqueKeyOwnershipProof(pub ::std::vec::Vec<::core::primitive::u8>); + } + pub mod sp_consensus_beefy { + use super::runtime_types; + pub mod commitment { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Commitment<_0> { + pub payload: runtime_types::sp_consensus_beefy::payload::Payload, + pub block_number: _0, + pub validator_set_id: ::core::primitive::u64, + } + } + pub mod crypto { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Public(pub runtime_types::sp_core::ecdsa::Public); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Signature(pub runtime_types::sp_core::ecdsa::Signature); + } + pub mod payload { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Payload( + pub ::std::vec::Vec<( + [::core::primitive::u8; 2usize], + ::std::vec::Vec<::core::primitive::u8>, + )>, + ); + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct EquivocationProof<_0, _1, _2> { + pub first: runtime_types::sp_consensus_beefy::VoteMessage<_0, _1, _2>, + pub second: runtime_types::sp_consensus_beefy::VoteMessage<_0, _1, _2>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OpaqueKeyOwnershipProof(pub ::std::vec::Vec<::core::primitive::u8>); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ValidatorSet<_0> { + pub validators: ::std::vec::Vec<_0>, + pub id: ::core::primitive::u64, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct VoteMessage<_0, _1, _2> { + pub commitment: runtime_types::sp_consensus_beefy::commitment::Commitment<_0>, + pub id: _1, + pub signature: _2, + } } pub mod sp_consensus_grandpa { use super::runtime_types; @@ -50002,6 +52815,17 @@ pub mod api { pub set_id: ::core::primitive::u64, pub equivocation: runtime_types::sp_consensus_grandpa::Equivocation<_0, _1>, } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OpaqueKeyOwnershipProof(pub ::std::vec::Vec<::core::primitive::u8>); } pub mod sp_consensus_slots { use super::runtime_types; @@ -50181,6 +53005,17 @@ pub mod api { # [codec (crate = :: subxt :: ext :: codec)] #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OpaqueMetadata(pub ::std::vec::Vec<::core::primitive::u8>); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct OpaquePeerId(pub ::std::vec::Vec<::core::primitive::u8>); #[derive( :: subxt :: ext :: codec :: Decode, @@ -50194,6 +53029,101 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub enum Void {} } + pub mod sp_inherents { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckInherentsResult { + pub okay: ::core::primitive::bool, + pub fatal_error: ::core::primitive::bool, + pub errors: runtime_types::sp_inherents::InherentData, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct InherentData { + pub data: ::subxt::utils::KeyedVec< + [::core::primitive::u8; 8usize], + ::std::vec::Vec<::core::primitive::u8>, + >, + } + } + pub mod sp_mmr_primitives { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct EncodableOpaqueLeaf(pub ::std::vec::Vec<::core::primitive::u8>); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Error { + #[codec(index = 0)] + InvalidNumericOp, + #[codec(index = 1)] + Push, + #[codec(index = 2)] + GetRoot, + #[codec(index = 3)] + Commit, + #[codec(index = 4)] + GenerateProof, + #[codec(index = 5)] + Verify, + #[codec(index = 6)] + LeafNotFound, + #[codec(index = 7)] + PalletNotIncluded, + #[codec(index = 8)] + InvalidLeafIndex, + #[codec(index = 9)] + InvalidBestKnownBlock, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Proof<_0> { + pub leaf_indices: ::std::vec::Vec<::core::primitive::u64>, + pub leaf_count: ::core::primitive::u64, + pub items: ::std::vec::Vec<_0>, + } + } pub mod sp_npos_elections { use super::runtime_types; #[derive( @@ -50230,6 +53160,23 @@ pub mod api { use super::runtime_types; pub mod generic { use super::runtime_types; + pub mod block { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Block<_0, _1> { + pub header: _0, + pub extrinsics: ::std::vec::Vec<_1>, + } + } pub mod digest { use super::runtime_types; #[derive( @@ -50860,6 +53807,112 @@ pub mod api { #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct BlakeTwo256; } + pub mod transaction_validity { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum InvalidTransaction { + #[codec(index = 0)] + Call, + #[codec(index = 1)] + Payment, + #[codec(index = 2)] + Future, + #[codec(index = 3)] + Stale, + #[codec(index = 4)] + BadProof, + #[codec(index = 5)] + AncientBirthBlock, + #[codec(index = 6)] + ExhaustsResources, + #[codec(index = 7)] + Custom(::core::primitive::u8), + #[codec(index = 8)] + BadMandatory, + #[codec(index = 9)] + MandatoryValidation, + #[codec(index = 10)] + BadSigner, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum TransactionSource { + #[codec(index = 0)] + InBlock, + #[codec(index = 1)] + Local, + #[codec(index = 2)] + External, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum TransactionValidityError { + #[codec(index = 0)] + Invalid(runtime_types::sp_runtime::transaction_validity::InvalidTransaction), + #[codec(index = 1)] + Unknown(runtime_types::sp_runtime::transaction_validity::UnknownTransaction), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum UnknownTransaction { + #[codec(index = 0)] + CannotLookup, + #[codec(index = 1)] + NoUnsignedValidator, + #[codec(index = 2)] + Custom(::core::primitive::u8), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ValidTransaction { + pub priority: ::core::primitive::u64, + pub requires: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + pub provides: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + pub longevity: ::core::primitive::u64, + pub propagate: ::core::primitive::bool, + } + } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, From 7bd4bfd990bb4ff38a722ecddb2c6b571c3bab8d Mon Sep 17 00:00:00 2001 From: James Wilson Date: Thu, 4 May 2023 13:14:40 +0100 Subject: [PATCH 16/22] Runtime APIs; don't ask for validation hash anywhere except new_static (#947) * remove validation hash where not wanted * .into() * fix example * cargo fmt --- examples/examples/runtime_calls.rs | 7 ++----- subxt/src/runtime_api/runtime_payload.rs | 16 +++------------- 2 files changed, 5 insertions(+), 18 deletions(-) diff --git a/examples/examples/runtime_calls.rs b/examples/examples/runtime_calls.rs index c4e4311f32..edf8eb356a 100644 --- a/examples/examples/runtime_calls.rs +++ b/examples/examples/runtime_calls.rs @@ -68,11 +68,8 @@ async fn main() -> Result<(), Box> { println!("AccountNonceApi_account_nonce for Alice: {:?}", nonce); // Dynamic calls. - let runtime_api_call = subxt::dynamic::runtime_api_call( - "Metadata_metadata_versions", - Vec::>::new(), - None, - ); + let runtime_api_call = + subxt::dynamic::runtime_api_call("Metadata_metadata_versions", Vec::>::new()); let versions = api .runtime_api() .at_latest() diff --git a/subxt/src/runtime_api/runtime_payload.rs b/subxt/src/runtime_api/runtime_payload.rs index 7636ea6a02..c264742e84 100644 --- a/subxt/src/runtime_api/runtime_payload.rs +++ b/subxt/src/runtime_api/runtime_payload.rs @@ -97,15 +97,11 @@ pub type DynamicRuntimeApiPayload = Payload, DecodedValueThunk>; impl Payload { /// Create a new [`Payload`]. - pub fn new( - fn_name: impl Into, - args_data: ArgsData, - validation_hash: Option<[u8; 32]>, - ) -> Self { + pub fn new(fn_name: impl Into, args_data: ArgsData) -> Self { Payload { fn_name: Cow::Owned(fn_name.into()), args_data, - validation_hash, + validation_hash: None, _marker: PhantomData, } } @@ -151,12 +147,6 @@ impl Payload { pub fn dynamic( fn_name: impl Into, args_data: impl Into>, - hash: Option<[u8; 32]>, ) -> DynamicRuntimeApiPayload { - DynamicRuntimeApiPayload { - fn_name: Cow::Owned(fn_name.into()), - args_data: args_data.into(), - validation_hash: hash, - _marker: std::marker::PhantomData, - } + Payload::new(fn_name, args_data.into()) } From 9e175077c14cb33ca6debf0ef6de81d0a31a4db3 Mon Sep 17 00:00:00 2001 From: James Wilson Date: Thu, 4 May 2023 15:03:42 +0100 Subject: [PATCH 17/22] Subxt Guide (#890) * WIP Starting to write book; extrinsics first pass done * cargo fmt * Ongoing work; events, constants, wip blocks * at_latest() and wip blocks * remove need to import parity-scale-codec crate with Subxt for macro to work * More docs; expanding on setup guide and finish pass of main sections * Tidy and remove example section for now * format book lines to 100chars * Fix example code * cargo fmt * cargo fmt * fix example * Fix typos * fix broken doc links, pub mods * Update Subxt macro docs * can't link to Subxt here * move macro docs to Subxt to make linking better and fix example code * note on macro about docs * cargo fmt * document the no_default_derives macro feature * Address feedback and remove redundant text * address review comments; minor tweaks * WIP add Runtime calls to book * Improve Runtime API docs * expose thing we forgot to expose and doc link fixes --- Cargo.lock | 78 +++-- Cargo.toml | 2 +- codegen/src/api/mod.rs | 9 +- examples/Cargo.toml | 4 - examples/README.md | 4 +- examples/examples/balance_transfer.rs | 40 --- examples/examples/balance_transfer_basic.rs | 34 ++ .../balance_transfer_status_stream.rs | 58 ++++ .../examples/balance_transfer_with_params.rs | 46 +-- ...scribe_blocks.rs => blocks_subscribing.rs} | 18 +- .../examples/concurrent_storage_requests.rs | 39 --- examples/examples/constants_dynamic.rs | 17 + examples/examples/constants_static.rs | 19 ++ examples/examples/custom_config.rs | 59 ---- examples/examples/custom_metadata_url.rs | 12 - examples/examples/custom_type_derives.rs | 32 -- examples/examples/dynamic_multisig.rs | 74 ----- examples/examples/dynamic_queries.rs | 85 ----- examples/examples/events.rs | 60 ++++ examples/examples/fetch_all_accounts.rs | 32 -- examples/examples/fetch_constants.rs | 35 -- examples/examples/fetch_staking_details.rs | 71 ---- examples/examples/metadata_compatibility.rs | 33 -- examples/examples/multisig.rs | 72 ---- examples/examples/rpc_call.rs | 32 -- .../examples/rpc_call_subscribe_blocks.rs | 36 -- examples/examples/runtime_apis_dynamic.rs | 31 ++ examples/examples/runtime_apis_raw.rs | 22 ++ examples/examples/runtime_apis_static.rs | 27 ++ examples/examples/runtime_calls.rs | 85 ----- examples/examples/runtime_types_only.rs | 62 ---- .../examples/setup_client_custom_config.rs | 30 ++ ...c_client.rs => setup_client_custom_rpc.rs} | 9 - examples/examples/setup_client_offline.rs | 37 +++ examples/examples/storage_fetch.rs | 29 ++ examples/examples/storage_fetch_dynamic.rs | 27 ++ examples/examples/storage_iterating.rs | 112 +------ .../examples/storage_iterating_dynamic.rs | 25 ++ examples/examples/submit_and_watch.rs | 166 ---------- examples/examples/subscribe_block_events.rs | 88 ----- .../examples/subscribe_runtime_updates.rs | 36 -- macro/src/lib.rs | 108 +----- subxt/src/blocks/mod.rs | 2 +- subxt/src/book/mod.rs | 96 ++++++ subxt/src/book/setup/client.rs | 54 +++ subxt/src/book/setup/codegen.rs | 66 ++++ subxt/src/book/setup/mod.rs | 13 + subxt/src/book/usage/blocks.rs | 39 +++ subxt/src/book/usage/constants.rs | 61 ++++ subxt/src/book/usage/events.rs | 50 +++ subxt/src/book/usage/extrinsics.rs | 175 ++++++++++ subxt/src/book/usage/mod.rs | 21 ++ subxt/src/book/usage/runtime_apis.rs | 81 +++++ subxt/src/book/usage/storage.rs | 110 ++++++ subxt/src/config/mod.rs | 3 +- subxt/src/dynamic.rs | 2 +- subxt/src/lib.rs | 312 ++++++++++++------ subxt/src/metadata/mod.rs | 1 + 58 files changed, 1473 insertions(+), 1508 deletions(-) delete mode 100644 examples/examples/balance_transfer.rs create mode 100644 examples/examples/balance_transfer_basic.rs create mode 100644 examples/examples/balance_transfer_status_stream.rs rename examples/examples/{subscribe_blocks.rs => blocks_subscribing.rs} (74%) delete mode 100644 examples/examples/concurrent_storage_requests.rs create mode 100644 examples/examples/constants_dynamic.rs create mode 100644 examples/examples/constants_static.rs delete mode 100644 examples/examples/custom_config.rs delete mode 100644 examples/examples/custom_metadata_url.rs delete mode 100644 examples/examples/custom_type_derives.rs delete mode 100644 examples/examples/dynamic_multisig.rs delete mode 100644 examples/examples/dynamic_queries.rs create mode 100644 examples/examples/events.rs delete mode 100644 examples/examples/fetch_all_accounts.rs delete mode 100644 examples/examples/fetch_constants.rs delete mode 100644 examples/examples/fetch_staking_details.rs delete mode 100644 examples/examples/metadata_compatibility.rs delete mode 100644 examples/examples/multisig.rs delete mode 100644 examples/examples/rpc_call.rs delete mode 100644 examples/examples/rpc_call_subscribe_blocks.rs create mode 100644 examples/examples/runtime_apis_dynamic.rs create mode 100644 examples/examples/runtime_apis_raw.rs create mode 100644 examples/examples/runtime_apis_static.rs delete mode 100644 examples/examples/runtime_calls.rs delete mode 100644 examples/examples/runtime_types_only.rs create mode 100644 examples/examples/setup_client_custom_config.rs rename examples/examples/{custom_rpc_client.rs => setup_client_custom_rpc.rs} (90%) create mode 100644 examples/examples/setup_client_offline.rs create mode 100644 examples/examples/storage_fetch.rs create mode 100644 examples/examples/storage_fetch_dynamic.rs create mode 100644 examples/examples/storage_iterating_dynamic.rs delete mode 100644 examples/examples/submit_and_watch.rs delete mode 100644 examples/examples/subscribe_block_events.rs delete mode 100644 examples/examples/subscribe_runtime_updates.rs create mode 100644 subxt/src/book/mod.rs create mode 100644 subxt/src/book/setup/client.rs create mode 100644 subxt/src/book/setup/codegen.rs create mode 100644 subxt/src/book/setup/mod.rs create mode 100644 subxt/src/book/usage/blocks.rs create mode 100644 subxt/src/book/usage/constants.rs create mode 100644 subxt/src/book/usage/events.rs create mode 100644 subxt/src/book/usage/extrinsics.rs create mode 100644 subxt/src/book/usage/mod.rs create mode 100644 subxt/src/book/usage/runtime_apis.rs create mode 100644 subxt/src/book/usage/storage.rs diff --git a/Cargo.lock b/Cargo.lock index c58c56f890..f1bbec594c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -94,9 +94,9 @@ dependencies = [ [[package]] name = "anstream" -version = "0.3.1" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6342bd4f5a1205d7f41e94a41a901f5647c938cdfa96036338e8533c9d6c2450" +checksum = "0ca84f3628370c59db74ee214b3263d58f9aadd9b4fe7e711fd87dc452b7f163" dependencies = [ "anstyle", "anstyle-parse", @@ -143,9 +143,9 @@ dependencies = [ [[package]] name = "anyhow" -version = "1.0.70" +version = "1.0.71" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7de8ce5e0f9f8d88245311066a578d72b7af3e7088f32783804676302df237e4" +checksum = "9c7d0618f0e0b7e8ff11427422b64564d5fb0be1940354bfe2e0529b18a9d9b8" [[package]] name = "array-bytes" @@ -353,9 +353,9 @@ dependencies = [ [[package]] name = "bounded-collections" -version = "0.1.5" +version = "0.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a071c348a5ef6da1d3a87166b408170b46002382b1dda83992b5c2208cefb370" +checksum = "e3888522b497857eb606bf51695988dba7096941822c1bcf676e3a929a9ae7a0" dependencies = [ "log", "parity-scale-codec", @@ -458,9 +458,9 @@ dependencies = [ [[package]] name = "clap" -version = "3.2.23" +version = "3.2.25" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "71655c45cb9845d3270c9d6df84ebe72b4dad3c2ba3f7023ad47c144e4e473a5" +checksum = "4ea181bf566f71cb9a5d17a59e1871af638180a18fb0035c92ae62b705207123" dependencies = [ "bitflags", "clap_lex 0.2.4", @@ -470,9 +470,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.2.5" +version = "4.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a1f23fa97e1d1641371b51f35535cb26959b8e27ab50d167a8b996b5bada819" +checksum = "34d21f9bf1b425d2968943631ec91202fe5e837264063503708b83013f8fc938" dependencies = [ "clap_builder", "clap_derive", @@ -481,9 +481,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.2.5" +version = "4.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fdc5d93c358224b4d6867ef1356d740de2303e9892edc06c5340daeccd96bab" +checksum = "914c8c79fb560f238ef6429439a30023c862f7a28e688c58f7203f12b29970bd" dependencies = [ "anstream", "anstyle", @@ -640,7 +640,7 @@ dependencies = [ "atty", "cast", "ciborium", - "clap 3.2.23", + "clap 3.2.25", "criterion-plot", "itertools", "lazy_static", @@ -837,12 +837,12 @@ dependencies = [ [[package]] name = "darling" -version = "0.20.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7c99d16b88c92aef47e58dadd53e87b4bd234c29934947a6cec8b466300f99b" +checksum = "0558d22a7b463ed0241e993f76f09f30b126687447751a8638587b864e4b3944" dependencies = [ - "darling_core 0.20.0", - "darling_macro 0.20.0", + "darling_core 0.20.1", + "darling_macro 0.20.1", ] [[package]] @@ -861,9 +861,9 @@ dependencies = [ [[package]] name = "darling_core" -version = "0.20.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ea05d2fcb27b53f7a98faddaf5f2914760330ab7703adfc9df13332b42189f9" +checksum = "ab8bfa2e259f8ee1ce5e97824a3c55ec4404a0d772ca7fa96bf19f0752a046eb" dependencies = [ "fnv", "ident_case", @@ -886,11 +886,11 @@ dependencies = [ [[package]] name = "darling_macro" -version = "0.20.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7bfb82b62b1b8a2a9808fb4caf844ede819a76cfc23b2827d7f94eefb49551eb" +checksum = "29a358ff9f12ec09c3e61fef9b5a9902623a695a46a917b07f269bff1445611a" dependencies = [ - "darling_core 0.20.0", + "darling_core 0.20.1", "quote", "syn 2.0.15", ] @@ -1691,7 +1691,7 @@ checksum = "adcf93614601c8129ddf72e2d5633df827ba6551541c6d8c59520a371475be1f" dependencies = [ "hermit-abi 0.3.1", "io-lifetimes", - "rustix 0.37.14", + "rustix 0.37.19", "windows-sys 0.48.0", ] @@ -1905,9 +1905,9 @@ checksum = "f051f77a7c8e6957c0696eac88f26b0117e54f52d3fc682ab19397a8812846a4" [[package]] name = "linux-raw-sys" -version = "0.3.4" +version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "36eb31c1778188ae1e64398743890d0877fef36d11521ac60406b42016e8c2cf" +checksum = "ece97ea872ece730aed82664c424eb4c8291e1ff2480247ccf7409044bc6479f" [[package]] name = "lock_api" @@ -1958,7 +1958,7 @@ version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ffc89ccdc6e10d6907450f753537ebc5c5d3460d2e4e62ea74bd571db62c0f9e" dependencies = [ - "rustix 0.37.14", + "rustix 0.37.19", ] [[package]] @@ -2630,15 +2630,15 @@ dependencies = [ [[package]] name = "rustix" -version = "0.37.14" +version = "0.37.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9b864d3c18a5785a05953adeed93e2dca37ed30f18e69bba9f30079d51f363f" +checksum = "acf8729d8542766f1b2cf77eb034d52f40d375bb8b615d0b147089946e16613d" dependencies = [ "bitflags", "errno", "io-lifetimes", "libc", - "linux-raw-sys 0.3.4", + "linux-raw-sys 0.3.7", "windows-sys 0.48.0", ] @@ -3457,9 +3457,9 @@ checksum = "6e63cff320ae2c57904679ba7cb63280a3dc4613885beafb148ee7bf9aa9042d" [[package]] name = "ss58-registry" -version = "1.39.0" +version = "1.40.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecf0bd63593ef78eca595a7fc25e9a443ca46fe69fd472f8f09f5245cdcd769d" +checksum = "eb47a8ad42e5fc72d5b1eb104a5546937eaf39843499948bb666d6e93c62423b" dependencies = [ "Inflector", "num-format", @@ -3574,7 +3574,7 @@ dependencies = [ name = "subxt-cli" version = "0.28.0" dependencies = [ - "clap 4.2.5", + "clap 4.2.7", "color-eyre", "frame-metadata", "hex", @@ -3614,20 +3614,16 @@ version = "0.28.0" dependencies = [ "futures", "hex", - "parity-scale-codec", - "sp-core", "sp-keyring", - "sp-runtime", "subxt", "tokio", - "tracing-subscriber 0.3.17", ] [[package]] name = "subxt-macro" version = "0.28.0" dependencies = [ - "darling 0.20.0", + "darling 0.20.1", "proc-macro-error", "subxt-codegen", "syn 2.0.15", @@ -3824,9 +3820,9 @@ dependencies = [ [[package]] name = "tokio-util" -version = "0.7.7" +version = "0.7.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5427d89453009325de0d8f342c9490009f76e999cb7672d77e46267448f7e6b2" +checksum = "806fe8c2c87eccc8b3267cbae29ed3ab2d0bd37fca70ab622e46aaa9375ddb7d" dependencies = [ "bytes", "futures-core", @@ -4638,9 +4634,9 @@ checksum = "1a515f5799fe4961cb532f983ce2b23082366b898e52ffbce459c86f67c8378a" [[package]] name = "winnow" -version = "0.4.1" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae8970b36c66498d8ff1d66685dc86b91b29db0c7739899012f63a63814b4b28" +checksum = "61de7bac303dc551fe038e2b3cef0f571087a47571ea6e79a87692ac99b99699" dependencies = [ "memchr", ] diff --git a/Cargo.toml b/Cargo.toml index cf87f98ec1..71c7eb4d4d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -86,4 +86,4 @@ subxt-macro = { version = "0.28.0", path = "macro" } subxt-metadata = { version = "0.28.0", path = "metadata" } subxt-codegen = { version = "0.28.0", path = "codegen" } test-runtime = { path = "testing/test-runtime" } -substrate-runner = { path = "testing/substrate-runner" } \ No newline at end of file +substrate-runner = { path = "testing/substrate-runner" } diff --git a/codegen/src/api/mod.rs b/codegen/src/api/mod.rs index 8f112b088f..2421e711f1 100644 --- a/codegen/src/api/mod.rs +++ b/codegen/src/api/mod.rs @@ -225,8 +225,13 @@ impl RuntimeGenerator { // Preserve any Rust items that were previously defined in the adorned module #( #rust_items ) * - // Make it easy to access the root via `root_mod` at different levels: - use super::#mod_ident as root_mod; + // Make it easy to access the root items via `root_mod` at different levels + // without reaching out of this module. + #[allow(unused_imports)] + mod root_mod { + pub use super::*; + } + #types_mod } }) diff --git a/examples/Cargo.toml b/examples/Cargo.toml index 2b28de852b..d6972e640c 100644 --- a/examples/Cargo.toml +++ b/examples/Cargo.toml @@ -16,9 +16,5 @@ description = "Subxt example usage" subxt = { workspace = true } tokio = { workspace = true } futures = { workspace = true } -codec = { package = "parity-scale-codec", workspace = true, features = ["derive", "bit-vec"] } hex = { workspace = true } sp-keyring = { workspace = true } -sp-core = { workspace = true } -sp-runtime = { workspace = true } -tracing-subscriber = { workspace = true } diff --git a/examples/README.md b/examples/README.md index 30ae9c8b65..a7c3c186ab 100644 --- a/examples/README.md +++ b/examples/README.md @@ -1,3 +1,5 @@ # Subxt Examples -Take a look in the [examples](./examples) subfolder for various `subxt` usage examples. \ No newline at end of file +Take a look in the [examples](./examples) subfolder for various `subxt` usage examples. + +All examples form part of the `subxt` documentation; there should be no examples without corresponding links from the docs. \ No newline at end of file diff --git a/examples/examples/balance_transfer.rs b/examples/examples/balance_transfer.rs deleted file mode 100644 index 1ef07256d0..0000000000 --- a/examples/examples/balance_transfer.rs +++ /dev/null @@ -1,40 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use sp_keyring::AccountKeyring; -use subxt::{tx::PairSigner, OnlineClient, PolkadotConfig}; - -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] -pub mod polkadot {} - -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - let signer = PairSigner::new(AccountKeyring::Alice.pair()); - let dest = AccountKeyring::Bob.to_account_id().into(); - - // Create a client to use: - let api = OnlineClient::::new().await?; - - // Create a transaction to submit: - let tx = polkadot::tx() - .balances() - .transfer(dest, 123_456_789_012_345); - - // Submit the transaction with default params: - let hash = api.tx().sign_and_submit_default(&tx, &signer).await?; - - println!("Balance transfer extrinsic submitted: {hash}"); - - Ok(()) -} diff --git a/examples/examples/balance_transfer_basic.rs b/examples/examples/balance_transfer_basic.rs new file mode 100644 index 0000000000..787f1f9ef2 --- /dev/null +++ b/examples/examples/balance_transfer_basic.rs @@ -0,0 +1,34 @@ +use sp_keyring::AccountKeyring; +use subxt::{tx::PairSigner, OnlineClient, PolkadotConfig}; + +// Generate an interface that we can use from the node's metadata. +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +pub mod polkadot {} + +#[tokio::main] +async fn main() -> Result<(), Box> { + // Create a new API client, configured to talk to Polkadot nodes. + let api = OnlineClient::::new().await?; + + // Build a balance transfer extrinsic. + let dest = AccountKeyring::Bob.to_account_id().into(); + let balance_transfer_tx = polkadot::tx().balances().transfer(dest, 10_000); + + // Submit the balance transfer extrinsic from Alice, and wait for it to be successful + // and in a finalized block. We get back the extrinsic events if all is well. + let from = PairSigner::new(AccountKeyring::Alice.pair()); + let events = api + .tx() + .sign_and_submit_then_watch_default(&balance_transfer_tx, &from) + .await? + .wait_for_finalized_success() + .await?; + + // Find a Transfer event and print it. + let transfer_event = events.find_first::()?; + if let Some(event) = transfer_event { + println!("Balance transfer success: {event:?}"); + } + + Ok(()) +} diff --git a/examples/examples/balance_transfer_status_stream.rs b/examples/examples/balance_transfer_status_stream.rs new file mode 100644 index 0000000000..a390f9e3d4 --- /dev/null +++ b/examples/examples/balance_transfer_status_stream.rs @@ -0,0 +1,58 @@ +use futures::StreamExt; +use sp_keyring::AccountKeyring; +use subxt::{ + tx::{PairSigner, TxStatus}, + OnlineClient, PolkadotConfig, +}; + +// Generate an interface that we can use from the node's metadata. +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +pub mod polkadot {} + +#[tokio::main] +async fn main() -> Result<(), Box> { + // Create a new API client, configured to talk to Polkadot nodes. + let api = OnlineClient::::new().await?; + + // Build a balance transfer extrinsic. + let dest = AccountKeyring::Bob.to_account_id().into(); + let balance_transfer_tx = polkadot::tx().balances().transfer(dest, 10_000); + + // Submit the balance transfer extrinsic from Alice, and then monitor the + // progress of it. + let signer = PairSigner::new(AccountKeyring::Alice.pair()); + let mut balance_transfer_progress = api + .tx() + .sign_and_submit_then_watch_default(&balance_transfer_tx, &signer) + .await?; + + while let Some(status) = balance_transfer_progress.next().await { + match status? { + // It's finalized in a block! + TxStatus::Finalized(in_block) => { + println!( + "Transaction {:?} is finalized in block {:?}", + in_block.extrinsic_hash(), + in_block.block_hash() + ); + + // grab the events and fail if no ExtrinsicSuccess event seen: + let events = in_block.wait_for_success().await?; + // We can look for events (this uses the static interface; we can also iterate + // over them and dynamically decode them): + let transfer_event = events.find_first::()?; + + if let Some(event) = transfer_event { + println!("Balance transfer success: {event:?}"); + } else { + println!("Failed to find Balances::Transfer Event"); + } + } + // Just log any other status we encounter: + other => { + println!("Status: {other:?}"); + } + } + } + Ok(()) +} diff --git a/examples/examples/balance_transfer_with_params.rs b/examples/examples/balance_transfer_with_params.rs index ce79ef00ab..c64dcc2029 100644 --- a/examples/examples/balance_transfer_with_params.rs +++ b/examples/examples/balance_transfer_with_params.rs @@ -1,52 +1,28 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - use sp_keyring::AccountKeyring; -use subxt::{ - config::{ - polkadot::{Era, PlainTip, PolkadotExtrinsicParamsBuilder as Params}, - PolkadotConfig, - }, - tx::PairSigner, - OnlineClient, -}; +use subxt::config::polkadot::{Era, PlainTip, PolkadotExtrinsicParamsBuilder as Params}; +use subxt::{tx::PairSigner, OnlineClient, PolkadotConfig}; #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - let signer = PairSigner::new(AccountKeyring::Alice.pair()); - let dest = AccountKeyring::Bob.to_account_id().into(); - - // Create a client to use: + // Create a new API client, configured to talk to Polkadot nodes. let api = OnlineClient::::new().await?; - // Create a transaction to submit: - let tx = polkadot::tx() - .balances() - .transfer(dest, 123_456_789_012_345); + // Build a balance transfer extrinsic. + let dest = AccountKeyring::Bob.to_account_id().into(); + let tx = polkadot::tx().balances().transfer(dest, 10_000); - // Configure the transaction tip and era: + // Configure the transaction parameters; for Polkadot the tip and era: let tx_params = Params::new() - .tip(PlainTip::new(20_000_000_000)) + .tip(PlainTip::new(1_000)) .era(Era::Immortal, api.genesis_hash()); // submit the transaction: - let hash = api.tx().sign_and_submit(&tx, &signer, tx_params).await?; - - println!("Balance transfer extrinsic submitted: {hash}"); + let from = PairSigner::new(AccountKeyring::Alice.pair()); + let hash = api.tx().sign_and_submit(&tx, &from, tx_params).await?; + println!("Balance transfer extrinsic submitted with hash : {hash}"); Ok(()) } diff --git a/examples/examples/subscribe_blocks.rs b/examples/examples/blocks_subscribing.rs similarity index 74% rename from examples/examples/subscribe_blocks.rs rename to examples/examples/blocks_subscribing.rs index a842e15487..922e99bc6a 100644 --- a/examples/examples/subscribe_blocks.rs +++ b/examples/examples/blocks_subscribing.rs @@ -1,15 +1,3 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot 0.9.29-41a9d84b152. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.29/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - use futures::StreamExt; use subxt::{OnlineClient, PolkadotConfig}; @@ -18,14 +6,13 @@ pub mod polkadot {} #[tokio::main] async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - // Create a client to use: let api = OnlineClient::::new().await?; // Subscribe to all finalized blocks: let mut blocks_sub = api.blocks().subscribe_finalized().await?; + // For each block, print a bunch of information about it: while let Some(block) = blocks_sub.next().await { let block = block?; @@ -36,6 +23,7 @@ async fn main() -> Result<(), Box> { println!(" Hash: {block_hash}"); println!(" Extrinsics:"); + // Log each of the extrinsic with it's associated events: let body = block.body().await?; for ext in body.extrinsics() { let idx = ext.index(); @@ -51,8 +39,10 @@ async fn main() -> Result<(), Box> { let pallet_name = evt.pallet_name(); let event_name = evt.variant_name(); + let event_values = evt.field_values()?; println!(" {pallet_name}_{event_name}"); + println!(" {}", event_values); } } } diff --git a/examples/examples/concurrent_storage_requests.rs b/examples/examples/concurrent_storage_requests.rs deleted file mode 100644 index acaee188d3..0000000000 --- a/examples/examples/concurrent_storage_requests.rs +++ /dev/null @@ -1,39 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use futures::join; -use sp_keyring::AccountKeyring; -use subxt::{OnlineClient, PolkadotConfig}; - -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] -pub mod polkadot {} - -#[tokio::main] -async fn main() -> Result<(), Box> { - let api = OnlineClient::::new().await?; - - let addr = AccountKeyring::Bob.to_account_id().into(); - - // Construct storage addresses to access: - let staking_bonded = polkadot::storage().staking().bonded(&addr); - let staking_ledger = polkadot::storage().staking().ledger(&addr); - - // For storage requests, we can join futures together to - // await multiple futures concurrently: - let a_fut = api.storage().at_latest().await?.fetch(&staking_bonded); - let b_fut = api.storage().at_latest().await?.fetch(&staking_ledger); - let (a, b) = join!(a_fut, b_fut); - - println!("{a:?}, {b:?}"); - - Ok(()) -} diff --git a/examples/examples/constants_dynamic.rs b/examples/examples/constants_dynamic.rs new file mode 100644 index 0000000000..ba23a8415d --- /dev/null +++ b/examples/examples/constants_dynamic.rs @@ -0,0 +1,17 @@ +use subxt::{OnlineClient, PolkadotConfig}; + +#[tokio::main] +async fn main() -> Result<(), Box> { + // Create a client to use: + let api = OnlineClient::::new().await?; + + // A dynamic query to obtain some contant: + let constant_query = subxt::dynamic::constant("System", "BlockLength"); + + // Obtain the value: + let value = api.constants().at(&constant_query)?; + + println!("Constant bytes: {:?}", value.encoded()); + println!("Constant value: {}", value.to_value()?); + Ok(()) +} diff --git a/examples/examples/constants_static.rs b/examples/examples/constants_static.rs new file mode 100644 index 0000000000..1dd9409c0e --- /dev/null +++ b/examples/examples/constants_static.rs @@ -0,0 +1,19 @@ +use subxt::{OnlineClient, PolkadotConfig}; + +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +pub mod polkadot {} + +#[tokio::main] +async fn main() -> Result<(), Box> { + // Create a client to use: + let api = OnlineClient::::new().await?; + + // A query to obtain some contant: + let constant_query = polkadot::constants().system().block_length(); + + // Obtain the value: + let value = api.constants().at(&constant_query)?; + + println!("Block length: {value:?}"); + Ok(()) +} diff --git a/examples/examples/custom_config.rs b/examples/examples/custom_config.rs deleted file mode 100644 index e12977c223..0000000000 --- a/examples/examples/custom_config.rs +++ /dev/null @@ -1,59 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! This example should compile but should fail to work, since we've modified the -//! config to not align with a Polkadot node. - -use sp_keyring::AccountKeyring; -use subxt::{ - config::{substrate::SubstrateExtrinsicParams, Config, SubstrateConfig}, - tx::PairSigner, - OnlineClient, -}; - -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] -pub mod polkadot {} - -/// Custom [`Config`] impl where the default types for the target chain differ from the -/// [`DefaultConfig`] -#[derive(Clone, Debug, Default, Eq, PartialEq)] -pub struct MyConfig; -impl Config for MyConfig { - // This is different from the default `u32`. - // - // *Note* that in this example it does differ from the actual `Index` type in the - // polkadot runtime used, so some operations will fail. Normally when using a custom `Config` - // impl types MUST match exactly those used in the actual runtime. - type Index = u64; - type Hash = ::Hash; - type Hasher = ::Hasher; - type Header = ::Header; - type AccountId = ::AccountId; - type Address = ::Address; - type Signature = ::Signature; - // ExtrinsicParams makes use of the index type, so we need to adjust it - // too to align with our modified index type, above: - type ExtrinsicParams = SubstrateExtrinsicParams; -} - -#[tokio::main] -async fn main() -> Result<(), Box> { - let signer = PairSigner::new(AccountKeyring::Alice.pair()); - let dest = AccountKeyring::Bob.to_account_id().into(); - - // Create a client to use: - let api = OnlineClient::::new().await?; - - // Create a transaction to submit: - let tx = polkadot::tx() - .balances() - .transfer(dest, 123_456_789_012_345); - - // submit the transaction with default params: - let hash = api.tx().sign_and_submit_default(&tx, &signer).await?; - - println!("Balance transfer extrinsic submitted: {hash}"); - - Ok(()) -} diff --git a/examples/examples/custom_metadata_url.rs b/examples/examples/custom_metadata_url.rs deleted file mode 100644 index 7fb1893075..0000000000 --- a/examples/examples/custom_metadata_url.rs +++ /dev/null @@ -1,12 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -// If you'd like to use metadata directly from a running node, you -// can provide a URL to that node here. HTTP or WebSocket URLs can be -// provided. Note that if the metadata cannot be retrieved from this -// node URL at compile time, compilation will fail. -#[subxt::subxt(runtime_metadata_url = "wss://rpc.polkadot.io:443")] -pub mod polkadot {} - -fn main() {} diff --git a/examples/examples/custom_type_derives.rs b/examples/examples/custom_type_derives.rs deleted file mode 100644 index b8cf6433c7..0000000000 --- a/examples/examples/custom_type_derives.rs +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! Example verified against polkadot polkadot 0.9.25-5174e9ae75b. -#![allow(clippy::redundant_clone)] - -#[subxt::subxt( - runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale", - // We can add (certain) custom derives to the generated types by providing - // a comma separated list to the below attribute. Most useful for adding `Clone`. - // The derives that we can add ultimately is limited to the traits that the base - // types relied upon by the codegen implement. - derive_for_all_types = "Clone, PartialEq, Eq", - - // To apply derives to specific generated types, add a `derive_for_type` per type, - // mapping the type path to the derives which should be added for that type only. - // Note that these derives will be in addition to those specified above in - // `derive_for_all_types` - derive_for_type(path = "frame_support::PalletId", derive = "Eq, Ord, PartialOrd"), - derive_for_type(path = "sp_runtime::ModuleError", derive = "Eq, Hash"), -)] -pub mod polkadot {} - -use polkadot::runtime_types::frame_support::PalletId; - -#[tokio::main] -async fn main() -> Result<(), Box> { - let pallet_id = PalletId([1u8; 8]); - let _ = pallet_id.clone(); - Ok(()) -} diff --git a/examples/examples/dynamic_multisig.rs b/examples/examples/dynamic_multisig.rs deleted file mode 100644 index 68d43347a3..0000000000 --- a/examples/examples/dynamic_multisig.rs +++ /dev/null @@ -1,74 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.31-3711c6f9b2a. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.31/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use sp_keyring::AccountKeyring; -use subxt::{dynamic::Value, tx::PairSigner, OnlineClient, PolkadotConfig}; - -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - // My account. - let signer_account = AccountKeyring::Alice; - let signer_account_id = signer_account.to_account_id(); - let signer = PairSigner::new(signer_account.pair()); - - // Transfer balance to this destination: - let dest = AccountKeyring::Bob.to_account_id(); - - // Create a client to use: - let api = OnlineClient::::new().await?; - - // Create the inner balance transfer call. - let inner_tx = subxt::dynamic::tx( - "Balances", - "transfer", - vec![ - Value::unnamed_variant("Id", [Value::from_bytes(&dest)]), - Value::u128(123_456_789_012_345), - ], - ); - - // Now, build an outer call which this inner call will be a part of. - // This sets up the multisig arrangement. - // - // Note: Since this is a dynamic call, we can either use named or unnamed - // arguments (if unnamed, the order matters). - let tx = subxt::dynamic::tx( - "Multisig", - "as_multi", - vec![ - ("threshold", Value::u128(1)), - ( - "other_signatories", - Value::unnamed_composite([Value::from_bytes(&signer_account_id)]), - ), - ("maybe_timepoint", Value::unnamed_variant("None", [])), - ("call", inner_tx.into_value()), - ( - "max_weight", - Value::named_composite([ - ("ref_time", Value::u128(10000000000)), - ("proof_size", Value::u128(1)), - ]), - ), - ], - ); - - // Submit it: - let encoded = hex::encode(api.tx().call_data(&tx)?); - println!("Call data: {encoded}"); - let tx_hash = api.tx().sign_and_submit_default(&tx, &signer).await?; - println!("Submitted tx with hash {tx_hash}"); - - Ok(()) -} diff --git a/examples/examples/dynamic_queries.rs b/examples/examples/dynamic_queries.rs deleted file mode 100644 index c7c69fe66e..0000000000 --- a/examples/examples/dynamic_queries.rs +++ /dev/null @@ -1,85 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -// This example showcases working with dynamic values rather than those that are generated via the subxt proc macro. - -use sp_keyring::AccountKeyring; -use subxt::{dynamic::Value, tx::PairSigner, OnlineClient, PolkadotConfig}; - -#[tokio::main] -async fn main() -> Result<(), Box> { - let api = OnlineClient::::new().await?; - - // 1. Dynamic Balance Transfer (the dynamic equivalent to the balance_transfer example). - - let signer = PairSigner::new(AccountKeyring::Alice.pair()); - let dest = AccountKeyring::Bob.to_account_id(); - - // Create a transaction to submit: - let tx = subxt::dynamic::tx( - "Balances", - "transfer", - vec![ - // A value representing a MultiAddress. We want the "Id" variant, and that - // will ultimately contain the bytes for our destination address (there is a new type wrapping - // the address, but our encoding will happily ignore such things and do it's best to line up what - // we provide with what it needs). - Value::unnamed_variant("Id", [Value::from_bytes(&dest)]), - // A value representing the amount we'd like to transfer. - Value::u128(123_456_789_012_345), - ], - ); - - // submit the transaction with default params: - let hash = api.tx().sign_and_submit_default(&tx, &signer).await?; - println!("Balance transfer extrinsic submitted: {hash}"); - - // 2. Dynamic constant access (the dynamic equivalent to the fetch_constants example). - - let constant_address = subxt::dynamic::constant("Balances", "ExistentialDeposit"); - let existential_deposit = api.constants().at(&constant_address)?.to_value()?; - println!("Existential Deposit: {existential_deposit}"); - - // 3. Dynamic storage access - - let storage_address = subxt::dynamic::storage( - "System", - "Account", - vec![ - // Something that encodes to an AccountId32 is what we need for the map key here: - Value::from_bytes(&dest), - ], - ); - let account = api - .storage() - .at_latest() - .await? - .fetch_or_default(&storage_address) - .await? - .to_value()?; - println!("Bob's account details: {account}"); - - // 4. Dynamic storage iteration (the dynamic equivalent to the fetch_all_accounts example). - - let storage_address = subxt::dynamic::storage_root("System", "Account"); - let mut iter = api - .storage() - .at_latest() - .await? - .iter(storage_address, 10) - .await?; - while let Some((key, account)) = iter.next().await? { - println!("{}: {}", hex::encode(key), account.to_value()?); - } - - Ok(()) -} diff --git a/examples/examples/events.rs b/examples/examples/events.rs new file mode 100644 index 0000000000..4c35398349 --- /dev/null +++ b/examples/examples/events.rs @@ -0,0 +1,60 @@ +use subxt::{OnlineClient, PolkadotConfig}; + +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +pub mod polkadot {} + +#[tokio::main] +async fn main() -> Result<(), Box> { + // Create a client to use: + let api = OnlineClient::::new().await?; + + // Get events for the latest block: + let events = api.events().at_latest().await?; + + // We can dynamically decode events: + println!("Dynamic event details:"); + for event in events.iter() { + let event = event?; + + let pallet = event.pallet_name(); + let variant = event.variant_name(); + let field_values = event.field_values()?; + + println!("{pallet}::{variant}: {field_values}"); + } + + // Or we can attempt to statically decode them into the root Event type: + println!("Static event details:"); + for event in events.iter() { + let event = event?; + + if let Ok(ev) = event.as_root_event::() { + println!("{ev:?}"); + } else { + println!(""); + } + } + + // Or we can attempt to decode them into a specific arbitraty pallet enum + // (We could also set the output type to Value to dynamically decode, here): + println!("Event details for Balances pallet:"); + for event in events.iter() { + let event = event?; + + if let Ok(ev) = event.as_pallet_event::() { + println!("{ev:?}"); + } else { + continue; + } + } + + // Or we can look for specific events which match our statically defined ones: + let transfer_event = events.find_first::()?; + if let Some(ev) = transfer_event { + println!(" - Balance transfer success: value: {:?}", ev.amount); + } else { + println!(" - No balance transfer event found in this block"); + } + + Ok(()) +} diff --git a/examples/examples/fetch_all_accounts.rs b/examples/examples/fetch_all_accounts.rs deleted file mode 100644 index 7d51a1205e..0000000000 --- a/examples/examples/fetch_all_accounts.rs +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use subxt::{OnlineClient, PolkadotConfig}; - -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] -pub mod polkadot {} - -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - let api = OnlineClient::::new().await?; - - let address = polkadot::storage().system().account_root(); - - let mut iter = api.storage().at_latest().await?.iter(address, 10).await?; - - while let Some((key, account)) = iter.next().await? { - println!("{}: {}", hex::encode(key), account.data.free); - } - Ok(()) -} diff --git a/examples/examples/fetch_constants.rs b/examples/examples/fetch_constants.rs deleted file mode 100644 index 379fefeb8e..0000000000 --- a/examples/examples/fetch_constants.rs +++ /dev/null @@ -1,35 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use subxt::{OnlineClient, PolkadotConfig}; - -// Generate the API from a static metadata path. -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] -pub mod polkadot {} - -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - // Create a client to use: - let api = OnlineClient::::new().await?; - - // Build a constant address to query: - let address = polkadot::constants().balances().existential_deposit(); - - // Look it up: - let existential_deposit = api.constants().at(&address)?; - - println!("Existential Deposit: {existential_deposit}"); - - Ok(()) -} diff --git a/examples/examples/fetch_staking_details.rs b/examples/examples/fetch_staking_details.rs deleted file mode 100644 index f1a59d8e93..0000000000 --- a/examples/examples/fetch_staking_details.rs +++ /dev/null @@ -1,71 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use sp_core::{sr25519, Pair}; -use sp_keyring::AccountKeyring; -use subxt::{utils::AccountId32, OnlineClient, PolkadotConfig}; - -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] -pub mod polkadot {} - -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - // Create a client to use: - let api = OnlineClient::::new().await?; - - let active_era_addr = polkadot::storage().staking().active_era(); - let era = api - .storage() - .at_latest() - .await? - .fetch(&active_era_addr) - .await? - .unwrap(); - println!( - "Staking active era: index: {:?}, start: {:?}", - era.index, era.start - ); - - let alice_id = AccountKeyring::Alice.to_account_id(); - println!(" Alice account id: {alice_id:?}"); - - // Get Alice' Stash account ID - let alice_stash_id: AccountId32 = sr25519::Pair::from_string("//Alice//stash", None) - .expect("Could not obtain stash signer pair") - .public() - .into(); - println!(" Alice//stash account id: {alice_stash_id:?}"); - - // Map from all locked "stash" accounts to the controller account. - let controller_acc_addr = polkadot::storage().staking().bonded(&alice_stash_id); - let controller_acc = api - .storage() - .at_latest() - .await? - .fetch(&controller_acc_addr) - .await? - .unwrap(); - println!(" account controlled by: {controller_acc:?}"); - - let era_reward_addr = polkadot::storage().staking().eras_reward_points(era.index); - let era_result = api - .storage() - .at_latest() - .await? - .fetch(&era_reward_addr) - .await?; - println!("Era reward points: {era_result:?}"); - - Ok(()) -} diff --git a/examples/examples/metadata_compatibility.rs b/examples/examples/metadata_compatibility.rs deleted file mode 100644 index 352ed4c02a..0000000000 --- a/examples/examples/metadata_compatibility.rs +++ /dev/null @@ -1,33 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use subxt::{OnlineClient, PolkadotConfig}; - -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_tiny.scale")] -pub mod polkadot {} - -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - let api = OnlineClient::::new().await?; - - // Each individual request will be validated against the static code that was - // used to construct it, if possible. We can also validate the entirety of the - // statically generated code against some client at a given point in time using - // this check. If it fails, then there is some breaking change between the metadata - // used to generate this static code, and the runtime metadata from a node that the - // client is using. - polkadot::validate_codegen(&api)?; - - Ok(()) -} diff --git a/examples/examples/multisig.rs b/examples/examples/multisig.rs deleted file mode 100644 index 718ac4759a..0000000000 --- a/examples/examples/multisig.rs +++ /dev/null @@ -1,72 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.31-3711c6f9b2a. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.31/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use sp_keyring::AccountKeyring; -use subxt::{tx::PairSigner, OnlineClient, PolkadotConfig}; - -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] -pub mod polkadot {} - -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - // My account. - let signer_account = AccountKeyring::Alice; - let signer_account_id = signer_account.to_account_id(); - let signer = PairSigner::new(signer_account.pair()); - - // Transfer balance to this destination: - let dest = AccountKeyring::Bob.to_account_id(); - - // Create a client to use: - let api = OnlineClient::::new().await?; - - // Create the inner balance transfer call. - // - // Note: This call, being manually constructed, will have a specific pallet and call index - // which is determined by the generated code. If you're trying to submit this to a node which - // has the pallets/calls at different indexes, it will fail. See `dynamic_multisig.rs` for a - // workaround in this case which will work regardless of pallet and call indexes. - let inner_tx = polkadot::runtime_types::polkadot_runtime::RuntimeCall::Balances( - polkadot::runtime_types::pallet_balances::pallet::Call::transfer { - dest: dest.into(), - value: 123_456_789_012_345, - }, - ); - - // Now, build an outer call which this inner call will be a part of. - // This sets up the multisig arrangement. - let tx = polkadot::tx().multisig().as_multi( - // threshold - 1, - // other signatories - vec![signer_account_id.into()], - // maybe timepoint - None, - // call - inner_tx, - // max weight - polkadot::runtime_types::sp_weights::weight_v2::Weight { - ref_time: 10000000000, - proof_size: 1, - }, - ); - - // Submit the extrinsic with default params: - let encoded = hex::encode(api.tx().call_data(&tx)?); - println!("Call data: {encoded}"); - let tx_hash = api.tx().sign_and_submit_default(&tx, &signer).await?; - println!("Submitted tx with hash {tx_hash}"); - - Ok(()) -} diff --git a/examples/examples/rpc_call.rs b/examples/examples/rpc_call.rs deleted file mode 100644 index cdffa03854..0000000000 --- a/examples/examples/rpc_call.rs +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use subxt::{OnlineClient, PolkadotConfig}; - -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - let api = OnlineClient::::new().await?; - - let block_number = 1u32; - - let block_hash = api.rpc().block_hash(Some(block_number.into())).await?; - - if let Some(hash) = block_hash { - println!("Block hash for block number {block_number}: {hash}"); - } else { - println!("Block number {block_number} not found."); - } - - Ok(()) -} diff --git a/examples/examples/rpc_call_subscribe_blocks.rs b/examples/examples/rpc_call_subscribe_blocks.rs deleted file mode 100644 index bd5ff2dc0b..0000000000 --- a/examples/examples/rpc_call_subscribe_blocks.rs +++ /dev/null @@ -1,36 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use subxt::{config::Header, OnlineClient, PolkadotConfig}; - -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - let api = OnlineClient::::from_url("wss://rpc.polkadot.io:443").await?; - - // For non-finalised blocks use `.subscribe_blocks()` - let mut blocks = api.rpc().subscribe_finalized_block_headers().await?; - - while let Some(Ok(block)) = blocks.next().await { - println!( - "block number: {} hash:{} parent:{} state root:{} extrinsics root:{}", - block.number, - block.hash(), - block.parent_hash, - block.state_root, - block.extrinsics_root - ); - } - - Ok(()) -} diff --git a/examples/examples/runtime_apis_dynamic.rs b/examples/examples/runtime_apis_dynamic.rs new file mode 100644 index 0000000000..c861c53357 --- /dev/null +++ b/examples/examples/runtime_apis_dynamic.rs @@ -0,0 +1,31 @@ +use sp_keyring::AccountKeyring; +use subxt::dynamic::Value; +use subxt::{config::PolkadotConfig, OnlineClient}; + +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +pub mod polkadot {} + +#[tokio::main] +async fn main() -> Result<(), Box> { + // Create a client to use: + let api = OnlineClient::::new().await?; + + // Create a dynamically runtime API payload that calls the + // `AccountNonceApi_account_nonce` function. + let account = AccountKeyring::Alice.to_account_id(); + let runtime_api_call = subxt::dynamic::runtime_api_call( + "AccountNonceApi_account_nonce", + vec![Value::from_bytes(account)], + ); + + // Submit the call to get back a result. + let nonce = api + .runtime_api() + .at_latest() + .await? + .call(runtime_api_call) + .await?; + + println!("Account nonce: {:#?}", nonce.to_value()); + Ok(()) +} diff --git a/examples/examples/runtime_apis_raw.rs b/examples/examples/runtime_apis_raw.rs new file mode 100644 index 0000000000..fc61ff4b3b --- /dev/null +++ b/examples/examples/runtime_apis_raw.rs @@ -0,0 +1,22 @@ +use subxt::ext::codec::Compact; +use subxt::ext::frame_metadata::RuntimeMetadataPrefixed; +use subxt::{OnlineClient, PolkadotConfig}; + +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +pub mod polkadot {} + +#[tokio::main] +async fn main() -> Result<(), Box> { + // Create a client to use: + let api = OnlineClient::::new().await?; + + // Use runtime APIs at the latest block: + let runtime_apis = api.runtime_api().at_latest().await?; + + // Ask for metadata and decode it: + let (_, meta): (Compact, RuntimeMetadataPrefixed) = + runtime_apis.call_raw("Metadata_metadata", None).await?; + + println!("{meta:?}"); + Ok(()) +} diff --git a/examples/examples/runtime_apis_static.rs b/examples/examples/runtime_apis_static.rs new file mode 100644 index 0000000000..5e0d256bde --- /dev/null +++ b/examples/examples/runtime_apis_static.rs @@ -0,0 +1,27 @@ +use sp_keyring::AccountKeyring; +use subxt::{config::PolkadotConfig, OnlineClient}; + +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +pub mod polkadot {} + +#[tokio::main] +async fn main() -> Result<(), Box> { + // Create a client to use: + let api = OnlineClient::::new().await?; + + // Create a runtime API payload that calls into + // `AccountNonceApi_account_nonce` function. + let account = AccountKeyring::Alice.to_account_id().into(); + let runtime_api_call = polkadot::apis().account_nonce_api().account_nonce(account); + + // Submit the call and get back a result. + let nonce = api + .runtime_api() + .at_latest() + .await? + .call(runtime_api_call) + .await; + + println!("AccountNonceApi_account_nonce for Alice: {:?}", nonce); + Ok(()) +} diff --git a/examples/examples/runtime_calls.rs b/examples/examples/runtime_calls.rs deleted file mode 100644 index edf8eb356a..0000000000 --- a/examples/examples/runtime_calls.rs +++ /dev/null @@ -1,85 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use sp_keyring::AccountKeyring; -use subxt::dynamic::Value; -use subxt::{config::PolkadotConfig, OnlineClient}; - -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_tiny.scale")] -pub mod polkadot {} - -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - // Create a client to use: - let api = OnlineClient::::new().await?; - - // In the first part of the example calls are made using the static generated code - // and as a result the returned values are strongly typed. - - // Create a runtime API payload that calls into - // `Core_version` function. - let runtime_api_call = polkadot::apis().core().version(); - - // Submit the runtime API call. - let version = api - .runtime_api() - .at_latest() - .await? - .call(runtime_api_call) - .await; - println!("Core_version: {:?}", version); - - // Show the supported metadata versions of the node. - // Calls into `Metadata_metadata_versions` runtime function. - let runtime_api_call = polkadot::apis().metadata().metadata_versions(); - - // Submit the runtime API call. - let versions = api - .runtime_api() - .at_latest() - .await? - .call(runtime_api_call) - .await?; - println!("Metadata_metadata_versions: {:?}", versions); - - // Create a runtime API payload that calls into - // `AccountNonceApi_account_nonce` function. - let account = AccountKeyring::Alice.to_account_id().into(); - let runtime_api_call = polkadot::apis().account_nonce_api().account_nonce(account); - - // Submit the runtime API call. - let nonce = api - .runtime_api() - .at_latest() - .await? - .call(runtime_api_call) - .await; - println!("AccountNonceApi_account_nonce for Alice: {:?}", nonce); - - // Dynamic calls. - let runtime_api_call = - subxt::dynamic::runtime_api_call("Metadata_metadata_versions", Vec::>::new()); - let versions = api - .runtime_api() - .at_latest() - .await? - .call(runtime_api_call) - .await?; - println!( - " dynamic Metadata_metadata_versions: {:#?}", - versions.to_value() - ); - - Ok(()) -} diff --git a/examples/examples/runtime_types_only.rs b/examples/examples/runtime_types_only.rs deleted file mode 100644 index a12365b961..0000000000 --- a/examples/examples/runtime_types_only.rs +++ /dev/null @@ -1,62 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! In some cases we are interested only in the `RuntimeCall` enum (or more generally, only in some -//! runtime types). We can ask `subxt` to generate only runtime types by passing a corresponding -//! flag. -//! -//! Here we present how to correctly create `Block` type for the Polkadot chain. - -use sp_core::H256; -use sp_runtime::{ - generic, - traits::{BlakeTwo256, Block as _, Header as _}, - Digest, -}; -use subxt::PolkadotConfig; - -#[subxt::subxt( - runtime_metadata_path = "../artifacts/polkadot_metadata_tiny.scale", - derive_for_all_types = "Clone, PartialEq, Eq", - runtime_types_only -)] -pub mod polkadot {} - -type RuntimeCall = polkadot::runtime_types::polkadot_runtime::RuntimeCall; - -type UncheckedExtrinsic = generic::UncheckedExtrinsic< - ::Address, - RuntimeCall, - ::Signature, - // Usually we are not interested in `SignedExtra`. - (), ->; - -type Header = generic::Header; -type Block = generic::Block; - -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - // Although we could build an online client, we do not have access to the full runtime API. For - // that, we would have to specify `runtime_types_only = false` (or just skipping it). - // - // let api = subxt::OnlineClient::::new().await?; - // let address = polkadot::constants().balances().existential_deposit(); <- this won't compile! - - let polkadot_header = Header::new( - 41, - H256::default(), - H256::default(), - H256::default(), - Digest::default(), - ); - - let polkadot_block = Block::new(polkadot_header, vec![]); - - println!("{polkadot_block:?}"); - - Ok(()) -} diff --git a/examples/examples/setup_client_custom_config.rs b/examples/examples/setup_client_custom_config.rs new file mode 100644 index 0000000000..0acf71ae4a --- /dev/null +++ b/examples/examples/setup_client_custom_config.rs @@ -0,0 +1,30 @@ +use subxt::{ + config::{substrate::SubstrateExtrinsicParams, Config, SubstrateConfig}, + OnlineClient, +}; + +/// Define a custom config type (see the `subxt::config::Config` docs for +/// more information about each type): +enum MyConfig {} +impl Config for MyConfig { + // This is different from the default `u32`: + type Index = u64; + // We can point to the default types if we don't need to change things: + type Hash = ::Hash; + type Hasher = ::Hasher; + type Header = ::Header; + type AccountId = ::AccountId; + type Address = ::Address; + type Signature = ::Signature; + // ExtrinsicParams makes use of the index type, so we need to tweak it + // too to align with our modified index type, above: + type ExtrinsicParams = SubstrateExtrinsicParams; +} + +#[tokio::main] +async fn main() -> Result<(), Box> { + // Create a client which uses the custom config: + let _api = OnlineClient::::new().await?; + + Ok(()) +} diff --git a/examples/examples/custom_rpc_client.rs b/examples/examples/setup_client_custom_rpc.rs similarity index 90% rename from examples/examples/custom_rpc_client.rs rename to examples/examples/setup_client_custom_rpc.rs index 474e7a71d6..ed04f1f4fa 100644 --- a/examples/examples/custom_rpc_client.rs +++ b/examples/examples/setup_client_custom_rpc.rs @@ -1,7 +1,3 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - use std::{ fmt::Write, pin::Pin, @@ -64,13 +60,8 @@ impl RpcClientT for MyLoggingClient { } } -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] -pub mod polkadot {} - #[tokio::main] async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - // Instantiate our replacement RPC client. let log = Arc::default(); let rpc_client = MyLoggingClient { diff --git a/examples/examples/setup_client_offline.rs b/examples/examples/setup_client_offline.rs new file mode 100644 index 0000000000..ba5d9b31ab --- /dev/null +++ b/examples/examples/setup_client_offline.rs @@ -0,0 +1,37 @@ +use subxt::ext::codec::Decode; +use subxt::ext::frame_metadata::RuntimeMetadataPrefixed; +use subxt::metadata::Metadata; +use subxt::utils::H256; +use subxt::{config::PolkadotConfig, OfflineClient}; + +#[tokio::main] +async fn main() -> Result<(), Box> { + // We need to obtain the following details for an OfflineClient to be instantiated: + + // 1. Genesis hash (RPC call: chain_getBlockHash(0)): + let genesis_hash = { + let h = "91b171bb158e2d3848fa23a9f1c25182fb8e20313b2c1eb49219da7a70ce90c3"; + let bytes = hex::decode(h).unwrap(); + H256::from_slice(&bytes) + }; + + // 2. A runtime version (system_version constant on a Substrate node has these): + let runtime_version = subxt::rpc::types::RuntimeVersion { + spec_version: 9370, + transaction_version: 20, + other: Default::default(), + }; + + // 3. Metadata (I'll load it from the downloaded metadata, but you can use + // `subxt metadata > file.scale` to download it): + let metadata = { + let bytes = std::fs::read("./artifacts/polkadot_metadata.scale").unwrap(); + let metadata = RuntimeMetadataPrefixed::decode(&mut &*bytes).unwrap(); + Metadata::try_from(metadata).unwrap() + }; + + // Create an offline client using the details obtained above: + let _api = OfflineClient::::new(genesis_hash, runtime_version, metadata); + + Ok(()) +} diff --git a/examples/examples/storage_fetch.rs b/examples/examples/storage_fetch.rs new file mode 100644 index 0000000000..1a5b034be5 --- /dev/null +++ b/examples/examples/storage_fetch.rs @@ -0,0 +1,29 @@ +use sp_keyring::AccountKeyring; +use subxt::{OnlineClient, PolkadotConfig}; + +// Generate an interface that we can use from the node's metadata. +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +pub mod polkadot {} + +#[tokio::main] +async fn main() -> Result<(), Box> { + // Create a new API client, configured to talk to Polkadot nodes. + let api = OnlineClient::::new().await?; + + // Build a storage query to access account information. + let account = AccountKeyring::Alice.to_account_id().into(); + let storage_query = polkadot::storage().system().account(&account); + + // Use that query to `fetch` a result. This returns an `Option<_>`, which will be + // `None` if no value exists at the given address. You can also use `fetch_default` + // where applicable, which will return the default value if none exists. + let result = api + .storage() + .at_latest() + .await? + .fetch(&storage_query) + .await?; + + println!("Alice has free balance: {}", result.unwrap().data.free); + Ok(()) +} diff --git a/examples/examples/storage_fetch_dynamic.rs b/examples/examples/storage_fetch_dynamic.rs new file mode 100644 index 0000000000..43325770ea --- /dev/null +++ b/examples/examples/storage_fetch_dynamic.rs @@ -0,0 +1,27 @@ +use sp_keyring::AccountKeyring; +use subxt::dynamic::{At, Value}; +use subxt::{OnlineClient, PolkadotConfig}; + +#[tokio::main] +async fn main() -> Result<(), Box> { + // Create a new API client, configured to talk to Polkadot nodes. + let api = OnlineClient::::new().await?; + + // Build a dynamic storage query to access account information. + let account = AccountKeyring::Alice.to_account_id(); + let storage_query = + subxt::dynamic::storage("System", "Account", vec![Value::from_bytes(account)]); + + // Use that query to `fetch` a result. Because the query is dynamic, we don't know what the result + // type will be either, and so we get a type back that can be decoded into a dynamic Value type. + let result = api + .storage() + .at_latest() + .await? + .fetch(&storage_query) + .await?; + let value = result.unwrap().to_value()?; + + println!("Alice has free balance: {:?}", value.at("data").at("free")); + Ok(()) +} diff --git a/examples/examples/storage_iterating.rs b/examples/examples/storage_iterating.rs index f15c3c65eb..7b7864cf7c 100644 --- a/examples/examples/storage_iterating.rs +++ b/examples/examples/storage_iterating.rs @@ -1,16 +1,3 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use codec::{Decode, Encode}; use subxt::{OnlineClient, PolkadotConfig}; #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] @@ -18,91 +5,24 @@ pub mod polkadot {} #[tokio::main] async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - // Create a client to use: + // Create a new API client, configured to talk to Polkadot nodes. let api = OnlineClient::::new().await?; - // Example 1. Iterate over (keys, value) using the storage client. - // This is the standard and most ergonomic approach. - { - let key_addr = polkadot::storage().xcm_pallet().version_notifiers_root(); - - let mut iter = api.storage().at_latest().await?.iter(key_addr, 10).await?; - - println!("\nExample 1. Obtained keys:"); - while let Some((key, value)) = iter.next().await? { - println!("Key: 0x{}", hex::encode(key)); - println!(" Value: {value}"); - } - } - - // Example 2. Iterate over fetched keys manually. Here, you forgo any static type - // safety and work directly with the bytes on either side. - { - let key_addr = polkadot::storage().xcm_pallet().version_notifiers_root(); - - // Fetch at most 10 keys from below the prefix XcmPallet' VersionNotifiers. - let keys = api - .storage() - .at_latest() - .await? - .fetch_keys(&key_addr.to_root_bytes(), 10, None) - .await?; - - println!("Example 2. Obtained keys:"); - for key in keys.iter() { - println!("Key: 0x{}", hex::encode(key)); - - if let Some(storage_data) = api.storage().at_latest().await?.fetch_raw(&key.0).await? { - // We know the return value to be `QueryId` (`u64`) from inspecting either: - // - polkadot code - // - polkadot.rs generated file under `version_notifiers()` fn - // - metadata in json format - let value = u64::decode(&mut &*storage_data)?; - println!(" Value: {value}"); - } - } - } - - // Example 3. Custom iteration over double maps. Here, we manually append one lookup - // key to the root and just iterate over the values underneath that. - { - let key_addr = polkadot::storage().xcm_pallet().version_notifiers_root(); - - // Obtain the root bytes (`twox_128("XcmPallet") ++ twox_128("VersionNotifiers")`). - let mut query_key = key_addr.to_root_bytes(); - - // We know that the first key is a u32 (the `XcmVersion`) and is hashed by twox64_concat. - // twox64_concat is just the result of running the twox_64 hasher on some value and concatenating - // the value itself after it: - query_key.extend(subxt::ext::sp_core::twox_64(&2u32.encode())); - query_key.extend(&2u32.encode()); - - // The final query key is essentially the result of: - // `twox_128("XcmPallet") ++ twox_128("VersionNotifiers") ++ twox_64(scale_encode(2u32)) ++ scale_encode(2u32)` - println!("\nExample 3\nQuery key: 0x{}", hex::encode(&query_key)); - - let keys = api - .storage() - .at_latest() - .await? - .fetch_keys(&query_key, 10, None) - .await?; - - println!("Obtained keys:"); - for key in keys.iter() { - println!("Key: 0x{}", hex::encode(key)); - - if let Some(storage_data) = api.storage().at_latest().await?.fetch_raw(&key.0).await? { - // We know the return value to be `QueryId` (`u64`) from inspecting either: - // - polkadot code - // - polkadot.rs generated file under `version_notifiers()` fn - // - metadata in json format - let value = u64::decode(&mut &storage_data[..])?; - println!(" Value: {value}"); - } - } + // Build a storage query to iterate over account information. + let storage_query = polkadot::storage().system().account_root(); + + // Get back an iterator of results (here, we are fetching 10 items at + // a time from the node, but we always iterate over oen at a time). + let mut results = api + .storage() + .at_latest() + .await? + .iter(storage_query, 10) + .await?; + + while let Some((key, value)) = results.next().await? { + println!("Key: 0x{}", hex::encode(&key)); + println!("Value: {:?}", value); } Ok(()) diff --git a/examples/examples/storage_iterating_dynamic.rs b/examples/examples/storage_iterating_dynamic.rs new file mode 100644 index 0000000000..9deca9ad8a --- /dev/null +++ b/examples/examples/storage_iterating_dynamic.rs @@ -0,0 +1,25 @@ +use subxt::{OnlineClient, PolkadotConfig}; + +#[tokio::main] +async fn main() -> Result<(), Box> { + // Create a new API client, configured to talk to Polkadot nodes. + let api = OnlineClient::::new().await?; + + // Build a dynamic storage query to iterate account information. + let storage_query = subxt::dynamic::storage_root("System", "Account"); + + // Use that query to return an iterator over the results. + let mut results = api + .storage() + .at_latest() + .await? + .iter(storage_query, 10) + .await?; + + while let Some((key, value)) = results.next().await? { + println!("Key: 0x{}", hex::encode(&key)); + println!("Value: {:?}", value.to_value()?); + } + + Ok(()) +} diff --git a/examples/examples/submit_and_watch.rs b/examples/examples/submit_and_watch.rs deleted file mode 100644 index ede993df53..0000000000 --- a/examples/examples/submit_and_watch.rs +++ /dev/null @@ -1,166 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use futures::StreamExt; -use sp_keyring::AccountKeyring; -use subxt::{tx::PairSigner, OnlineClient, PolkadotConfig}; - -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] -pub mod polkadot {} - -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - simple_transfer().await?; - simple_transfer_separate_events().await?; - handle_transfer_events().await?; - - Ok(()) -} - -/// This is the highest level approach to using this API. We use `wait_for_finalized_success` -/// to wait for the transaction to make it into a finalized block, and also ensure that the -/// transaction was successful according to the associated events. -async fn simple_transfer() -> Result<(), Box> { - let signer = PairSigner::new(AccountKeyring::Alice.pair()); - let dest = AccountKeyring::Bob.to_account_id().into(); - - let api = OnlineClient::::new().await?; - - let balance_transfer_tx = polkadot::tx().balances().transfer(dest, 10_000); - - let balance_transfer = api - .tx() - .sign_and_submit_then_watch_default(&balance_transfer_tx, &signer) - .await? - .wait_for_finalized_success() - .await?; - - let transfer_event = balance_transfer.find_first::()?; - - if let Some(event) = transfer_event { - println!("Balance transfer success: {event:?}"); - } else { - println!("Failed to find Balances::Transfer Event"); - } - Ok(()) -} - -/// This is very similar to `simple_transfer`, except to show that we can handle -/// waiting for the transaction to be finalized separately from obtaining and checking -/// for success on the events. -async fn simple_transfer_separate_events() -> Result<(), Box> { - let signer = PairSigner::new(AccountKeyring::Alice.pair()); - let dest = AccountKeyring::Bob.to_account_id().into(); - - let api = OnlineClient::::new().await?; - - let balance_transfer_tx = polkadot::tx().balances().transfer(dest, 10_000); - - let balance_transfer = api - .tx() - .sign_and_submit_then_watch_default(&balance_transfer_tx, &signer) - .await? - .wait_for_finalized() - .await?; - - // Now we know it's been finalized, we can get hold of a couple of - // details, including events. Calling `wait_for_finalized_success` is - // equivalent to calling `wait_for_finalized` and then `wait_for_success`: - let _events = balance_transfer.wait_for_success().await?; - - // Alternately, we could just `fetch_events`, which grabs all of the events like - // the above, but does not check for success, and leaves it up to you: - let events = balance_transfer.fetch_events().await?; - - let failed_event = events.find_first::()?; - - if let Some(_ev) = failed_event { - // We found a failed event; the transfer didn't succeed. - println!("Balance transfer failed"); - } else { - // We didn't find a failed event; the transfer succeeded. Find - // more details about it to report.. - let transfer_event = events.find_first::()?; - if let Some(event) = transfer_event { - println!("Balance transfer success: {event:?}"); - } else { - println!("Failed to find Balances::Transfer Event"); - } - } - - Ok(()) -} - -/// If we need more visibility into the state of the transaction, we can also ditch -/// `wait_for_finalized` entirely and stream the transaction progress events, handling -/// them more manually. -async fn handle_transfer_events() -> Result<(), Box> { - let signer = PairSigner::new(AccountKeyring::Alice.pair()); - let dest = AccountKeyring::Bob.to_account_id().into(); - - let api = OnlineClient::::new().await?; - - let balance_transfer_tx = polkadot::tx().balances().transfer(dest, 10_000); - - let mut balance_transfer_progress = api - .tx() - .sign_and_submit_then_watch_default(&balance_transfer_tx, &signer) - .await?; - - while let Some(ev) = balance_transfer_progress.next().await { - let ev = ev?; - use subxt::tx::TxStatus::*; - - // Made it into a block, but not finalized. - if let InBlock(details) = ev { - println!( - "Transaction {:?} made it into block {:?}", - details.extrinsic_hash(), - details.block_hash() - ); - - let events = details.wait_for_success().await?; - let transfer_event = events.find_first::()?; - - if let Some(event) = transfer_event { - println!("Balance transfer is now in block (but not finalized): {event:?}"); - } else { - println!("Failed to find Balances::Transfer Event"); - } - } - // Finalized! - else if let Finalized(details) = ev { - println!( - "Transaction {:?} is finalized in block {:?}", - details.extrinsic_hash(), - details.block_hash() - ); - - let events = details.wait_for_success().await?; - let transfer_event = events.find_first::()?; - - if let Some(event) = transfer_event { - println!("Balance transfer success: {event:?}"); - } else { - println!("Failed to find Balances::Transfer Event"); - } - } - // Report other statuses we see. - else { - println!("Current transaction status: {ev:?}"); - } - } - - Ok(()) -} diff --git a/examples/examples/subscribe_block_events.rs b/examples/examples/subscribe_block_events.rs deleted file mode 100644 index ad2dd07dbb..0000000000 --- a/examples/examples/subscribe_block_events.rs +++ /dev/null @@ -1,88 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use futures::StreamExt; -use sp_keyring::AccountKeyring; -use std::time::Duration; -use subxt::{tx::PairSigner, OnlineClient, PolkadotConfig}; - -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] -pub mod polkadot {} - -/// Subscribe to all events, and then manually look through them and -/// pluck out the events that we care about. -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - // Create a client to use: - let api = OnlineClient::::new().await?; - - // Subscribe to (in this case, finalized) blocks. - let mut block_sub = api.blocks().subscribe_finalized().await?; - - // While this subscription is active, balance transfers are made somewhere: - tokio::task::spawn({ - let api = api.clone(); - async move { - let signer = PairSigner::new(AccountKeyring::Alice.pair()); - let mut transfer_amount = 1_000_000_000; - - // Make small balance transfers from Alice to Bob in a loop: - loop { - let transfer_tx = polkadot::tx() - .balances() - .transfer(AccountKeyring::Bob.to_account_id().into(), transfer_amount); - api.tx() - .sign_and_submit_default(&transfer_tx, &signer) - .await - .unwrap(); - - tokio::time::sleep(Duration::from_secs(10)).await; - transfer_amount += 100_000_000; - } - } - }); - - // Get each finalized block as it arrives. - while let Some(block) = block_sub.next().await { - let block = block?; - - // Ask for the events for this block. - let events = block.events().await?; - - let block_hash = block.hash(); - - // We can dynamically decode events: - println!(" Dynamic event details: {block_hash:?}:"); - for event in events.iter() { - let event = event?; - let is_balance_transfer = event - .as_event::()? - .is_some(); - let pallet = event.pallet_name(); - let variant = event.variant_name(); - println!(" {pallet}::{variant} (is balance transfer? {is_balance_transfer})"); - } - - // Or we can find the first transfer event, ignoring any others: - let transfer_event = events.find_first::()?; - - if let Some(ev) = transfer_event { - println!(" - Balance transfer success: value: {:?}", ev.amount); - } else { - println!(" - No balance transfer event found in this block"); - } - } - - Ok(()) -} diff --git a/examples/examples/subscribe_runtime_updates.rs b/examples/examples/subscribe_runtime_updates.rs deleted file mode 100644 index 29145f0d8c..0000000000 --- a/examples/examples/subscribe_runtime_updates.rs +++ /dev/null @@ -1,36 +0,0 @@ -// Copyright 2019-2023 Parity Technologies (UK) Ltd. -// This file is dual-licensed as Apache-2.0 or GPL-3.0. -// see LICENSE for license details. - -//! To run this example, a local polkadot node should be running. Example verified against polkadot v0.9.28-9ffe6e9e3da. -//! -//! E.g. -//! ```bash -//! curl "https://github.com/paritytech/polkadot/releases/download/v0.9.28/polkadot" --output /usr/local/bin/polkadot --location -//! polkadot --dev --tmp -//! ``` - -use std::time::Duration; -use subxt::{OnlineClient, PolkadotConfig}; - -#[tokio::main] -async fn main() -> Result<(), Box> { - tracing_subscriber::fmt::init(); - - // Create a client to use: - let api = OnlineClient::::new().await?; - - // Start a new tokio task to perform the runtime updates while - // utilizing the API for other use cases. - let update_client = api.updater(); - tokio::spawn(async move { - let result = update_client.perform_runtime_updates().await; - println!("Runtime update failed with result={result:?}"); - }); - - // If this client is kept in use a while, it'll update its metadata and such - // as needed when the node it's pointed at updates. - tokio::time::sleep(Duration::from_secs(10_000)).await; - - Ok(()) -} diff --git a/macro/src/lib.rs b/macro/src/lib.rs index f0621a1ec4..8954679305 100644 --- a/macro/src/lib.rs +++ b/macro/src/lib.rs @@ -2,113 +2,6 @@ // This file is dual-licensed as Apache-2.0 or GPL-3.0. // see LICENSE for license details. -//! Generate a strongly typed API for interacting with a Substrate runtime from its metadata. -//! -//! Usage: -//! -//! Download metadata from a running Substrate node using `subxt-cli`: -//! -//! ```bash -//! subxt metadata > polkadot_metadata.scale -//! ``` -//! -//! Annotate a Rust module with the `subxt` attribute referencing the aforementioned metadata file. -//! -//! ```ignore -//! #[subxt::subxt( -//! runtime_metadata_path = "polkadot_metadata.scale", -//! )] -//! pub mod polkadot {} -//! ``` -//! -//! The `subxt` macro will populate the annotated module with all of the methods and types required -//! for submitting extrinsics and reading from storage for the given runtime. -//! -//! ## Substituting types -//! -//! In order to replace a generated type by a user-defined type, use `substitute_type`: -//! -//! ```ignore -//! #[subxt::subxt( -//! runtime_metadata_path = "polkadot_metadata.scale", -//! substitute_type(path = "sp_arithmetic::per_things::Perbill", with = "sp_runtime::Perbill") -//! )] -//! pub mod polkadot {} -//! ``` -//! -//! This will replace the generated type and any usages with the specified type at the `use` import. -//! It is useful for using custom decoding for specific types, or to provide a type with foreign -//! trait implementations, or other specialized functionality. - -//! ## Custom Derives -//! -//! By default all generated types are annotated with `scale::Encode` and `scale::Decode` derives. -//! However when using the generated types in the client, they may require additional derives to be -//! useful. -//! -//! ### Adding derives for all types -//! -//! Add `derive_for_all_types` with a comma separated list of the derives to apply to *all* types -//! -//! ```ignore -//! #[subxt::subxt( -//! runtime_metadata_path = "polkadot_metadata.scale", -//! derive_for_all_types = "Eq, PartialEq" -//! )] -//! pub mod polkadot {} -//! ``` -//! -//! ### Adding derives for specific types -//! -//! Add `derive_for_type` for each specific type with a comma separated list of the derives to -//! apply for that type only. -//! -//! ```ignore -//! #[subxt::subxt( -//! runtime_metadata_path = "polkadot_metadata.scale", -//! derive_for_all_types = "Eq, PartialEq", -//! derive_for_type(path = "frame_support::PalletId", derive = "Ord, PartialOrd"), -//! derive_for_type(path = "sp_runtime::ModuleError", derive = "Hash"), -//! )] -//! pub mod polkadot {} -//! ``` -//! -//! ### Custom crate path -//! -//! In order to specify a custom crate path to be used for the code generation: -//! -//! ```ignore -//! #[subxt::subxt(crate = "crate::path::to::subxt")] -//! pub mod polkadot {} -//! ``` -//! -//! By default the path `::subxt` is used. -//! -//! ### Expose documentation -//! -//! In order to expose the documentation from the runtime metadata on the generated -//! code, users must specify the `generate_docs` flag: -//! -//! ```ignore -//! #[subxt::subxt(generate_docs)] -//! pub mod polkadot {} -//! ``` -//! -//! By default the documentation is not generated. -//! -//! ### Runtime types generation -//! -//! In some cases, you may be interested only in the runtime types, like `RuntimeCall` enum. You can -//! limit code generation to just `runtime_types` module with `runtime_types_only` flag: -//! -//! ```ignore -//! #[subxt::subxt(runtime_types_only)] -//! // or equivalently -//! #[subxt::subxt(runtime_types_only = true)] -//! ``` - -#![deny(unused_crate_dependencies)] - extern crate proc_macro; use std::str::FromStr; @@ -174,6 +67,7 @@ struct SubstituteType { with: syn::Path, } +// Note: docs for this are in the subxt library; don't add any here as they will be appended. #[proc_macro_attribute] #[proc_macro_error] pub fn subxt(args: TokenStream, input: TokenStream) -> TokenStream { diff --git a/subxt/src/blocks/mod.rs b/subxt/src/blocks/mod.rs index d60df23d99..9d6e62d8b3 100644 --- a/subxt/src/blocks/mod.rs +++ b/subxt/src/blocks/mod.rs @@ -7,5 +7,5 @@ mod block_types; mod blocks_client; -pub use block_types::{Block, Extrinsic, ExtrinsicEvents}; +pub use block_types::{Block, BlockBody, Extrinsic, ExtrinsicEvents}; pub use blocks_client::{subscribe_to_block_headers_filling_in_gaps, BlocksClient}; diff --git a/subxt/src/book/mod.rs b/subxt/src/book/mod.rs new file mode 100644 index 0000000000..47124df1ab --- /dev/null +++ b/subxt/src/book/mod.rs @@ -0,0 +1,96 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +// Dev note; I used the following command to normalize and wrap comments: +// rustfmt +nightly --config wrap_comments=true,comment_width=100,normalize_comments=true subxt/src/book/mod.rs +// It messed up comments in code blocks though, so be prepared to go and fix those. + +//! # The Subxt Guide +//! +//! Subxt is a library for interacting with Substrate based nodes. It has a focus on **sub**mitting +//! e**xt**rinsics, hence the name, however it's also capable of reading blocks, storage, events and +//! constants from a node. The aim of this guide is to explain key concepts and get you started with +//! using Subxt. +//! +//! 1. [Features](#features-at-a-glance) +//! 2. [Limitations](#limitations) +//! 3. [Quick start](#quick-start) +//! 4. [Usage](#usage) +//! +//! ## Features at a glance +//! +//! Here's a quick overview of the features that Subxt has to offer: +//! +//! - Subxt allows you to generate a static, type safe interface to a node given some metadata; this +//! allows you to catch many errors at compile time rather than runtime. +//! - Subxt also makes heavy use of node metadata to encode/decode the data sent to/from it. This +//! allows it to target almost any node which can output the correct metadata, and allows it some +//! flexibility in encoding and decoding things to account for cross-node differences. +//! - Subxt has a pallet-oriented interface, meaning that code you write to talk to some pallet on +//! one node will often "Just Work" when pointed at different nodes that use the same pallet. +//! - Subxt can work offline; you can generate and sign transactions, access constants from node +//! metadata and more, without a network connection. This is all checked at compile time, so you +//! can be certain it won't try to establish a network connection if you don't want it to. +//! - Subxt can forego the statically generated interface and build transactions, storage queries +//! and constant queries using data provided at runtime, rather than queries constructed +//! statically. +//! - Subxt can be compiled to WASM to run in the browser, allowing it to back Rust based browser +//! apps, or even bind to JS apps. +//! +//! ## Limitations +//! +//! In various places, you can provide a block hash to access data at a particular block, for +//! instance: +//! +//! - [`crate::storage::StorageClient::at`] +//! - [`crate::events::EventsClient::at`] +//! - [`crate::blocks::BlocksClient::at`] +//! - [`crate::runtime_api::RuntimeApiClient::at`] +//! +//! However, Subxt is (by default) only capable of properly working with blocks that were produced +//! after the most recent runtime update. This is because it uses the most recent metadata given +//! back by a node to encode and decode things. It's possible to decode older blocks produced by a +//! runtime that emits compatible (currently, V14) metadata by manually setting the metadata used by +//! the client using [`crate::client::OnlineClient::set_metadata()`]. +//! +//! Subxt does not support working with blocks produced prior to the runtime update that introduces +//! V14 metadata. It may have some success decoding older blocks using newer metadata, but may also +//! completely fail to do so. +//! +//! ## Quick start +//! +//! Here is a simple but complete example of using Subxt to transfer some tokens from the example +//! accounts, Alice to Bob: +//! +//! ```rust,ignore +#![doc = include_str!("../../../examples/examples/balance_transfer_basic.rs")] +//! ``` +//! +//! This example assumes that a Polkadot node is running locally (Subxt endeavors to support all +//! recent releases). Typically, to use Subxt to talk to some custom Substrate node (for example a +//! parachain node), you'll want to: +//! +//! 1. [Generate an interface](setup::codegen). +//! 2. [Configure and instantiate the client](setup::client). +//! +//! Follow the above links to learn more about each step. +//! +//! ## Usage +//! +//! Once Subxt is configured, the next step is interacting with a node. Follow the links +//! below to learn more about how to use Subxt for each of the following things: +//! +//! - [Extrinsics](usage::extrinsics): Subxt can build and submit extrinsics, wait until they are in +//! blocks, and retrieve the associated events. +//! - [Storage](usage::storage): Subxt can query the node storage. +//! - [Events](usage::events): Subxt can read the events emitted for recent blocks. +//! - [Constants](usage::constants): Subxt can access the constant values stored in a node, which +//! remain the same for a given runtime version. +//! - [Blocks](usage::blocks): Subxt can load recent blocks or subscribe to new/finalized blocks, +//! reading the extrinsics, events and storage at these blocks. +//! - [Runtime APIs](usage::runtime_apis): Subxt can make calls into pallet runtime APIs to retrieve +//! data. +//! +pub mod setup; +pub mod usage; diff --git a/subxt/src/book/setup/client.rs b/subxt/src/book/setup/client.rs new file mode 100644 index 0000000000..92fd621769 --- /dev/null +++ b/subxt/src/book/setup/client.rs @@ -0,0 +1,54 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +//! # Configuring the Subxt client +//! +//! Subxt ships with two clients, an [offline client](crate::client::OfflineClient) and an [online +//! client](crate::client::OnlineClient). These are backed by the traits +//! [`crate::client::OfflineClientT`] and [`crate::client::OnlineClientT`], so in theory it's +//! possible for users to implement their own clients, although this isn't generally expected. +//! +//! Both clients are generic over a [`crate::config::Config`] trait, which is the way that we give +//! the client certain information about how to interact with a node that isn't otherwise available +//! or possible to include in the node metadata. Subxt ships out of the box with two default +//! implementations: +//! +//! - [`crate::config::PolkadotConfig`] for talking to Polkadot nodes, and +//! - [`crate::config::SubstrateConfig`] for talking to generic nodes built with Substrate. +//! +//! The latter will generally work in many cases, but will need modifying if the chain you'd like to +//! connect to has altered any of the details mentioned in [the trait](`crate::config::Config`). +//! +//! In the case of the [`crate::OnlineClient`], we have a few options to instantiate it: +//! +//! - [`crate::OnlineClient::new()`] to connect to a node running locally. +//! - [`crate::OnlineClient::from_url()`] to connect to a node at a specific URL. +//! - [`crate::OnlineClient::from_rpc_client()`] to instantiate the client with a custom RPC +//! implementation. +//! +//! The latter accepts anything that implements the low level [`crate::rpc::RpcClientT`] trait; this +//! allows you to decide how Subxt will attempt to talk to a node if you'd prefer something other +//! than the provided interfaces. +//! +//! ## Examples +//! +//! Defining some custom config based off the default Substrate config: +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/setup_client_custom_config.rs")] +//! ``` +//! Writing a custom [`crate::rpc::RpcClientT`] implementation: +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/setup_client_custom_rpc.rs")] +//! ``` +//! Creating an [`crate::OfflineClient`]: +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/setup_client_offline.rs")] +//! ``` +//! diff --git a/subxt/src/book/setup/codegen.rs b/subxt/src/book/setup/codegen.rs new file mode 100644 index 0000000000..5cf0d8032d --- /dev/null +++ b/subxt/src/book/setup/codegen.rs @@ -0,0 +1,66 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +//! # Generating an interface +//! +//! The simplest way to use Subxt is to generate an interface to a chain that you'd like to interact +//! with. This generated interface allows you to build transactions and construct queries to access +//! data while leveraging the full type safety of the Rust compiler. +//! +//! ## The `#[subxt]` macro +//! +//! The most common way to generate the interface is to use the [`#[subxt]`](crate::subxt) macro. +//! Using this macro looks something like: +//! +//! ```rust,no_run +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! pub mod polkadot {} +//! ``` +//! +//! The macro takes a path to some node metadata, and uses that to generate the interface you'll use +//! to talk to it. [Go here](crate::subxt) to learn more about the options available to the macro. +//! +//! To obtain this metadata you'll need for the above, you can use the `subxt` CLI tool to download it +//! from a node. The tool can be installed via `cargo`: +//! +//! ```shell +//! cargo install subxt-cli +//! ``` +//! +//! And then it can be used to fetch metadata and save it to a file: +//! +//! ```shell +//! # Download and save all of the metadata: +//! subxt metadata > metadata.scale +//! # Download and save only the pallets you want to generate an interface for: +//! subxt metadata --pallets Balances,System > metadata.scale +//! ``` +//! +//! Explicitly specifying pallets will cause the tool to strip out all unnecessary metadata and type +//! information, making the bundle much smaller in the event that you only need to generate an +//! interface for a subset of the available pallets on the node. +//! +//! ## The CLI tool +//! +//! Using the [`#[subxt]`](crate::subxt) macro carries some downsides: +//! +//! - Using it to generate an interface will have a small impact on compile times (though much less of +//! one if you only need a few pallets). +//! - IDE support for autocompletion and documentation when using the macro interface can be poor. +//! - It's impossible to manually look at the generated code to understand and debug things. +//! +//! If these are an issue, you can manually generate the same code that the macro generates under the hood +//! by using the `subxt codegen` command: +//! +//! ```shell +//! # Install the CLI tool if you haven't already: +//! cargo install subxt-cli +//! # Generate and format rust code, saving it to `interface.rs`: +//! subxt codegen | rustfmt > interface.rs +//! ``` +//! +//! Use `subxt codegen --help` for more options; many of the options available via the macro are +//! also available via the CLI tool, such as the ability to substitute generated types for others, +//! or strip out docs from the generated code. +//! diff --git a/subxt/src/book/setup/mod.rs b/subxt/src/book/setup/mod.rs new file mode 100644 index 0000000000..f3f3c8e109 --- /dev/null +++ b/subxt/src/book/setup/mod.rs @@ -0,0 +1,13 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +//! This modules contains details on setting up Subxt: +//! +//! - [Codegen](codegen) +//! - [Client](client) +//! +//! Alternately, [go back](super). + +pub mod client; +pub mod codegen; diff --git a/subxt/src/book/usage/blocks.rs b/subxt/src/book/usage/blocks.rs new file mode 100644 index 0000000000..b991500f86 --- /dev/null +++ b/subxt/src/book/usage/blocks.rs @@ -0,0 +1,39 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +//! # Blocks +//! +//! The [blocks API](crate::blocks::BlocksClient) in Subxt unifies many of the other interfaces, and +//! allows you to: +//! +//! - Access information about specific blocks (see [`crate::blocks::BlocksClient::at()`] and +//! [`crate::blocks::BlocksClient::at_latest()`]). +//! - Subscribe to [all](crate::blocks::BlocksClient::subscribe_all()), +//! [best](crate::blocks::BlocksClient::subscribe_best()) or +//! [finalized](crate::blocks::BlocksClient::subscribe_finalized()) blocks as they are produced. +//! Prefer to subscribe to finalized blocks unless you know what you're doing. +//! +//! In either case, you'll end up with [`crate::blocks::Block`]'s, from which you can access various +//! information about the block, such a the [header](crate::blocks::Block::header()), [block +//! number](crate::blocks::Block::number()) and [body](crate::blocks::Block::body()). +//! [`crate::blocks::Block`]'s also provide shortcuts to other Subxt APIs that will operate at the +//! given block: +//! +//! - [storage](crate::blocks::Block::storage()), +//! - [events](crate::blocks::Block::events()) +//! - [runtime APIs](crate::blocks::Block::runtime_api()) +//! +//! ## Example +//! +//! Given a block, you can [download the block body](crate::blocks::Block::body()) and iterate over +//! the extrinsics stored within it using [`crate::blocks::BlockBody::extrinsics()`]. +//! +//! Here's an example in which we subscribe to blocks and print a bunch of information about each +//! one: +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/blocks_subscribing.rs")] +//! ``` +//! diff --git a/subxt/src/book/usage/constants.rs b/subxt/src/book/usage/constants.rs new file mode 100644 index 0000000000..94074113ee --- /dev/null +++ b/subxt/src/book/usage/constants.rs @@ -0,0 +1,61 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +//! # Constants +//! +//! There are various constants stored in a node; the types and values of these are defined in a +//! runtime, and can only change when the runtime is updated. Much like [`super::storage`], we can +//! query these using Subxt by taking the following steps: +//! +//! 1. [Constructing a constant query](#constructing-a-query). +//! 2. [Submitting the query to get back the associated value](#submitting-it). +//! +//! ## Constructing a constant query +//! +//! We can use the statically generated interface to build constant queries: +//! +//! ```rust,no_run +//! use sp_keyring::AccountKeyring; +//! +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! pub mod polkadot {} +//! +//! let constant_query = polkadot::constants().system().block_length(); +//! ``` +//! +//! Alternately, we can dynamically construct a constant query: +//! +//! ```rust,no_run +//! use sp_keyring::AccountKeyring; +//! use subxt::dynamic::Value; +//! +//! let account = AccountKeyring::Alice.to_account_id(); +//! let storage_query = subxt::dynamic::constant("System", "BlockLength"); +//! ``` +//! +//! Static queries also have a static return type, so the constant is decoded appropriately. In +//! addition, they are validated at runtime to ensure that they align with the current node state. +//! Dynamic queries must be decoded into some static type manually, or into the dynamic +//! [`crate::dynamic::Value`] type. +//! +//! ## Submitting it +//! +//! Constant queries are handed to Subxt via [`crate::constants::ConstantsClient::at()`]. It's worth +//! noting that constant values are pulled directly out of the node metadata which Subxt has +//! already acquired, and so this function requires no network access and is available from a +//! [`crate::OfflineClient`]. +//! +//! Here's an example using a static query: +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/constants_static.rs")] +//! ``` +//! And here's one using a dynamic query: +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/constants_dynamic.rs")] +//! ``` +//! diff --git a/subxt/src/book/usage/events.rs b/subxt/src/book/usage/events.rs new file mode 100644 index 0000000000..b64382731e --- /dev/null +++ b/subxt/src/book/usage/events.rs @@ -0,0 +1,50 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +//! # Events +//! +//! In the process of adding extrinsics to a block, they are executed. When extrinsics are executed, +//! they normally produce events describing what's happening (at the very least, an event dictating whether +//! the extrinsic has succeeded or failed). The node may also emit some events of its own as the block is +//! processed. +//! +//! Events live in a single location in node storage which is overwritten at each block. Normal nodes tend to +//! keep a snapshot of the state at a small number of previous blocks, so you can sometimes access +//! older events by using [`crate::events::EventsClient::at()`] and providing an older block hash. +//! +//! When we submit extrinsics using Subxt, methods like [`crate::tx::TxProgress::wait_for_finalized_success()`] +//! return [`crate::blocks::ExtrinsicEvents`], which can be used to iterate and inspect the events produced +//! for a specific extrinsic. We can also access _all_ of the events produced in a single block using one of these +//! two interfaces: +//! +//! ```rust,no_run +//! # #[tokio::main] +//! # async fn main() -> Result<(), Box> { +//! use subxt::client::OnlineClient; +//! use subxt::config::PolkadotConfig; +//! +//! // Create client: +//! let client = OnlineClient::::new().await?; +//! +//! // Get events from the latest block (use .at() to specify a block hash): +//! let events = client.blocks().at_latest().await?.events().await?; +//! // We can use this shorthand too: +//! let events = client.events().at_latest().await?; +//! # Ok(()) +//! # } +//! ``` +//! +//! Once we've loaded our events, we can iterate all events or search for specific events via +//! methods like [`crate::events::Events::iter()`] and [`crate::events::Events::find()`]. See +//! [`crate::events::Events`] and [`crate::events::EventDetails`] for more information. +//! +//! ## Example +//! +//! Here's an example which puts this all together: +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/events.rs")] +//! ``` +//! diff --git a/subxt/src/book/usage/extrinsics.rs b/subxt/src/book/usage/extrinsics.rs new file mode 100644 index 0000000000..3d409f5772 --- /dev/null +++ b/subxt/src/book/usage/extrinsics.rs @@ -0,0 +1,175 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +//! # Extrinsics +//! +//! Extrinsics define function calls and their parameters, and are the only way that you can change +//! the state of the blockchain. Submitting extrinsics to a node is one of the core features of +//! Subxt, and generally consists of the following steps: +//! +//! 1. [Constructing an extrinsic payload to submit](#constructing-an-extrinsic-payload). +//! 2. [Signing it](#signing-it). +//! 3. [Submitting it (optionally with some additional parameters)](#submitting-it). +//! +//! We'll look at each of these steps in turn. +//! +//! > As a side note, an _extrinsic_ is anything that can be added to a block, and a _transaction_ +//! > is an extrinsic that is submitted from a particular user (and is therefore also signed). Subxt +//! > can construct unsigned extrinsics, but overwhelmingly you'll need to sign them, and so the +//! > documentation tends to use the terms _extrinsic_ and _transaction_ interchangeably. +//! +//! ## Constructing an extrinsic payload +//! +//! We can use the statically generated interface to build extrinsic payloads: +//! +//! ```rust,no_run +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! pub mod polkadot {} +//! +//! let remark = "Hello there".as_bytes().to_vec(); +//! let extrinsic_payload = polkadot::tx().system().remark(remark); +//! ``` +//! +//! > If you're not sure what types to import and use to build a given payload, you can use the +//! > `subxt` CLI tool to generate the interface by using something like `subxt codegen | rustfmt > +//! > interface.rs`, to see what types and things are available (or even just to use directly +//! > instead of the [`#[subxt]`](crate::subxt) macro). +//! +//! Alternately, we can dynamically construct an extrinsic payload. This will not be type checked or +//! validated until it's submitted: +//! +//! ```rust,no_run +//! use subxt::dynamic::Value; +//! +//! let extrinsic_payload = subxt::dynamic::tx("System", "remark", vec![ +//! Value::from_bytes("Hello there") +//! ]); +//! ``` +//! +//! The [`crate::dynamic::Value`] type is a dynamic type much like a `serde_json::Value` but instead +//! represents any type of data that can be SCALE encoded or decoded. It can be serialized, +//! deserialized and parsed from/to strings. +//! +//! A valid extrinsic payload is just something that implements the [`crate::tx::TxPayload`] trait; +//! you can implement this trait on your own custom types if the built-in ones are not suitable for +//! your needs. +//! +//! ## Signing it +//! +//! You'll normally need to sign an extrinsic to prove that it originated from an account that you +//! control. To do this, you will typically first create an [`crate::tx::Signer`], which tells Subxt +//! who the extrinsic is from, and takes care of signing the relevant details to prove this. +//! +//! Subxt provides a [`crate::tx::PairSigner`] which implements this trait (if the +//! `substrate-compat` feature is enabled) which accepts any valid [`sp_core::Pair`] and uses that +//! to sign transactions: +//! +//! ```rust +//! use subxt::tx::PairSigner; +//! use sp_core::Pair; +//! use subxt::config::PolkadotConfig; +//! +//! // Get hold of a `Signer` given a test account: +//! let pair = sp_keyring::AccountKeyring::Alice.pair(); +//! let signer = PairSigner::::new(pair); +//! +//! // Or generate an `sr25519` keypair to use: +//! let (pair, _, _) = sp_core::sr25519::Pair::generate_with_phrase(Some("password")); +//! let signer = PairSigner::::new(pair); +//! ``` +//! +//! See the [`sp_core::Pair`] docs for more ways to generate them. +//! +//! If this isn't suitable/available, you can either implement [`crate::tx::Signer`] yourself to use +//! custom signing logic, or you can use some external signing logic, like so: +//! +//! ```rust,no_run +//! # #[tokio::main] +//! # async fn main() -> Result<(), Box> { +//! use subxt::client::OnlineClient; +//! use subxt::config::PolkadotConfig; +//! use subxt::dynamic::Value; +//! +//! // Create client: +//! let client = OnlineClient::::new().await?; +//! +//! // Create a dummy extrinsic payload to sign: +//! let payload = subxt::dynamic::tx("System", "remark", vec![ +//! Value::from_bytes("Hello there") +//! ]); +//! +//! // Construct the extrinsic but don't sign it. You need to provide the nonce +//! // here, or can use `create_partial_signed` to fetch the correct nonce. +//! let partial_extrinsic = client.tx().create_partial_signed_with_nonce( +//! &payload, +//! 0, +//! Default::default() +//! )?; +//! +//! // Fetch the payload that needs to be signed: +//! let signer_payload = partial_extrinsic.signer_payload(); +//! +//! // ... At this point, we can hand off the `signer_payload` to be signed externally. +//! // Ultimately we need to be given back a `signature` (or really, anything +//! // that can be SCALE encoded) and an `address`: +//! let signature; +//! let address; +//! # use subxt::tx::Signer; +//! # let pair = sp_keyring::AccountKeyring::Alice.pair(); +//! # let signer = subxt::tx::PairSigner::::new(pair); +//! # signature = signer.sign(&signer_payload); +//! # address = signer.address(); +//! +//! // Now we can build an extrinsic, which one can call `submit` or `submit_and_watch` +//! // on to submit to a node and optionally watch the status. +//! let extrinsic = partial_extrinsic.sign_with_address_and_signature( +//! &address, +//! &signature +//! ); +//! # Ok(()) +//! # } +//! ``` +//! +//! ## Submitting it +//! +//! Once we are able to sign the extrinsic, we need to submit it. +//! +//! ### The high level API +//! +//! The highest level approach to doing this is to call +//! [`crate::tx::TxClient::sign_and_submit_then_watch_default`]. This hands back a +//! [`crate::tx::TxProgress`] struct which will monitor the transaction status. We can then call +//! [`crate::tx::TxProgress::wait_for_finalized_success()`] to wait for this transaction to make it +//! into a finalized block, check for an `ExtrinsicSuccess` event, and then hand back the events for +//! inspection. This looks like: +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/balance_transfer_basic.rs")] +//! ``` +//! ### Providing extrinsic parameters +//! +//! If you'd like to provide extrinsic parameters (such as mortality), you can use +//! [`crate::tx::TxClient::sign_and_submit_then_watch`] instead, and provide parameters for your +//! chain: +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/balance_transfer_with_params.rs")] +//! ``` +//! This example doesn't wait for the extrinsic to be included in a block; it just submits it and +//! hopes for the best! +//! +//! ### Custom handling of transaction status updates +//! +//! If you'd like more control or visibility over exactly which status updates are being emitted for +//! the transaction, you can monitor them as they are emitted and react however you choose: +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/balance_transfer_status_stream.rs")] +//! ``` +//! Take a look at the API docs for [`crate::tx::TxProgress`], [`crate::tx::TxStatus`] and +//! [`crate::tx::TxInBlock`] for more options. +//! diff --git a/subxt/src/book/usage/mod.rs b/subxt/src/book/usage/mod.rs new file mode 100644 index 0000000000..8243cf2ce2 --- /dev/null +++ b/subxt/src/book/usage/mod.rs @@ -0,0 +1,21 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +//! This modules contains examples of using Subxt; follow the links for more: +//! +//! - [Extrinsics](extrinsics) +//! - [Storage](storage) +//! - [Events](events) +//! - [Constants](constants) +//! - [Blocks](blocks) +//! - [Runtime APIs](runtime_apis) +//! +//! Alternately, [go back](super). + +pub mod blocks; +pub mod constants; +pub mod events; +pub mod extrinsics; +pub mod runtime_apis; +pub mod storage; diff --git a/subxt/src/book/usage/runtime_apis.rs b/subxt/src/book/usage/runtime_apis.rs new file mode 100644 index 0000000000..f5b4dd0799 --- /dev/null +++ b/subxt/src/book/usage/runtime_apis.rs @@ -0,0 +1,81 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +//! # Runtime API interface +//! +//! The Runtime API interface allows Subxt to call runtime APIs exposed by certain pallets in order +//! to obtain information. Much like [`super::storage`] and [`super::extrinsics`], Making a runtime +//! call to a node and getting the response back takes the following steps: +//! +//! 1. [Constructing a runtime call](#constructing-a-runtime-call) +//! 2. [Submitting it to get back the response](#submitting-it) +//! +//! **Note:** Runtime APIs are only available when using V15 metadata, which is currently unstable. +//! You'll need to use `subxt metadata --version unstable` command to download the unstable V15 metadata, +//! and activate the `unstable-metadata` feature in Subxt for it to also use this metadata from a node. The +//! metadata format is unstable because it may change and break compatibility with Subxt at any moment, so +//! use at your own risk. +//! +//! ## Constructing a runtime call +//! +//! We can use the statically generated interface to build runtime calls: +//! +//! ```rust,no_run +//! use sp_keyring::AccountKeyring; +//! +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! pub mod polkadot {} +//! +//! let runtime_call = polkadot::apis().metadata().metadata_versions(); +//! ``` +//! +//! Alternately, we can dynamically construct a runtime call: +//! +//! ```rust,no_run +//! use sp_keyring::AccountKeyring; +//! use subxt::dynamic::Value; +//! +//! let account = AccountKeyring::Alice.to_account_id(); +//! let runtime_call = subxt::dynamic::runtime_api_call( +//! "Metadata_metadata_versions", +//! Vec::>::new() +//! ); +//! ``` +//! +//! All valid runtime calls implement [`crate::runtime_api::RuntimeApiPayload`], a trait which +//! describes how to encode the runtime call arguments and what return type to decode from the +//! response. +//! +//! ## Submitting it +//! +//! Runtime calls can be handed to [`crate::runtime_api::RuntimeApi::call()`], which will submit +//! them and hand back the associated response. +//! +//! ### Making a static Runtime API call +//! +//! The easiest way to make a runtime API call is to use the statically generated interface. +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/runtime_apis_static.rs")] +//! ``` +//! +//! ### Making a dynamic Runtime API call +//! +//! If you'd prefer to construct the call at runtime, you can do this using the +//! [`crate::dynamic::runtime_api_call`] method. +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/runtime_apis_dynamic.rs")] +//! ``` +//! +//! ### Making a raw call +//! +//! This is generally discouraged in favour of one of the above, but may be necessary (especially if +//! the node you're talking to does not yet serve V15 metadata). Here, you must manually encode +//! the argument bytes and manually provide a type for the response bytes to be decoded into. +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/runtime_apis_raw.rs")] +//! ``` +//! diff --git a/subxt/src/book/usage/storage.rs b/subxt/src/book/usage/storage.rs new file mode 100644 index 0000000000..92efb13890 --- /dev/null +++ b/subxt/src/book/usage/storage.rs @@ -0,0 +1,110 @@ +// Copyright 2019-2023 Parity Technologies (UK) Ltd. +// This file is dual-licensed as Apache-2.0 or GPL-3.0. +// see LICENSE for license details. + +//! # Storage +//! +//! A Substrate based chain has storage, whose values are determined by the extrinsics added to past +//! blocks. Subxt allows you to query the storage of a node, which consists of the following steps: +//! +//! 1. [Constructing a storage query](#constructing-a-storage-query). +//! 2. [Submitting the query to get back the associated values](#submitting-it). +//! +//! ## Constructing a storage query +//! +//! We can use the statically generated interface to build storage queries: +//! +//! ```rust,no_run +//! use sp_keyring::AccountKeyring; +//! +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! pub mod polkadot {} +//! +//! let account = AccountKeyring::Alice.to_account_id().into(); +//! let storage_query = polkadot::storage().system().account(&account); +//! ``` +//! +//! Alternately, we can dynamically construct a storage query. This will not be type checked or +//! validated until it's submitted: +//! +//! ```rust,no_run +//! use sp_keyring::AccountKeyring; +//! use subxt::dynamic::Value; +//! +//! let account = AccountKeyring::Alice.to_account_id(); +//! let storage_query = subxt::dynamic::storage("System", "Account", vec![ +//! Value::from_bytes(account) +//! ]); +//! ``` +//! +//! As well as accessing specific entries, some storage locations can also be iterated over (such as +//! the map of account information). To do this, suffix `_root` onto the query constructor (this +//! will only be available on static constructors when iteration is actually possible): +//! +//! ```rust,no_run +//! use sp_keyring::AccountKeyring; +//! +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! pub mod polkadot {} +//! +//! // A static query capable of iterating over accounts: +//! let storage_query = polkadot::storage().system().account_root(); +//! // A dynamic query to do the same: +//! let storage_query = subxt::dynamic::storage_root("System", "Account"); +//! ``` +//! +//! All valid storage queries implement [`crate::storage::StorageAddress`]. As well as describing +//! how to build a valid storage query, this trait also has some associated types that determine the +//! shape of the result you'll get back, and determine what you can do with it (ie, can you iterate +//! over storage entries using it). +//! +//! Static queries set appropriate values for these associated types, and can therefore only be used +//! where it makes sense. Dynamic queries don't know any better and can be used in more places, but +//! may fail at runtime instead if they are invalid in those places. +//! +//! ## Submitting it +//! +//! Storage queries can be handed to various functions in [`crate::storage::Storage`] in order to +//! obtain the associated values (also referred to as storage entries) back. +//! +//! ### Fetching storage entries +//! +//! The simplest way to access storage entries is to construct a query and then call either +//! [`crate::storage::Storage::fetch()`] or [`crate::storage::Storage::fetch_or_default()`] (the +//! latter will only work for storage queries that have a default value when empty): +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/storage_fetch.rs")] +//! ``` +//! For completeness, below is an example using a dynamic query instead. The return type from a +//! dynamic query is a [`crate::dynamic::DecodedValueThunk`], which can be decoded into a +//! [`crate::dynamic::Value`], or else the raw bytes can be accessed instead. +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/storage_fetch_dynamic.rs")] +//! ``` +//! ### Iterating storage entries +//! +//! Many storage entries are maps of values; as well as fetching individual values, it's possible to +//! iterate over all of the values stored at that location: +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/storage_iterating.rs")] +//! ``` +//! Here's the same logic but using dynamically constructed values instead: +//! +//! +//! ```rust,ignore +#![doc = include_str!("../../../../examples/examples/storage_iterating_dynamic.rs")] +//! ``` +//! ### Advanced +//! +//! For more advanced use cases, have a look at [`crate::storage::Storage::fetch_raw`] and +//! [`crate::storage::Storage::fetch_keys`]. Both of these take raw bytes as arguments, which can be +//! obtained from a [`crate::storage::StorageAddress`] by using +//! [`crate::storage::StorageClient::address_bytes()`] or +//! [`crate::storage::StorageClient::address_root_bytes()`]. +//! diff --git a/subxt/src/config/mod.rs b/subxt/src/config/mod.rs index ba569efa39..702a90eb07 100644 --- a/subxt/src/config/mod.rs +++ b/subxt/src/config/mod.rs @@ -29,7 +29,7 @@ pub trait Config: 'static { /// transactions associated with a sender account. type Index: Debug + Copy + DeserializeOwned + Into; - /// The output of the `Hashing` function. + /// The output of the `Hasher` function. type Hash: Debug + Copy + Send @@ -95,7 +95,6 @@ pub trait Header: Sized + Encode { /// Take a type implementing [`Config`] (eg [`SubstrateConfig`]), and some type which describes the /// additional and extra parameters to pass to an extrinsic (see [`ExtrinsicParams`]), /// and returns a type implementing [`Config`] with those new [`ExtrinsicParams`]. -/// ``` pub struct WithExtrinsicParams> { _marker: std::marker::PhantomData<(T, E)>, } diff --git a/subxt/src/dynamic.rs b/subxt/src/dynamic.rs index df65cffb13..ec318da4c9 100644 --- a/subxt/src/dynamic.rs +++ b/subxt/src/dynamic.rs @@ -11,7 +11,7 @@ use crate::{ }; use scale_decode::DecodeAsType; -pub use scale_value::Value; +pub use scale_value::{At, Value}; /// A [`scale_value::Value`] type endowed with contextual information /// regarding what type was used to decode each part of it. This implements diff --git a/subxt/src/lib.rs b/subxt/src/lib.rs index fe7f227a26..f7eeca7bc3 100644 --- a/subxt/src/lib.rs +++ b/subxt/src/lib.rs @@ -2,112 +2,13 @@ // This file is dual-licensed as Apache-2.0 or GPL-3.0. // see LICENSE for license details. -//! Subxt is a library to **sub**mit e**xt**rinsics to a [substrate](https://github.com/paritytech/substrate) node via RPC. +//! Subxt is a library for interacting with Substrate based nodes. Using it looks something like this: //! -//! The generated Subxt API exposes the ability to: -//! - [Submit extrinsics](https://docs.substrate.io/v3/concepts/extrinsics/) (Calls) -//! - [Query storage](https://docs.substrate.io/v3/runtime/storage/) (Storage) -//! - [Query constants](https://docs.substrate.io/how-to-guides/v3/basics/configurable-constants/) (Constants) -//! - [Subscribe to events](https://docs.substrate.io/v3/runtime/events-and-errors/) (Events) -//! -//! # Initializing the API client -//! -//! To interact with a node, you'll need to construct a client. -//! -//! ```no_run -//! use subxt::{OnlineClient, PolkadotConfig}; -//! -//! # #[tokio::main] -//! # async fn main() { -//! let api = OnlineClient::::new().await.unwrap(); -//! # } +//! ```rust,ignore +#![doc = include_str!("../../examples/examples/balance_transfer_basic.rs")] //! ``` //! -//! This default client connects to a locally running node, but can be configured to point anywhere. -//! Additionally, an [`crate::OfflineClient`] is available to perform operations that don't require a -//! network connection to a node. -//! -//! The client takes a type parameter, here [`crate::PolkadotConfig`], which bakes in assumptions about -//! the structure of extrinsics and the underlying types used by the node for things like block numbers. -//! If the node you'd like to interact with deviates from Polkadot or the default Substrate node in these -//! areas, you'll need to configure them by implementing the [`crate::config::Config`] type yourself. -//! -//! # Generating runtime types -//! -//! Subxt can optionally generate types at compile time to help you interact with a node. These types are -//! generated using metadata which can be downloaded from a node using the [subxt-cli](https://crates.io/crates/subxt-cli) -//! tool. These generated types provide a degree of type safety when interacting with a node that is compatible with -//! the metadata that they were generated using. We also do runtime checks in case the node you're talking to has -//! deviated from the types you're using to communicate with it (see below). -//! -//! To generate the types, use the `subxt` macro and point it at the metadata you've downloaded, like so: -//! -//! ```ignore -//! #[subxt::subxt(runtime_metadata_path = "metadata.scale")] -//! pub mod node_runtime { } -//! ``` -//! -//! For more information, please visit the [subxt-codegen](https://docs.rs/subxt-codegen/latest/subxt_codegen/) -//! documentation. -//! -//! You can opt to skip this step and use dynamic queries to talk to nodes instead, which can be useful in some cases, -//! but doesn't provide any type safety. -//! -//! # Interacting with the API -//! -//! Once instantiated, a client exposes four core functions: -//! - `.tx()` for submitting extrinsics/transactions. See [`crate::tx::TxClient`] for more details, or see -//! the [balance_transfer](../examples/examples/balance_transfer.rs) example. -//! - `.storage()` for fetching and iterating over storage entries. See [`crate::storage::StorageClient`] for more details, or see -//! the [fetch_staking_details](../examples/examples/fetch_staking_details.rs) example. -//! - `.constants()` for getting hold of constants. See [`crate::constants::ConstantsClient`] for more details, or see -//! the [fetch_constants](../examples/examples/fetch_constants.rs) example. -//! - `.events()` for subscribing/obtaining events. See [`crate::events::EventsClient`] for more details, or see: -//! - [subscribe_all_events](../examples/examples/subscribe_all_events.rs): Subscribe to events emitted from blocks. -//! - [subscribe_one_event](../examples/examples/subscribe_one_event.rs): Subscribe and filter by one event. -//! - [subscribe_some_events](../examples/examples/subscribe_some_events.rs): Subscribe and filter event. -//! -//! # Static Metadata Validation -//! -//! If you use types generated by the [`crate::subxt`] macro, there is a chance that they will fall out of sync -//! with the actual state of the node you're trying to interact with. -//! -//! When you attempt to use any of these static types to interact with a node, Subxt will validate that they are -//! still compatible and issue an error if they have deviated. -//! -//! Additionally, you can validate that the entirety of the statically generated code aligns with a node like so: -//! -//! ```no_run -//! use subxt::{OnlineClient, PolkadotConfig}; -//! -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] -//! pub mod polkadot {} -//! -//! # #[tokio::main] -//! # async fn main() { -//! let api = OnlineClient::::new().await.unwrap(); -//! -//! if let Err(_e) = polkadot::validate_codegen(&api) { -//! println!("Generated code is not up to date with node we're connected to"); -//! } -//! # } -//! ``` -//! ## Opting out of static validation -//! -//! The static types that are used to query/access information are validated by default, to make sure that they are -//! compatible with the node being queried. You can generally call `.unvalidated()` on these static types to -//! disable this validation. -//! -//! # Runtime Updates -//! -//! The node you're connected to may occasionally perform runtime updates while you're connected, which would ordinarily -//! leave the runtime state of the node out of sync with the information Subxt requires to do things like submit -//! transactions. -//! -//! If this is a concern, you can use the `UpdateClient` API to keep the `RuntimeVersion` and `Metadata` of the client -//! synced with the target node. -//! -//! Please visit the [subscribe_runtime_updates](../examples/examples/subscribe_runtime_updates.rs) example for more details. +//! Take a look at [the Subxt guide](book) to learn more about how to use Subxt. #![deny( bad_style, @@ -132,13 +33,14 @@ )] #![allow(clippy::type_complexity)] +// The guide is here. +pub mod book; + // Suppress an unused dependency warning because tokio is // only used in example code snippets at the time of writing. #[cfg(test)] use tokio as _; -pub use subxt_macro::subxt; - // Used to enable the js feature for wasm. #[cfg(target_arch = "wasm32")] pub use getrandom as _; @@ -184,3 +86,203 @@ pub mod ext { #[cfg(feature = "substrate-compat")] pub use sp_runtime; } + +/// Generate a strongly typed API for interacting with a Substrate runtime from its metadata. +/// +/// # Metadata +/// +/// First, you'll need to get hold of some metadata for the node you'd like to interact with. One +/// way to do this is by using the `subxt` CLI tool: +/// +/// ```bash +/// # Install the CLI tool: +/// cargo install subxt-cli +/// # Use it to download metadata (in this case, from a node running locally) +/// subxt metadata > polkadot_metadata.scale +/// ``` +/// +/// Run `subxt metadata --help` for more options. +/// +/// # Basic usage +/// +/// Annotate a Rust module with the `subxt` attribute referencing the aforementioned metadata file. +/// +/// ```rust,no_run +/// #[subxt::subxt( +/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// )] +/// mod polkadot {} +/// ``` +/// +/// The `subxt` macro will populate the annotated module with all of the methods and types required +/// for interacting with the runtime that the metadata came from via Subxt. +/// +/// # Configuration +/// +/// This macro supports a number of attributes to configure what is generated: +/// +/// ## `crate = "..."` +/// +/// Use this attribute to specify a custom path to the `subxt` crate: +/// +/// ```rust +/// # pub extern crate subxt; +/// # pub mod path { pub mod to { pub use subxt; } } +/// # fn main() {} +/// #[subxt::subxt( +/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// crate = "crate::path::to::subxt" +/// )] +/// mod polkadot {} +/// ``` +/// +/// This is useful if you write a library which uses this macro, but don't want to force users to depend on `subxt` +/// at the top level too. By default the path `::subxt` is used. +/// +/// ## `substitute_type(path = "...", with = "...")` +/// +/// This attribute replaces any reference to the generated type at the path given by `path` with a +/// reference to the path given by `with`. +/// +/// ```rust +/// #[subxt::subxt( +/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// substitute_type(path = "sp_arithmetic::per_things::Perbill", with = "crate::Foo") +/// )] +/// mod polkadot {} +/// +/// # #[derive( +/// # scale_encode::EncodeAsType, +/// # scale_decode::DecodeAsType, +/// # codec::Encode, +/// # codec::Decode, +/// # Clone, +/// # Debug, +/// # )] +/// // In reality this needs some traits implementing on +/// // it to allow it to be used in place of Perbill: +/// pub struct Foo(u32); +/// # impl codec::CompactAs for Foo { +/// # type As = u32; +/// # fn encode_as(&self) -> &Self::As { +/// # &self.0 +/// # } +/// # fn decode_from(x: Self::As) -> Result { +/// # Ok(Foo(x)) +/// # } +/// # } +/// # impl From> for Foo { +/// # fn from(v: codec::Compact) -> Foo { +/// # v.0 +/// # } +/// # } +/// # fn main() {} +/// ``` +/// +/// If the type you're substituting contains generic parameters, you can "pattern match" on those, and +/// make use of them in the substituted type, like so: +/// +/// ```rust,no_run +/// #[subxt::subxt( +/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// substitute_type( +/// path = "sp_runtime::multiaddress::MultiAddress", +/// with = "::subxt::utils::Static<::sp_runtime::MultiAddress>" +/// ) +/// )] +/// mod polkadot {} +/// ``` +/// +/// The above is also an example of using the [`crate::utils::Static`] type to wrap some type which doesn't +/// on it's own implement [`scale_encode::EncodeAsType`] or [`scale_decode::DecodeAsType`], which are required traits +/// for any substitute type to implement by default. +/// +/// ## `derive_for_all_types = "..."` +/// +/// By default, all generated types derive a small set of traits. This attribute allows you to derive additional +/// traits on all generated types: +/// +/// ```rust,no_run +/// #[subxt::subxt( +/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// derive_for_all_types = "Eq, PartialEq" +/// )] +/// mod polkadot {} +/// ``` +/// +/// Any substituted types (including the default substitutes) must also implement these traits in order to avoid errors +/// here. +/// +/// ## `derive_for_type(path = "...", derive = "...")` +/// +/// Unlike the above, which derives some trait on every generated type, this attribute allows you to derive traits only +/// for specific types. Note that any types which are used inside the specified type may also need to derive the same traits. +/// +/// ```rust,no_run +/// #[subxt::subxt( +/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// derive_for_all_types = "Eq, PartialEq", +/// derive_for_type(path = "frame_support::PalletId", derive = "Ord, PartialOrd"), +/// derive_for_type(path = "sp_runtime::ModuleError", derive = "Hash"), +/// )] +/// mod polkadot {} +/// ``` +/// +/// ## `runtime_metadata_url = "..."` +/// +/// This attribute can be used instead of `runtime_metadata_path` and will tell the macro to download metadata from a node running +/// at the provided URL, rather than a node running locally. This can be useful in CI, but is **not recommended** in production code, +/// since it runs at compile time and will cause compilation to fail if the node at the given address is unavailable or unresponsive. +/// +/// ```rust,ignore +/// #[subxt::subxt( +/// runtime_metadata_url = "wss://rpc.polkadot.io:443" +/// )] +/// mod polkadot {} +/// ``` +/// +/// ## `generate_docs` +/// +/// By default, documentation is not generated via the macro, since IDEs do not typically make use of it. This attribute +/// forces documentation to be generated, too. +/// +/// ```rust,no_run +/// #[subxt::subxt( +/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// generate_docs +/// )] +/// mod polkadot {} +/// ``` +/// +/// ## `runtime_types_only` +/// +/// By default, the macro will generate various interfaces to make using Subxt simpler in addition with any types that need +/// generating to make this possible. This attribute makes the codegen only generate the types and not the Subxt interface. +/// +/// ```rust,no_run +/// #[subxt::subxt( +/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// runtime_types_only +/// )] +/// mod polkadot {} +/// ``` +/// ## `no_default_derives` +/// +/// By default, the macro will add all derives necessary for the generated code to play nicely with Subxt. Adding this attribute +/// removes all default derives. +/// +/// ```rust,no_run +/// #[subxt::subxt( +/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// runtime_types_only, +/// no_default_derives, +/// derive_for_all_types="codec::Encode, codec::Decode" +/// )] +/// mod polkadot {} +/// ``` +/// +/// **Note**: At the moment, you must derive at least one of `codec::Encode` or `codec::Decode` or `scale_encode::EncodeAsType` or +/// `scale_decode::DecodeAsType` (because we add `#[codec(..)]` attributes on some fields/types during codegen), and you must use this +/// feature in conjunction with `runtime_types_only` (or manually specify a bunch of defaults to make codegen work properly when +/// generating the subxt interfaces). +pub use subxt_macro::subxt; diff --git a/subxt/src/metadata/mod.rs b/subxt/src/metadata/mod.rs index 2e80ac9c15..7ada3e62b7 100644 --- a/subxt/src/metadata/mod.rs +++ b/subxt/src/metadata/mod.rs @@ -13,6 +13,7 @@ pub use metadata_location::MetadataLocation; pub use metadata_type::{ ErrorMetadata, EventMetadata, InvalidMetadataError, Metadata, MetadataError, PalletMetadata, + RuntimeFnMetadata, }; pub use decode_encode_traits::{DecodeWithMetadata, EncodeWithMetadata}; From b07f01545b5fe08296e5015d4c13f2b71bfaa72b Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Thu, 4 May 2023 19:39:01 +0200 Subject: [PATCH 18/22] use new metadata files in book --- examples/examples/balance_transfer_basic.rs | 2 +- examples/examples/balance_transfer_status_stream.rs | 2 +- examples/examples/constants_static.rs | 2 +- examples/examples/events.rs | 2 +- examples/examples/runtime_apis_dynamic.rs | 2 +- examples/examples/runtime_apis_raw.rs | 2 +- examples/examples/runtime_apis_static.rs | 2 +- examples/examples/setup_client_offline.rs | 2 +- examples/examples/storage_fetch.rs | 2 +- subxt/src/book/setup/codegen.rs | 2 +- subxt/src/book/usage/constants.rs | 2 +- subxt/src/book/usage/extrinsics.rs | 2 +- subxt/src/book/usage/runtime_apis.rs | 2 +- subxt/src/book/usage/storage.rs | 4 ++-- 14 files changed, 15 insertions(+), 15 deletions(-) diff --git a/examples/examples/balance_transfer_basic.rs b/examples/examples/balance_transfer_basic.rs index 787f1f9ef2..2f31e2476e 100644 --- a/examples/examples/balance_transfer_basic.rs +++ b/examples/examples/balance_transfer_basic.rs @@ -2,7 +2,7 @@ use sp_keyring::AccountKeyring; use subxt::{tx::PairSigner, OnlineClient, PolkadotConfig}; // Generate an interface that we can use from the node's metadata. -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/balance_transfer_status_stream.rs b/examples/examples/balance_transfer_status_stream.rs index a390f9e3d4..47d0b9196c 100644 --- a/examples/examples/balance_transfer_status_stream.rs +++ b/examples/examples/balance_transfer_status_stream.rs @@ -6,7 +6,7 @@ use subxt::{ }; // Generate an interface that we can use from the node's metadata. -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/constants_static.rs b/examples/examples/constants_static.rs index 1dd9409c0e..ebbf6ed0e9 100644 --- a/examples/examples/constants_static.rs +++ b/examples/examples/constants_static.rs @@ -1,6 +1,6 @@ use subxt::{OnlineClient, PolkadotConfig}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/events.rs b/examples/examples/events.rs index 4c35398349..01499c1acb 100644 --- a/examples/examples/events.rs +++ b/examples/examples/events.rs @@ -1,6 +1,6 @@ use subxt::{OnlineClient, PolkadotConfig}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/runtime_apis_dynamic.rs b/examples/examples/runtime_apis_dynamic.rs index c861c53357..bc2690bcf0 100644 --- a/examples/examples/runtime_apis_dynamic.rs +++ b/examples/examples/runtime_apis_dynamic.rs @@ -2,7 +2,7 @@ use sp_keyring::AccountKeyring; use subxt::dynamic::Value; use subxt::{config::PolkadotConfig, OnlineClient}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/runtime_apis_raw.rs b/examples/examples/runtime_apis_raw.rs index fc61ff4b3b..c1ee7cf8d5 100644 --- a/examples/examples/runtime_apis_raw.rs +++ b/examples/examples/runtime_apis_raw.rs @@ -2,7 +2,7 @@ use subxt::ext::codec::Compact; use subxt::ext::frame_metadata::RuntimeMetadataPrefixed; use subxt::{OnlineClient, PolkadotConfig}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/runtime_apis_static.rs b/examples/examples/runtime_apis_static.rs index 5e0d256bde..53732ce817 100644 --- a/examples/examples/runtime_apis_static.rs +++ b/examples/examples/runtime_apis_static.rs @@ -1,7 +1,7 @@ use sp_keyring::AccountKeyring; use subxt::{config::PolkadotConfig, OnlineClient}; -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/examples/examples/setup_client_offline.rs b/examples/examples/setup_client_offline.rs index ba5d9b31ab..f6fbb77ba8 100644 --- a/examples/examples/setup_client_offline.rs +++ b/examples/examples/setup_client_offline.rs @@ -25,7 +25,7 @@ async fn main() -> Result<(), Box> { // 3. Metadata (I'll load it from the downloaded metadata, but you can use // `subxt metadata > file.scale` to download it): let metadata = { - let bytes = std::fs::read("./artifacts/polkadot_metadata.scale").unwrap(); + let bytes = std::fs::read("./artifacts/polkadot_metadata_small.scale").unwrap(); let metadata = RuntimeMetadataPrefixed::decode(&mut &*bytes).unwrap(); Metadata::try_from(metadata).unwrap() }; diff --git a/examples/examples/storage_fetch.rs b/examples/examples/storage_fetch.rs index 1a5b034be5..5674d51ff7 100644 --- a/examples/examples/storage_fetch.rs +++ b/examples/examples/storage_fetch.rs @@ -2,7 +2,7 @@ use sp_keyring::AccountKeyring; use subxt::{OnlineClient, PolkadotConfig}; // Generate an interface that we can use from the node's metadata. -#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] pub mod polkadot {} #[tokio::main] diff --git a/subxt/src/book/setup/codegen.rs b/subxt/src/book/setup/codegen.rs index 5cf0d8032d..03c48439a2 100644 --- a/subxt/src/book/setup/codegen.rs +++ b/subxt/src/book/setup/codegen.rs @@ -14,7 +14,7 @@ //! Using this macro looks something like: //! //! ```rust,no_run -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] //! pub mod polkadot {} //! ``` //! diff --git a/subxt/src/book/usage/constants.rs b/subxt/src/book/usage/constants.rs index 94074113ee..5abede310c 100644 --- a/subxt/src/book/usage/constants.rs +++ b/subxt/src/book/usage/constants.rs @@ -18,7 +18,7 @@ //! ```rust,no_run //! use sp_keyring::AccountKeyring; //! -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] //! pub mod polkadot {} //! //! let constant_query = polkadot::constants().system().block_length(); diff --git a/subxt/src/book/usage/extrinsics.rs b/subxt/src/book/usage/extrinsics.rs index 3d409f5772..19e8a698ed 100644 --- a/subxt/src/book/usage/extrinsics.rs +++ b/subxt/src/book/usage/extrinsics.rs @@ -24,7 +24,7 @@ //! We can use the statically generated interface to build extrinsic payloads: //! //! ```rust,no_run -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] //! pub mod polkadot {} //! //! let remark = "Hello there".as_bytes().to_vec(); diff --git a/subxt/src/book/usage/runtime_apis.rs b/subxt/src/book/usage/runtime_apis.rs index f5b4dd0799..eb49560277 100644 --- a/subxt/src/book/usage/runtime_apis.rs +++ b/subxt/src/book/usage/runtime_apis.rs @@ -24,7 +24,7 @@ //! ```rust,no_run //! use sp_keyring::AccountKeyring; //! -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] //! pub mod polkadot {} //! //! let runtime_call = polkadot::apis().metadata().metadata_versions(); diff --git a/subxt/src/book/usage/storage.rs b/subxt/src/book/usage/storage.rs index 92efb13890..3c454f7aab 100644 --- a/subxt/src/book/usage/storage.rs +++ b/subxt/src/book/usage/storage.rs @@ -17,7 +17,7 @@ //! ```rust,no_run //! use sp_keyring::AccountKeyring; //! -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] //! pub mod polkadot {} //! //! let account = AccountKeyring::Alice.to_account_id().into(); @@ -44,7 +44,7 @@ //! ```rust,no_run //! use sp_keyring::AccountKeyring; //! -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] //! pub mod polkadot {} //! //! // A static query capable of iterating over accounts: From 82a5a21298e4fc86fd9a4418e798c57925903db9 Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Fri, 5 May 2023 10:52:43 +0200 Subject: [PATCH 19/22] use mtadata full in docs --- subxt/src/lib.rs | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/subxt/src/lib.rs b/subxt/src/lib.rs index f7eeca7bc3..65b4917432 100644 --- a/subxt/src/lib.rs +++ b/subxt/src/lib.rs @@ -109,7 +109,7 @@ pub mod ext { /// /// ```rust,no_run /// #[subxt::subxt( -/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale", /// )] /// mod polkadot {} /// ``` @@ -130,7 +130,7 @@ pub mod ext { /// # pub mod path { pub mod to { pub use subxt; } } /// # fn main() {} /// #[subxt::subxt( -/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale", /// crate = "crate::path::to::subxt" /// )] /// mod polkadot {} @@ -146,7 +146,7 @@ pub mod ext { /// /// ```rust /// #[subxt::subxt( -/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale", /// substitute_type(path = "sp_arithmetic::per_things::Perbill", with = "crate::Foo") /// )] /// mod polkadot {} @@ -184,7 +184,7 @@ pub mod ext { /// /// ```rust,no_run /// #[subxt::subxt( -/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale", /// substitute_type( /// path = "sp_runtime::multiaddress::MultiAddress", /// with = "::subxt::utils::Static<::sp_runtime::MultiAddress>" @@ -204,7 +204,7 @@ pub mod ext { /// /// ```rust,no_run /// #[subxt::subxt( -/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale", /// derive_for_all_types = "Eq, PartialEq" /// )] /// mod polkadot {} @@ -220,7 +220,7 @@ pub mod ext { /// /// ```rust,no_run /// #[subxt::subxt( -/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale", /// derive_for_all_types = "Eq, PartialEq", /// derive_for_type(path = "frame_support::PalletId", derive = "Ord, PartialOrd"), /// derive_for_type(path = "sp_runtime::ModuleError", derive = "Hash"), @@ -248,7 +248,7 @@ pub mod ext { /// /// ```rust,no_run /// #[subxt::subxt( -/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale", /// generate_docs /// )] /// mod polkadot {} @@ -261,7 +261,7 @@ pub mod ext { /// /// ```rust,no_run /// #[subxt::subxt( -/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale", /// runtime_types_only /// )] /// mod polkadot {} @@ -273,7 +273,7 @@ pub mod ext { /// /// ```rust,no_run /// #[subxt::subxt( -/// runtime_metadata_path = "../artifacts/polkadot_metadata.scale", +/// runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale", /// runtime_types_only, /// no_default_derives, /// derive_for_all_types="codec::Encode, codec::Decode" From a6f2a174a0604d75b43f11cae6b0425a3bb2b1b9 Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Thu, 11 May 2023 16:22:44 +0200 Subject: [PATCH 20/22] regenerate polkadot.rs --- .../integration-tests/src/codegen/polkadot.rs | 34 ++++++++++++++----- 1 file changed, 25 insertions(+), 9 deletions(-) diff --git a/testing/integration-tests/src/codegen/polkadot.rs b/testing/integration-tests/src/codegen/polkadot.rs index 3a324f6925..37746296a1 100644 --- a/testing/integration-tests/src/codegen/polkadot.rs +++ b/testing/integration-tests/src/codegen/polkadot.rs @@ -591,14 +591,14 @@ pub mod api { Paras(paras::Call), #[codec(index = 57)] Initializer(initializer::Call), - #[codec(index = 58)] - Dmp(dmp::Call), #[codec(index = 59)] Ump(ump::Call), #[codec(index = 60)] Hrmp(hrmp::Call), #[codec(index = 62)] ParasDisputes(paras_disputes::Call), + #[codec(index = 63)] + ParasSlashing(paras_slashing::Call), #[codec(index = 70)] Registrar(registrar::Call), #[codec(index = 71)] @@ -911,13 +911,6 @@ pub mod api { metadata, )?)); } - if pallet_name == "Dmp" { - return Ok(Call::Dmp(dmp::Call::decode_with_metadata( - &mut &*pallet_bytes, - pallet_ty, - metadata, - )?)); - } if pallet_name == "Ump" { return Ok(Call::Ump(ump::Call::decode_with_metadata( &mut &*pallet_bytes, @@ -941,6 +934,15 @@ pub mod api { )?, )); } + if pallet_name == "ParasSlashing" { + return Ok(Call::ParasSlashing( + paras_slashing::Call::decode_with_metadata( + &mut &*pallet_bytes, + pallet_ty, + metadata, + )?, + )); + } if pallet_name == "Registrar" { return Ok(Call::Registrar(registrar::Call::decode_with_metadata( &mut &*pallet_bytes, @@ -36322,6 +36324,8 @@ pub mod api { pub type Error = runtime_types::polkadot_runtime_parachains::disputes::slashing::pallet::Error; #[doc = "Contains one variant per dispatchable that can be called by an extrinsic."] + pub type Call = + runtime_types::polkadot_runtime_parachains::disputes::slashing::pallet::Call; pub mod calls { use super::root_mod; use super::runtime_types; @@ -36339,6 +36343,10 @@ pub mod api { #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] pub struct ReportDisputeLostUnsigned { pub dispute_proof : :: std :: boxed :: Box < runtime_types :: polkadot_runtime_parachains :: disputes :: slashing :: DisputeProof > , pub key_owner_proof : runtime_types :: sp_session :: MembershipProof , } + impl ::subxt::blocks::StaticExtrinsic for ReportDisputeLostUnsigned { + const PALLET: &'static str = "ParasSlashing"; + const CALL: &'static str = "report_dispute_lost_unsigned"; + } } pub struct TransactionApi; impl TransactionApi { @@ -38934,6 +38942,10 @@ pub mod api { pub fee_asset_item: ::core::primitive::u32, pub weight_limit: runtime_types::xcm::v3::WeightLimit, } + impl ::subxt::blocks::StaticExtrinsic for LimitedTeleportAssets { + const PALLET: &'static str = "XcmPallet"; + const CALL: &'static str = "limited_teleport_assets"; + } #[derive( :: subxt :: ext :: codec :: Decode, :: subxt :: ext :: codec :: Encode, @@ -38947,6 +38959,10 @@ pub mod api { pub struct ForceSuspension { pub suspended: ::core::primitive::bool, } + impl ::subxt::blocks::StaticExtrinsic for ForceSuspension { + const PALLET: &'static str = "XcmPallet"; + const CALL: &'static str = "force_suspension"; + } } pub struct TransactionApi; impl TransactionApi { From ae211fb99a39db25fe3e7e710a4cff0221eced8b Mon Sep 17 00:00:00 2001 From: Tadeo hepperle Date: Thu, 11 May 2023 17:31:38 +0200 Subject: [PATCH 21/22] use small metadata in a couple of places --- subxt/src/book/setup/codegen.rs | 2 +- subxt/src/book/usage/runtime_apis.rs | 2 +- subxt/src/book/usage/storage.rs | 4 ++-- subxt/src/book/usage/transactions.rs | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/subxt/src/book/setup/codegen.rs b/subxt/src/book/setup/codegen.rs index 03c48439a2..602f108e22 100644 --- a/subxt/src/book/setup/codegen.rs +++ b/subxt/src/book/setup/codegen.rs @@ -14,7 +14,7 @@ //! Using this macro looks something like: //! //! ```rust,no_run -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_tiny.scale")] //! pub mod polkadot {} //! ``` //! diff --git a/subxt/src/book/usage/runtime_apis.rs b/subxt/src/book/usage/runtime_apis.rs index 27f0cc10f0..37ec878f42 100644 --- a/subxt/src/book/usage/runtime_apis.rs +++ b/subxt/src/book/usage/runtime_apis.rs @@ -24,7 +24,7 @@ //! ```rust,no_run //! use sp_keyring::AccountKeyring; //! -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] //! pub mod polkadot {} //! //! let runtime_call = polkadot::apis().metadata().metadata_versions(); diff --git a/subxt/src/book/usage/storage.rs b/subxt/src/book/usage/storage.rs index 272549148e..23b0dbc1e7 100644 --- a/subxt/src/book/usage/storage.rs +++ b/subxt/src/book/usage/storage.rs @@ -18,7 +18,7 @@ //! ```rust,no_run //! use sp_keyring::AccountKeyring; //! -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] //! pub mod polkadot {} //! //! let account = AccountKeyring::Alice.to_account_id().into(); @@ -45,7 +45,7 @@ //! ```rust,no_run //! use sp_keyring::AccountKeyring; //! -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] //! pub mod polkadot {} //! //! // A static query capable of iterating over accounts: diff --git a/subxt/src/book/usage/transactions.rs b/subxt/src/book/usage/transactions.rs index ac800b8e2a..49779228ab 100644 --- a/subxt/src/book/usage/transactions.rs +++ b/subxt/src/book/usage/transactions.rs @@ -26,7 +26,7 @@ //! We can use the statically generated interface to build transaction payloads: //! //! ```rust,no_run -//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_full.scale")] +//! #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata_small.scale")] //! pub mod polkadot {} //! //! let remark = "Hello there".as_bytes().to_vec(); From 00768558767af7d639aae6dc79077198207a4108 Mon Sep 17 00:00:00 2001 From: Tadeo Hepperle <62739623+tadeohepperle@users.noreply.github.com> Date: Thu, 11 May 2023 20:18:57 +0200 Subject: [PATCH 22/22] Update scripts/artifacts.sh Co-authored-by: Niklas Adolfsson --- scripts/artifacts.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/artifacts.sh b/scripts/artifacts.sh index b08b1761d8..f561228a2a 100755 --- a/scripts/artifacts.sh +++ b/scripts/artifacts.sh @@ -18,4 +18,4 @@ cargo run --bin subxt codegen --file artifacts/polkadot_metadata_full.scale | ru # generate a metadata file that only contains the pallets Balances, Staking, System and Multisig cargo run --bin subxt metadata --file artifacts/polkadot_metadata_full.scale --pallets "Balances,Staking,System,Multisig" > artifacts/polkadot_metadata_small.scale # generate a metadata file that only contains no pallets -cargo run --bin subxt metadata --file artifacts/polkadot_metadata_full.scale --pallets "" > artifacts/polkadot_metadata_tiny.scale \ No newline at end of file +cargo run --bin subxt metadata --file artifacts/polkadot_metadata_full.scale --pallets "" > artifacts/polkadot_metadata_tiny.scale