Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] Adds Scroll network support #9299

Closed
wants to merge 16 commits into from
Closed
21 changes: 21 additions & 0 deletions core/chains/evm/config/toml/defaults/Scroll_Testnet.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
ChainID = '534353'
FinalityDepth = 1
LogPollInterval = '3s'
MinIncomingConfirmations = 1
# Scroll only emits blocks when a new tx is received, so this method of liveness detection is not useful
NoNewHeadsThreshold = '0'
OCR.ContractConfirmations = 1

[GasEstimator]
Mode = 'L2Suggested'
# Scroll uses the L2Suggested estimator; we don't want to place any limits on the minimum gas price
PriceMin = '0'
# Never bump gas on Scroll
BumpThreshold = 0

[GasEstimator.BlockHistory]
# Force an error if someone enables the estimator by accident; we never want to run the block history estimator on Scroll
BlockHistorySize = 0

[HeadTracker]
HistoryDepth = 50
6 changes: 6 additions & 0 deletions integration-tests/contracts/contract_deployer.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,8 @@ func NewContractDeployer(bcClient blockchain.EVMClient) (ContractDeployer, error
return &CeloContractDeployer{NewEthereumContractDeployer(clientImpl)}, nil
case *blockchain.QuorumClient:
return &QuorumContractDeployer{NewEthereumContractDeployer(clientImpl)}, nil
case *blockchain.ScrollClient:
return &ScrollContractDeployer{NewEthereumContractDeployer(clientImpl)}, nil
}
return nil, errors.New("unknown blockchain client implementation for contract deployer, register blockchain client in NewContractDeployer")
}
Expand Down Expand Up @@ -160,6 +162,10 @@ type QuorumContractDeployer struct {
*EthereumContractDeployer
}

type ScrollContractDeployer struct {
*EthereumContractDeployer
}

// NewEthereumContractDeployer returns an instantiated instance of the ETH contract deployer
func NewEthereumContractDeployer(ethClient blockchain.EVMClient) *EthereumContractDeployer {
return &EthereumContractDeployer{
Expand Down
2 changes: 1 addition & 1 deletion integration-tests/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ require (
github.com/rs/zerolog v1.29.1
github.com/slack-go/slack v0.12.2
github.com/smartcontractkit/chainlink-env v0.36.0
github.com/smartcontractkit/chainlink-testing-framework v1.15.0
github.com/smartcontractkit/chainlink-testing-framework v1.15.1-0.20230803114539-6b5389e0aa2a
github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000
github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac
github.com/smartcontractkit/ocr2keepers v0.7.2
Expand Down
4 changes: 2 additions & 2 deletions integration-tests/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -2246,8 +2246,8 @@ github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a8
github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw=
github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA=
github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c=
github.com/smartcontractkit/chainlink-testing-framework v1.15.0 h1:1ARN70Httew87gFQ27MAv4Iat7aoCnM3K87/d0r4Aho=
github.com/smartcontractkit/chainlink-testing-framework v1.15.0/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg=
github.com/smartcontractkit/chainlink-testing-framework v1.15.1-0.20230803114539-6b5389e0aa2a h1:+Ou6NgoNGTMdzoPOCYZLrlAw5MmkU2gwT0F5SaEGg1U=
github.com/smartcontractkit/chainlink-testing-framework v1.15.1-0.20230803114539-6b5389e0aa2a/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg=
github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI=
github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0=
github.com/smartcontractkit/ocr2keepers v0.7.2 h1:ls8KsVImEEFFVAneFbhS7HXJ9nUlyX+tKoxSQNeirHs=
Expand Down
12 changes: 12 additions & 0 deletions integration-tests/networks/known_networks.go
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,17 @@ var (
GasEstimationBuffer: 1000,
}

ScrollTestnet = blockchain.EVMNetwork{
Name: "Scroll Testnet",
ClientImplementation: blockchain.ScrollClientImplementation,
ChainID: 534353,
Simulated: false,
ChainlinkTransactionLimit: 5000,
Timeout: blockchain.JSONStrDuration{Duration: time.Minute},
MinimumConfirmations: 1,
GasEstimationBuffer: 0,
}

CeloMainnet = blockchain.EVMNetwork{
Name: "Celo",
ClientImplementation: blockchain.CeloClientImplementation,
Expand Down Expand Up @@ -395,6 +406,7 @@ var (
"AVALANCHE_MAINNET": AvalancheMainnet,
"QUORUM": Quorum,
"BASE_MAINNET": BaseMainnet,
"SCROLL_TESTNET": ScrollTestnet,
}
)

Expand Down
Loading