Skip to content

Commit

Permalink
fix: RDK proto dependencies (#1230)
Browse files Browse the repository at this point in the history
  • Loading branch information
keruch authored Nov 14, 2024
1 parent 792e757 commit 59179aa
Show file tree
Hide file tree
Showing 8 changed files with 67 additions and 1,844 deletions.
5 changes: 2 additions & 3 deletions block/consensus.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,10 @@ import (

sdk "github.com/cosmos/cosmos-sdk/types"
authtypes "github.com/cosmos/cosmos-sdk/x/auth/types"
rdktypes "github.com/dymensionxyz/dymension-rdk/x/sequencers/types"
"github.com/gogo/protobuf/proto"

"github.com/dymensionxyz/dymint/types"
rdktypes "github.com/dymensionxyz/dymint/types/pb/rollapp/sequencers/types"
protoutils "github.com/dymensionxyz/dymint/utils/proto"
"github.com/dymensionxyz/dymint/utils/queue"
)

Expand Down Expand Up @@ -63,7 +62,7 @@ func ConsensusMsgsOnSequencerSetUpdate(newSequencers []types.Sequencer) ([]proto
msgs = append(msgs, &rdktypes.ConsensusMsgUpsertSequencer{
Signer: signer.String(),
Operator: s.SettlementAddress,
ConsPubKey: protoutils.CosmosToGogo(anyPK),
ConsPubKey: anyPK,
RewardAddr: s.RewardAddr,
Relayers: s.WhitelistedRelayers,
})
Expand Down
2 changes: 1 addition & 1 deletion block/consensus_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ package block_test
import (
"testing"

rdktypes "github.com/dymensionxyz/dymension-rdk/x/sequencers/types"
"github.com/stretchr/testify/require"

"github.com/dymensionxyz/dymint/block"
sequencertypes "github.com/dymensionxyz/dymint/types/pb/dymensionxyz/dymension/sequencer"
rdktypes "github.com/dymensionxyz/dymint/types/pb/rollapp/sequencers/types"
)

func TestConsensusMsgSigner(t *testing.T) {
Expand Down
9 changes: 4 additions & 5 deletions block/production_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (
"testing"
"time"

rdktypes "github.com/dymensionxyz/dymension-rdk/x/sequencers/types"
"github.com/gogo/protobuf/proto"
prototypes "github.com/gogo/protobuf/types"
"github.com/libp2p/go-libp2p/core/crypto"
Expand All @@ -29,10 +30,8 @@ import (
"github.com/dymensionxyz/dymint/node/events"
"github.com/dymensionxyz/dymint/testutil"
"github.com/dymensionxyz/dymint/types"
rdktypes "github.com/dymensionxyz/dymint/types/pb/rollapp/sequencers/types"
uchannel "github.com/dymensionxyz/dymint/utils/channel"
uevent "github.com/dymensionxyz/dymint/utils/event"
protoutils "github.com/dymensionxyz/dymint/utils/proto"
)

// TODO: test producing lastBlock
Expand Down Expand Up @@ -362,7 +361,7 @@ func TestUpdateInitialSequencerSet(t *testing.T) {
expectedConsMsg1 := &rdktypes.ConsensusMsgUpsertSequencer{
Signer: signer.String(),
Operator: proposer.SettlementAddress,
ConsPubKey: protoutils.CosmosToGogo(anyPK1),
ConsPubKey: anyPK1,
RewardAddr: proposer.RewardAddr,
Relayers: proposer.WhitelistedRelayers,
}
Expand All @@ -379,7 +378,7 @@ func TestUpdateInitialSequencerSet(t *testing.T) {
expectedConsMsg2 := &rdktypes.ConsensusMsgUpsertSequencer{
Signer: signer.String(),
Operator: sequencer.SettlementAddress,
ConsPubKey: protoutils.CosmosToGogo(anyPK2),
ConsPubKey: anyPK2,
RewardAddr: sequencer.RewardAddr,
Relayers: sequencer.WhitelistedRelayers,
}
Expand Down Expand Up @@ -486,7 +485,7 @@ func TestUpdateExistingSequencerSet(t *testing.T) {
expectedConsMsg := &rdktypes.ConsensusMsgUpsertSequencer{
Signer: signer.String(),
Operator: updatedSequencer.SettlementAddress,
ConsPubKey: protoutils.CosmosToGogo(anyPK),
ConsPubKey: anyPK,
RewardAddr: updatedSequencer.RewardAddr,
Relayers: updatedSequencer.WhitelistedRelayers,
}
Expand Down
33 changes: 17 additions & 16 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ require (
github.com/cosmos/cosmos-sdk v0.46.16
github.com/dgraph-io/badger/v4 v4.3.0
github.com/dymensionxyz/cosmosclient v0.4.2-beta.0.20240821081230-b4018b2bac13
github.com/dymensionxyz/dymension-rdk v1.6.1-0.20241029165002-545051749bc0
github.com/dymensionxyz/gerr-cosmos v1.0.0
github.com/go-kit/kit v0.12.0
github.com/gofrs/uuid v4.3.0+incompatible
Expand All @@ -35,25 +36,25 @@ require (
github.com/stretchr/testify v1.9.0
github.com/tendermint/tendermint v0.34.29
go.uber.org/multierr v1.11.0
golang.org/x/net v0.28.0
golang.org/x/net v0.30.0
gonum.org/v1/gonum v0.14.0
google.golang.org/grpc v1.64.0
google.golang.org/protobuf v1.33.0
)

require (
cloud.google.com/go v0.112.1 // indirect
cloud.google.com/go/storage v1.38.0 // indirect
cosmossdk.io/api v0.7.0 // indirect
cosmossdk.io/collections v0.4.0 // indirect
cosmossdk.io/core v0.12.0 // indirect
cosmossdk.io/depinject v1.0.0-alpha.4 // indirect
github.com/celestiaorg/go-square v1.0.1 // indirect
github.com/celestiaorg/go-square/merkle v0.0.0-20240429192549-dea967e1533b // indirect
github.com/cosmos/cosmos-db v1.0.0 // indirect
github.com/cskr/pubsub v1.0.2 // indirect
github.com/dgraph-io/badger/v3 v3.2103.3 // indirect
github.com/felixge/httpsnoop v1.0.4 // indirect
github.com/hashicorp/go-getter v1.7.5 // indirect
github.com/hashicorp/go-multierror v1.1.1 // indirect
github.com/ipfs/go-block-format v0.2.0 // indirect
github.com/tklauser/go-sysconf v0.3.11 // indirect
google.golang.org/api v0.169.0 // indirect
)

require (
Expand Down Expand Up @@ -118,7 +119,7 @@ require (
go.opentelemetry.io/otel/trace v1.24.0 // indirect
go.uber.org/dig v1.17.1 // indirect
go.uber.org/fx v1.20.1 // indirect
golang.org/x/exp v0.0.0-20240213143201-ec583247a57a
golang.org/x/exp v0.0.0-20241009180824-f66d83c29e7c
golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20240318140521-94a12d6c2237 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20240318140521-94a12d6c2237 // indirect
Expand Down Expand Up @@ -242,12 +243,12 @@ require (
go.etcd.io/bbolt v1.3.8 // indirect
go.opencensus.io v0.24.0 // indirect
go.uber.org/zap v1.27.0 // indirect
golang.org/x/crypto v0.26.0 // indirect
golang.org/x/mod v0.17.0 // indirect
golang.org/x/crypto v0.28.0 // indirect
golang.org/x/mod v0.21.0 // indirect
golang.org/x/sync v0.8.0
golang.org/x/sys v0.24.0 // indirect
golang.org/x/term v0.23.0 // indirect
golang.org/x/text v0.17.0 // indirect
golang.org/x/sys v0.26.0 // indirect
golang.org/x/term v0.25.0 // indirect
golang.org/x/text v0.19.0 // indirect
google.golang.org/genproto v0.0.0-20240213162025-012b6fc9bca9 // indirect
gopkg.in/ini.v1 v1.67.0 // indirect
gopkg.in/yaml.v2 v2.4.0
Expand All @@ -257,7 +258,7 @@ require (

require (
cosmossdk.io/math v1.3.0 // indirect
github.com/DataDog/zstd v1.5.2 // indirect
github.com/DataDog/zstd v1.5.5 // indirect
github.com/Jorropo/jsync v1.0.1 // indirect
github.com/blang/semver/v4 v4.0.0 // indirect
github.com/btcsuite/btcd/btcutil v1.1.3 // indirect
Expand All @@ -267,10 +268,9 @@ require (
github.com/cockroachdb/pebble v1.1.0 // indirect
github.com/cockroachdb/redact v1.1.5 // indirect
github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect
github.com/cosmos/ibc-go/v6 v6.2.1 // indirect
github.com/danwt/gerr v1.0.0 // indirect
github.com/evmos/evmos/v12 v12.1.6 // indirect
github.com/getsentry/sentry-go v0.18.0 // indirect
github.com/getsentry/sentry-go v0.23.0 // indirect
github.com/gopherjs/gopherjs v0.0.0-20190812055157-5d271430af9f // indirect
github.com/holiman/uint256 v1.2.2 // indirect
github.com/ipfs/bbloom v0.0.4 // indirect
Expand All @@ -291,11 +291,12 @@ require (
github.com/rogpeppe/go-internal v1.12.0 // indirect
github.com/whyrusleeping/chunker v0.0.0-20181014151217-fe64bd25879f // indirect
go.uber.org/mock v0.4.0 // indirect
golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d // indirect
golang.org/x/tools v0.26.0 // indirect
pgregory.net/rapid v1.1.0
)

replace (
github.com/CosmWasm/wasmd => github.com/decentrio/wasmd v0.33.0-sdk46.2
github.com/centrifuge/go-substrate-rpc-client/v4 => github.com/availproject/go-substrate-rpc-client/v4 v4.0.12-avail-1.4.0-rc1-5e286e3
github.com/evmos/evmos/v12 => github.com/dymensionxyz/evmos/v12 v12.1.6-dymension-v0.3
github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.2-alpha.regen.4
Expand Down
Loading

0 comments on commit 59179aa

Please sign in to comment.