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

neon core rpc #215

Merged
merged 4 commits into from
Mar 7, 2024
Merged

neon core rpc #215

merged 4 commits into from
Mar 7, 2024

Conversation

BoogVAr
Copy link

@BoogVAr BoogVAr commented Oct 11, 2023

No description provided.

@BoogVAr BoogVAr force-pushed the NDEV-1871-core-api branch 4 times, most recently from 41b9b7a to 7e94eb1 Compare October 16, 2023 05:43
@BoogVAr BoogVAr force-pushed the NDEV-1871-core-api branch 2 times, most recently from 2a92468 to 0e053af Compare October 20, 2023 12:40
@BoogVAr BoogVAr requested a review from anton-lisanin October 24, 2023 08:10
@Deniskore
Copy link

@BoogVAr Please provide the main changes in the description of this PR, as well as the motivation for why it was done.

Copy link

@andreisilviudragnea andreisilviudragnea left a comment

Choose a reason for hiding this comment

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

Everything looks good to me. I left some comments with suggestions.

Some of the suggestions can also be checked out on https://github.com/neonlabsorg/neon-evm/tree/NDEV-1871-core-api-cr They are just suggestions and I did them to make sure they are actually possible.

evm_loader/lib/src/errors.rs Outdated Show resolved Hide resolved
evm_loader/lib/src/abi/collect_treasury.rs Outdated Show resolved Hide resolved
Dockerfile Show resolved Hide resolved
evm_loader/rpc-client/src/http.rs Outdated Show resolved Hide resolved
evm_loader/lib/src/abi/mod.rs Outdated Show resolved Hide resolved
evm_loader/rpc-client/src/http.rs Outdated Show resolved Hide resolved
evm_loader/rpc-client/src/http.rs Outdated Show resolved Hide resolved
evm_loader/rpc-client/src/http.rs Outdated Show resolved Hide resolved
evm_loader/rpc-client/src/http.rs Outdated Show resolved Hide resolved
evm_loader/lib-interface/src/lib.rs Show resolved Hide resolved
Copy link

@andreisilviudragnea andreisilviudragnea left a comment

Choose a reason for hiding this comment

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

I have no other comments apart from the ones from the previous review.

@BoogVAr BoogVAr force-pushed the NDEV-1871-core-api branch 2 times, most recently from 8ebb6e1 to ffbd24f Compare December 1, 2023 08:48
@BoogVAr BoogVAr force-pushed the NDEV-1871-core-api branch 2 times, most recently from e971ee9 to fb6e13b Compare January 10, 2024 10:21
@anton-lisanin anton-lisanin added the fullTestSuite Run OZ tests and part of dapps tests label Jan 17, 2024
anton-lisanin
anton-lisanin previously approved these changes Jan 26, 2024
@BoogVAr BoogVAr changed the title neon core rpc (for testing) neon core rpc Feb 16, 2024
@BoogVAr BoogVAr force-pushed the NDEV-1871-core-api branch 2 times, most recently from 58f8dbf to 469ec3f Compare February 19, 2024 07:30
Copy link

@andreisilviudragnea andreisilviudragnea left a comment

Choose a reason for hiding this comment

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

I discovered two bugs and two performance improvements.

You can check the suggested fixes tested locally in this branch: #280

If you agree with them, they can be merged directly into this PR, so we merge this PR sooner.

evm_loader/rpc/src/handlers/mod.rs Outdated Show resolved Hide resolved
evm_loader/lib/src/abi/mod.rs Show resolved Hide resolved
evm_loader/lib/src/abi/mod.rs Outdated Show resolved Hide resolved
evm_loader/lib/src/abi/mod.rs Outdated Show resolved Hide resolved
@BoogVAr BoogVAr force-pushed the NDEV-1871-core-api branch 3 times, most recently from 169853d to 18d4dfd Compare March 5, 2024 12:48
@BoogVAr BoogVAr force-pushed the NDEV-1871-core-api branch from b6bcdd3 to 523af5f Compare March 6, 2024 10:39
@neonlabstech
Copy link

Dapps report

Cost report for "Aave" dApp

Action Fee Cost in $ Accounts TRx Estimated Gas Used Gas Used % of EG
Token mint 0.00234464 0.0033520476119775996 9 1 1192320 1172320 98.32
Token approve 0.00234464 0.0033520476119775996 9 1 1192320 1172320 98.32
Deposit to lending pool 0.00795264 0.0113696038286976 4 5 4845360 3976320 82.06
Borrow from lending pool 0.00519928 0.007433223909855199 4 30 3793040 2599640 68.54
Repay 0.00049 0.0007005354041 4 27 2586800 245000 9.47
Flashloan 0.00512928 0.0073331474235551995 4 28 7499680 2564640 34.2
Withdraw 7e-05 0.00010007648629999999 4 5 1857760 35000 1.88
Liquidation 0.00341464 0.0048817881882776 4 57 4967840 1707320 34.37

Cost report for "Saddle Finance" dApp

Action Fee Cost in $ Accounts TRx Estimated Gas Used Gas Used % of EG
Add liquidity 0.00235464 0.0033663442528776 3 2 3209760 1177320 36.68
Swap DAI -> USDC 2e-05 2.85932818e-05 21 1 1797760 10000 0.56
Swap USDC -> DAI 2e-05 2.8584905800000005e-05 21 1 1797760 10000 0.56
Remove liquidity 2e-05 2.8584905800000005e-05 23 1 1937440 10000 0.52
Add liquidity in 3 Tokens 0.00284464 0.0040656883217456 4 30 3559440 1422320 39.96
Swap DAI -> USDC 3 pool 2e-05 2.8584905800000005e-05 21 1 1348400 10000 0.74
Swap USDC -> USDT 3 pool 2e-05 2.8584905800000005e-05 21 1 1348400 10000 0.74
Swap USDC -> DAI 3 pool 2e-05 2.8584905800000005e-05 21 1 1348400 10000 0.74
Remove liquidity 3 pool 3e-05 4.2877358700000004e-05 3 2 1957440 15000 0.77
Add liquidity in metapool 0.00291464 0.004165735492045601 3 31 3299760 1457320 44.16
Swap SUSD -> LP metapool 2e-05 2.8584905800000005e-05 22 1 1807760 10000 0.55
Swap USDC -> SUSD metapool 0.00103 0.0014721226487000002 4 53 3775520 515000 13.64
Swap DAI -> USDT metapool 0.00056 0.0008003773624 4 30 3086160 280000 9.07
Remove liquidity in Metapool 2e-05 2.8584905800000005e-05 23 1 1937440 10000 0.52

Cost report for "Uniswap V3" dApp

Action Fee Cost in $ Accounts TRx Estimated Gas Used Gas Used % of EG
Token approve 0.00234464 0.0033510656767456 9 1 1192320 1172320 98.32
NonfungiblePositionManager - Mint position 0.02786064 0.039819688496385605 4 28 31435120 13930320 44.31
NonfungiblePositionManager - Increase liquidity 0.00044 0.0006288679276 23 23 4364240 220000 5.04
NonfungiblePositionManager - Decrease Liquidity 0.00139808 0.0019981992550432 17 1 4274240 699040 16.35
NonfungiblePositionManager - Collect Fees 0.00466928 0.0066735464476912 20 1 3553040 2334640 65.71
NonfungiblePositionManager - Burn Liquidity Position 2e-05 2.8584905800000005e-05 15 1 3954560 10000 0.25
Direct swap 2e-05 2.8584905800000005e-05 17 1 1328400 10000 0.75
Burn transaction 0.00047936 0.0006851230222144001 11 1 739040 239680 32.43
Collect transaction 0.00234464 0.0033510656767456 12 1 1661680 1172320 70.55

@andreisilviudragnea andreisilviudragnea merged commit e46cb7c into develop Mar 7, 2024
4 checks passed
@andreisilviudragnea andreisilviudragnea deleted the NDEV-1871-core-api branch March 7, 2024 13:25
anton-lisanin pushed a commit that referenced this pull request Mar 14, 2024
* neon core rpc

* add param to CI

* emulate response has been fixed

* fix fmt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fullTestSuite Run OZ tests and part of dapps tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants