From 5df9c12a25139f0d0fa7d362f2f756eebaf517f0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=96mer=20Faruk=20IRMAK?= Date: Fri, 3 Nov 2023 14:27:33 +0300 Subject: [PATCH] Fallback to feeder traces for blocks <= 0.12.2 there was social consensus on this --- rpc/handlers.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rpc/handlers.go b/rpc/handlers.go index f62026188b..49b342db9d 100644 --- a/rpc/handlers.go +++ b/rpc/handlers.go @@ -1374,7 +1374,7 @@ func (h *Handler) LegacyTraceBlockTransactions(ctx context.Context, hash felt.Fe return h.traceBlockTransactions(ctx, block, true) } -var traceFallbackVersion = semver.MustParse("0.12.0") +var traceFallbackVersion = semver.MustParse("0.12.2") func (h *Handler) traceBlockTransactions(ctx context.Context, block *core.Block, //nolint: gocyclo legacyJSON bool, @@ -1384,7 +1384,7 @@ func (h *Handler) traceBlockTransactions(ctx context.Context, block *core.Block, if blockVer, err := core.ParseBlockVersion(block.ProtocolVersion); err != nil { return nil, ErrUnexpectedError.CloneWithData(err.Error()) } else if blockVer.Compare(traceFallbackVersion) != 1 { - // version <= 0.12.0 + // version <= 0.12.2 return h.fetchTraces(ctx, block.Hash, legacyJSON) }