feat: Provide Configuration Options for POB (#206) (#211)

Co-authored-by: Keefer Taylor | Tessellated <keefer@tessellated.io>
This commit is contained in:
Nikhil Vasan
2023-07-17 14:32:20 +00:00
committed by GitHub
co-authored by Keefer Taylor | Tessellated
parent 43789945e9
commit 8b5ebc310a
17 changed files with 322 additions and 308 deletions
+2 -1
View File
@@ -452,7 +452,8 @@ type Module struct {
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Authority defines the custom module authority. If not set, defaults to the governance module.
// Authority defines the custom module authority. If not set, defaults to the
// governance module.
Authority string `protobuf:"bytes,2,opt,name=authority,proto3" json:"authority,omitempty"`
}
+61 -154
View File
@@ -455,7 +455,6 @@ var (
fd_Params_max_bundle_size protoreflect.FieldDescriptor
fd_Params_escrow_account_address protoreflect.FieldDescriptor
fd_Params_reserve_fee protoreflect.FieldDescriptor
fd_Params_min_buy_in_fee protoreflect.FieldDescriptor
fd_Params_min_bid_increment protoreflect.FieldDescriptor
fd_Params_front_running_protection protoreflect.FieldDescriptor
fd_Params_proposer_fee protoreflect.FieldDescriptor
@@ -467,7 +466,6 @@ func init() {
fd_Params_max_bundle_size = md_Params.Fields().ByName("max_bundle_size")
fd_Params_escrow_account_address = md_Params.Fields().ByName("escrow_account_address")
fd_Params_reserve_fee = md_Params.Fields().ByName("reserve_fee")
fd_Params_min_buy_in_fee = md_Params.Fields().ByName("min_buy_in_fee")
fd_Params_min_bid_increment = md_Params.Fields().ByName("min_bid_increment")
fd_Params_front_running_protection = md_Params.Fields().ByName("front_running_protection")
fd_Params_proposer_fee = md_Params.Fields().ByName("proposer_fee")
@@ -544,8 +542,8 @@ func (x *fastReflection_Params) Range(f func(protoreflect.FieldDescriptor, proto
return
}
}
if x.EscrowAccountAddress != "" {
value := protoreflect.ValueOfString(x.EscrowAccountAddress)
if len(x.EscrowAccountAddress) != 0 {
value := protoreflect.ValueOfBytes(x.EscrowAccountAddress)
if !f(fd_Params_escrow_account_address, value) {
return
}
@@ -556,12 +554,6 @@ func (x *fastReflection_Params) Range(f func(protoreflect.FieldDescriptor, proto
return
}
}
if x.MinBuyInFee != nil {
value := protoreflect.ValueOfMessage(x.MinBuyInFee.ProtoReflect())
if !f(fd_Params_min_buy_in_fee, value) {
return
}
}
if x.MinBidIncrement != nil {
value := protoreflect.ValueOfMessage(x.MinBidIncrement.ProtoReflect())
if !f(fd_Params_min_bid_increment, value) {
@@ -598,11 +590,9 @@ func (x *fastReflection_Params) Has(fd protoreflect.FieldDescriptor) bool {
case "pob.builder.v1.Params.max_bundle_size":
return x.MaxBundleSize != uint32(0)
case "pob.builder.v1.Params.escrow_account_address":
return x.EscrowAccountAddress != ""
return len(x.EscrowAccountAddress) != 0
case "pob.builder.v1.Params.reserve_fee":
return x.ReserveFee != nil
case "pob.builder.v1.Params.min_buy_in_fee":
return x.MinBuyInFee != nil
case "pob.builder.v1.Params.min_bid_increment":
return x.MinBidIncrement != nil
case "pob.builder.v1.Params.front_running_protection":
@@ -628,11 +618,9 @@ func (x *fastReflection_Params) Clear(fd protoreflect.FieldDescriptor) {
case "pob.builder.v1.Params.max_bundle_size":
x.MaxBundleSize = uint32(0)
case "pob.builder.v1.Params.escrow_account_address":
x.EscrowAccountAddress = ""
x.EscrowAccountAddress = nil
case "pob.builder.v1.Params.reserve_fee":
x.ReserveFee = nil
case "pob.builder.v1.Params.min_buy_in_fee":
x.MinBuyInFee = nil
case "pob.builder.v1.Params.min_bid_increment":
x.MinBidIncrement = nil
case "pob.builder.v1.Params.front_running_protection":
@@ -660,13 +648,10 @@ func (x *fastReflection_Params) Get(descriptor protoreflect.FieldDescriptor) pro
return protoreflect.ValueOfUint32(value)
case "pob.builder.v1.Params.escrow_account_address":
value := x.EscrowAccountAddress
return protoreflect.ValueOfString(value)
return protoreflect.ValueOfBytes(value)
case "pob.builder.v1.Params.reserve_fee":
value := x.ReserveFee
return protoreflect.ValueOfMessage(value.ProtoReflect())
case "pob.builder.v1.Params.min_buy_in_fee":
value := x.MinBuyInFee
return protoreflect.ValueOfMessage(value.ProtoReflect())
case "pob.builder.v1.Params.min_bid_increment":
value := x.MinBidIncrement
return protoreflect.ValueOfMessage(value.ProtoReflect())
@@ -699,11 +684,9 @@ func (x *fastReflection_Params) Set(fd protoreflect.FieldDescriptor, value proto
case "pob.builder.v1.Params.max_bundle_size":
x.MaxBundleSize = uint32(value.Uint())
case "pob.builder.v1.Params.escrow_account_address":
x.EscrowAccountAddress = value.Interface().(string)
x.EscrowAccountAddress = value.Bytes()
case "pob.builder.v1.Params.reserve_fee":
x.ReserveFee = value.Message().Interface().(*v1beta1.Coin)
case "pob.builder.v1.Params.min_buy_in_fee":
x.MinBuyInFee = value.Message().Interface().(*v1beta1.Coin)
case "pob.builder.v1.Params.min_bid_increment":
x.MinBidIncrement = value.Message().Interface().(*v1beta1.Coin)
case "pob.builder.v1.Params.front_running_protection":
@@ -735,11 +718,6 @@ func (x *fastReflection_Params) Mutable(fd protoreflect.FieldDescriptor) protore
x.ReserveFee = new(v1beta1.Coin)
}
return protoreflect.ValueOfMessage(x.ReserveFee.ProtoReflect())
case "pob.builder.v1.Params.min_buy_in_fee":
if x.MinBuyInFee == nil {
x.MinBuyInFee = new(v1beta1.Coin)
}
return protoreflect.ValueOfMessage(x.MinBuyInFee.ProtoReflect())
case "pob.builder.v1.Params.min_bid_increment":
if x.MinBidIncrement == nil {
x.MinBidIncrement = new(v1beta1.Coin)
@@ -769,13 +747,10 @@ func (x *fastReflection_Params) NewField(fd protoreflect.FieldDescriptor) protor
case "pob.builder.v1.Params.max_bundle_size":
return protoreflect.ValueOfUint32(uint32(0))
case "pob.builder.v1.Params.escrow_account_address":
return protoreflect.ValueOfString("")
return protoreflect.ValueOfBytes(nil)
case "pob.builder.v1.Params.reserve_fee":
m := new(v1beta1.Coin)
return protoreflect.ValueOfMessage(m.ProtoReflect())
case "pob.builder.v1.Params.min_buy_in_fee":
m := new(v1beta1.Coin)
return protoreflect.ValueOfMessage(m.ProtoReflect())
case "pob.builder.v1.Params.min_bid_increment":
m := new(v1beta1.Coin)
return protoreflect.ValueOfMessage(m.ProtoReflect())
@@ -863,10 +838,6 @@ func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods {
l = options.Size(x.ReserveFee)
n += 1 + l + runtime.Sov(uint64(l))
}
if x.MinBuyInFee != nil {
l = options.Size(x.MinBuyInFee)
n += 1 + l + runtime.Sov(uint64(l))
}
if x.MinBidIncrement != nil {
l = options.Size(x.MinBidIncrement)
n += 1 + l + runtime.Sov(uint64(l))
@@ -912,7 +883,7 @@ func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods {
copy(dAtA[i:], x.ProposerFee)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ProposerFee)))
i--
dAtA[i] = 0x3a
dAtA[i] = 0x32
}
if x.FrontRunningProtection {
i--
@@ -922,7 +893,7 @@ func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods {
dAtA[i] = 0
}
i--
dAtA[i] = 0x30
dAtA[i] = 0x28
}
if x.MinBidIncrement != nil {
encoded, err := options.Marshal(x.MinBidIncrement)
@@ -936,20 +907,6 @@ func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods {
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x2a
}
if x.MinBuyInFee != nil {
encoded, err := options.Marshal(x.MinBuyInFee)
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x22
}
if x.ReserveFee != nil {
@@ -1050,7 +1007,7 @@ func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods {
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field EscrowAccountAddress", wireType)
}
var stringLen uint64
var byteLen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
@@ -1060,23 +1017,25 @@ func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods {
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
byteLen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
if byteLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
postIndex := iNdEx + byteLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.EscrowAccountAddress = string(dAtA[iNdEx:postIndex])
x.EscrowAccountAddress = append(x.EscrowAccountAddress[:0], dAtA[iNdEx:postIndex]...)
if x.EscrowAccountAddress == nil {
x.EscrowAccountAddress = []byte{}
}
iNdEx = postIndex
case 3:
if wireType != 2 {
@@ -1115,42 +1074,6 @@ func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods {
}
iNdEx = postIndex
case 4:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MinBuyInFee", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if x.MinBuyInFee == nil {
x.MinBuyInFee = &v1beta1.Coin{}
}
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.MinBuyInFee); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 5:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MinBidIncrement", wireType)
}
@@ -1186,7 +1109,7 @@ func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 6:
case 5:
if wireType != 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FrontRunningProtection", wireType)
}
@@ -1206,7 +1129,7 @@ func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods {
}
}
x.FrontRunningProtection = bool(v != 0)
case 7:
case 6:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ProposerFee", wireType)
}
@@ -1333,21 +1256,18 @@ type Params struct {
MaxBundleSize uint32 `protobuf:"varint,1,opt,name=max_bundle_size,json=maxBundleSize,proto3" json:"max_bundle_size,omitempty"`
// escrow_account_address is the address of the account that will receive a
// portion of the bid proceeds.
EscrowAccountAddress string `protobuf:"bytes,2,opt,name=escrow_account_address,json=escrowAccountAddress,proto3" json:"escrow_account_address,omitempty"`
EscrowAccountAddress []byte `protobuf:"bytes,2,opt,name=escrow_account_address,json=escrowAccountAddress,proto3" json:"escrow_account_address,omitempty"`
// reserve_fee specifies the bid floor for the auction.
ReserveFee *v1beta1.Coin `protobuf:"bytes,3,opt,name=reserve_fee,json=reserveFee,proto3" json:"reserve_fee,omitempty"`
// min_buy_in_fee specifies the fee that the bidder must pay to enter the
// auction.
MinBuyInFee *v1beta1.Coin `protobuf:"bytes,4,opt,name=min_buy_in_fee,json=minBuyInFee,proto3" json:"min_buy_in_fee,omitempty"`
// min_bid_increment specifies the minimum amount that the next bid must be
// greater than the previous bid.
MinBidIncrement *v1beta1.Coin `protobuf:"bytes,5,opt,name=min_bid_increment,json=minBidIncrement,proto3" json:"min_bid_increment,omitempty"`
MinBidIncrement *v1beta1.Coin `protobuf:"bytes,4,opt,name=min_bid_increment,json=minBidIncrement,proto3" json:"min_bid_increment,omitempty"`
// front_running_protection specifies whether front running and sandwich
// attack protection is enabled.
FrontRunningProtection bool `protobuf:"varint,6,opt,name=front_running_protection,json=frontRunningProtection,proto3" json:"front_running_protection,omitempty"`
FrontRunningProtection bool `protobuf:"varint,5,opt,name=front_running_protection,json=frontRunningProtection,proto3" json:"front_running_protection,omitempty"`
// proposer_fee defines the portion of the winning bid that goes to the block
// proposer that proposed the block.
ProposerFee string `protobuf:"bytes,7,opt,name=proposer_fee,json=proposerFee,proto3" json:"proposer_fee,omitempty"`
ProposerFee string `protobuf:"bytes,6,opt,name=proposer_fee,json=proposerFee,proto3" json:"proposer_fee,omitempty"`
}
func (x *Params) Reset() {
@@ -1377,11 +1297,11 @@ func (x *Params) GetMaxBundleSize() uint32 {
return 0
}
func (x *Params) GetEscrowAccountAddress() string {
func (x *Params) GetEscrowAccountAddress() []byte {
if x != nil {
return x.EscrowAccountAddress
}
return ""
return nil
}
func (x *Params) GetReserveFee() *v1beta1.Coin {
@@ -1391,13 +1311,6 @@ func (x *Params) GetReserveFee() *v1beta1.Coin {
return nil
}
func (x *Params) GetMinBuyInFee() *v1beta1.Coin {
if x != nil {
return x.MinBuyInFee
}
return nil
}
func (x *Params) GetMinBidIncrement() *v1beta1.Coin {
if x != nil {
return x.MinBidIncrement
@@ -1433,50 +1346,45 @@ var file_pob_builder_v1_genesis_proto_rawDesc = []byte{
0x69, 0x73, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x34, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d,
0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x70, 0x6f, 0x62, 0x2e, 0x62, 0x75,
0x69, 0x6c, 0x64, 0x65, 0x72, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42,
0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0xf9, 0x03,
0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0xae, 0x03,
0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x26, 0x0a, 0x0f, 0x6d, 0x61, 0x78, 0x5f,
0x62, 0x75, 0x6e, 0x64, 0x6c, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28,
0x0d, 0x52, 0x0d, 0x6d, 0x61, 0x78, 0x42, 0x75, 0x6e, 0x64, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65,
0x12, 0x34, 0x0a, 0x16, 0x65, 0x73, 0x63, 0x72, 0x6f, 0x77, 0x5f, 0x61, 0x63, 0x63, 0x6f, 0x75,
0x6e, 0x74, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09,
0x6e, 0x74, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c,
0x52, 0x14, 0x65, 0x73, 0x63, 0x72, 0x6f, 0x77, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x41,
0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x45, 0x0a, 0x0b, 0x72, 0x65, 0x73, 0x65, 0x72, 0x76,
0x65, 0x5f, 0x66, 0x65, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63, 0x6f,
0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61,
0x31, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x42, 0x09, 0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a,
0x01, 0x52, 0x0a, 0x72, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x46, 0x65, 0x65, 0x12, 0x49, 0x0a,
0x0e, 0x6d, 0x69, 0x6e, 0x5f, 0x62, 0x75, 0x79, 0x5f, 0x69, 0x6e, 0x5f, 0x66, 0x65, 0x65, 0x18,
0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62,
0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x43, 0x6f, 0x69, 0x6e,
0x42, 0x09, 0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x0b, 0x6d, 0x69, 0x6e,
0x42, 0x75, 0x79, 0x49, 0x6e, 0x46, 0x65, 0x65, 0x12, 0x50, 0x0a, 0x11, 0x6d, 0x69, 0x6e, 0x5f,
0x62, 0x69, 0x64, 0x5f, 0x69, 0x6e, 0x63, 0x72, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x05, 0x20,
0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73,
0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x42, 0x09,
0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x0f, 0x6d, 0x69, 0x6e, 0x42, 0x69,
0x64, 0x49, 0x6e, 0x63, 0x72, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x38, 0x0a, 0x18, 0x66, 0x72,
0x6f, 0x6e, 0x74, 0x5f, 0x72, 0x75, 0x6e, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x70, 0x72, 0x6f, 0x74,
0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x16, 0x66, 0x72,
0x6f, 0x6e, 0x74, 0x52, 0x75, 0x6e, 0x6e, 0x69, 0x6e, 0x67, 0x50, 0x72, 0x6f, 0x74, 0x65, 0x63,
0x74, 0x69, 0x6f, 0x6e, 0x12, 0x51, 0x0a, 0x0c, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72,
0x5f, 0x66, 0x65, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x42, 0x2e, 0xc8, 0xde, 0x1f, 0x00,
0xda, 0xde, 0x1f, 0x26, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63,
0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b,
0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x70,
0x6f, 0x73, 0x65, 0x72, 0x46, 0x65, 0x65, 0x3a, 0x20, 0x8a, 0xe7, 0xb0, 0x2a, 0x1b, 0x63, 0x6f,
0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x78, 0x2f, 0x62, 0x75, 0x69, 0x6c, 0x64,
0x65, 0x72, 0x2f, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0xa7, 0x01, 0x0a, 0x12, 0x63, 0x6f,
0x6d, 0x2e, 0x70, 0x6f, 0x62, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x2e, 0x76, 0x31,
0x42, 0x0c, 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01,
0x5a, 0x29, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61,
0x70, 0x69, 0x2f, 0x70, 0x6f, 0x62, 0x2f, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x2f, 0x76,
0x31, 0x3b, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x50, 0x42,
0x58, 0xaa, 0x02, 0x0e, 0x50, 0x6f, 0x62, 0x2e, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x2e,
0x56, 0x31, 0xca, 0x02, 0x0e, 0x50, 0x6f, 0x62, 0x5c, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72,
0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1a, 0x50, 0x6f, 0x62, 0x5c, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x65,
0x72, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61,
0xea, 0x02, 0x10, 0x50, 0x6f, 0x62, 0x3a, 0x3a, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x3a,
0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
0x01, 0x52, 0x0a, 0x72, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x46, 0x65, 0x65, 0x12, 0x50, 0x0a,
0x11, 0x6d, 0x69, 0x6e, 0x5f, 0x62, 0x69, 0x64, 0x5f, 0x69, 0x6e, 0x63, 0x72, 0x65, 0x6d, 0x65,
0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f,
0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x43,
0x6f, 0x69, 0x6e, 0x42, 0x09, 0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x0f,
0x6d, 0x69, 0x6e, 0x42, 0x69, 0x64, 0x49, 0x6e, 0x63, 0x72, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x12,
0x38, 0x0a, 0x18, 0x66, 0x72, 0x6f, 0x6e, 0x74, 0x5f, 0x72, 0x75, 0x6e, 0x6e, 0x69, 0x6e, 0x67,
0x5f, 0x70, 0x72, 0x6f, 0x74, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28,
0x08, 0x52, 0x16, 0x66, 0x72, 0x6f, 0x6e, 0x74, 0x52, 0x75, 0x6e, 0x6e, 0x69, 0x6e, 0x67, 0x50,
0x72, 0x6f, 0x74, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x51, 0x0a, 0x0c, 0x70, 0x72, 0x6f,
0x70, 0x6f, 0x73, 0x65, 0x72, 0x5f, 0x66, 0x65, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x42,
0x2e, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x26, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e,
0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f,
0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52,
0x0b, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x46, 0x65, 0x65, 0x3a, 0x20, 0x8a, 0xe7,
0xb0, 0x2a, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x78, 0x2f,
0x62, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x2f, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0xa7,
0x01, 0x0a, 0x12, 0x63, 0x6f, 0x6d, 0x2e, 0x70, 0x6f, 0x62, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64,
0x65, 0x72, 0x2e, 0x76, 0x31, 0x42, 0x0c, 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x50, 0x72,
0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x29, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b,
0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x70, 0x6f, 0x62, 0x2f, 0x62, 0x75, 0x69, 0x6c,
0x64, 0x65, 0x72, 0x2f, 0x76, 0x31, 0x3b, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x76, 0x31,
0xa2, 0x02, 0x03, 0x50, 0x42, 0x58, 0xaa, 0x02, 0x0e, 0x50, 0x6f, 0x62, 0x2e, 0x42, 0x75, 0x69,
0x6c, 0x64, 0x65, 0x72, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0e, 0x50, 0x6f, 0x62, 0x5c, 0x42, 0x75,
0x69, 0x6c, 0x64, 0x65, 0x72, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1a, 0x50, 0x6f, 0x62, 0x5c, 0x42,
0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74,
0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x10, 0x50, 0x6f, 0x62, 0x3a, 0x3a, 0x42, 0x75, 0x69,
0x6c, 0x64, 0x65, 0x72, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (
@@ -1500,13 +1408,12 @@ var file_pob_builder_v1_genesis_proto_goTypes = []interface{}{
var file_pob_builder_v1_genesis_proto_depIdxs = []int32{
1, // 0: pob.builder.v1.GenesisState.params:type_name -> pob.builder.v1.Params
2, // 1: pob.builder.v1.Params.reserve_fee:type_name -> cosmos.base.v1beta1.Coin
2, // 2: pob.builder.v1.Params.min_buy_in_fee:type_name -> cosmos.base.v1beta1.Coin
2, // 3: pob.builder.v1.Params.min_bid_increment:type_name -> cosmos.base.v1beta1.Coin
4, // [4:4] is the sub-list for method output_type
4, // [4:4] is the sub-list for method input_type
4, // [4:4] is the sub-list for extension type_name
4, // [4:4] is the sub-list for extension extendee
0, // [0:4] is the sub-list for field type_name
2, // 2: pob.builder.v1.Params.min_bid_increment:type_name -> cosmos.base.v1beta1.Coin
3, // [3:3] is the sub-list for method output_type
3, // [3:3] is the sub-list for method input_type
3, // [3:3] is the sub-list for extension type_name
3, // [3:3] is the sub-list for extension extendee
0, // [0:3] is the sub-list for field type_name
}
func init() { file_pob_builder_v1_genesis_proto_init() }
+24 -24
View File
@@ -18,49 +18,49 @@ import (
sync "sync"
)
var _ protoreflect.List = (*_MsgAuctionBid_4_list)(nil)
var _ protoreflect.List = (*_MsgAuctionBid_3_list)(nil)
type _MsgAuctionBid_4_list struct {
type _MsgAuctionBid_3_list struct {
list *[][]byte
}
func (x *_MsgAuctionBid_4_list) Len() int {
func (x *_MsgAuctionBid_3_list) Len() int {
if x.list == nil {
return 0
}
return len(*x.list)
}
func (x *_MsgAuctionBid_4_list) Get(i int) protoreflect.Value {
func (x *_MsgAuctionBid_3_list) Get(i int) protoreflect.Value {
return protoreflect.ValueOfBytes((*x.list)[i])
}
func (x *_MsgAuctionBid_4_list) Set(i int, value protoreflect.Value) {
func (x *_MsgAuctionBid_3_list) Set(i int, value protoreflect.Value) {
valueUnwrapped := value.Bytes()
concreteValue := valueUnwrapped
(*x.list)[i] = concreteValue
}
func (x *_MsgAuctionBid_4_list) Append(value protoreflect.Value) {
func (x *_MsgAuctionBid_3_list) Append(value protoreflect.Value) {
valueUnwrapped := value.Bytes()
concreteValue := valueUnwrapped
*x.list = append(*x.list, concreteValue)
}
func (x *_MsgAuctionBid_4_list) AppendMutable() protoreflect.Value {
func (x *_MsgAuctionBid_3_list) AppendMutable() protoreflect.Value {
panic(fmt.Errorf("AppendMutable can not be called on message MsgAuctionBid at list field Transactions as it is not of Message kind"))
}
func (x *_MsgAuctionBid_4_list) Truncate(n int) {
func (x *_MsgAuctionBid_3_list) Truncate(n int) {
*x.list = (*x.list)[:n]
}
func (x *_MsgAuctionBid_4_list) NewElement() protoreflect.Value {
func (x *_MsgAuctionBid_3_list) NewElement() protoreflect.Value {
var v []byte
return protoreflect.ValueOfBytes(v)
}
func (x *_MsgAuctionBid_4_list) IsValid() bool {
func (x *_MsgAuctionBid_3_list) IsValid() bool {
return x.list != nil
}
@@ -157,7 +157,7 @@ func (x *fastReflection_MsgAuctionBid) Range(f func(protoreflect.FieldDescriptor
}
}
if len(x.Transactions) != 0 {
value := protoreflect.ValueOfList(&_MsgAuctionBid_4_list{list: &x.Transactions})
value := protoreflect.ValueOfList(&_MsgAuctionBid_3_list{list: &x.Transactions})
if !f(fd_MsgAuctionBid_transactions, value) {
return
}
@@ -229,9 +229,9 @@ func (x *fastReflection_MsgAuctionBid) Get(descriptor protoreflect.FieldDescript
return protoreflect.ValueOfMessage(value.ProtoReflect())
case "pob.builder.v1.MsgAuctionBid.transactions":
if len(x.Transactions) == 0 {
return protoreflect.ValueOfList(&_MsgAuctionBid_4_list{})
return protoreflect.ValueOfList(&_MsgAuctionBid_3_list{})
}
listValue := &_MsgAuctionBid_4_list{list: &x.Transactions}
listValue := &_MsgAuctionBid_3_list{list: &x.Transactions}
return protoreflect.ValueOfList(listValue)
default:
if descriptor.IsExtension() {
@@ -259,7 +259,7 @@ func (x *fastReflection_MsgAuctionBid) Set(fd protoreflect.FieldDescriptor, valu
x.Bid = value.Message().Interface().(*v1beta1.Coin)
case "pob.builder.v1.MsgAuctionBid.transactions":
lv := value.List()
clv := lv.(*_MsgAuctionBid_4_list)
clv := lv.(*_MsgAuctionBid_3_list)
x.Transactions = *clv.list
default:
if fd.IsExtension() {
@@ -290,7 +290,7 @@ func (x *fastReflection_MsgAuctionBid) Mutable(fd protoreflect.FieldDescriptor)
if x.Transactions == nil {
x.Transactions = [][]byte{}
}
value := &_MsgAuctionBid_4_list{list: &x.Transactions}
value := &_MsgAuctionBid_3_list{list: &x.Transactions}
return protoreflect.ValueOfList(value)
case "pob.builder.v1.MsgAuctionBid.bidder":
panic(fmt.Errorf("field bidder of message pob.builder.v1.MsgAuctionBid is not mutable"))
@@ -314,7 +314,7 @@ func (x *fastReflection_MsgAuctionBid) NewField(fd protoreflect.FieldDescriptor)
return protoreflect.ValueOfMessage(m.ProtoReflect())
case "pob.builder.v1.MsgAuctionBid.transactions":
list := [][]byte{}
return protoreflect.ValueOfList(&_MsgAuctionBid_4_list{list: &list})
return protoreflect.ValueOfList(&_MsgAuctionBid_3_list{list: &list})
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: pob.builder.v1.MsgAuctionBid"))
@@ -433,7 +433,7 @@ func (x *fastReflection_MsgAuctionBid) ProtoMethods() *protoiface.Methods {
copy(dAtA[i:], x.Transactions[iNdEx])
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Transactions[iNdEx])))
i--
dAtA[i] = 0x22
dAtA[i] = 0x1a
}
}
if x.Bid != nil {
@@ -448,7 +448,7 @@ func (x *fastReflection_MsgAuctionBid) ProtoMethods() *protoiface.Methods {
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x1a
dAtA[i] = 0x12
}
if len(x.Bidder) > 0 {
i -= len(x.Bidder)
@@ -538,7 +538,7 @@ func (x *fastReflection_MsgAuctionBid) ProtoMethods() *protoiface.Methods {
}
x.Bidder = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 3:
case 2:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Bid", wireType)
}
@@ -574,7 +574,7 @@ func (x *fastReflection_MsgAuctionBid) ProtoMethods() *protoiface.Methods {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 4:
case 3:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Transactions", wireType)
}
@@ -1877,10 +1877,10 @@ type MsgAuctionBid struct {
Bidder string `protobuf:"bytes,1,opt,name=bidder,proto3" json:"bidder,omitempty"`
// bid is the amount of coins that the bidder is bidding to participate in the
// auction.
Bid *v1beta1.Coin `protobuf:"bytes,3,opt,name=bid,proto3" json:"bid,omitempty"`
Bid *v1beta1.Coin `protobuf:"bytes,2,opt,name=bid,proto3" json:"bid,omitempty"`
// transactions are the bytes of the transactions that the bidder wants to
// bundle together.
Transactions [][]byte `protobuf:"bytes,4,rep,name=transactions,proto3" json:"transactions,omitempty"`
Transactions [][]byte `protobuf:"bytes,3,rep,name=transactions,proto3" json:"transactions,omitempty"`
}
func (x *MsgAuctionBid) Reset() {
@@ -2047,11 +2047,11 @@ var file_pob_builder_v1_tx_proto_rawDesc = []byte{
0x6e, 0x42, 0x69, 0x64, 0x12, 0x30, 0x0a, 0x06, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x18, 0x01,
0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73,
0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x06,
0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x12, 0x36, 0x0a, 0x03, 0x62, 0x69, 0x64, 0x18, 0x03, 0x20,
0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x12, 0x36, 0x0a, 0x03, 0x62, 0x69, 0x64, 0x18, 0x02, 0x20,
0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73,
0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x42, 0x09,
0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x03, 0x62, 0x69, 0x64, 0x12, 0x22,
0x0a, 0x0c, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x04,
0x0a, 0x0c, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x03,
0x20, 0x03, 0x28, 0x0c, 0x52, 0x0c, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f,
0x6e, 0x73, 0x3a, 0x2f, 0xe8, 0xa0, 0x1f, 0x00, 0x82, 0xe7, 0xb0, 0x2a, 0x06, 0x62, 0x69, 0x64,
0x64, 0x65, 0x72, 0x8a, 0xe7, 0xb0, 0x2a, 0x1b, 0x70, 0x6f, 0x62, 0x2f, 0x78, 0x2f, 0x62, 0x75,