Further updates to wrappers.go and rpc/handler.go, chaising bugs
This commit is contained in:
parent
86fd4f27e2
commit
7d7fad0988
@ -3,11 +3,11 @@ package wrappers
|
|||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
|
"fmt"
|
||||||
"math/big"
|
"math/big"
|
||||||
|
"reflect"
|
||||||
"sync"
|
"sync"
|
||||||
"time"
|
"time"
|
||||||
"reflect"
|
|
||||||
"fmt"
|
|
||||||
|
|
||||||
"github.com/ethereum/go-ethereum"
|
"github.com/ethereum/go-ethereum"
|
||||||
"github.com/ethereum/go-ethereum/common"
|
"github.com/ethereum/go-ethereum/common"
|
||||||
@ -19,12 +19,12 @@ import (
|
|||||||
"github.com/ethereum/go-ethereum/event"
|
"github.com/ethereum/go-ethereum/event"
|
||||||
"github.com/ethereum/go-ethereum/log"
|
"github.com/ethereum/go-ethereum/log"
|
||||||
"github.com/ethereum/go-ethereum/node"
|
"github.com/ethereum/go-ethereum/node"
|
||||||
|
"github.com/ethereum/go-ethereum/params"
|
||||||
"github.com/ethereum/go-ethereum/plugins/interfaces"
|
"github.com/ethereum/go-ethereum/plugins/interfaces"
|
||||||
"github.com/ethereum/go-ethereum/rlp"
|
"github.com/ethereum/go-ethereum/rlp"
|
||||||
"github.com/ethereum/go-ethereum/rpc"
|
"github.com/ethereum/go-ethereum/rpc"
|
||||||
"github.com/openrelayxyz/plugeth-utils/core"
|
"github.com/openrelayxyz/plugeth-utils/core"
|
||||||
"github.com/openrelayxyz/plugeth-utils/restricted"
|
"github.com/openrelayxyz/plugeth-utils/restricted"
|
||||||
"github.com/openrelayxyz/plugeth-utils/restricted/params"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type WrappedScopeContext struct {
|
type WrappedScopeContext struct {
|
||||||
@ -583,7 +583,9 @@ func (b *Backend) ChainConfig() *params.ChainConfig {
|
|||||||
// pparams.ChainConfig, so this function shouldn't need to be touched for
|
// pparams.ChainConfig, so this function shouldn't need to be touched for
|
||||||
// simple changes to ChainConfig (though pparams.ChainConfig may need to be
|
// simple changes to ChainConfig (though pparams.ChainConfig may need to be
|
||||||
// updated). Note that this probably won't carry over consensus engine data.
|
// updated). Note that this probably won't carry over consensus engine data.
|
||||||
if b.chainConfig != nil { return b.chainConfig }
|
if b.chainConfig != nil {
|
||||||
|
return b.chainConfig
|
||||||
|
}
|
||||||
b.chainConfig = ¶ms.ChainConfig{}
|
b.chainConfig = ¶ms.ChainConfig{}
|
||||||
nval := reflect.ValueOf(b.b.ChainConfig())
|
nval := reflect.ValueOf(b.b.ChainConfig())
|
||||||
ntype := nval.Type()
|
ntype := nval.Type()
|
||||||
|
@ -333,6 +333,8 @@ func (h *handler) handleCall(cp *callProc, msg *jsonrpcMessage) *jsonrpcMessage
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return msg.errorResponse(&invalidParamsError{err.Error()})
|
return msg.errorResponse(&invalidParamsError{err.Error()})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pluginGetRPCCalls(string(msg.ID), string(msg.Method), string(msg.Params))
|
||||||
start := time.Now()
|
start := time.Now()
|
||||||
answer := h.runMethod(cp.ctx, msg, callb, args)
|
answer := h.runMethod(cp.ctx, msg, callb, args)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user