Skip to content

Commit

Permalink
merge issues
Browse files Browse the repository at this point in the history
  • Loading branch information
srene authored and omritoptix committed Sep 25, 2024
1 parent b6b26fc commit 522b95b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 22 deletions.
16 changes: 5 additions & 11 deletions block/manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,7 @@ import (
"github.com/dymensionxyz/gerr-cosmos/gerrc"
"golang.org/x/sync/errgroup"

<<<<<<< HEAD
=======
"github.com/dymensionxyz/dymint/da/registry"
"github.com/dymensionxyz/dymint/indexers/txindex"
>>>>>>> 5055ae7 (feat(manager): run dymint store block pruning in background (#1053))
"github.com/dymensionxyz/dymint/store"
uerrors "github.com/dymensionxyz/dymint/utils/errors"
uevent "github.com/dymensionxyz/dymint/utils/event"
Expand Down Expand Up @@ -115,17 +111,17 @@ func NewManager(

m := &Manager{
Pubsub: pubsub,
P2PClient: p2pClient,
p2pClient: p2pClient,
LocalKey: localKey,
Conf: conf.BlockManagerConfig,
Conf: conf,
Genesis: genesis,
Store: store,
Executor: exec,
DAClient: dalc,
DAClient: dalc,
SLClient: settlementClient,
indexerService: indexerService,
Retriever: dalc.(da.BatchRetriever),
logger: logger.With("module", "block_manager"),
Retriever: dalc.(da.BatchRetriever),
logger: logger,
blockCache: &Cache{
cache: make(map[uint64]types.CachedBlock),
},
Expand Down Expand Up @@ -161,15 +157,13 @@ func (m *Manager) Start(ctx context.Context) error {
}
}

eg, ctx := errgroup.WithContext(ctx)
eg, ctx := errgroup.WithContext(ctx)
uerrors.ErrGroupGoLog(eg, m.logger, func() error {
return m.PruningLoop(ctx)
})

if isSequencer {


// Sequencer must wait till DA is synced to start submitting blobs
<-m.DAClient.Synced()

Expand Down
12 changes: 1 addition & 11 deletions testutil/block.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,17 +104,12 @@ func GetManagerWithProposerKey(conf config.BlockManagerConfig, proposerKey crypt
return nil, err
}

config := config.NodeConfig{
BlockManagerConfig: conf,
DAConfig: "",
}

indexer, err := createIndexerService()
if err != nil {
return nil, err
}

manager, err := block.NewManager(proposerKey, config, genesis, managerStore, mp, proxyApp, settlementlc, nil,
manager, err := block.NewManager(proposerKey, conf, genesis, managerStore, mp, proxyApp, dalc, settlementlc, nil,
pubsubServer, p2pClient, nil, indexer, logger)
if err != nil {
return nil, err
Expand All @@ -128,11 +123,6 @@ func GetManagerWithProposerKey(conf config.BlockManagerConfig, proposerKey crypt
return nil, err
}

manager, err := block.NewManager(proposerKey, conf, genesis, managerStore, mp, proxyApp, dalc, settlementlc, nil,
pubsubServer, p2pClient, logger)
if err != nil {
return nil, err
}
return manager, nil
}

Expand Down

0 comments on commit 522b95b

Please sign in to comment.