diff --git a/pkg/reportingplugins/mercury/v1/mercury.go b/pkg/reportingplugins/mercury/v1/mercury.go index 379ad2993..50fb60727 100644 --- a/pkg/reportingplugins/mercury/v1/mercury.go +++ b/pkg/reportingplugins/mercury/v1/mercury.go @@ -379,35 +379,6 @@ func (rp *reportingPlugin) validateReport(rf ReportFields) error { ) } -func (rp *reportingPlugin) ShouldAcceptFinalizedReport(ctx context.Context, repts types.ReportTimestamp, report types.Report) (bool, error) { - reportEpochRound := mercury.EpochRound{Epoch: repts.Epoch, Round: repts.Round} - if !rp.latestAcceptedEpochRound.Less(reportEpochRound) { - rp.logger.Debugw("ShouldAcceptFinalizedReport() = false, report is stale", - "latestAcceptedEpochRound", rp.latestAcceptedEpochRound, - "reportEpochRound", reportEpochRound, - ) - return false, nil - } - - if !(len(report) <= rp.maxReportLength) { - rp.logger.Warnw("report violates MaxReportLength limit set by ReportCodec", - "reportEpochRound", reportEpochRound, - "reportLength", len(report), - "maxReportLength", rp.maxReportLength, - ) - return false, nil - } - - rp.logger.Debugw("ShouldAcceptFinalizedReport() = true", - "reportEpochRound", reportEpochRound, - "latestAcceptedEpochRound", rp.latestAcceptedEpochRound, - ) - - rp.latestAcceptedEpochRound = reportEpochRound - - return true, nil -} - func (rp *reportingPlugin) ShouldTransmitAcceptedReport(ctx context.Context, repts types.ReportTimestamp, report types.Report) (bool, error) { return true, nil } diff --git a/pkg/reportingplugins/mercury/v2/mercury.go b/pkg/reportingplugins/mercury/v2/mercury.go index 10f425956..1eacbf9e1 100644 --- a/pkg/reportingplugins/mercury/v2/mercury.go +++ b/pkg/reportingplugins/mercury/v2/mercury.go @@ -379,35 +379,6 @@ func (rp *reportingPlugin) validateReport(rf ReportFields) error { ) } -func (rp *reportingPlugin) ShouldAcceptFinalizedReport(ctx context.Context, repts ocrtypes.ReportTimestamp, report ocrtypes.Report) (bool, error) { - reportEpochRound := mercury.EpochRound{Epoch: repts.Epoch, Round: repts.Round} - if !rp.latestAcceptedEpochRound.Less(reportEpochRound) { - rp.logger.Debugw("ShouldAcceptFinalizedReport() = false, report is stale", - "latestAcceptedEpochRound", rp.latestAcceptedEpochRound, - "reportEpochRound", reportEpochRound, - ) - return false, nil - } - - if !(len(report) <= rp.maxReportLength) { - rp.logger.Warnw("report violates MaxReportLength limit set by ReportCodec", - "reportEpochRound", reportEpochRound, - "reportLength", len(report), - "maxReportLength", rp.maxReportLength, - ) - return false, nil - } - - rp.logger.Debugw("ShouldAcceptFinalizedReport() = true", - "reportEpochRound", reportEpochRound, - "latestAcceptedEpochRound", rp.latestAcceptedEpochRound, - ) - - rp.latestAcceptedEpochRound = reportEpochRound - - return true, nil -} - func (rp *reportingPlugin) ShouldTransmitAcceptedReport(ctx context.Context, repts ocrtypes.ReportTimestamp, report ocrtypes.Report) (bool, error) { return true, nil } diff --git a/pkg/reportingplugins/mercury/v3/mercury.go b/pkg/reportingplugins/mercury/v3/mercury.go index 6e82082ef..5a86a7345 100644 --- a/pkg/reportingplugins/mercury/v3/mercury.go +++ b/pkg/reportingplugins/mercury/v3/mercury.go @@ -422,35 +422,6 @@ func (rp *reportingPlugin) validateReport(rf ReportFields) error { ) } -func (rp *reportingPlugin) ShouldAcceptFinalizedReport(ctx context.Context, repts ocrtypes.ReportTimestamp, report ocrtypes.Report) (bool, error) { - reportEpochRound := mercury.EpochRound{Epoch: repts.Epoch, Round: repts.Round} - if !rp.latestAcceptedEpochRound.Less(reportEpochRound) { - rp.logger.Debugw("ShouldAcceptFinalizedReport() = false, report is stale", - "latestAcceptedEpochRound", rp.latestAcceptedEpochRound, - "reportEpochRound", reportEpochRound, - ) - return false, nil - } - - if !(len(report) <= rp.maxReportLength) { - rp.logger.Warnw("report violates MaxReportLength limit set by ReportCodec", - "reportEpochRound", reportEpochRound, - "reportLength", len(report), - "maxReportLength", rp.maxReportLength, - ) - return false, nil - } - - rp.logger.Debugw("ShouldAcceptFinalizedReport() = true", - "reportEpochRound", reportEpochRound, - "latestAcceptedEpochRound", rp.latestAcceptedEpochRound, - ) - - rp.latestAcceptedEpochRound = reportEpochRound - - return true, nil -} - func (rp *reportingPlugin) ShouldTransmitAcceptedReport(ctx context.Context, repts ocrtypes.ReportTimestamp, report ocrtypes.Report) (bool, error) { return true, nil }