AFK-AlignedFamKernel / afk_monorepo

AFK: Aligned Fam Kernel - Monorepo
https://portal.afk-community.xyz
MIT License
9 stars 20 forks source link

Pump Solidity contract #86

Open MSghais opened 2 weeks ago

MSghais commented 2 weeks ago

Description

Create the Pump.sol contract in the /launchpad You can Check the launchpad.cairo

SoarinSkySagar commented 2 weeks ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

I am a blockchain developer with a year of experience up my sleeve. I have worked with and created many dapps on Ethereum, Solana and Starknet chains and have also contributed to such dapps. I also have experience writing smart contracts in languages like Solidity, Vyper, Move, Rust, Cairo and Noir.

How I plan on tackling this issue

I would implement the contract in the following manner:

  1. Write the functions for the create_token, create_and_launch_token, buy_token(quote_amount) and sell_token(quote_amount)
  2. When the threshold_liquidity is reached for the pool, add liquidity to the token
  3. An owner only function to set quote token
  4. Write tests with foundry

ETA: 3-4 days

onlydustapp[bot] commented 2 weeks ago

The maintainer MSghais has assigned SoarinSkySagar to this issue via OnlyDust Platform. Good luck!

KevinMB0220 commented 1 week ago

Hi, my name is Kevin, and I would like to work on this issue. I have experience with Solidity and have worked on similar projects before. Additionally, I’m a member of Dojo Coding, where I have honed my skills in blockchain development. I’m familiar with creating and managing smart contracts, and I can implement the requested functions, such as create_token, create_and_launch_token, and the others listed. I can also write the corresponding tests using Foundry. I’m excited to contribute and hope to help move this project forward.

onlydustapp[bot] commented 1 week ago

Hey @KevinMB0220! Thanks for showing interest. We've created an application for you to contribute to AFK - Aligned Fam Kernel. Go check it out on OnlyDust!

DrParadox05 commented 1 week ago

I am applying to this issue via OnlyDust platform.

Hey, can I work on this?

ShantelPeters commented 1 week ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

I am a blockchain developer

How I plan on tackling this issue

  1. Create Pump.sol Contract:

    • Location: /launchpad
    • Functionality Define functions for token operations and liquidity management.
  2. mplement Functions

    • create_token()`: Initializes a new token.
    • create_and_launch_token()`: Creates and deploys the token.
  3. Check launchpad.cairoVerify that thePump.solcontract adheres to the specifications inlaunchpad.cairo`.

4.Write Tests:

Sravya-212 commented 6 days ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

I have almost an year experience in developing solidity contracts, my expertise stands in creating DApps, DeFi platforms. I have developed a ChatApp, Google Drive3.0, a staking token app. As an experienced Smart Contracts developer in Ethereum and Solana I am confident that I can solve this issue using my Cairo and Solidity skills with seamless interaction with the other functionalities.

How I plan on tackling this issue

Here is my approach for building the Pump.sol contract:

Set Up the Contract:

-Utilize OpenZeppelin libraries for ERC20 functionality to ensure secure and standardized token management. -Define contract parameters, including the quote_token and liquidity threshold, which will be essential for buying, selling, and adding liquidity.

Implement Core Functions:

-create_token: This function will mint a new ERC20 token based on the specified parameters. -create_and_launch_token: Combines the token creation process with the launch setup, ensuring the token is ready for trading. -buy_token(quote_amount): Facilitates token purchases by users, converting a specified amount of the quote_token into the new token. -sell_token(quote_amount): Enables users to sell their tokens, receiving a specified amount of the quote_token in return. -add_liquidity: Automatically adds liquidity to Uniswap V2 when the liquidity threshold is reached, using the token and quote_token.

Admin Functions:

-set_quote_token: Allows the admin to set or update the quote_token used for transactions.

Testing: -Write comprehensive tests using Foundry to validate each function's correctness. Ensure scenarios like token creation, buying, selling, and liquidity addition are thoroughly tested.

0xJeanmi commented 5 days ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

I'm full stack developer with experience in languages like PHP, JS, TS and Frameworks like React, Laravel. Also, I made several courses in Alchemy University to be prepared to challenges in web3 like this one. So I hope to move forward in this application.

How I plan on tackling this issue

Well, basically I'll review the examples of .sol contracts in the /launchpad and will write the new features that you required, make the tests and make the PR. Hope to have news from you soon. Thanks!

ikemHood commented 4 days ago

Hello @MSghais , I would love to close this out. ETA 48hrs

onlydustapp[bot] commented 4 days ago

Hey @ikemHood! Thanks for showing interest. We've created an application for you to contribute to AFK - Aligned Fam Kernel. Go check it out on OnlyDust!

llamitaOnfire commented 2 days ago

I am applying to this issue via OnlyDust platform.

My background and how it can be leveraged

Hi! I’m a Computer Engineering student with a growing interest in smart contracts and decentralized finance. Although I’m new to contributing to open source, I’m eager to apply my knowledge and help with this task.

How I plan on tackling this issue

Plan for Tackling the Issue:

  1. Create the Pump.sol Contract:

Location: The Pump.sol contract will be created in the /launchpad directory, as specified in the project structure.

Functionality:

create_token: This function will initialize a new token with essential parameters such as name, symbol, and initial supply. It will handle the deployment and setup of the token contract, ensuring that it conforms to the ERC20 standard. create_and_launch_token: This function will encompass the logic to both create a new token and immediately launch it. It will handle the setup of any initial configurations required for the token to be active and tradable. Buy_token(quote_amount): Implement a function to facilitate the purchase of tokens using a specified amount of quote currency. This function will interact with the token’s contract to transfer tokens to the buyer and handle the quote currency conversion or exchange. Sell_token(quote_amount): This function will handle the sale of tokens, allowing users to sell their tokens in exchange for a specified amount of quote currency. It will include mechanisms to ensure proper token transfer and quote currency handling. Add Liquidity: Develop functionality to automatically add liquidity to Uniswap V2 when the threshold_liquidity is reached. This will involve interacting with Uniswap’s router contract to ensure liquidity is provided to the pool efficiently. Admin Functionality: Include a function for the admin to set or update the quote token, allowing for flexibility in managing the token sale and liquidity provisions.

  1. Reference launchpad.cairo:

Review and Analyze: Examine the launchpad.cairo file for any relevant logic, patterns, or structures that might be applicable to the Pump.sol contract. Ensure that any pertinent aspects of the existing launchpad.cairo logic are considered to maintain consistency and integration within the broader system.

  1. Write Tests with Foundry:

Develop Comprehensive Tests: Utilize Foundry to create a suite of tests that cover all functionalities of the Pump.sol contract. This will include unit tests to verify the correctness of individual functions (e.g., token creation, buying/selling tokens) and integration tests to ensure that the contract works as intended within the entire ecosystem. Test Scenarios: Token Creation: Test scenarios to validate that new tokens are created correctly with appropriate parameters. Buying Tokens: Ensure that tokens can be purchased with the specified quote amount and verify that balances are updated accurately. Selling Tokens: Verify that tokens can be sold and that the exchange of tokens for quote currency works as expected. Liquidity Addition: Test the functionality of adding liquidity to Uniswap V2, ensuring that the contract correctly interacts with the Uniswap protocol when the threshold is met. Admin Operations: Validate the admin’s ability to set or update the quote token and ensure that such changes are reflected correctly in the contract’s operations. By following this detailed plan, I aim to deliver a robust Pump.sol contract with comprehensive functionality and reliability. I’m excited to contribute to the project and look forward to your feedback and collaboration.