BUIDL-Weekly: 10JUL23 - 16JUL23

Dev Update

BUIDL-Weekly: 10JUL23 - 16JUL23

Welcome to another weekly wrap-up, Spartans! Thanks to all the community contributors and friends who helped Buidl, promote and support during the week! Read on for the update

BUIDL-Weekly: 10JUL23 - 16JUL23

Community Mentions

CoinMarketLeague

Remember to cast your vote for SPARTA every day, Spartans!


‌SpartAnalytics Report

Our community creates a monthly PDF report that includes an overview of Spartan Protocol data from Google Search (impressions, clicks, devices, keywords, and geographical data) and Twitter analytics.


‌Community DApp‌

‌GitHub Repo: https://github.com/spartan-protocol/SpartanProtocol-DAppV2

Front-end: https://dapp.spartanprotocol.org/

dependencies

  • Bump semver from 6.3.0 to 6.3.1

‌Protocol Site

GitHub Repo: https://github.com/spartan-protocol/spartan-site

Front-end: https://spartanprotocol.org/

‌Protocol API

GitHub Repo: https://github.com/spartan-protocol/spartan-api

Front-end: https://api.spartanprotocol.org/api/v1/pools

‌Protocol Subgraph

GitHub Repo: https://github.com/spartan-protocol/spartan-subgraph

Front-end: https://thegraph.com/hosted-service/subgraph/spartan-protocol/pool-factory

‌Protocol Contracts V3

GitHub Repo: https://github.com/spartan-protocol/spartan-contracts

minor changes + ext testing

  • added sanity checks on pool creation to ensure input of both assets > 100000 wei (a fixed number is problematic, but even with an expensive asset like BTC this still allows for a pool creation as low as $0.000000006 USD TVL)
  • this in theory would leave a min remainder of 10wei tokens if the user adds and then instantly removes 100% of their liquidity (when combined with the 10000wei fixed LP units on creation and 1wei locked/burned permanently)
  • added tests for each of these new sanity checks
  • added a test to check the emitted PoolCreated event args are correct

continued testing + adjustments

  • small refactor (gas saving) in Pool contract
  • refactored use of ONE in Tools contract with 1 ether instead
  • changed calcLiquidityUnits() fallback for initial add to match recent changes (static 10,000 units)
  • fixed the slip adjustment check to be within 2% instead of 100% exact
  • converted the Tools math to normal math operators
  • fixed the wrong/broken math in Tools (too many LP units were given to subsequent liquidity providers)
  • bumped up the initial liqAdd of the stablecoin pool to 100k ether-units each so that we can test underflow 1-wei rounding
  • changed the btc:native initial liqAdd ratios to resemble actual BTC & BNB asset values
  • changed all use of ethers to hre-ethers for the extended hardhat functionality
  • changed iBEP20 interfaces to ERC20
  • added a changeHandler call to the fixture so that the Tools contract can be correctly picked up when its called externally (when adding liquidity for instance)
  • added exported references to each token contract as addr2 (alternatively we can just grab the contract objects attached to addr1 and call .connect(addr2) but we can decide on that later)
  • removed the args from the createPoolsFixture as that is not supported (as an actual fixture)
  • created export refs to each pool contract attached to addr1 && addr2
  • moved onto the pool contract for adding test units
  • added a test to make sure addForMember() reverts if either input is !>0
  • added a test to make sure addForMember() reverts if the calculated LP units to mint is < 1 wei

test file structure cleanup

  • renamed some test files
  • moved some test files / file structure

‌Protocol Resources

GitHub Repo: https://github.com/spartan-protocol/resources

‌Protocol Docs

‌GitHub Repo: https://github.com/spartan-protocol/spartan-docs

Frontend: https://docs.spartanprotocol.org/

‌Protocol Contracts V1 - V2

GitHub Repo: https://github.com/spartan-protocol/spartanswap-contracts


‌Ecosystem Project: SpartanSwap‌

SpartanSwap is a separate project currently in development with the goal of creating a user-friendly interface for interacting with Spartan Protocol pools. Initially, the focus will be on providing swap functionality, with the long-term aim of becoming a swap aggregator for BNB SmartChain and potentially other chains in the future

SpartanSwap Contracts

GitHub Repo: https://github.com/Spartan-Swap/SpartanSwapContracts

SpartanSwap DApp

GitHub Repo: https://github.com/Spartan-Swap/SpartanSwapDApp

SpartanSwap Resources

GitHub Repo: https://github.com/Spartan-Swap/SpartanSwapResources


‌Ecosystem Project: SpartanArena‌

SpartanArena is a separate project that focuses on developing subprojects related to gaming. Some ideas that are being considered for the future include an NFT looter game, a lottery, and a prediction/parimutuel game

SpartanArena Contracts

GitHub Repo: https://github.com/SpartanArena/SpartanArenaContracts

SpartanArena DApp

GitHub Repo: https://github.com/SpartanArena/SpartanArenaDApp

SpartanArena Resources

GitHub Repo: https://github.com/SpartanArena/SpartanArenaResources


‌Ecosystem Project: SpartanToolkit

Spartan Toolkit is an ecosystem project initiated by the Spartan Protocol community with the goal of improving tools for projects and users within the BNBChain ecosystem, including Beacon, Smart, and BAS chains

BepTools Fork

GitHub Repo: https://github.com/Spartan-Toolkit/beptools

Legacy BepTools Repo: https://gitlab.com/canyacoin/binancechain/beptools (will request a PR and/or mirror to GitHub)

Temp Frontend: https://beptools.netlify.app/

The contributors of Spartan Toolkit have forked and updated/fixed the wallet connections in the BepTools DApp to enable BinanceChain/BeaconChain/BEP2 users to freeze/unfreeze and batch send BEP2 tokens on the BNB Beacon Chain

Web3BNB Library

GitHub Repo: https://github.com/Spartan-Toolkit/web3-bnb

A React library with the intention of providing builders with a plug-and-play solution for any web3 wallet compatible with BNB ecosystem chains (Beacon, Smart, BAS etc)

BNB Beacon Chain Toolkit DApp

GitHub Repo: https://github.com/Spartan-Toolkit/beacon-chain-tools-dapp

A tooling user interface for users + projects on BNB Beacon Chain. Batch-send, freeze/unfreeze, deploy BEP2 token etc without touching the command line!

BNB Smart Chain Toolkit DApp

GitHub Repo: https://github.com/Spartan-Toolkit/beacon-chain-tools-dapp

Tooling and informational user interface for users + projects on BNB Smart Chain‌


Protocol Information

Project Community

Spartan Protocol and its related ecosystem is a 100% open-source community initiative. As an open organization, the community is responsible for building, running, and maintaining everything. If you are interested in contributing or learning more, please reach out in the community channels!