CarmineOptions / derisk-research

MIT License
6 stars 31 forks source link

Rework SwapAmm class and write test cases #228

Open djeck1432 opened 3 hours ago

djeck1432 commented 3 hours ago
  1. Read our Contributor Guidelines and README.
  2. For SwapAmm do next things:
    1. Create mapping for add_pool values to move it out of the class to another file, like constants.py
      self.add_pool(
          "ETH",
          "USDC",
          [
              "0x04d0390b777b424e43839cd1e744799f3de6c176c7e32c1812a41dbd9c19db6a",  # jediswap
              "0x030615bec9c1506bfac97d9dbd3c546307987d467a7f95d5533c2e861eb81f3f",  # sithswap
              "0x000023c72abdf49dffc85ae3ede714f2168ad384cc67d08524732acea90df325",  # 10kswap
          ],
          1,
      )
  3. Add to __init__ method adding all pools from your new mapping
  4. Remove from init() method adding pools
  5. For each method, please add docstring and annotation types
  6. Create new folder, tests in shared folder
  7. Create for SwapAmm test cases with positive and negative scenarios in a new file test_swap_amm.py
  8. Please, use pytest for creating and running test cases.
blessingbytes commented 2 hours ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

Hello, i'm a frontend and a blockchain developer, i would love to take this task

How I plan on tackling this issue

I would take a look at the requirement and follow it exactly to make sure that i complete everything and leave no stone unturned. i would first go through the codebase to understand the project and coding style

blessingbytes commented 2 hours ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

Hello, i'm a frontend and a blockchain developer, i would love to take this task

How I plan on tackling this issue

I would take a look at the requirement and follow it exactly to make sure that i complete everything and leave no stone unturned. i would first go through the codebase to understand the project and coding style

blessingbytes commented 2 hours ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

Hello, i'm a frontend and a blockchain developer, i would love to take this task

How I plan on tackling this issue

I would take a look at the requirement and follow it exactly to make sure that i complete everything and leave no stone unturned. i would first go through the codebase to understand the project and coding style

blessingbytes commented 2 hours ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

Hello, i'm a frontend and a blockchain developer, i would love to take this task

How I plan on tackling this issue

I would take a look at the requirement and follow it exactly to make sure that i complete everything and leave no stone unturned. i would first go through the codebase to understand the project and coding style

blessingbytes commented 2 hours ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

Hello, i'm a frontend and a blockchain developer, i would love to take this task

How I plan on tackling this issue

I would take a look at the requirement and follow it exactly to make sure that i complete everything and leave no stone unturned. i would first go through the codebase to understand the project and coding style

blessingbytes commented 2 hours ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

Hello, i'm a frontend and a blockchain developer, i would love to take this task

How I plan on tackling this issue

I would take a look at the requirement and follow it exactly to make sure that i complete everything and leave no stone unturned. i would first go through the codebase to understand the project and coding style

blessingbytes commented 2 hours ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

Hello, i'm a frontend and a blockchain developer, i would love to take this task

How I plan on tackling this issue

I would take a look at the requirement and follow it exactly to make sure that i complete everything and leave no stone unturned. i would first go through the codebase to understand the project and coding style

blessingbytes commented 2 hours ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

Hello, i'm a frontend and a blockchain developer, i would love to take this task

How I plan on tackling this issue

I would take a look at the requirement and follow it exactly to make sure that i complete everything and leave no stone unturned. i would first go through the codebase to understand the project and coding style

blessingbytes commented 2 hours ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

Hello, i'm a frontend and a blockchain developer, i would love to take this task

How I plan on tackling this issue

I would take a look at the requirement and follow it exactly to make sure that i complete everything and leave no stone unturned. i would first go through the codebase to understand the project and coding style

bruhhgnik commented 2 hours ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

I'm nik, a python dev..i have prior experience in blocjchain and linux development.

How I plan on tackling this issue

I'll reorganize the code by moving the pool data to a sepaarate constants.py file, then modify the SwapAmm class to automatically load these pools when starting up. But i would love to interact with the admin for better guidance.