From adf7c89939de5184d608451b588d65245613f74d Mon Sep 17 00:00:00 2001 From: Sniezka Date: Mon, 8 Jul 2024 12:14:32 +0200 Subject: [PATCH 1/5] Implented exporting >= u128 types from wasm --- sdk/contracts/invariant/invariant.json | 545 +++++++++++++---------- sdk/contracts/invariant/invariant.wasm | Bin 119056 -> 119179 bytes sdk/contracts/psp22/psp22.json | 2 +- sdk/contracts/psp22/psp22.wasm | Bin 15123 -> 15123 bytes sdk/src/abis/invariant.ts | 545 +++++++++++++---------- sdk/src/abis/psp22.ts | 2 +- sdk/src/poc-u256.ts | 13 + sdk/src/wasm/Cargo.toml | 1 + sdk/src/wasm/storage/invariant_config.rs | 53 +++ 9 files changed, 709 insertions(+), 452 deletions(-) create mode 100644 sdk/src/poc-u256.ts diff --git a/sdk/contracts/invariant/invariant.json b/sdk/contracts/invariant/invariant.json index 8939d7fe..85fc95d7 100644 --- a/sdk/contracts/invariant/invariant.json +++ b/sdk/contracts/invariant/invariant.json @@ -1,6 +1,6 @@ { "source": { - "hash": "0x86f442ed070586bbb8157cda6fdc259b84f953e62727d779806988f81937cd1f", + "hash": "0xf1173d8a30aa5cb75a057960692ea174fa6eac1c0209d5d1ba5d16d810939697", "language": "ink! 5.0.0", "compiler": "rustc 1.77.0", "build_info": { @@ -44,7 +44,7 @@ "ink_primitives", "ConstructorResult" ], - "type": 54 + "type": 57 }, "selector": "0x9bae9d5e" } @@ -73,13 +73,13 @@ "displayName": [ "ChainExtension" ], - "type": 113 + "type": 116 }, "hash": { "displayName": [ "Hash" ], - "type": 112 + "type": 115 }, "maxEventTopics": 4, "staticBufferSize": 16384, @@ -219,7 +219,7 @@ "displayName": [ "Vec" ], - "type": 103 + "type": 106 } } ], @@ -481,7 +481,7 @@ "displayName": [ "Option" ], - "type": 111 + "type": 114 } }, { @@ -494,7 +494,7 @@ "displayName": [ "Option" ], - "type": 111 + "type": 114 } }, { @@ -524,7 +524,7 @@ "ink", "LangError" ], - "type": 55 + "type": 58 }, "messages": [ { @@ -539,7 +539,7 @@ "ink", "MessageResult" ], - "type": 56 + "type": 59 }, "selector": "0xe285b69a" }, @@ -565,7 +565,7 @@ "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x5a059796" }, @@ -591,7 +591,7 @@ "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0xc8bd0f58" }, @@ -626,7 +626,7 @@ "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x0ebd3ec6" }, @@ -697,7 +697,7 @@ "ink", "MessageResult" ], - "type": 60 + "type": 63 }, "selector": "0x0a1ca76b" }, @@ -759,7 +759,7 @@ "ink", "MessageResult" ], - "type": 62 + "type": 65 }, "selector": "0x1c590004" }, @@ -798,7 +798,7 @@ "displayName": [ "Vec" ], - "type": 66 + "type": 69 } } ], @@ -812,7 +812,7 @@ "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x5ff8d655" }, @@ -874,7 +874,7 @@ "ink", "MessageResult" ], - "type": 68 + "type": 71 }, "selector": "0xa2bd3fc7" }, @@ -895,7 +895,7 @@ "displayName": [ "Vec" ], - "type": 66 + "type": 69 } } ], @@ -909,7 +909,7 @@ "ink", "MessageResult" ], - "type": 71 + "type": 74 }, "selector": "0x879b5256" }, @@ -944,7 +944,7 @@ "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0xe5af145a" }, @@ -979,7 +979,7 @@ "ink", "MessageResult" ], - "type": 60 + "type": 63 }, "selector": "0xccb84930" }, @@ -1005,7 +1005,7 @@ "ink", "MessageResult" ], - "type": 73 + "type": 76 }, "selector": "0xa509d69f" }, @@ -1049,7 +1049,7 @@ "ink", "MessageResult" ], - "type": 75 + "type": 78 }, "selector": "0xb2155f6b" }, @@ -1075,7 +1075,7 @@ "ink", "MessageResult" ], - "type": 80 + "type": 83 }, "selector": "0x4eb580e1" }, @@ -1101,7 +1101,7 @@ "ink", "MessageResult" ], - "type": 80 + "type": 83 }, "selector": "0xfe63d239" }, @@ -1127,7 +1127,7 @@ "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x009b6a3d" }, @@ -1153,7 +1153,7 @@ "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x3b497d6e" }, @@ -1179,7 +1179,7 @@ "ink", "MessageResult" ], - "type": 83 + "type": 86 }, "selector": "0x4e9e07ce" }, @@ -1241,7 +1241,7 @@ "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x98b595e9" }, @@ -1285,7 +1285,7 @@ "ink", "MessageResult" ], - "type": 84 + "type": 87 }, "selector": "0xf91e4a49" }, @@ -1320,7 +1320,7 @@ "ink", "MessageResult" ], - "type": 86 + "type": 89 }, "selector": "0xb62aa10d" }, @@ -1355,7 +1355,7 @@ "ink", "MessageResult" ], - "type": 90 + "type": 93 }, "selector": "0xeebd620b" }, @@ -1390,7 +1390,7 @@ "ink", "MessageResult" ], - "type": 83 + "type": 86 }, "selector": "0xdbae15e5" }, @@ -1425,7 +1425,7 @@ "ink", "MessageResult" ], - "type": 92 + "type": 95 }, "selector": "0x6dd2d776" }, @@ -1441,7 +1441,7 @@ "ink", "MessageResult" ], - "type": 96 + "type": 99 }, "selector": "0xd05b6003" }, @@ -1476,7 +1476,7 @@ "ink", "MessageResult" ], - "type": 97 + "type": 100 }, "selector": "0xcc9476e7" }, @@ -1529,7 +1529,7 @@ "ink", "MessageResult" ], - "type": 100 + "type": 103 }, "selector": "0x3b83b256" }, @@ -1550,7 +1550,7 @@ "displayName": [ "Vec" ], - "type": 103 + "type": 106 } } ], @@ -1564,7 +1564,7 @@ "ink", "MessageResult" ], - "type": 104 + "type": 107 }, "selector": "0x8ef8d345" }, @@ -1590,7 +1590,7 @@ "ink", "MessageResult" ], - "type": 108 + "type": 111 }, "selector": "0xd842f034" }, @@ -1634,7 +1634,7 @@ "ink", "MessageResult" ], - "type": 109 + "type": 112 }, "selector": "0xf360dea7" }, @@ -1660,7 +1660,7 @@ "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x06099ca3" } @@ -2405,6 +2405,41 @@ } }, "name": "protocol_fee" + }, + { + "layout": { + "struct": { + "fields": [ + { + "layout": { + "struct": { + "fields": [ + { + "layout": { + "array": { + "layout": { + "leaf": { + "key": "0x00000000", + "ty": 9 + } + }, + "len": 4, + "offset": "0x00000000" + } + }, + "name": "0" + } + ], + "name": "U256T" + } + }, + "name": "0" + } + ], + "name": "PocType" + } + }, + "name": "poc_field" } ], "name": "InvariantConfig" @@ -3641,6 +3676,11 @@ "name": "protocol_fee", "type": 18, "typeName": ",>>::Type" + }, + { + "name": "poc_field", + "type": 54, + "typeName": ",>>::Type" } ] } @@ -3656,6 +3696,61 @@ }, { "id": 54, + "type": { + "def": { + "composite": { + "fields": [ + { + "type": 55, + "typeName": "U256T" + } + ] + } + }, + "path": [ + "invariant", + "contracts", + "storage", + "invariant_config", + "PocType" + ] + } + }, + { + "id": 55, + "type": { + "def": { + "composite": { + "fields": [ + { + "type": 56, + "typeName": "[u64; 4]" + } + ] + } + }, + "path": [ + "invariant", + "contracts", + "storage", + "invariant_config", + "U256T" + ] + } + }, + { + "id": 56, + "type": { + "def": { + "array": { + "len": 4, + "type": 9 + } + } + } + }, + { + "id": 57, "type": { "def": { "variant": { @@ -3672,7 +3767,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -3688,7 +3783,7 @@ }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -3697,7 +3792,7 @@ } }, { - "id": 55, + "id": 58, "type": { "def": { "variant": { @@ -3716,7 +3811,7 @@ } }, { - "id": 56, + "id": 59, "type": { "def": { "variant": { @@ -3733,7 +3828,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -3749,7 +3844,7 @@ }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -3758,7 +3853,7 @@ } }, { - "id": 57, + "id": 60, "type": { "def": { "variant": { @@ -3766,7 +3861,7 @@ { "fields": [ { - "type": 58 + "type": 61 } ], "index": 0, @@ -3775,7 +3870,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -3787,11 +3882,11 @@ "params": [ { "name": "T", - "type": 58 + "type": 61 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -3800,7 +3895,7 @@ } }, { - "id": 58, + "id": 61, "type": { "def": { "variant": { @@ -3817,7 +3912,7 @@ { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -3833,7 +3928,7 @@ }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -3842,7 +3937,7 @@ } }, { - "id": 59, + "id": 62, "type": { "def": { "variant": { @@ -4015,7 +4110,7 @@ } }, { - "id": 60, + "id": 63, "type": { "def": { "variant": { @@ -4023,7 +4118,7 @@ { "fields": [ { - "type": 61 + "type": 64 } ], "index": 0, @@ -4032,7 +4127,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4044,11 +4139,11 @@ "params": [ { "name": "T", - "type": 61 + "type": 64 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4057,7 +4152,7 @@ } }, { - "id": 61, + "id": 64, "type": { "def": { "variant": { @@ -4074,7 +4169,7 @@ { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4090,7 +4185,7 @@ }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4099,7 +4194,7 @@ } }, { - "id": 62, + "id": 65, "type": { "def": { "variant": { @@ -4107,7 +4202,7 @@ { "fields": [ { - "type": 63 + "type": 66 } ], "index": 0, @@ -4116,7 +4211,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4128,11 +4223,11 @@ "params": [ { "name": "T", - "type": 63 + "type": 66 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4141,7 +4236,7 @@ } }, { - "id": 63, + "id": 66, "type": { "def": { "variant": { @@ -4149,7 +4244,7 @@ { "fields": [ { - "type": 64 + "type": 67 } ], "index": 0, @@ -4158,7 +4253,7 @@ { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4170,11 +4265,11 @@ "params": [ { "name": "T", - "type": 64 + "type": 67 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4183,7 +4278,7 @@ } }, { - "id": 64, + "id": 67, "type": { "def": { "composite": { @@ -4220,7 +4315,7 @@ }, { "name": "ticks", - "type": 65, + "type": 68, "typeName": "Vec" } ] @@ -4235,7 +4330,7 @@ } }, { - "id": 65, + "id": 68, "type": { "def": { "sequence": { @@ -4245,17 +4340,17 @@ } }, { - "id": 66, + "id": 69, "type": { "def": { "sequence": { - "type": 67 + "type": 70 } } } }, { - "id": 67, + "id": 70, "type": { "def": { "composite": { @@ -4282,7 +4377,7 @@ } }, { - "id": 68, + "id": 71, "type": { "def": { "variant": { @@ -4290,7 +4385,7 @@ { "fields": [ { - "type": 69 + "type": 72 } ], "index": 0, @@ -4299,7 +4394,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4311,11 +4406,11 @@ "params": [ { "name": "T", - "type": 69 + "type": 72 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4324,7 +4419,7 @@ } }, { - "id": 69, + "id": 72, "type": { "def": { "variant": { @@ -4332,7 +4427,7 @@ { "fields": [ { - "type": 70 + "type": 73 } ], "index": 0, @@ -4341,7 +4436,7 @@ { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4353,11 +4448,11 @@ "params": [ { "name": "T", - "type": 70 + "type": 73 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4366,7 +4461,7 @@ } }, { - "id": 70, + "id": 73, "type": { "def": { "composite": { @@ -4388,7 +4483,7 @@ }, { "name": "ticks", - "type": 65, + "type": 68, "typeName": "Vec" } ] @@ -4403,7 +4498,7 @@ } }, { - "id": 71, + "id": 74, "type": { "def": { "variant": { @@ -4411,7 +4506,7 @@ { "fields": [ { - "type": 72 + "type": 75 } ], "index": 0, @@ -4420,7 +4515,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4432,11 +4527,11 @@ "params": [ { "name": "T", - "type": 72 + "type": 75 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4445,7 +4540,7 @@ } }, { - "id": 72, + "id": 75, "type": { "def": { "variant": { @@ -4462,7 +4557,7 @@ { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4478,7 +4573,7 @@ }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4487,7 +4582,7 @@ } }, { - "id": 73, + "id": 76, "type": { "def": { "variant": { @@ -4495,7 +4590,7 @@ { "fields": [ { - "type": 74 + "type": 77 } ], "index": 0, @@ -4504,7 +4599,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4516,11 +4611,11 @@ "params": [ { "name": "T", - "type": 74 + "type": 77 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4529,7 +4624,7 @@ } }, { - "id": 74, + "id": 77, "type": { "def": { "sequence": { @@ -4539,7 +4634,7 @@ } }, { - "id": 75, + "id": 78, "type": { "def": { "variant": { @@ -4547,7 +4642,7 @@ { "fields": [ { - "type": 76 + "type": 79 } ], "index": 0, @@ -4556,7 +4651,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4568,11 +4663,11 @@ "params": [ { "name": "T", - "type": 76 + "type": 79 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4581,7 +4676,7 @@ } }, { - "id": 76, + "id": 79, "type": { "def": { "variant": { @@ -4589,7 +4684,7 @@ { "fields": [ { - "type": 77 + "type": 80 } ], "index": 0, @@ -4598,7 +4693,7 @@ { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4610,11 +4705,11 @@ "params": [ { "name": "T", - "type": 77 + "type": 80 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4623,28 +4718,28 @@ } }, { - "id": 77, + "id": 80, "type": { "def": { "tuple": [ - 78, + 81, 0 ] } } }, { - "id": 78, + "id": 81, "type": { "def": { "sequence": { - "type": 79 + "type": 82 } } } }, { - "id": 79, + "id": 82, "type": { "def": { "tuple": [ @@ -4657,7 +4752,7 @@ } }, { - "id": 80, + "id": 83, "type": { "def": { "variant": { @@ -4665,7 +4760,7 @@ { "fields": [ { - "type": 81 + "type": 84 } ], "index": 0, @@ -4674,7 +4769,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4686,11 +4781,11 @@ "params": [ { "name": "T", - "type": 81 + "type": 84 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4699,7 +4794,7 @@ } }, { - "id": 81, + "id": 84, "type": { "def": { "variant": { @@ -4707,7 +4802,7 @@ { "fields": [ { - "type": 82 + "type": 85 } ], "index": 0, @@ -4716,7 +4811,7 @@ { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4728,11 +4823,11 @@ "params": [ { "name": "T", - "type": 82 + "type": 85 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4741,7 +4836,7 @@ } }, { - "id": 82, + "id": 85, "type": { "def": { "tuple": [ @@ -4752,7 +4847,7 @@ } }, { - "id": 83, + "id": 86, "type": { "def": { "variant": { @@ -4769,7 +4864,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4785,7 +4880,7 @@ }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4794,7 +4889,7 @@ } }, { - "id": 84, + "id": 87, "type": { "def": { "variant": { @@ -4802,7 +4897,7 @@ { "fields": [ { - "type": 85 + "type": 88 } ], "index": 0, @@ -4811,7 +4906,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4823,11 +4918,11 @@ "params": [ { "name": "T", - "type": 85 + "type": 88 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4836,7 +4931,7 @@ } }, { - "id": 85, + "id": 88, "type": { "def": { "variant": { @@ -4853,7 +4948,7 @@ { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4869,7 +4964,7 @@ }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4878,7 +4973,7 @@ } }, { - "id": 86, + "id": 89, "type": { "def": { "variant": { @@ -4886,7 +4981,7 @@ { "fields": [ { - "type": 87 + "type": 90 } ], "index": 0, @@ -4895,7 +4990,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4907,11 +5002,11 @@ "params": [ { "name": "T", - "type": 87 + "type": 90 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4920,7 +5015,7 @@ } }, { - "id": 87, + "id": 90, "type": { "def": { "variant": { @@ -4928,7 +5023,7 @@ { "fields": [ { - "type": 88 + "type": 91 } ], "index": 0, @@ -4937,7 +5032,7 @@ { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4949,11 +5044,11 @@ "params": [ { "name": "T", - "type": 88 + "type": 91 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4962,17 +5057,17 @@ } }, { - "id": 88, + "id": 91, "type": { "def": { "sequence": { - "type": 89 + "type": 92 } } } }, { - "id": 89, + "id": 92, "type": { "def": { "tuple": [ @@ -4983,7 +5078,7 @@ } }, { - "id": 90, + "id": 93, "type": { "def": { "variant": { @@ -4991,7 +5086,7 @@ { "fields": [ { - "type": 91 + "type": 94 } ], "index": 0, @@ -5000,7 +5095,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5012,11 +5107,11 @@ "params": [ { "name": "T", - "type": 91 + "type": 94 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5025,7 +5120,7 @@ } }, { - "id": 91, + "id": 94, "type": { "def": { "variant": { @@ -5042,7 +5137,7 @@ { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -5058,7 +5153,7 @@ }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -5067,7 +5162,7 @@ } }, { - "id": 92, + "id": 95, "type": { "def": { "variant": { @@ -5075,7 +5170,7 @@ { "fields": [ { - "type": 93 + "type": 96 } ], "index": 0, @@ -5084,7 +5179,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5096,11 +5191,11 @@ "params": [ { "name": "T", - "type": 93 + "type": 96 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5109,7 +5204,7 @@ } }, { - "id": 93, + "id": 96, "type": { "def": { "variant": { @@ -5117,7 +5212,7 @@ { "fields": [ { - "type": 94 + "type": 97 } ], "index": 0, @@ -5126,7 +5221,7 @@ { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -5138,11 +5233,11 @@ "params": [ { "name": "T", - "type": 94 + "type": 97 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -5151,18 +5246,18 @@ } }, { - "id": 94, + "id": 97, "type": { "def": { "tuple": [ - 95, + 98, 10 ] } } }, { - "id": 95, + "id": 98, "type": { "def": { "sequence": { @@ -5172,7 +5267,7 @@ } }, { - "id": 96, + "id": 99, "type": { "def": { "variant": { @@ -5189,7 +5284,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5205,7 +5300,7 @@ }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5214,7 +5309,7 @@ } }, { - "id": 97, + "id": 100, "type": { "def": { "variant": { @@ -5222,7 +5317,7 @@ { "fields": [ { - "type": 98 + "type": 101 } ], "index": 0, @@ -5231,7 +5326,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5243,11 +5338,11 @@ "params": [ { "name": "T", - "type": 98 + "type": 101 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5256,17 +5351,17 @@ } }, { - "id": 98, + "id": 101, "type": { "def": { "sequence": { - "type": 99 + "type": 102 } } } }, { - "id": 99, + "id": 102, "type": { "def": { "composite": { @@ -5304,7 +5399,7 @@ } }, { - "id": 100, + "id": 103, "type": { "def": { "variant": { @@ -5312,7 +5407,7 @@ { "fields": [ { - "type": 101 + "type": 104 } ], "index": 0, @@ -5321,7 +5416,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5333,11 +5428,11 @@ "params": [ { "name": "T", - "type": 101 + "type": 104 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5346,17 +5441,17 @@ } }, { - "id": 101, + "id": 104, "type": { "def": { "sequence": { - "type": 102 + "type": 105 } } } }, { - "id": 102, + "id": 105, "type": { "def": { "tuple": [ @@ -5367,7 +5462,7 @@ } }, { - "id": 103, + "id": 106, "type": { "def": { "sequence": { @@ -5377,7 +5472,7 @@ } }, { - "id": 104, + "id": 107, "type": { "def": { "variant": { @@ -5385,7 +5480,7 @@ { "fields": [ { - "type": 105 + "type": 108 } ], "index": 0, @@ -5394,7 +5489,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5406,11 +5501,11 @@ "params": [ { "name": "T", - "type": 105 + "type": 108 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5419,7 +5514,7 @@ } }, { - "id": 105, + "id": 108, "type": { "def": { "variant": { @@ -5427,7 +5522,7 @@ { "fields": [ { - "type": 106 + "type": 109 } ], "index": 0, @@ -5436,7 +5531,7 @@ { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -5448,11 +5543,11 @@ "params": [ { "name": "T", - "type": 106 + "type": 109 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -5461,17 +5556,17 @@ } }, { - "id": 106, + "id": 109, "type": { "def": { "sequence": { - "type": 107 + "type": 110 } } } }, { - "id": 107, + "id": 110, "type": { "def": { "composite": { @@ -5504,7 +5599,7 @@ } }, { - "id": 108, + "id": 111, "type": { "def": { "variant": { @@ -5521,7 +5616,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5537,7 +5632,7 @@ }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5546,7 +5641,7 @@ } }, { - "id": 109, + "id": 112, "type": { "def": { "variant": { @@ -5554,7 +5649,7 @@ { "fields": [ { - "type": 110 + "type": 113 } ], "index": 0, @@ -5563,7 +5658,7 @@ { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5575,11 +5670,11 @@ "params": [ { "name": "T", - "type": 110 + "type": 113 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5588,7 +5683,7 @@ } }, { - "id": 110, + "id": 113, "type": { "def": { "variant": { @@ -5605,7 +5700,7 @@ { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -5621,7 +5716,7 @@ }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -5630,7 +5725,7 @@ } }, { - "id": 111, + "id": 114, "type": { "def": { "variant": { @@ -5663,7 +5758,7 @@ } }, { - "id": 112, + "id": 115, "type": { "def": { "composite": { @@ -5683,7 +5778,7 @@ } }, { - "id": 113, + "id": 116, "type": { "def": { "variant": {} diff --git a/sdk/contracts/invariant/invariant.wasm b/sdk/contracts/invariant/invariant.wasm index 98751cd2470b67479ca399f42d9c386d30e871b2..3dca2c15c10d360cf2b614a6adf66e175250b83e 100644 GIT binary patch delta 33564 zcmc(I3w&KwmG{}_-kW=KAIWXgrb(Kl=ia1w^p&JdleDF6POvYEP#!AETR}>SR1g87 z!wp&>LWRIVPQ(HMibS4~01Z+kFhv4Zj8L^`)u6@cH=@KDW~fdFzW;ykv(LS0E6U6_ z-@vaqXRos#Yp=atd#!!W?YSp>!@c32Es0&h^hP=G>XH95ipFH5pu3H{~>>TC=|;W_8UWv2+TEi>>F$h zY!8WUXMd#992;^X`InmGPdHuq-zZO8hHZ6PB8i*&Ks!n!MrVUC06EtAN}`R`pGjQE z>T?U`i%RFLf-3yoTyP@({;VK{zke>U@VBh6LR1d66<%br$%B)wWRtqdi;Asu(0*TB zWSc7!re)gujZQ0&taL7$oJOnLC$ong^6#%Eqo2X|Czpz;J4`c_5m!|ic3)sa+N?Iv z@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NAqG&jGIddpHZ2)L&Rcf*uv>Mo%Du9noURR$-zmIr38B)2Z@eDB)O^N$ce` z+8qhgxHrwdCGRI2ZjXHD{pHeDk6eN&*UKs3DD70vbL-}@SJ@#R%o8yl_^#4&!Fd}k zt5+r0FYz~=^B?eyO~1m?t^P9X-fMzY#?q9od3%L7y~1>@9^}CGxTHuKq-B3i)lUihnI;jZ**s diff --git a/sdk/src/abis/invariant.ts b/sdk/src/abis/invariant.ts index 164539be..5a1f2389 100644 --- a/sdk/src/abis/invariant.ts +++ b/sdk/src/abis/invariant.ts @@ -1,7 +1,7 @@ export const abi = ` { "source": { - "hash": "0x86f442ed070586bbb8157cda6fdc259b84f953e62727d779806988f81937cd1f", + "hash": "0xf1173d8a30aa5cb75a057960692ea174fa6eac1c0209d5d1ba5d16d810939697", "language": "ink! 5.0.0", "compiler": "rustc 1.77.0", "build_info": { @@ -45,7 +45,7 @@ export const abi = ` "ink_primitives", "ConstructorResult" ], - "type": 54 + "type": 57 }, "selector": "0x9bae9d5e" } @@ -74,13 +74,13 @@ export const abi = ` "displayName": [ "ChainExtension" ], - "type": 113 + "type": 116 }, "hash": { "displayName": [ "Hash" ], - "type": 112 + "type": 115 }, "maxEventTopics": 4, "staticBufferSize": 16384, @@ -220,7 +220,7 @@ export const abi = ` "displayName": [ "Vec" ], - "type": 103 + "type": 106 } } ], @@ -482,7 +482,7 @@ export const abi = ` "displayName": [ "Option" ], - "type": 111 + "type": 114 } }, { @@ -495,7 +495,7 @@ export const abi = ` "displayName": [ "Option" ], - "type": 111 + "type": 114 } }, { @@ -525,7 +525,7 @@ export const abi = ` "ink", "LangError" ], - "type": 55 + "type": 58 }, "messages": [ { @@ -540,7 +540,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 56 + "type": 59 }, "selector": "0xe285b69a" }, @@ -566,7 +566,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x5a059796" }, @@ -592,7 +592,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0xc8bd0f58" }, @@ -627,7 +627,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x0ebd3ec6" }, @@ -698,7 +698,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 60 + "type": 63 }, "selector": "0x0a1ca76b" }, @@ -760,7 +760,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 62 + "type": 65 }, "selector": "0x1c590004" }, @@ -799,7 +799,7 @@ export const abi = ` "displayName": [ "Vec" ], - "type": 66 + "type": 69 } } ], @@ -813,7 +813,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x5ff8d655" }, @@ -875,7 +875,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 68 + "type": 71 }, "selector": "0xa2bd3fc7" }, @@ -896,7 +896,7 @@ export const abi = ` "displayName": [ "Vec" ], - "type": 66 + "type": 69 } } ], @@ -910,7 +910,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 71 + "type": 74 }, "selector": "0x879b5256" }, @@ -945,7 +945,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0xe5af145a" }, @@ -980,7 +980,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 60 + "type": 63 }, "selector": "0xccb84930" }, @@ -1006,7 +1006,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 73 + "type": 76 }, "selector": "0xa509d69f" }, @@ -1050,7 +1050,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 75 + "type": 78 }, "selector": "0xb2155f6b" }, @@ -1076,7 +1076,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 80 + "type": 83 }, "selector": "0x4eb580e1" }, @@ -1102,7 +1102,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 80 + "type": 83 }, "selector": "0xfe63d239" }, @@ -1128,7 +1128,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x009b6a3d" }, @@ -1154,7 +1154,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x3b497d6e" }, @@ -1180,7 +1180,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 83 + "type": 86 }, "selector": "0x4e9e07ce" }, @@ -1242,7 +1242,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x98b595e9" }, @@ -1286,7 +1286,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 84 + "type": 87 }, "selector": "0xf91e4a49" }, @@ -1321,7 +1321,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 86 + "type": 89 }, "selector": "0xb62aa10d" }, @@ -1356,7 +1356,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 90 + "type": 93 }, "selector": "0xeebd620b" }, @@ -1391,7 +1391,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 83 + "type": 86 }, "selector": "0xdbae15e5" }, @@ -1426,7 +1426,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 92 + "type": 95 }, "selector": "0x6dd2d776" }, @@ -1442,7 +1442,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 96 + "type": 99 }, "selector": "0xd05b6003" }, @@ -1477,7 +1477,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 97 + "type": 100 }, "selector": "0xcc9476e7" }, @@ -1530,7 +1530,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 100 + "type": 103 }, "selector": "0x3b83b256" }, @@ -1551,7 +1551,7 @@ export const abi = ` "displayName": [ "Vec" ], - "type": 103 + "type": 106 } } ], @@ -1565,7 +1565,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 104 + "type": 107 }, "selector": "0x8ef8d345" }, @@ -1591,7 +1591,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 108 + "type": 111 }, "selector": "0xd842f034" }, @@ -1635,7 +1635,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 109 + "type": 112 }, "selector": "0xf360dea7" }, @@ -1661,7 +1661,7 @@ export const abi = ` "ink", "MessageResult" ], - "type": 57 + "type": 60 }, "selector": "0x06099ca3" } @@ -2406,6 +2406,41 @@ export const abi = ` } }, "name": "protocol_fee" + }, + { + "layout": { + "struct": { + "fields": [ + { + "layout": { + "struct": { + "fields": [ + { + "layout": { + "array": { + "layout": { + "leaf": { + "key": "0x00000000", + "ty": 9 + } + }, + "len": 4, + "offset": "0x00000000" + } + }, + "name": "0" + } + ], + "name": "U256T" + } + }, + "name": "0" + } + ], + "name": "PocType" + } + }, + "name": "poc_field" } ], "name": "InvariantConfig" @@ -3642,6 +3677,11 @@ export const abi = ` "name": "protocol_fee", "type": 18, "typeName": ",>>::Type" + }, + { + "name": "poc_field", + "type": 54, + "typeName": ",>>::Type" } ] } @@ -3657,6 +3697,61 @@ export const abi = ` }, { "id": 54, + "type": { + "def": { + "composite": { + "fields": [ + { + "type": 55, + "typeName": "U256T" + } + ] + } + }, + "path": [ + "invariant", + "contracts", + "storage", + "invariant_config", + "PocType" + ] + } + }, + { + "id": 55, + "type": { + "def": { + "composite": { + "fields": [ + { + "type": 56, + "typeName": "[u64; 4]" + } + ] + } + }, + "path": [ + "invariant", + "contracts", + "storage", + "invariant_config", + "U256T" + ] + } + }, + { + "id": 56, + "type": { + "def": { + "array": { + "len": 4, + "type": 9 + } + } + } + }, + { + "id": 57, "type": { "def": { "variant": { @@ -3673,7 +3768,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -3689,7 +3784,7 @@ export const abi = ` }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -3698,7 +3793,7 @@ export const abi = ` } }, { - "id": 55, + "id": 58, "type": { "def": { "variant": { @@ -3717,7 +3812,7 @@ export const abi = ` } }, { - "id": 56, + "id": 59, "type": { "def": { "variant": { @@ -3734,7 +3829,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -3750,7 +3845,7 @@ export const abi = ` }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -3759,7 +3854,7 @@ export const abi = ` } }, { - "id": 57, + "id": 60, "type": { "def": { "variant": { @@ -3767,7 +3862,7 @@ export const abi = ` { "fields": [ { - "type": 58 + "type": 61 } ], "index": 0, @@ -3776,7 +3871,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -3788,11 +3883,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 58 + "type": 61 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -3801,7 +3896,7 @@ export const abi = ` } }, { - "id": 58, + "id": 61, "type": { "def": { "variant": { @@ -3818,7 +3913,7 @@ export const abi = ` { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -3834,7 +3929,7 @@ export const abi = ` }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -3843,7 +3938,7 @@ export const abi = ` } }, { - "id": 59, + "id": 62, "type": { "def": { "variant": { @@ -4016,7 +4111,7 @@ export const abi = ` } }, { - "id": 60, + "id": 63, "type": { "def": { "variant": { @@ -4024,7 +4119,7 @@ export const abi = ` { "fields": [ { - "type": 61 + "type": 64 } ], "index": 0, @@ -4033,7 +4128,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4045,11 +4140,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 61 + "type": 64 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4058,7 +4153,7 @@ export const abi = ` } }, { - "id": 61, + "id": 64, "type": { "def": { "variant": { @@ -4075,7 +4170,7 @@ export const abi = ` { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4091,7 +4186,7 @@ export const abi = ` }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4100,7 +4195,7 @@ export const abi = ` } }, { - "id": 62, + "id": 65, "type": { "def": { "variant": { @@ -4108,7 +4203,7 @@ export const abi = ` { "fields": [ { - "type": 63 + "type": 66 } ], "index": 0, @@ -4117,7 +4212,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4129,11 +4224,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 63 + "type": 66 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4142,7 +4237,7 @@ export const abi = ` } }, { - "id": 63, + "id": 66, "type": { "def": { "variant": { @@ -4150,7 +4245,7 @@ export const abi = ` { "fields": [ { - "type": 64 + "type": 67 } ], "index": 0, @@ -4159,7 +4254,7 @@ export const abi = ` { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4171,11 +4266,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 64 + "type": 67 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4184,7 +4279,7 @@ export const abi = ` } }, { - "id": 64, + "id": 67, "type": { "def": { "composite": { @@ -4221,7 +4316,7 @@ export const abi = ` }, { "name": "ticks", - "type": 65, + "type": 68, "typeName": "Vec" } ] @@ -4236,7 +4331,7 @@ export const abi = ` } }, { - "id": 65, + "id": 68, "type": { "def": { "sequence": { @@ -4246,17 +4341,17 @@ export const abi = ` } }, { - "id": 66, + "id": 69, "type": { "def": { "sequence": { - "type": 67 + "type": 70 } } } }, { - "id": 67, + "id": 70, "type": { "def": { "composite": { @@ -4283,7 +4378,7 @@ export const abi = ` } }, { - "id": 68, + "id": 71, "type": { "def": { "variant": { @@ -4291,7 +4386,7 @@ export const abi = ` { "fields": [ { - "type": 69 + "type": 72 } ], "index": 0, @@ -4300,7 +4395,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4312,11 +4407,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 69 + "type": 72 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4325,7 +4420,7 @@ export const abi = ` } }, { - "id": 69, + "id": 72, "type": { "def": { "variant": { @@ -4333,7 +4428,7 @@ export const abi = ` { "fields": [ { - "type": 70 + "type": 73 } ], "index": 0, @@ -4342,7 +4437,7 @@ export const abi = ` { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4354,11 +4449,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 70 + "type": 73 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4367,7 +4462,7 @@ export const abi = ` } }, { - "id": 70, + "id": 73, "type": { "def": { "composite": { @@ -4389,7 +4484,7 @@ export const abi = ` }, { "name": "ticks", - "type": 65, + "type": 68, "typeName": "Vec" } ] @@ -4404,7 +4499,7 @@ export const abi = ` } }, { - "id": 71, + "id": 74, "type": { "def": { "variant": { @@ -4412,7 +4507,7 @@ export const abi = ` { "fields": [ { - "type": 72 + "type": 75 } ], "index": 0, @@ -4421,7 +4516,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4433,11 +4528,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 72 + "type": 75 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4446,7 +4541,7 @@ export const abi = ` } }, { - "id": 72, + "id": 75, "type": { "def": { "variant": { @@ -4463,7 +4558,7 @@ export const abi = ` { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4479,7 +4574,7 @@ export const abi = ` }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4488,7 +4583,7 @@ export const abi = ` } }, { - "id": 73, + "id": 76, "type": { "def": { "variant": { @@ -4496,7 +4591,7 @@ export const abi = ` { "fields": [ { - "type": 74 + "type": 77 } ], "index": 0, @@ -4505,7 +4600,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4517,11 +4612,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 74 + "type": 77 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4530,7 +4625,7 @@ export const abi = ` } }, { - "id": 74, + "id": 77, "type": { "def": { "sequence": { @@ -4540,7 +4635,7 @@ export const abi = ` } }, { - "id": 75, + "id": 78, "type": { "def": { "variant": { @@ -4548,7 +4643,7 @@ export const abi = ` { "fields": [ { - "type": 76 + "type": 79 } ], "index": 0, @@ -4557,7 +4652,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4569,11 +4664,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 76 + "type": 79 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4582,7 +4677,7 @@ export const abi = ` } }, { - "id": 76, + "id": 79, "type": { "def": { "variant": { @@ -4590,7 +4685,7 @@ export const abi = ` { "fields": [ { - "type": 77 + "type": 80 } ], "index": 0, @@ -4599,7 +4694,7 @@ export const abi = ` { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4611,11 +4706,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 77 + "type": 80 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4624,28 +4719,28 @@ export const abi = ` } }, { - "id": 77, + "id": 80, "type": { "def": { "tuple": [ - 78, + 81, 0 ] } } }, { - "id": 78, + "id": 81, "type": { "def": { "sequence": { - "type": 79 + "type": 82 } } } }, { - "id": 79, + "id": 82, "type": { "def": { "tuple": [ @@ -4658,7 +4753,7 @@ export const abi = ` } }, { - "id": 80, + "id": 83, "type": { "def": { "variant": { @@ -4666,7 +4761,7 @@ export const abi = ` { "fields": [ { - "type": 81 + "type": 84 } ], "index": 0, @@ -4675,7 +4770,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4687,11 +4782,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 81 + "type": 84 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4700,7 +4795,7 @@ export const abi = ` } }, { - "id": 81, + "id": 84, "type": { "def": { "variant": { @@ -4708,7 +4803,7 @@ export const abi = ` { "fields": [ { - "type": 82 + "type": 85 } ], "index": 0, @@ -4717,7 +4812,7 @@ export const abi = ` { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4729,11 +4824,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 82 + "type": 85 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4742,7 +4837,7 @@ export const abi = ` } }, { - "id": 82, + "id": 85, "type": { "def": { "tuple": [ @@ -4753,7 +4848,7 @@ export const abi = ` } }, { - "id": 83, + "id": 86, "type": { "def": { "variant": { @@ -4770,7 +4865,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4786,7 +4881,7 @@ export const abi = ` }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4795,7 +4890,7 @@ export const abi = ` } }, { - "id": 84, + "id": 87, "type": { "def": { "variant": { @@ -4803,7 +4898,7 @@ export const abi = ` { "fields": [ { - "type": 85 + "type": 88 } ], "index": 0, @@ -4812,7 +4907,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4824,11 +4919,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 85 + "type": 88 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4837,7 +4932,7 @@ export const abi = ` } }, { - "id": 85, + "id": 88, "type": { "def": { "variant": { @@ -4854,7 +4949,7 @@ export const abi = ` { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4870,7 +4965,7 @@ export const abi = ` }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4879,7 +4974,7 @@ export const abi = ` } }, { - "id": 86, + "id": 89, "type": { "def": { "variant": { @@ -4887,7 +4982,7 @@ export const abi = ` { "fields": [ { - "type": 87 + "type": 90 } ], "index": 0, @@ -4896,7 +4991,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -4908,11 +5003,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 87 + "type": 90 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -4921,7 +5016,7 @@ export const abi = ` } }, { - "id": 87, + "id": 90, "type": { "def": { "variant": { @@ -4929,7 +5024,7 @@ export const abi = ` { "fields": [ { - "type": 88 + "type": 91 } ], "index": 0, @@ -4938,7 +5033,7 @@ export const abi = ` { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -4950,11 +5045,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 88 + "type": 91 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -4963,17 +5058,17 @@ export const abi = ` } }, { - "id": 88, + "id": 91, "type": { "def": { "sequence": { - "type": 89 + "type": 92 } } } }, { - "id": 89, + "id": 92, "type": { "def": { "tuple": [ @@ -4984,7 +5079,7 @@ export const abi = ` } }, { - "id": 90, + "id": 93, "type": { "def": { "variant": { @@ -4992,7 +5087,7 @@ export const abi = ` { "fields": [ { - "type": 91 + "type": 94 } ], "index": 0, @@ -5001,7 +5096,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5013,11 +5108,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 91 + "type": 94 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5026,7 +5121,7 @@ export const abi = ` } }, { - "id": 91, + "id": 94, "type": { "def": { "variant": { @@ -5043,7 +5138,7 @@ export const abi = ` { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -5059,7 +5154,7 @@ export const abi = ` }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -5068,7 +5163,7 @@ export const abi = ` } }, { - "id": 92, + "id": 95, "type": { "def": { "variant": { @@ -5076,7 +5171,7 @@ export const abi = ` { "fields": [ { - "type": 93 + "type": 96 } ], "index": 0, @@ -5085,7 +5180,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5097,11 +5192,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 93 + "type": 96 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5110,7 +5205,7 @@ export const abi = ` } }, { - "id": 93, + "id": 96, "type": { "def": { "variant": { @@ -5118,7 +5213,7 @@ export const abi = ` { "fields": [ { - "type": 94 + "type": 97 } ], "index": 0, @@ -5127,7 +5222,7 @@ export const abi = ` { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -5139,11 +5234,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 94 + "type": 97 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -5152,18 +5247,18 @@ export const abi = ` } }, { - "id": 94, + "id": 97, "type": { "def": { "tuple": [ - 95, + 98, 10 ] } } }, { - "id": 95, + "id": 98, "type": { "def": { "sequence": { @@ -5173,7 +5268,7 @@ export const abi = ` } }, { - "id": 96, + "id": 99, "type": { "def": { "variant": { @@ -5190,7 +5285,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5206,7 +5301,7 @@ export const abi = ` }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5215,7 +5310,7 @@ export const abi = ` } }, { - "id": 97, + "id": 100, "type": { "def": { "variant": { @@ -5223,7 +5318,7 @@ export const abi = ` { "fields": [ { - "type": 98 + "type": 101 } ], "index": 0, @@ -5232,7 +5327,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5244,11 +5339,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 98 + "type": 101 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5257,17 +5352,17 @@ export const abi = ` } }, { - "id": 98, + "id": 101, "type": { "def": { "sequence": { - "type": 99 + "type": 102 } } } }, { - "id": 99, + "id": 102, "type": { "def": { "composite": { @@ -5305,7 +5400,7 @@ export const abi = ` } }, { - "id": 100, + "id": 103, "type": { "def": { "variant": { @@ -5313,7 +5408,7 @@ export const abi = ` { "fields": [ { - "type": 101 + "type": 104 } ], "index": 0, @@ -5322,7 +5417,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5334,11 +5429,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 101 + "type": 104 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5347,17 +5442,17 @@ export const abi = ` } }, { - "id": 101, + "id": 104, "type": { "def": { "sequence": { - "type": 102 + "type": 105 } } } }, { - "id": 102, + "id": 105, "type": { "def": { "tuple": [ @@ -5368,7 +5463,7 @@ export const abi = ` } }, { - "id": 103, + "id": 106, "type": { "def": { "sequence": { @@ -5378,7 +5473,7 @@ export const abi = ` } }, { - "id": 104, + "id": 107, "type": { "def": { "variant": { @@ -5386,7 +5481,7 @@ export const abi = ` { "fields": [ { - "type": 105 + "type": 108 } ], "index": 0, @@ -5395,7 +5490,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5407,11 +5502,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 105 + "type": 108 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5420,7 +5515,7 @@ export const abi = ` } }, { - "id": 105, + "id": 108, "type": { "def": { "variant": { @@ -5428,7 +5523,7 @@ export const abi = ` { "fields": [ { - "type": 106 + "type": 109 } ], "index": 0, @@ -5437,7 +5532,7 @@ export const abi = ` { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -5449,11 +5544,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 106 + "type": 109 }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -5462,17 +5557,17 @@ export const abi = ` } }, { - "id": 106, + "id": 109, "type": { "def": { "sequence": { - "type": 107 + "type": 110 } } } }, { - "id": 107, + "id": 110, "type": { "def": { "composite": { @@ -5505,7 +5600,7 @@ export const abi = ` } }, { - "id": 108, + "id": 111, "type": { "def": { "variant": { @@ -5522,7 +5617,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5538,7 +5633,7 @@ export const abi = ` }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5547,7 +5642,7 @@ export const abi = ` } }, { - "id": 109, + "id": 112, "type": { "def": { "variant": { @@ -5555,7 +5650,7 @@ export const abi = ` { "fields": [ { - "type": 110 + "type": 113 } ], "index": 0, @@ -5564,7 +5659,7 @@ export const abi = ` { "fields": [ { - "type": 55 + "type": 58 } ], "index": 1, @@ -5576,11 +5671,11 @@ export const abi = ` "params": [ { "name": "T", - "type": 110 + "type": 113 }, { "name": "E", - "type": 55 + "type": 58 } ], "path": [ @@ -5589,7 +5684,7 @@ export const abi = ` } }, { - "id": 110, + "id": 113, "type": { "def": { "variant": { @@ -5606,7 +5701,7 @@ export const abi = ` { "fields": [ { - "type": 59 + "type": 62 } ], "index": 1, @@ -5622,7 +5717,7 @@ export const abi = ` }, { "name": "E", - "type": 59 + "type": 62 } ], "path": [ @@ -5631,7 +5726,7 @@ export const abi = ` } }, { - "id": 111, + "id": 114, "type": { "def": { "variant": { @@ -5664,7 +5759,7 @@ export const abi = ` } }, { - "id": 112, + "id": 115, "type": { "def": { "composite": { @@ -5684,7 +5779,7 @@ export const abi = ` } }, { - "id": 113, + "id": 116, "type": { "def": { "variant": {} diff --git a/sdk/src/abis/psp22.ts b/sdk/src/abis/psp22.ts index 5e314bf1..5c9af541 100644 --- a/sdk/src/abis/psp22.ts +++ b/sdk/src/abis/psp22.ts @@ -1,7 +1,7 @@ export const abi = ` { "source": { - "hash": "0xb4082b7d4aedb8479925aa96a383ea722dc1a7e9b29ad5a4d5f95ad707db4e09", + "hash": "0xb4a6778b80073e24c68d7aafad474beed429019761b4e2ba5786359aede38ed7", "language": "ink! 5.0.0", "compiler": "rustc 1.77.0", "build_info": { diff --git a/sdk/src/poc-u256.ts b/sdk/src/poc-u256.ts new file mode 100644 index 00000000..9b201988 --- /dev/null +++ b/sdk/src/poc-u256.ts @@ -0,0 +1,13 @@ +import { assert } from 'chai' +import { receiveBigType } from './wasm/pkg/invariant_a0_wasm.js' + +const main = async () => { + const u128Max = BigInt('0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF') + const u192Max = BigInt('0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF') + const u256Max = BigInt('0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF') + assert.equal(receiveBigType(u128Max), u128Max) + assert.equal(receiveBigType(u192Max), u192Max) + assert.equal(receiveBigType(u256Max), u256Max) +} + +main() diff --git a/sdk/src/wasm/Cargo.toml b/sdk/src/wasm/Cargo.toml index 38fa807f..c21eca87 100644 --- a/sdk/src/wasm/Cargo.toml +++ b/sdk/src/wasm/Cargo.toml @@ -15,6 +15,7 @@ serde-wasm-bindgen = "0.6.3" tsify = "0.4.5" paste = "1.0.14" js-sys = "0.3.66" +uint = {version = "0.9.5", default-features = false} decimal = { path= "../../../src/decimal" } traceable_result = { path = "../../../src/traceable_result" } diff --git a/sdk/src/wasm/storage/invariant_config.rs b/sdk/src/wasm/storage/invariant_config.rs index b83bedc1..b823b373 100644 --- a/sdk/src/wasm/storage/invariant_config.rs +++ b/sdk/src/wasm/storage/invariant_config.rs @@ -1,8 +1,14 @@ use crate::alloc::string::ToString; +use crate::log; use crate::types::percentage::Percentage; +use js_sys::BigInt; use serde::{Deserialize, Serialize}; +use traceable_result::TrackableResult; use tsify::Tsify; +use uint::construct_uint; use wasm_bindgen::prelude::*; +use wasm_wrapper::wasm_wrapper; + #[derive(Debug, Clone, Tsify, Serialize, Deserialize)] #[tsify(into_wasm_abi, from_wasm_abi)] #[serde(rename_all = "camelCase")] @@ -10,4 +16,51 @@ pub struct InvariantConfig { #[tsify(type = "string")] pub admin: String, pub protocol_fee: Percentage, + pub poc_field: PocType, +} + +construct_uint! { + #[derive(Serialize, Deserialize, Tsify)] + pub struct U256T(4); +} + +#[derive(Default, Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Serialize, Deserialize, Tsify)] +#[tsify(into_wasm_abi, from_wasm_abi)] +pub struct PocType(pub U256T); + +#[wasm_bindgen(js_name = "receiveBigType")] +pub fn receive_big_type(big: JsValue) -> Result { + log(format!("received: {:?}", big).as_str()); + let mut arr = [0u64; 4]; + let big_int = BigInt::new(&big)?; + let x = BigInt::as_uint_n(256f64, &big_int); + + // cast to PocType + for i in 0..4 { + let shift_amount = BigInt::from(64 * i); + let x_shifted = &big_int >> shift_amount; + let mask = BigInt::from(0xFFFF_FFFF_FFFF_FFFFu64); + let x_masked = x_shifted & &mask; + + let package: u64 = serde_wasm_bindgen::from_value(x_masked.into())?; + arr[i] = package; + log(format!("Package: {:?} index: {:?}", package, i).as_str()); + } + + let nested_type: U256T = U256T(arr); + log(format!("nested_type: {:?}", nested_type).as_str()); + let big_type = PocType(nested_type); + log(format!("big_type: {:?}", big_type).as_str()); + + // cast back to BigInt + let mut cast_back = BigInt::from(0u64); + + for (index, &value) in arr.iter().enumerate() { + let value_bigint = BigInt::from(value); + let shift_amount = BigInt::from(64 * index); + let intermediate = value_bigint << shift_amount; + cast_back = cast_back + intermediate; + } + + Ok(cast_back) } From 52c3bae04d583bac36892693512ecb0736cb65e8 Mon Sep 17 00:00:00 2001 From: Sniezka Date: Mon, 8 Jul 2024 12:21:51 +0200 Subject: [PATCH 2/5] Validated passing u256t as argument to entrypoint --- Cargo.lock | 1 + Cargo.toml | 3 +- src/contracts/storage/invariant_config.rs | 14 +++++++ src/e2e/constructor.rs | 4 +- src/e2e/mod.rs | 48 +++++++++++------------ src/lib.rs | 24 +++++++----- 6 files changed, 59 insertions(+), 35 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 931aca08..c24a53ee 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2901,6 +2901,7 @@ dependencies = [ "test_helpers", "token", "traceable_result", + "uint", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 6fbdf298..2468008c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -14,6 +14,7 @@ ink = { version = "5.0.0", default-features = false } token = { path = "src/token", default-features = false, features = [ "ink-as-dependency", ] } +uint = {version = "0.9.5", default-features = false} [dev-dependencies] ink_e2e = "5.0.0" @@ -25,7 +26,7 @@ path = "src/lib.rs" [features] default = ["std"] -std = ["ink/std", "token/std"] +std = ["ink/std", "token/std", "uint/std"] ink-as-dependency = [] e2e-tests = [] diff --git a/src/contracts/storage/invariant_config.rs b/src/contracts/storage/invariant_config.rs index 32b56947..ae534287 100644 --- a/src/contracts/storage/invariant_config.rs +++ b/src/contracts/storage/invariant_config.rs @@ -1,11 +1,13 @@ use crate::math::types::percentage::Percentage; use ink::primitives::AccountId; +use uint::construct_uint; #[ink::storage_item] #[derive(Debug)] pub struct InvariantConfig { pub admin: AccountId, pub protocol_fee: Percentage, + pub poc_field: PocType, } impl Default for InvariantConfig { @@ -13,6 +15,18 @@ impl Default for InvariantConfig { Self { admin: AccountId::from([0x0; 32]), protocol_fee: Default::default(), + poc_field: PocType(U256T::from(0)), } } } + +construct_uint! { + #[ink::scale_derive(Encode, Decode, TypeInfo)] + #[cfg_attr(feature = "std", derive(ink::storage::traits::StorageLayout))] + pub struct U256T(4); +} + +#[derive(Default, Debug, Clone, Copy, PartialEq, Eq, PartialOrd)] +#[ink::scale_derive(Encode, Decode, TypeInfo)] +#[cfg_attr(feature = "std", derive(ink::storage::traits::StorageLayout))] +pub struct PocType(pub U256T); diff --git a/src/e2e/constructor.rs b/src/e2e/constructor.rs index bab6b4c3..7d0c62d5 100644 --- a/src/e2e/constructor.rs +++ b/src/e2e/constructor.rs @@ -1,5 +1,6 @@ #[cfg(test)] pub mod e2e_tests { + use crate::contracts::{PocType, U256T}; use crate::{invariant::InvariantRef, math::types::percentage::Percentage}; use decimal::*; use ink_e2e::ContractsBackend; @@ -17,7 +18,8 @@ pub mod e2e_tests { .await .expect("instantiate failed"); - let mut constructor = InvariantRef::new(Percentage::new(0)); + let poc_field = PocType(U256T::from(0)); + let mut constructor = InvariantRef::new(Percentage::new(0), poc_field); let _contract = client .instantiate("invariant", &ink_e2e::alice(), &mut constructor) .submit() diff --git a/src/e2e/mod.rs b/src/e2e/mod.rs index 646b50d0..4483ab24 100644 --- a/src/e2e/mod.rs +++ b/src/e2e/mod.rs @@ -1,25 +1,25 @@ -pub mod add_fee_tier; -pub mod change_fee_receiver; -pub mod change_protocol_fee; -pub mod claim; +// pub mod add_fee_tier; +// pub mod change_fee_receiver; +// pub mod change_protocol_fee; +// pub mod claim; pub mod constructor; -pub mod create_pool; -pub mod cross; -pub mod cross_both_side; -pub mod get_liquidity_ticks; -pub mod get_position_ticks; -pub mod get_positions; -pub mod get_tickmap; -pub mod interaction_with_pool_on_removed_fee_tier; -pub mod limits; -pub mod liquidity_gap; -pub mod max_tick_cross; -pub mod multiple_swap; -pub mod position; -pub mod position_list; -pub mod position_slippage; -pub mod protocol_fee; -pub mod remove_fee_tier; -pub mod slippage; -pub mod swap; -pub mod swap_route; +// pub mod create_pool; +// pub mod cross; +// pub mod cross_both_side; +// pub mod get_liquidity_ticks; +// pub mod get_position_ticks; +// pub mod get_positions; +// pub mod get_tickmap; +// pub mod interaction_with_pool_on_removed_fee_tier; +// pub mod limits; +// pub mod liquidity_gap; +// pub mod max_tick_cross; +// pub mod multiple_swap; +// pub mod position; +// pub mod position_list; +// pub mod position_slippage; +// pub mod protocol_fee; +// pub mod remove_fee_tier; +// pub mod slippage; +// pub mod swap; +// pub mod swap_route; diff --git a/src/lib.rs b/src/lib.rs index 26cb4595..72aa305e 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -10,10 +10,10 @@ pub mod math; pub mod invariant { use crate::contracts::{ get_max_chunk, get_min_chunk, tick_to_position, CalculateSwapResult, CreatePositionEvent, - CrossTickEvent, FeeTier, FeeTiers, InvariantConfig, InvariantTrait, LiquidityTick, Pool, - PoolKey, PoolKeys, Pools, Position, PositionTick, Positions, QuoteResult, + CrossTickEvent, FeeTier, FeeTiers, InvariantConfig, InvariantTrait, LiquidityTick, PocType, + Pool, PoolKey, PoolKeys, Pools, Position, PositionTick, Positions, QuoteResult, RemovePositionEvent, SwapEvent, SwapHop, Tick, Tickmap, Ticks, UpdatePoolTick, CHUNK_SIZE, - LIQUIDITY_TICK_LIMIT, MAX_TICKMAP_QUERY_SIZE, POSITION_TICK_LIMIT, + LIQUIDITY_TICK_LIMIT, MAX_TICKMAP_QUERY_SIZE, POSITION_TICK_LIMIT, U256T, }; use crate::math::calculate_min_amount_out; use crate::math::check_tick; @@ -60,11 +60,12 @@ pub mod invariant { impl Invariant { #[ink(constructor)] - pub fn new(protocol_fee: Percentage) -> Self { + pub fn new(protocol_fee: Percentage, poc_field: PocType) -> Self { Self { config: InvariantConfig { admin: Self::env().caller(), protocol_fee, + poc_field, }, ..Self::default() } @@ -1146,12 +1147,14 @@ pub mod invariant { #[ink::test] fn initialize_works() { - let _ = Invariant::new(Percentage::new(0)); + let poc = PocType(U256T::from(0)); + let _ = Invariant::new(Percentage::new(0), poc); } #[ink::test] fn test_add_pool() { - let mut contract = Invariant::new(Percentage::new(0)); + let poc = PocType(U256T::from(0)); + let mut contract = Invariant::new(Percentage::new(0), poc); let token_0 = AccountId::from([0x01; 32]); let token_1 = AccountId::from([0x02; 32]); let fee_tier = FeeTier { @@ -1189,7 +1192,8 @@ pub mod invariant { #[ink::test] fn test_get_pool() { - let mut contract = Invariant::new(Percentage::new(0)); + let poc = PocType(U256T::from(0)); + let mut contract = Invariant::new(Percentage::new(0), poc); let token_0 = AccountId::from([0x01; 32]); let token_1 = AccountId::from([0x02; 32]); let init_sqrt_price = calculate_sqrt_price(0).unwrap(); @@ -1225,7 +1229,8 @@ pub mod invariant { #[ink::test] fn create_tick() { - let mut contract = Invariant::new(Percentage::new(0)); + let poc = PocType(U256T::from(0)); + let mut contract = Invariant::new(Percentage::new(0), poc); let init_sqrt_price = calculate_sqrt_price(0).unwrap(); let token_0 = AccountId::from([0x01; 32]); let token_1 = AccountId::from([0x02; 32]); @@ -1255,7 +1260,8 @@ pub mod invariant { #[ink::test] fn test_fee_tiers() { - let mut contract = Invariant::new(Percentage::new(0)); + let poc = PocType(U256T::from(0)); + let mut contract = Invariant::new(Percentage::new(0), poc); let fee_tier = FeeTier::new(Percentage::new(1), 10u16).unwrap(); let fee_tier_value = FeeTier { fee: Percentage::new(1), From e28cce788c5442278296ca64c19e53773dd43d76 Mon Sep 17 00:00:00 2001 From: Sniezka Date: Mon, 8 Jul 2024 13:31:34 +0200 Subject: [PATCH 3/5] Added invariant deploy with uint parameter --- sdk/contracts/invariant/invariant.json | 15 ++++++++++--- sdk/contracts/invariant/invariant.wasm | Bin 119179 -> 119395 bytes sdk/package.json | 3 ++- sdk/src/abis/invariant.ts | 15 ++++++++++--- sdk/src/invariant.ts | 23 ++++++++++---------- sdk/src/poc-u256.ts | 14 +++++++++++++ sdk/tests/u256t-poc.test.ts | 28 +++++++++++++++++++++++++ 7 files changed, 80 insertions(+), 18 deletions(-) create mode 100644 sdk/tests/u256t-poc.test.ts diff --git a/sdk/contracts/invariant/invariant.json b/sdk/contracts/invariant/invariant.json index 85fc95d7..5f4ff477 100644 --- a/sdk/contracts/invariant/invariant.json +++ b/sdk/contracts/invariant/invariant.json @@ -1,6 +1,6 @@ { "source": { - "hash": "0xf1173d8a30aa5cb75a057960692ea174fa6eac1c0209d5d1ba5d16d810939697", + "hash": "0xe5065094388665399a5388d0b73d0cfca82ffc9680284fcef1eeb053d5a4591f", "language": "ink! 5.0.0", "compiler": "rustc 1.77.0", "build_info": { @@ -33,6 +33,15 @@ ], "type": 18 } + }, + { + "label": "poc_field", + "type": { + "displayName": [ + "PocType" + ], + "type": 54 + } } ], "default": false, @@ -3819,7 +3828,7 @@ { "fields": [ { - "type": 18 + "type": 54 } ], "index": 0, @@ -3840,7 +3849,7 @@ "params": [ { "name": "T", - "type": 18 + "type": 54 }, { "name": "E", diff --git a/sdk/contracts/invariant/invariant.wasm b/sdk/contracts/invariant/invariant.wasm index 3dca2c15c10d360cf2b614a6adf66e175250b83e..29ef34056252c2fcc0bb1321d50dcf595e5e4b78 100644 GIT binary patch delta 553 zcmYk3ze}4z7{{OIxqI=2_my7NAqXXxvqLgiBZMSWhn!Tm5{jF2ap-bF$5JRXZ=plP zAc{hyQ)x0}Ov&)Zp^!0SMn^#?;?Tdr=VBXs!`*#9&yRba=Z-paH{H4Z3qj|<2SxFx zh`-LVrQ;B+cAAtKq@~^+{cNWDSuEx#`#L?V;nD`h_4M)+cEg4SdmA|3zoRP%s0iTu z^^{!vN3N#iPcGs}78K4qDhG!7_z>xgN?gNvg5aIB*8@1lzL4 z2DZm+U6mGI0%)|MV=A38F-AVjqUR5e50-aP+WLyactLZT*r5HAU|rTAir3SfQ`~=w zqTTy}@1sLOK?6T?L6df_gU=SLJ|UM-b%qpa$Wyibri05-Rr{yqL76t&A3FG|G0*Mi zY18WZJVj~`B8YsaD(BnO96k-^w?kKezthS)BRGqCBt>T=lgx~0oO)+C3D3}=`i6cY z=(L;-eZ*>4%;b&z$7k^B`LI)M`FP=Sz!ss2Rm4RR!U?kF$n { + const pocField = [1n, 0n, 0n, 0n] const deploymentData = await getDeploymentData('invariant') const deploy = await deployContract( api, @@ -105,7 +106,7 @@ export class Invariant { deploymentData.abi, deploymentData.wasm, 'new', - [fee] + [fee, pocField] ) return new Invariant( diff --git a/sdk/src/poc-u256.ts b/sdk/src/poc-u256.ts index 9b201988..54e2301c 100644 --- a/sdk/src/poc-u256.ts +++ b/sdk/src/poc-u256.ts @@ -1,4 +1,8 @@ +import { Keyring } from '@polkadot/api' import { assert } from 'chai' +import { Invariant } from './invariant.js' +import { Network } from './network.js' +import { initPolkadotApi } from './utils.js' import { receiveBigType } from './wasm/pkg/invariant_a0_wasm.js' const main = async () => { @@ -8,6 +12,16 @@ const main = async () => { assert.equal(receiveBigType(u128Max), u128Max) assert.equal(receiveBigType(u192Max), u192Max) assert.equal(receiveBigType(u256Max), u256Max) + + // Deploy invariant + const api = await initPolkadotApi(Network.Local) + const keyring = new Keyring({ type: 'sr25519' }) + const account = keyring.addFromUri('//Alice') + + const invariant = await Invariant.deploy(api, Network.Local, account, 10000000000n) + console.log(invariant) + const protocolFee = await invariant.getProtocolFee() + console.log(protocolFee) } main() diff --git a/sdk/tests/u256t-poc.test.ts b/sdk/tests/u256t-poc.test.ts new file mode 100644 index 00000000..cdcfab4f --- /dev/null +++ b/sdk/tests/u256t-poc.test.ts @@ -0,0 +1,28 @@ +import { Keyring } from '@polkadot/api' +import { deployContract } from '@scio-labs/use-inkathon' +import { describe, it } from 'mocha' +import { Network } from '../src/network' +import { getDeploymentData, initPolkadotApi } from '../src/utils' + +const api = await initPolkadotApi(Network.Local) + +const keyring = new Keyring({ type: 'sr25519' }) +const account = await keyring.addFromUri('//Alice') + +describe('u256t-poc', async function () { + it('entrypoint with uint parameter passes', async () => { + // const invariant = await Invariant.deploy(api, Network.Local, account, 10000000000n) + const fee = 10000000000n + const pocField = [1n, 0n, 0n, 0n] + const deploymentData = await getDeploymentData('invariant') + const deploy = await deployContract( + api, + account, + deploymentData.abi, + deploymentData.wasm, + 'new', + [fee, pocField] + ) + console.log(deploy) + }) +}) From f383e60ce6cae216e26004dab5de04cdb71fc8b7 Mon Sep 17 00:00:00 2001 From: Sniezka Date: Mon, 8 Jul 2024 14:24:57 +0200 Subject: [PATCH 4/5] Cleanup --- sdk/package.json | 3 +-- sdk/tests/u256t-poc.test.ts | 28 ---------------------------- 2 files changed, 1 insertion(+), 30 deletions(-) delete mode 100644 sdk/tests/u256t-poc.test.ts diff --git a/sdk/package.json b/sdk/package.json index b11f00e6..dd9872e2 100644 --- a/sdk/package.json +++ b/sdk/package.json @@ -54,8 +54,7 @@ "test:crosses": "mocha ./tests/crosses-testnet.test.ts -g testnet-crosses-limitations", "test:tx": "mocha ./tests/tx.test.ts -g tx", "test:simulate-invariant-swap": "mocha ./tests/simulate-invariant-swap.test.ts -g simulateInvariantSwap", - "test:query-on-pair": "mocha ./tests/query-on-pair.test.ts -g query-on-pair", - "test:u256t-poc": "mocha ./tests/query-on-pair.test.ts -g u256t-poc" + "test:query-on-pair": "mocha ./tests/query-on-pair.test.ts -g query-on-pair" }, "dependencies": { "@polkadot/api": "^10.12.4", diff --git a/sdk/tests/u256t-poc.test.ts b/sdk/tests/u256t-poc.test.ts deleted file mode 100644 index cdcfab4f..00000000 --- a/sdk/tests/u256t-poc.test.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Keyring } from '@polkadot/api' -import { deployContract } from '@scio-labs/use-inkathon' -import { describe, it } from 'mocha' -import { Network } from '../src/network' -import { getDeploymentData, initPolkadotApi } from '../src/utils' - -const api = await initPolkadotApi(Network.Local) - -const keyring = new Keyring({ type: 'sr25519' }) -const account = await keyring.addFromUri('//Alice') - -describe('u256t-poc', async function () { - it('entrypoint with uint parameter passes', async () => { - // const invariant = await Invariant.deploy(api, Network.Local, account, 10000000000n) - const fee = 10000000000n - const pocField = [1n, 0n, 0n, 0n] - const deploymentData = await getDeploymentData('invariant') - const deploy = await deployContract( - api, - account, - deploymentData.abi, - deploymentData.wasm, - 'new', - [fee, pocField] - ) - console.log(deploy) - }) -}) From 74a6a6b1d092cdac2d0be480ac6b64a645a3e645 Mon Sep 17 00:00:00 2001 From: Sniezka Date: Mon, 8 Jul 2024 14:37:42 +0200 Subject: [PATCH 5/5] Added contract type --- src/contracts/entrypoints.rs | 4 +++- src/lib.rs | 6 +++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/contracts/entrypoints.rs b/src/contracts/entrypoints.rs index 7ef8e06f..a807a6bf 100644 --- a/src/contracts/entrypoints.rs +++ b/src/contracts/entrypoints.rs @@ -11,11 +11,13 @@ use crate::{ use alloc::vec::Vec; use ink::primitives::AccountId; +use super::PocType; + #[ink::trait_definition] pub trait InvariantTrait { /// Retrieves the protocol fee represented as a percentage. #[ink(message)] - fn get_protocol_fee(&self) -> Percentage; + fn get_protocol_fee(&self) -> PocType; /// Allows an fee receiver to withdraw collected fees. /// diff --git a/src/lib.rs b/src/lib.rs index 72aa305e..2c5137a6 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -13,7 +13,7 @@ pub mod invariant { CrossTickEvent, FeeTier, FeeTiers, InvariantConfig, InvariantTrait, LiquidityTick, PocType, Pool, PoolKey, PoolKeys, Pools, Position, PositionTick, Positions, QuoteResult, RemovePositionEvent, SwapEvent, SwapHop, Tick, Tickmap, Ticks, UpdatePoolTick, CHUNK_SIZE, - LIQUIDITY_TICK_LIMIT, MAX_TICKMAP_QUERY_SIZE, POSITION_TICK_LIMIT, U256T, + LIQUIDITY_TICK_LIMIT, MAX_TICKMAP_QUERY_SIZE, POSITION_TICK_LIMIT, }; use crate::math::calculate_min_amount_out; use crate::math::check_tick; @@ -415,8 +415,8 @@ pub mod invariant { impl InvariantTrait for Invariant { #[ink(message)] - fn get_protocol_fee(&self) -> Percentage { - self.config.protocol_fee + fn get_protocol_fee(&self) -> PocType { + self.config.poc_field } #[ink(message)]