-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[CCIP-2958] Token price reader implementation (#67)
* WIP new token price reader * Bind first token aggregator to price reader * Moving price reader binding to chainlink inprocess.go and removing from commit factory * Calculate USD price per 1e18 of smallest token denomination with 18 decimal precision * Fix call to GetLatestValue Signed-off-by: asoliman <[email protected]> * Add decimals to offchain config Signed-off-by: asoliman <[email protected]> * Use TokenDecimals in on chain reader Signed-off-by: asoliman <[email protected]> * Normalize raw token prices Signed-off-by: asoliman <[email protected]> * Validate all tokens has decimals in offchain config Signed-off-by: asoliman <[email protected]> * Add comments Signed-off-by: asoliman <[email protected]> * Add new on chain prices reader to commitocb factory Signed-off-by: asoliman <[email protected]> * Validate ArbitrumPriceSource in the offchain config Signed-off-by: asoliman <[email protected]> * Add comments Signed-off-by: asoliman <[email protected]> * Fix tests - failing because of race condition Signed-off-by: asoliman <[email protected]> * Make the test work with one token as expected Signed-off-by: asoliman <[email protected]> * Update pluginconfig/commit.go Co-authored-by: Makram <[email protected]> * Update pluginconfig/commit.go Co-authored-by: Makram <[email protected]> * review comments Signed-off-by: asoliman <[email protected]> --------- Signed-off-by: asoliman <[email protected]> Co-authored-by: Makram <[email protected]>
- Loading branch information
1 parent
f342f6b
commit 1b2d9ea
Showing
12 changed files
with
301 additions
and
131 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.