From 02446b8f414af6e832d4bf170dbf1171caec02b1 Mon Sep 17 00:00:00 2001 From: ilija Date: Fri, 17 Nov 2023 17:32:30 +0100 Subject: [PATCH] Cleanup chain reader errors --- pkg/types/chain_reader.go | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) diff --git a/pkg/types/chain_reader.go b/pkg/types/chain_reader.go index 8c0f6cb25..65032e12f 100644 --- a/pkg/types/chain_reader.go +++ b/pkg/types/chain_reader.go @@ -2,6 +2,7 @@ package types import ( "context" + "errors" "time" "google.golang.org/grpc/status" @@ -25,26 +26,8 @@ func UnwrapClientError(err error) error { return err } -// Errors used only by relay plugins - -type ErrorChainReaderUnsupported struct{} - -func (e ErrorChainReaderUnsupported) Error() string { - return "ChainReader is not supported by the relay" -} - -type ErrorNoChainReaderInJobSpec struct{} - -func (e ErrorNoChainReaderInJobSpec) Error() string { - return "There is no ChainReader configuration defined in the job spec" -} - var ErrInvalidConfig = errors.New("invalid configuration") -func (e ErrorChainReaderInvalidConfig) Error() string { - return "Invalid ChainReader configuration" -} - type ChainReader interface { // returnVal should satisfy Marshaller interface GetLatestValue(ctx context.Context, bc BoundContract, method string, params, returnVal any) error