forked from cerc-io/laconicd-deprecated
Implement eth_pendingTransactions, bump sdk version (#124)
* Update sdk version, implement pending txs, fix nonce check * Bump cached dependencies in circleCI * bump circleci go version * updated linter and fixed bugs relating to go version 1.13
This commit is contained in:
+9
-9
@@ -9,11 +9,11 @@ const (
|
||||
// DefaultCodespace reserves a Codespace for Ethermint.
|
||||
DefaultCodespace sdk.CodespaceType = "ethermint"
|
||||
|
||||
CodeInvalidValue sdk.CodeType = 1
|
||||
CodeInvalidChainID sdk.CodeType = 2
|
||||
CodeInvalidSender sdk.CodeType = 3
|
||||
CodeVMExecution sdk.CodeType = 4
|
||||
CodeInvalidIntrinsicGas sdk.CodeType = 5
|
||||
CodeInvalidValue sdk.CodeType = 1
|
||||
CodeInvalidChainID sdk.CodeType = 2
|
||||
CodeInvalidSender sdk.CodeType = 3
|
||||
CodeVMExecution sdk.CodeType = 4
|
||||
CodeInvalidNonce sdk.CodeType = 5
|
||||
)
|
||||
|
||||
// CodeToDefaultMsg takes the CodeType variable and returns the error string
|
||||
@@ -27,8 +27,8 @@ func CodeToDefaultMsg(code sdk.CodeType) string {
|
||||
return "could not derive sender from transaction"
|
||||
case CodeVMExecution:
|
||||
return "error while executing evm transaction"
|
||||
case CodeInvalidIntrinsicGas:
|
||||
return "invalid intrinsic gas"
|
||||
case CodeInvalidNonce:
|
||||
return "invalid nonce"
|
||||
default:
|
||||
return sdk.CodeToDefaultMsg(code)
|
||||
}
|
||||
@@ -55,6 +55,6 @@ func ErrVMExecution(msg string) sdk.Error {
|
||||
}
|
||||
|
||||
// ErrVMExecution returns a standardized SDK error resulting from an error in EVM execution.
|
||||
func ErrInvalidIntrinsicGas(msg string) sdk.Error {
|
||||
return sdk.NewError(DefaultCodespace, CodeInvalidIntrinsicGas, msg)
|
||||
func ErrInvalidNonce(msg string) sdk.Error {
|
||||
return sdk.NewError(DefaultCodespace, CodeInvalidNonce, msg)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user