From d8afcaa992827653c72667e7047ea21892b78fc1 Mon Sep 17 00:00:00 2001 From: blxdyx Date: Tue, 3 Sep 2024 11:35:42 +0800 Subject: [PATCH] support rpcdaemon --- turbo/jsonrpc/bsc_api.go | 2 +- turbo/jsonrpc/daemon.go | 6 +----- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/turbo/jsonrpc/bsc_api.go b/turbo/jsonrpc/bsc_api.go index c6f673d9b7a..bf17768f51d 100644 --- a/turbo/jsonrpc/bsc_api.go +++ b/turbo/jsonrpc/bsc_api.go @@ -217,7 +217,7 @@ func (api *BscImpl) GetVerifyResult(ctx context.Context, blockNr rpc.BlockNumber // PendingTransactions returns the transactions that are in the transaction pool // and have a from address that is one of the accounts this node manages. -func (s *BscImpl) PendingTransactions() ([]*RPCTransaction, error) { +func (api *BscImpl) PendingTransactions() ([]*RPCTransaction, error) { return nil, fmt.Errorf(NotImplemented, "eth_pendingTransactions") } diff --git a/turbo/jsonrpc/daemon.go b/turbo/jsonrpc/daemon.go index c25e19d3953..75e1301bbbf 100644 --- a/turbo/jsonrpc/daemon.go +++ b/turbo/jsonrpc/daemon.go @@ -17,8 +17,6 @@ package jsonrpc import ( - "github.com/erigontech/erigon/consensus/parlia" - txpool "github.com/erigontech/erigon-lib/gointerfaces/txpoolproto" "github.com/erigontech/erigon-lib/kv" "github.com/erigontech/erigon-lib/kv/kvcache" @@ -49,8 +47,8 @@ func APIList(db kv.RoDB, eth rpchelper.ApiBackend, txPool txpool.TxpoolClient, m dbImpl := NewDBAPIImpl() /* deprecated */ adminImpl := NewAdminAPI(eth) parityImpl := NewParityAPIImpl(base, db) + bscImpl := NewBscAPI(ethImpl) - var bscImpl *BscImpl var borImpl *BorImpl type lazy interface { @@ -59,8 +57,6 @@ func APIList(db kv.RoDB, eth rpchelper.ApiBackend, txPool txpool.TxpoolClient, m } switch engine := engine.(type) { - case *parlia.Parlia: - bscImpl = NewBscAPI(ethImpl) case *bor.Bor: borImpl = NewBorAPI(base, db) case lazy: