Commit Graph

11 Commits

Author SHA1 Message Date
Ali Behjati 33f5b8a5bf
[eth] Remove ownership entirely in favor of governance (#405) 2022-11-30 12:13:46 +01:00
Ali Behjati c3461e5e1c
[eth] Use PythErrors everywhere (#404)
* Remove unnecessary check
* Use PythErrors everywhere
2022-11-29 18:30:45 +01:00
Ali Behjati 45ce07725f
Update contract initializer (#397)
* Update contract initializer
* Reduce optimizer runs to 1000
2022-11-29 12:11:49 +01:00
Ali Behjati d6e25d9209
Add pre-commit globally (#393)
* Add pre-commit globally

* Fix CI errors
2022-11-24 14:14:29 +01:00
Ali Behjati 275c7b8d1a
[eth] Add parsePriceFeedUpdates method (#392)
* Add the implementation with tests and benchmark

* Refactor the contract to reduce redundancy

* Reduce optimization runs as the contract was huge

It has 177 more gas usage on some benchmark tests
2022-11-23 17:16:28 +01:00
Ali Behjati bb06fdb831
[eth] Gas improvement: Optimize getPrice and getEmaPrice (#389)
* Optimize getPrice and getEmaPrice
2022-11-18 14:42:06 +01:00
Ali Behjati 2597596022
[eth] Gas improvement: Optimize events (#387)
* Update pyth-sdk-solidity version

* Add parsePriceFeedUpdates as an empty method

To be implemented in the future

* Update events

* Fix tests

* Address Tom review comment

* Fix Pyth forge test
2022-11-17 17:44:21 +01:00
Ali Behjati b23258112d
Remove middle structs (#375)
* Remove middle structs

* Parse and process attestation in place

It helps a lot because we won't expand memory anymore

* Update comments

* Remove unusued PriceAttestation struct
2022-11-04 16:44:07 +01:00
Ali Behjati 1a9dfb6c0d
[eth]: Fix gas benchmark to generate useful gas snapshot (#372)
* [eth]: Fix incorrect gas usage problem

* Make gas report more accurate

* Update readme

* Address Jayant comment
2022-11-03 12:18:48 +01:00
Ali Behjati 0df243ba9e
[eth] Add benchmark tests (#368)
* Add remappings

This helps vs code solidity LSP work

* Remove unused wormhole contract

* Format foundry config file

* Fix install foundry script

* Add benchmark tests and its utils
2022-11-02 10:59:39 +01:00
Ali Behjati 1c17499d03
Add foundry base (#362)
* Add foundry base

* Address Reisen comments
2022-10-25 17:49:24 +02:00