From 441703eb25762c2b5341afd5cabcbac658ae6fdd Mon Sep 17 00:00:00 2001 From: Kevin Jones Date: Fri, 18 Nov 2022 09:17:33 +0000 Subject: [PATCH] Add swap info to pool share estimation query --- docs/proposals/asymmetric-adds.md | 11 +- docs/tutorials/asymmetric-adds.md | 9 +- proto/sifnode/clp/v1/querier.proto | 31 ++ x/clp/keeper/calculations.go | 2 +- x/clp/keeper/calculations_test.go | 2 + x/clp/keeper/grpc_query.go | 26 +- x/clp/keeper/grpc_query_test.go | 20 + x/clp/types/querier.pb.go | 635 ++++++++++++++++++++++++----- 8 files changed, 633 insertions(+), 103 deletions(-) diff --git a/docs/proposals/asymmetric-adds.md b/docs/proposals/asymmetric-adds.md index b1dcd94a37..e2a1dfde3c 100644 --- a/docs/proposals/asymmetric-adds.md +++ b/docs/proposals/asymmetric-adds.md @@ -154,10 +154,19 @@ sifnoded query clp estimate-pool-share \ { "percentage": "0.183227703974514619", "native_asset_amount": "549683111923543857", - "external_asset_amount": "366455407949029238" + "external_asset_amount": "366455407949029238", + "swap_info": { + "status": "SELL_NATIVE", + "fee": "1102674246586848", + "fee_rate": "0.003000000000000000", + "amount": "450316888076456143", + "result": "366455407949029237" + } } ``` +Where `swap_info` `swap_status` is one of `NO_SWAP`, `SELL_NATIVe`, `BUY_NATIVE`. + ## References Detailed derivation of formulas https://hackmd.io/NjvaZY1qQiS17s_uEgZmTw?both diff --git a/docs/tutorials/asymmetric-adds.md b/docs/tutorials/asymmetric-adds.md index f5f79ba917..dc4a2801a2 100644 --- a/docs/tutorials/asymmetric-adds.md +++ b/docs/tutorials/asymmetric-adds.md @@ -86,7 +86,14 @@ sifnoded query clp estimate-pool-share --externalAmount=0 --nativeAmount=1000000 { "percentage": "0.183227703974514619", "native_asset_amount": "549683111923543857", - "external_asset_amount": "366455407949029238" + "external_asset_amount": "366455407949029238", + "swap_info": { + "status": "SELL_NATIVE", + "fee": "1102674246586848", + "fee_rate": "0.003000000000000000", + "amount": "450316888076456143", + "result": "366455407949029237" + } } ``` diff --git a/proto/sifnode/clp/v1/querier.proto b/proto/sifnode/clp/v1/querier.proto index e43971a7a4..c15539dcbb 100644 --- a/proto/sifnode/clp/v1/querier.proto +++ b/proto/sifnode/clp/v1/querier.proto @@ -231,4 +231,35 @@ message PoolShareEstimateRes { (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Uint", (gogoproto.nullable) = false ]; + SwapInfo swap_info = 4 [ + (gogoproto.nullable) = false + ]; + +} + +enum SwapStatus { + UNSPECIFIED = 0; + NO_SWAP = 1; + SELL_NATIVE = 2; + BUY_NATIVE = 3; +} + +message SwapInfo { + SwapStatus status = 1; + string fee = 2 [ + (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Uint", + (gogoproto.nullable) = false + ]; + string fee_rate = 3 [ + (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", + (gogoproto.nullable) = false + ]; + string amount = 4 [ + (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Uint", + (gogoproto.nullable) = false + ]; + string result= 5 [ + (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Uint", + (gogoproto.nullable) = false + ]; } \ No newline at end of file diff --git a/x/clp/keeper/calculations.go b/x/clp/keeper/calculations.go index c27d5b26d3..423a0113e9 100644 --- a/x/clp/keeper/calculations.go +++ b/x/clp/keeper/calculations.go @@ -158,7 +158,7 @@ func CalculatePoolUnits(P, R, A, r, a sdk.Uint, sellNativeSwapFeeRate, buyNative case Symmetric: // R/A == r/a poolUnits, lpUnits := CalculatePoolUnitsSymmetric(R, r, P) - return poolUnits, lpUnits, NoSwap, sdk.Uint{}, nil + return poolUnits, lpUnits, NoSwap, sdk.ZeroUint(), nil case NeedMoreX: // Need more external token to make R/A == r/a swapAmount := CalculateNativeSwapAmountAsymmetric(R, A, r, a, &sellNativeSwapFeeRateR, &pmtpCurrentRunningRateR) diff --git a/x/clp/keeper/calculations_test.go b/x/clp/keeper/calculations_test.go index b245a63254..070e1eed6b 100644 --- a/x/clp/keeper/calculations_test.go +++ b/x/clp/keeper/calculations_test.go @@ -1237,6 +1237,7 @@ func TestKeeper_CalculatePoolUnits(t *testing.T) { expectedPoolUnits: sdk.NewUint(7733018877666646), expectedLPunits: sdk.NewUint(76564543343234), expectedSwapStatus: clpkeeper.NoSwap, + expectedSwapAmount: sdk.ZeroUint(), }, { name: "negative symmetry - zero external", @@ -1292,6 +1293,7 @@ func TestKeeper_CalculatePoolUnits(t *testing.T) { expectedPoolUnits: sdk.NewUintFromString("1606938044258990275541962092341162602522202993783892346929152"), expectedLPunits: sdk.NewUint(1099511627776), expectedSwapStatus: clpkeeper.NoSwap, + expectedSwapAmount: sdk.ZeroUint(), }, { name: "very big - negative symmetry", diff --git a/x/clp/keeper/grpc_query.go b/x/clp/keeper/grpc_query.go index ada484c01c..f2152f2bc7 100755 --- a/x/clp/keeper/grpc_query.go +++ b/x/clp/keeper/grpc_query.go @@ -289,7 +289,7 @@ func (k Querier) GetPoolShareEstimate(c context.Context, req *types.PoolShareEst nativeAssetDepth, externalAssetDepth := pool.ExtractDebt(pool.NativeAssetBalance, pool.ExternalAssetBalance, false) - newPoolUnits, lpUnits, _, _, err := CalculatePoolUnits( + newPoolUnits, lpUnits, swapStatus, swapAmount, err := CalculatePoolUnits( pool.PoolUnits, nativeAssetDepth, externalAssetDepth, @@ -302,6 +302,8 @@ func (k Querier) GetPoolShareEstimate(c context.Context, req *types.PoolShareEst return nil, err } + feeRate, swapResult, feeAmount, resSwapStatus := calculateSwapInfo(swapStatus, swapAmount, nativeAssetDepth, externalAssetDepth, sellNativeSwapFeeRate, buyNativeSwapFeeRate, pmtpCurrentRunningRate) + newPoolUnitsD := sdk.NewDecFromBigInt(newPoolUnits.BigInt()) lpUnitsD := sdk.NewDecFromBigInt(lpUnits.BigInt()) @@ -317,6 +319,28 @@ func (k Querier) GetPoolShareEstimate(c context.Context, req *types.PoolShareEst Percentage: percentage, NativeAssetAmount: sdk.NewUintFromBigInt(nativeAssetAmountD.TruncateInt().BigInt()), ExternalAssetAmount: sdk.NewUintFromBigInt(externalAssetAmountD.TruncateInt().BigInt()), + SwapInfo: types.SwapInfo{ + Status: resSwapStatus, + Fee: feeAmount, + FeeRate: feeRate, + Amount: swapAmount, + Result: swapResult, + }, }, nil } + +func calculateSwapInfo(swapStatus int, swapAmount, nativeAssetDepth, externalAssetDepth sdk.Uint, sellNativeSwapFeeRate, buyNativeSwapFeeRate, pmtpCurrentRunningRate sdk.Dec) (sdk.Dec, sdk.Uint, sdk.Uint, types.SwapStatus) { + switch swapStatus { + case NoSwap: + return sdk.ZeroDec(), sdk.ZeroUint(), sdk.ZeroUint(), types.SwapStatus_NO_SWAP + case SellNative: + swapResult, liquidityFee := CalcSwapResult(false, nativeAssetDepth, swapAmount, externalAssetDepth, pmtpCurrentRunningRate, sellNativeSwapFeeRate) + return sellNativeSwapFeeRate, swapResult, liquidityFee, types.SwapStatus_SELL_NATIVE + case BuyNative: + swapResult, liquidityFee := CalcSwapResult(true, externalAssetDepth, swapAmount, nativeAssetDepth, pmtpCurrentRunningRate, buyNativeSwapFeeRate) + return buyNativeSwapFeeRate, swapResult, liquidityFee, types.SwapStatus_BUY_NATIVE + default: + panic("expect not to reach here!") + } +} diff --git a/x/clp/keeper/grpc_query_test.go b/x/clp/keeper/grpc_query_test.go index 3eaea7f00a..a3a8322e88 100644 --- a/x/clp/keeper/grpc_query_test.go +++ b/x/clp/keeper/grpc_query_test.go @@ -146,6 +146,11 @@ func TestQuerier_GetPoolShareEstimate(t *testing.T) { expectedExternalAssetAmount sdk.Uint expectedNativeAssetAmount sdk.Uint expectedPercentage sdk.Dec + expectedSwapStatus types.SwapStatus + expectedSwapFee sdk.Uint + expectedSwapFeeRate sdk.Dec + expectedSwapAmount sdk.Uint + expectedSwapResult sdk.Uint err error errString error }{ @@ -164,6 +169,11 @@ func TestQuerier_GetPoolShareEstimate(t *testing.T) { expectedExternalAssetAmount: sdk.NewUint(200), expectedNativeAssetAmount: sdk.NewUint(200), expectedPercentage: sdk.MustNewDecFromStr("0.166666666666666667"), + expectedSwapStatus: types.SwapStatus_NO_SWAP, + expectedSwapFee: sdk.ZeroUint(), + expectedSwapFeeRate: sdk.ZeroDec(), + expectedSwapAmount: sdk.ZeroUint(), + expectedSwapResult: sdk.ZeroUint(), }, { name: "asymmetric", @@ -180,6 +190,11 @@ func TestQuerier_GetPoolShareEstimate(t *testing.T) { expectedExternalAssetAmount: sdk.NewUint(115), expectedNativeAssetAmount: sdk.NewUint(138), expectedPercentage: sdk.MustNewDecFromStr("0.115826702033598585"), + expectedSwapStatus: types.SwapStatus_SELL_NATIVE, + expectedSwapFee: sdk.ZeroUint(), + expectedSwapFeeRate: sdk.MustNewDecFromStr("0.003"), + expectedSwapAmount: sdk.NewUint(61), + expectedSwapResult: sdk.NewUint(114), }, } @@ -236,6 +251,11 @@ func TestQuerier_GetPoolShareEstimate(t *testing.T) { require.Equal(t, tc.expectedExternalAssetAmount.String(), res.ExternalAssetAmount.String()) require.Equal(t, tc.expectedNativeAssetAmount.String(), res.NativeAssetAmount.String()) require.Equal(t, tc.expectedPercentage.String(), res.Percentage.String()) + require.Equal(t, tc.expectedSwapStatus, res.SwapInfo.Status) + require.Equal(t, tc.expectedSwapFee.String(), res.SwapInfo.Fee.String()) + require.Equal(t, tc.expectedSwapFeeRate.String(), res.SwapInfo.FeeRate.String()) + require.Equal(t, tc.expectedSwapAmount.String(), res.SwapInfo.Amount.String()) + require.Equal(t, tc.expectedSwapResult.String(), res.SwapInfo.Result.String()) }) } } diff --git a/x/clp/types/querier.pb.go b/x/clp/types/querier.pb.go index 64b9a25dc4..8ec17886fa 100644 --- a/x/clp/types/querier.pb.go +++ b/x/clp/types/querier.pb.go @@ -31,6 +31,37 @@ var _ = math.Inf // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package +type SwapStatus int32 + +const ( + SwapStatus_UNSPECIFIED SwapStatus = 0 + SwapStatus_NO_SWAP SwapStatus = 1 + SwapStatus_SELL_NATIVE SwapStatus = 2 + SwapStatus_BUY_NATIVE SwapStatus = 3 +) + +var SwapStatus_name = map[int32]string{ + 0: "UNSPECIFIED", + 1: "NO_SWAP", + 2: "SELL_NATIVE", + 3: "BUY_NATIVE", +} + +var SwapStatus_value = map[string]int32{ + "UNSPECIFIED": 0, + "NO_SWAP": 1, + "SELL_NATIVE": 2, + "BUY_NATIVE": 3, +} + +func (x SwapStatus) String() string { + return proto.EnumName(SwapStatus_name, int32(x)) +} + +func (SwapStatus) EnumDescriptor() ([]byte, []int) { + return fileDescriptor_5f4edede314ca3fd, []int{0} +} + type PoolReq struct { Symbol string `protobuf:"bytes,1,opt,name=symbol,proto3" json:"symbol,omitempty"` } @@ -1312,6 +1343,7 @@ type PoolShareEstimateRes struct { Percentage github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,1,opt,name=percentage,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"percentage"` NativeAssetAmount github_com_cosmos_cosmos_sdk_types.Uint `protobuf:"bytes,2,opt,name=native_asset_amount,json=nativeAssetAmount,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Uint" json:"native_asset_amount"` ExternalAssetAmount github_com_cosmos_cosmos_sdk_types.Uint `protobuf:"bytes,3,opt,name=external_asset_amount,json=externalAssetAmount,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Uint" json:"external_asset_amount"` + SwapInfo SwapInfo `protobuf:"bytes,4,opt,name=swap_info,json=swapInfo,proto3" json:"swap_info"` } func (m *PoolShareEstimateRes) Reset() { *m = PoolShareEstimateRes{} } @@ -1347,7 +1379,63 @@ func (m *PoolShareEstimateRes) XXX_DiscardUnknown() { var xxx_messageInfo_PoolShareEstimateRes proto.InternalMessageInfo +func (m *PoolShareEstimateRes) GetSwapInfo() SwapInfo { + if m != nil { + return m.SwapInfo + } + return SwapInfo{} +} + +type SwapInfo struct { + Status SwapStatus `protobuf:"varint,1,opt,name=status,proto3,enum=sifnode.clp.v1.SwapStatus" json:"status,omitempty"` + Fee github_com_cosmos_cosmos_sdk_types.Uint `protobuf:"bytes,2,opt,name=fee,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Uint" json:"fee"` + FeeRate github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,3,opt,name=fee_rate,json=feeRate,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"fee_rate"` + Amount github_com_cosmos_cosmos_sdk_types.Uint `protobuf:"bytes,4,opt,name=amount,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Uint" json:"amount"` + Result github_com_cosmos_cosmos_sdk_types.Uint `protobuf:"bytes,5,opt,name=result,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Uint" json:"result"` +} + +func (m *SwapInfo) Reset() { *m = SwapInfo{} } +func (m *SwapInfo) String() string { return proto.CompactTextString(m) } +func (*SwapInfo) ProtoMessage() {} +func (*SwapInfo) Descriptor() ([]byte, []int) { + return fileDescriptor_5f4edede314ca3fd, []int{28} +} +func (m *SwapInfo) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *SwapInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_SwapInfo.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *SwapInfo) XXX_Merge(src proto.Message) { + xxx_messageInfo_SwapInfo.Merge(m, src) +} +func (m *SwapInfo) XXX_Size() int { + return m.Size() +} +func (m *SwapInfo) XXX_DiscardUnknown() { + xxx_messageInfo_SwapInfo.DiscardUnknown(m) +} + +var xxx_messageInfo_SwapInfo proto.InternalMessageInfo + +func (m *SwapInfo) GetStatus() SwapStatus { + if m != nil { + return m.Status + } + return SwapStatus_UNSPECIFIED +} + func init() { + proto.RegisterEnum("sifnode.clp.v1.SwapStatus", SwapStatus_name, SwapStatus_value) proto.RegisterType((*PoolReq)(nil), "sifnode.clp.v1.PoolReq") proto.RegisterType((*PoolRes)(nil), "sifnode.clp.v1.PoolRes") proto.RegisterType((*PoolsReq)(nil), "sifnode.clp.v1.PoolsReq") @@ -1376,110 +1464,121 @@ func init() { proto.RegisterType((*SwapFeeParamsRes)(nil), "sifnode.clp.v1.SwapFeeParamsRes") proto.RegisterType((*PoolShareEstimateReq)(nil), "sifnode.clp.v1.PoolShareEstimateReq") proto.RegisterType((*PoolShareEstimateRes)(nil), "sifnode.clp.v1.PoolShareEstimateRes") + proto.RegisterType((*SwapInfo)(nil), "sifnode.clp.v1.SwapInfo") } func init() { proto.RegisterFile("sifnode/clp/v1/querier.proto", fileDescriptor_5f4edede314ca3fd) } var fileDescriptor_5f4edede314ca3fd = []byte{ - // 1567 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xdc, 0x58, 0xcd, 0x6f, 0x1b, 0xc5, - 0x1b, 0xce, 0x26, 0x6d, 0xda, 0x4c, 0xda, 0x26, 0x79, 0x9b, 0xa4, 0xee, 0xfe, 0x12, 0x27, 0xbf, - 0x55, 0x49, 0x43, 0x48, 0x76, 0x9b, 0x7e, 0x08, 0xca, 0xc7, 0x21, 0x51, 0x5b, 0x73, 0x28, 0x28, - 0x6c, 0x8b, 0x90, 0x90, 0x8a, 0x35, 0x5e, 0x4f, 0xec, 0x55, 0xd7, 0xde, 0xf5, 0xce, 0x38, 0xad, - 0x55, 0x0a, 0x12, 0xea, 0x01, 0x89, 0x4b, 0xa5, 0xde, 0x38, 0xa0, 0x5e, 0x38, 0x20, 0x81, 0xc4, - 0x01, 0x89, 0x0b, 0x57, 0xa4, 0x22, 0x21, 0x51, 0x89, 0x0b, 0x70, 0x28, 0xa8, 0xe5, 0xd0, 0x3f, - 0x03, 0xcd, 0xec, 0xac, 0xed, 0xfd, 0xb2, 0x9d, 0xa8, 0x02, 0xc1, 0x29, 0xd9, 0x79, 0x9f, 0x79, - 0x3f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e5, - 0x82, 0x50, 0x06, 0xfd, 0x5a, 0x41, 0x73, 0xb1, 0x0e, 0x88, 0x48, 0x2e, 0x58, 0x1d, 0x5c, 0x9d, - 0x91, 0x86, 0xba, 0x1b, 0x34, 0xd5, 0xce, 0x8a, 0x14, 0x75, 0x58, 0xed, 0xdd, 0x0d, 0x72, 0x5e, - 0x98, 0xf2, 0x37, 0x0a, 0x9a, 0xe7, 0x44, 0x65, 0x0a, 0x27, 0x58, 0xdb, 0x85, 0xc8, 0x22, 0x0d, - 0x75, 0x57, 0x70, 0xaa, 0x9d, 0x13, 0x59, 0x1b, 0xb0, 0x96, 0x24, 0xb6, 0x7d, 0xfa, 0x74, 0x4d, - 0x0c, 0xd3, 0xfe, 0x00, 0x4d, 0x16, 0x08, 0x8b, 0x68, 0x36, 0x58, 0xcc, 0xd0, 0x4d, 0x9d, 0xdc, - 0xfa, 0x21, 0x7a, 0xb5, 0x57, 0x44, 0x03, 0xc2, 0xdd, 0xe0, 0x5e, 0x49, 0x08, 0x8b, 0xe4, 0xbd, - 0x92, 0x26, 0xcc, 0xd4, 0x41, 0x50, 0xbd, 0x8e, 0x1f, 0x7e, 0xb9, 0x15, 0x29, 0xc7, 0x17, 0x89, - 0x9c, 0xb0, 0xb9, 0xf1, 0xe0, 0x71, 0x5e, 0x79, 0xf8, 0x38, 0xaf, 0xfc, 0xf1, 0x38, 0xaf, 0xdc, - 0x7d, 0x92, 0x1f, 0x7a, 0xf8, 0x24, 0x3f, 0xf4, 0xcb, 0x93, 0xfc, 0xd0, 0xbb, 0xdd, 0x8a, 0xe0, - 0x4a, 0xe8, 0x29, 0xfc, 0xa5, 0xfd, 0xa6, 0xf0, 0x29, 0x64, 0x41, 0x69, 0x54, 0xfc, 0x3c, 0x7e, - 0xe6, 0xaf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x59, 0xf3, 0x98, 0x25, 0xe7, 0x17, 0x00, 0x00, + // 1726 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xdc, 0x59, 0xcd, 0x6f, 0x1b, 0x5b, + 0x15, 0xcf, 0xd8, 0x69, 0x3e, 0x4e, 0xda, 0x7c, 0x9c, 0x26, 0xa9, 0x6b, 0x12, 0x27, 0x8c, 0x4a, + 0x5e, 0x08, 0x89, 0xfd, 0xd2, 0xd7, 0x27, 0x78, 0x3c, 0x58, 0x38, 0x34, 0x31, 0x11, 0x21, 0x98, + 0x49, 0x4b, 0x05, 0x52, 0xb1, 0xc6, 0xf6, 0xb5, 0x3d, 0xea, 0xd8, 0x33, 0x9e, 0x7b, 0x9d, 0x36, + 0x2a, 0x05, 0x09, 0x75, 0x81, 0xc4, 0xa6, 0x52, 0x77, 0x2c, 0x50, 0x37, 0x2c, 0x58, 0x20, 0xb1, + 0x40, 0x62, 0xc3, 0x16, 0xa9, 0x48, 0x48, 0x54, 0x62, 0x03, 0x2c, 0x0a, 0x6a, 0x59, 0x94, 0xff, + 0x02, 0xdd, 0x3b, 0x77, 0x6c, 0xcf, 0x97, 0xe3, 0x58, 0x15, 0x08, 0x56, 0xc9, 0xcc, 0xf9, 0x9d, + 0xaf, 0xdf, 0x9c, 0x7b, 0xef, 0xef, 0x26, 0xb0, 0x42, 0x8d, 0x5a, 0xcb, 0xaa, 0x92, 0x5c, 0xc5, + 0xb4, 0x73, 0xa7, 0xbb, 0xb9, 0x76, 0x87, 0x38, 0x06, 0x71, 0xb2, 0xb6, 0x63, 0x31, 0x0b, 0x67, + 0xa5, 0x35, 0x5b, 0x31, 0xed, 0xec, 0xe9, 0x6e, 0x7a, 0xb1, 0x6e, 0xd5, 0x2d, 0x61, 0xca, 0xf1, + 0xdf, 0x5c, 0x54, 0x3a, 0x1d, 0x88, 0xc1, 0xce, 0x6c, 0x42, 0xa5, 0xed, 0x33, 0x01, 0x9b, 0xad, + 0x3b, 0x7a, 0xd3, 0x33, 0x6e, 0x55, 0x2c, 0xda, 0xb4, 0x68, 0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12, 0x2f, 0x97, 0xa6, 0x94, 0xf5, 0x64, 0x6c, 0x47, 0x2e, 0xe4, 0xfd, 0xb4, 0x84, 0x05, 0x5f, + 0x1b, 0xe3, 0xa2, 0x8d, 0x0f, 0xce, 0x6d, 0x83, 0xda, 0x56, 0x8b, 0x12, 0x5f, 0x1f, 0xf7, 0x60, + 0xf1, 0xc8, 0x68, 0x77, 0x8c, 0xaa, 0xc1, 0xce, 0x8a, 0x8e, 0x75, 0x6a, 0x54, 0x89, 0x33, 0xe0, + 0x83, 0xe2, 0x2a, 0x80, 0x69, 0x07, 0xca, 0x9e, 0x36, 0x6d, 0x59, 0x6f, 0xdf, 0xf7, 0x7e, 0xa7, + 0x44, 0x46, 0xa6, 0x58, 0x04, 0x34, 0xbd, 0xf7, 0x25, 0x5b, 0x1a, 0xe4, 0x97, 0xf8, 0x6c, 0x90, + 0xb9, 0x70, 0x84, 0x05, 0x33, 0xf8, 0x0a, 0x3f, 0x84, 0x45, 0xde, 0xcd, 0x29, 0x29, 0xe9, 0x94, + 0x12, 0x56, 0x2a, 0xeb, 0xa6, 0xde, 0xaa, 0x10, 0x59, 0x1d, 0xba, 0xb6, 0x3c, 0x37, 0xed, 0xb9, + 0x16, 0xbc, 0x05, 0xcb, 0xe4, 0x11, 0x23, 0x4e, 0x4b, 0x37, 0x03, 0x3e, 0x49, 0xe1, 0xb3, 0xe8, + 0x59, 0x7d, 0x5e, 0xbd, 0x8f, 0x31, 0xee, 0x9b, 0xaf, 0x1f, 0xc1, 0x65, 0x81, 0x3b, 0x32, 0x28, + 0xe3, 0xdc, 0xf9, 0x39, 0x52, 0x02, 0x1c, 0x05, 0x46, 0x30, 0x31, 0xea, 0x08, 0xf6, 0x71, 0xfd, + 0x73, 0xc5, 0x57, 0x01, 0xc5, 0x1d, 0x98, 0x10, 0x6d, 0x79, 0x13, 0xb9, 0x14, 0xe4, 0x55, 0xa0, + 0x35, 0x09, 0xea, 0x6b, 0x2c, 0x31, 0x60, 0xca, 0x92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06, 0x4f, 0x0f, 0x83, 0x1a, 0xb4, 0xfd, 0xf0, 0xc3, 0xad, 0x44, 0x39, 0xbe, 0x44, 0xa4, 0xc3, + 0x5e, 0xfe, 0xe5, 0x9b, 0x8c, 0xf2, 0xea, 0x4d, 0x46, 0xf9, 0xc7, 0x9b, 0x8c, 0xf2, 0xec, 0x6d, + 0x66, 0xec, 0xd5, 0xdb, 0xcc, 0xd8, 0x5f, 0xde, 0x66, 0xc6, 0xbe, 0xd7, 0xaf, 0x28, 0x4e, 0xbc, + 0x48, 0xde, 0x3f, 0x55, 0x1e, 0x89, 0x98, 0x42, 0x56, 0x94, 0x27, 0xc4, 0x7f, 0x42, 0x3e, 0xfa, + 0x77, 0x00, 0x00, 0x00, 0xff, 0xff, 0xef, 0xab, 0xf9, 0x6e, 0xd2, 0x19, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -3172,6 +3271,16 @@ func (m *PoolShareEstimateRes) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l + { + size, err := m.SwapInfo.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintQuerier(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x22 { size := m.ExternalAssetAmount.Size() i -= size @@ -3205,6 +3314,74 @@ func (m *PoolShareEstimateRes) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *SwapInfo) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SwapInfo) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *SwapInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + { + size := m.Result.Size() + i -= size + if _, err := m.Result.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintQuerier(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x2a + { + size := m.Amount.Size() + i -= size + if _, err := m.Amount.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintQuerier(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x22 + { + size := m.FeeRate.Size() + i -= size + if _, err := m.FeeRate.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintQuerier(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + { + size := m.Fee.Size() + i -= size + if _, err := m.Fee.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintQuerier(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + if m.Status != 0 { + i = encodeVarintQuerier(dAtA, i, uint64(m.Status)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + func encodeVarintQuerier(dAtA []byte, offset int, v uint64) int { offset -= sovQuerier(v) base := offset @@ -3668,6 +3845,28 @@ func (m *PoolShareEstimateRes) Size() (n int) { n += 1 + l + sovQuerier(uint64(l)) l = m.ExternalAssetAmount.Size() n += 1 + l + sovQuerier(uint64(l)) + l = m.SwapInfo.Size() + n += 1 + l + sovQuerier(uint64(l)) + return n +} + +func (m *SwapInfo) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Status != 0 { + n += 1 + sovQuerier(uint64(m.Status)) + } + l = m.Fee.Size() + n += 1 + l + sovQuerier(uint64(l)) + l = m.FeeRate.Size() + n += 1 + l + sovQuerier(uint64(l)) + l = m.Amount.Size() + n += 1 + l + sovQuerier(uint64(l)) + l = m.Result.Size() + n += 1 + l + sovQuerier(uint64(l)) return n } @@ -6779,6 +6978,244 @@ func (m *PoolShareEstimateRes) Unmarshal(dAtA []byte) error { return err } iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SwapInfo", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuerier + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthQuerier + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthQuerier + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.SwapInfo.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipQuerier(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthQuerier + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SwapInfo) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuerier + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SwapInfo: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SwapInfo: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + m.Status = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuerier + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Status |= SwapStatus(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Fee", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuerier + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthQuerier + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthQuerier + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Fee.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FeeRate", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuerier + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthQuerier + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthQuerier + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.FeeRate.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuerier + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthQuerier + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthQuerier + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Result", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuerier + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthQuerier + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthQuerier + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Result.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuerier(dAtA[iNdEx:])