bnb-party / BNBParty.Factory

Smart contract manages Liquidity Pools and Token creation, enabling decentralized swaps and liquidity handling
MIT License
2 stars 0 forks source link

add `README` #48

Closed YouStillAlive closed 2 months ago

YouStillAlive commented 2 months ago

closes #3

github-actions[bot] commented 2 months ago

Methods

Symbol Meaning
Execution gas for this method does not include intrinsic gas overhead
Cost was non-zero but below the precision setting for the currency display (see options)
Min Max Avg Calls usd avg
BNBPartyFactory
       createParty(string,string) 5,668,766 5,882,454 5,723,205 31 3.26
       joinParty(address,uint256) 153,302 5,653,179 1,819,582 20 1.04
       leaveParty(address,uint256,uint256) 174,469 191,569 180,169 3 0.10
       setNonfungiblePositionManager(address,address) 27,399 68,928 66,159 15 0.04
       setSwapRouter(address) 24,119 46,259 44,783 15 0.03
       withdrawFee() - - 31,792 2 0.02
       withdrawPartyLPFee(address[]) - - 173,880 2 0.10
NonfungiblePositionManager
       approve(address,uint256) 46,052 46,383 46,273 3 0.03
SwapRouter
       exactInput((bytes,address,uint256,uint256,uint256)) 132,707 142,139 138,995 3 0.08
       multicall(bytes[]) - - 160,866 2 0.09

Deployments

Min Max Avg Block % usd avg
BNBPartyFactory 3,324,777 3,324,789 3,324,788 2.6 % 1.89
MockNonfungibleTokenPositionDescriptor - - 111,537 0.1 % 0.06
NonfungiblePositionManager 5,171,500 5,171,524 5,171,519 4 % 2.95
SwapRouter 2,201,066 2,201,090 2,201,088 1.7 % 1.25
UniswapV3Factory 5,437,097 5,437,109 5,437,107 4.2 % 3.10

Solidity and Network Config

Settings Value
Solidity: version 0.8.24
Solidity: optimized true
Solidity: runs 200
Solidity: viaIR false
Block Limit 130,000,000
L1 Gas Price 1 gwei
Token Price 569.80 usd/bnb
Network BINANCE
Toolchain hardhat
github-actions[bot] commented 2 months ago

Slither report

THIS CHECKLIST IS NOT COMPLETE. Use --show-ignored-findings to show all the results. Summary

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyLiquidity.sol#L7-L30

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyManageable.sol#L26-L32

reentrancy-no-eth

Impact: Medium Confidence: Medium

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyLiquidity.sol#L67-L108

uninitialized-local

Impact: Medium Confidence: Medium

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyLiquidity.sol#L10

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyLiquidity.sol#L9

unused-return

Impact: Medium Confidence: Medium

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyLiquidity.sol#L67-L108

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartySwaps.sol#L32-L49

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyLiquidity.sol#L7-L30

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyManageable.sol#L59-L71

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyLiquidity.sol#L67-L108

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyView.sol#L40-L60

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyLiquidity.sol#L67-L108

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyLiquidity.sol#L32-L65

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyLiquidity.sol#L67-L108

shadowing-local

Impact: Low Confidence: High

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/token/ERC20Token.sol#L9

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/token/ERC20Token.sol#L10

reentrancy-benign

Impact: Low Confidence: Medium

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyLiquidity.sol#L7-L30

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyFactory.sol#L21-L42

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyLiquidity.sol#L32-L65

reentrancy-events

Impact: Low Confidence: Medium

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartySwaps.sol#L7-L16

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartySwaps.sol#L7-L16

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartySwaps.sol#L18-L25

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyLiquidity.sol#L67-L108

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartySwaps.sol#L7-L16

assembly

Impact: Informational Confidence: High

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/node_modules/@openzeppelin/contracts/utils/Address.sol#L146-L158

low-level-calls

Impact: Informational Confidence: High

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/node_modules/@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol#L110-L117

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/node_modules/@openzeppelin/contracts/utils/Address.sol#L95-L98

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/node_modules/@openzeppelin/contracts/utils/Address.sol#L104-L107

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/node_modules/@openzeppelin/contracts/utils/Address.sol#L41-L50

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartySwaps.sol#L18-L25

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/node_modules/@openzeppelin/contracts/utils/Address.sol#L83-L89

naming-convention

Impact: Informational Confidence: High

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyState.sol#L22

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyState.sol#L13

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyManageable.sol#L18

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyManageable.sol#L8

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/interfaces/INonfungiblePositionManager.sol#L184

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyManageable.sol#L9

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/node_modules/@openzeppelin/contracts/token/ERC20/extensions/IERC20Permit.sol#L89

reentrancy-unlimited-gas

Impact: Informational Confidence: Medium

https://github.com/bnb-party/BNBParty.Factory/blob/5aca9394211f87636c2696c6bc25d27632bab24b/contracts/BNBPartyManageable.sol#L26-L32

unused-import

Impact: Informational Confidence: High

codecov-commenter commented 2 months ago

:warning: Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.