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

Opt-in Aggregate Rate Limiter #698

Closed
wants to merge 50 commits into from
Closed

Conversation

justinkaseman
Copy link
Collaborator

@justinkaseman justinkaseman commented Apr 9, 2024

Motivation

Currently, all token pools on a given lane are included in its ARL (Aggregate Rate Limiter). With permissonless token pools there may no longer be a price being reported for every token. ARL'ing should instead be opt-in, only when the pricegetter has been configured.

Solution

Add an additional piece of configuration per token for whether or not to include it in the ARL total.
This defaults to off, requiring admin/owner action to opt-in a token before it is included.

RensR added 30 commits March 4, 2024 11:45
# Conflicts:
#	contracts/src/v0.8/ccip/offRamp/EVM2EVMOffRamp.sol
#	contracts/src/v0.8/ccip/onRamp/EVM2EVMOnRamp.sol
#	contracts/src/v0.8/ccip/pools/TokenPool.sol
#	contracts/src/v0.8/ccip/test/StructFactory.sol
#	contracts/src/v0.8/ccip/test/applications/ImmutableExample.t.sol
#	contracts/src/v0.8/ccip/test/e2e/End2End.t.sol
#	contracts/src/v0.8/ccip/test/offRamp/EVM2EVMOffRamp.t.sol
#	contracts/src/v0.8/ccip/test/offRamp/EVM2EVMOffRampSetup.t.sol
#	contracts/src/v0.8/ccip/test/onRamp/EVM2EVMOnRamp.t.sol
#	contracts/src/v0.8/ccip/test/pools/BurnMintTokenPool.t.sol
#	contracts/src/v0.8/ccip/test/pools/LockReleaseTokenPool.t.sol
#	contracts/src/v0.8/ccip/test/pools/USDCTokenPool.t.sol
Create 1.4 versions of all in-use contracts so nothing breaks
@@ -496,8 +528,9 @@ contract EVM2EVMOffRamp is IAny2EVMOffRamp, AggregateRateLimiter, ITypeAndVersio
address receiver,
bytes[] memory encodedSourceTokenData,
bytes[] memory offchainTokenData
) internal returns (Client.EVMTokenAmount[] memory) {
Client.EVMTokenAmount[] memory destTokenAmounts = sourceTokenAmounts;
) internal returns (Client.EVMTokenAmount[] memory destTokenAmounts) {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using a named return saves some stack size

Copy link
Contributor

LCOV of commit 8642350 during Solidity Foundry #3627

Summary coverage rate:
  lines......: 98.5% (968 of 983 lines)
  functions..: 95.9% (209 of 218 functions)
  branches...: 89.5% (374 of 418 branches)

Files changed coverage rate: n/a

⛔ The code coverage is too low: 98.47. Expected at least 98.5.

Copy link
Contributor

LCOV of commit 488a841 during Solidity Foundry #3628

Summary coverage rate:
  lines......: 98.5% (968 of 983 lines)
  functions..: 95.9% (209 of 218 functions)
  branches...: 89.5% (374 of 418 branches)

Files changed coverage rate: n/a

⛔ The code coverage is too low: 98.47. Expected at least 98.5.

Copy link
Contributor

LCOV of commit e6681d4 during Solidity Foundry #3629

Summary coverage rate:
  lines......: 98.5% (968 of 983 lines)
  functions..: 95.9% (209 of 218 functions)
  branches...: 89.5% (374 of 418 branches)

Files changed coverage rate: n/a

⛔ The code coverage is too low: 98.47. Expected at least 98.5.

Copy link
Contributor

LCOV of commit 95512b8 during Solidity Foundry #3630

Summary coverage rate:
  lines......: 98.5% (968 of 983 lines)
  functions..: 95.9% (209 of 218 functions)
  branches...: 89.5% (374 of 418 branches)

Files changed coverage rate: n/a

⛔ The code coverage is too low: 98.47. Expected at least 98.5.

Copy link
Contributor

LCOV of commit a67cc61 during Solidity Foundry #3631

Summary coverage rate:
  lines......: 98.5% (968 of 983 lines)
  functions..: 95.9% (209 of 218 functions)
  branches...: 89.5% (374 of 418 branches)

Files changed coverage rate: n/a

⛔ The code coverage is too low: 98.47. Expected at least 98.5.

Copy link
Contributor

LCOV of commit 9a9e5a9 during Solidity Foundry #3633

Summary coverage rate:
  lines......: 98.5% (968 of 983 lines)
  functions..: 95.9% (209 of 218 functions)
  branches...: 89.5% (374 of 418 branches)

Files changed coverage rate: n/a

⛔ The code coverage is too low: 98.47. Expected at least 98.5.

Copy link
Contributor

LCOV of commit a80a8b9 during Solidity Foundry #3635

Summary coverage rate:
  lines......: 98.5% (968 of 983 lines)
  functions..: 95.9% (209 of 218 functions)
  branches...: 89.5% (374 of 418 branches)

Files changed coverage rate: n/a

⛔ The code coverage is too low: 98.47. Expected at least 98.5.

Copy link
Contributor

LCOV of commit 0704b11 during Solidity Foundry #3636

Summary coverage rate:
  lines......: 98.5% (968 of 983 lines)
  functions..: 95.9% (209 of 218 functions)
  branches...: 89.5% (374 of 418 branches)

Files changed coverage rate: n/a

⛔ The code coverage is too low: 98.47. Expected at least 98.5.

Base automatically changed from permissionless-token-pools-demo to ccip-develop April 12, 2024 08:44
@RensR
Copy link
Collaborator

RensR commented Apr 12, 2024

closed in favour of #714

@RensR RensR closed this Apr 12, 2024
@mateusz-sekara mateusz-sekara deleted the CCIP-1986-on-chain branch September 3, 2024 13:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants