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

feat(creating-pair-launcher): creating a pair launcher #32

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

SocksNFlops
Copy link
Contributor

@SocksNFlops SocksNFlops commented Feb 13, 2024

Changes:

  • Re-usable PairLauncher

Flow steps:

  1. Launcher enqueues the pairs and amounts they want using enqueuePair
  2. restrictedSetter transfers over the permission
  3. Launcher transfers over the required balances to the contract
  4. Launcher calls batchCreate5 to do at most 5 at a time
  5. Launcher/originalRestrictedSetter call returmPermissions() to give back the permissions to the restrictedSetter

Testing:

  • [] No tests yet

Reviewers:

@Fiddlekins

Copy link

Compiling 86 files with 0.8.19
Solc 0.8.19 finished in 5.29s
Compiler run �[33msuccessful with warnings:�[0m
�[1;33mWarning (5159)�[0m�[1;37m: "selfdestruct" has been deprecated. The underlying opcode will eventually undergo breaking changes, and its use is not recommended.�[0m
�[34m-->�[0m src/PairLauncher.sol:88:9:
�[34m |�[0m
�[34m88 |�[0m �[33mselfdestruct�[0m(payable(launcher));
�[34m |�[0m �[1;33m^^^^^^^^^^^^�[0m

Analysing contracts...
Running tests...

File % Lines % Statements % Branches % Funcs
script/ComputeInitHash.s.sol 0.00% (0/3) 0.00% (0/4) 100.00% (0/0) 0.00% (0/1)
script/Deploy.s.sol 100.00% (3/3) 100.00% (3/3) 100.00% (0/0) 100.00% (1/1)
src/BasicButtonswapRouter.sol 9.62% (5/52) 11.29% (7/62) 0.00% (0/18) 42.86% (3/7)
src/ButtonswapRouter.sol 77.78% (7/9) 76.47% (13/17) 100.00% (0/0) 77.78% (7/9)
src/ETHButtonswapRouter.sol 14.86% (11/74) 13.92% (11/79) 11.76% (4/34) 77.78% (7/9)
src/PairLauncher.sol 95.65% (22/23) 96.30% (26/27) 66.67% (4/6) 100.00% (5/5)
src/RootButtonswapRouter.sol 3.39% (2/59) 4.49% (4/89) 3.12% (1/32) 33.33% (1/3)
src/examples/ExampleFlashSwap.sol 0.00% (0/31) 0.00% (0/41) 0.00% (0/20) 0.00% (0/1)
src/examples/ExampleOracleSimple.sol 0.00% (0/14) 0.00% (0/14) 0.00% (0/6) 0.00% (0/2)
src/examples/ExampleSlidingWindowOracle.sol 0.00% (0/30) 0.00% (0/46) 0.00% (0/8) 0.00% (0/5)
src/examples/ExampleSwapToPrice.sol 0.00% (0/22) 0.00% (0/30) 0.00% (0/6) 0.00% (0/2)
src/libraries/Babylonian.sol 0.00% (0/8) 0.00% (0/10) 0.00% (0/4) 0.00% (0/1)
src/libraries/ButtonswapLibrary.sol 56.94% (41/72) 57.41% (62/108) 79.17% (19/24) 66.67% (8/12)
src/libraries/ButtonwoodOracleLibrary.sol 0.00% (0/10) 0.00% (0/12) 0.00% (0/2) 0.00% (0/2)
src/libraries/Math.sol 0.00% (0/25) 0.00% (0/28) 0.00% (0/4) 0.00% (0/1)
src/libraries/TransferHelper.sol 50.00% (4/8) 50.00% (6/12) 25.00% (2/8) 50.00% (2/4)
test/mocks/DeflatingERC20.sol 0.00% (0/27) 0.00% (0/31) 0.00% (0/6) 0.00% (0/8)
test/mocks/MockWeth.sol 0.00% (0/19) 0.00% (0/22) 0.00% (0/8) 0.00% (0/6)
Total 19.43% (95/489) 20.79% (132/635) 16.13% (30/186) 43.04% (34/79)

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.

1 participant