Skip to content

Commit

Permalink
Remove HistoryDepth-FinalityDepth validation check
Browse files Browse the repository at this point in the history
  • Loading branch information
HelloKashif committed Jun 12, 2024
1 parent 0d305d7 commit 7d09fa8
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
5 changes: 5 additions & 0 deletions .changeset/healthy-plants-guess.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"chainlink": patch
---

#internal removed HistoryDepth to FinalityDepth validation
4 changes: 0 additions & 4 deletions core/chains/evm/config/toml/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -380,10 +380,6 @@ func (c *Chain) ValidateConfig() (err error) {
err = multierr.Append(err, commonconfig.ErrInvalid{Name: "GasEstimator.BumpTxDepth", Value: *c.GasEstimator.BumpTxDepth,
Msg: "must be less than or equal to Transactions.MaxInFlight"})
}
if *c.HeadTracker.HistoryDepth < *c.FinalityDepth {
err = multierr.Append(err, commonconfig.ErrInvalid{Name: "HeadTracker.HistoryDepth", Value: *c.HeadTracker.HistoryDepth,
Msg: "must be equal to or greater than FinalityDepth"})
}
if *c.FinalityDepth < 1 {
err = multierr.Append(err, commonconfig.ErrInvalid{Name: "FinalityDepth", Value: *c.FinalityDepth,
Msg: "must be greater than or equal to 1"})
Expand Down
3 changes: 1 addition & 2 deletions core/services/chainlink/config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1282,11 +1282,10 @@ func TestConfig_Validate(t *testing.T) {
- WSURL: missing: required for primary nodes
- HTTPURL: missing: required for all nodes
- 1.HTTPURL: missing: required for all nodes
- 1: 10 errors:
- 1: 9 errors:
- ChainType: invalid value (Foo): must not be set with this chain id
- Nodes: missing: must have at least one node
- ChainType: invalid value (Foo): must be one of arbitrum, celo, gnosis, kroma, metis, optimismBedrock, scroll, wemix, xlayer, zkevm, zksync or omitted
- HeadTracker.HistoryDepth: invalid value (30): must be equal to or greater than FinalityDepth
- GasEstimator.BumpThreshold: invalid value (0): cannot be 0 if auto-purge feature is enabled for Foo
- Transactions.AutoPurge.Threshold: missing: needs to be set if auto-purge feature is enabled for Foo
- Transactions.AutoPurge.MinAttempts: missing: needs to be set if auto-purge feature is enabled for Foo
Expand Down

0 comments on commit 7d09fa8

Please sign in to comment.