Skip to main content

Python SDK for Geode Finance Ecosystem

Project description

geodefi

License: GPL v3

geodefi is a Python library which makes it easier to interact with the Proof of Stake networks that The Staking Library is available. It provides a simple and intuitive interface for accessing blockchain data, executing smart contract functions, and managing blockchain transactions related to Geode's Trustless staking solution.

Features

  • Supports Ethereum Goerli testnet (as of v1.1.2) where The Protocol is deployed.
  • Provides a simple and intuitive API for managing validators, operators, pools, tokens, and other smart contracts/packages.
  • Dynamically adapts to the contract upgrades.
  • Mostly chain agnostic. However, might differ according to the unique PoS implementations.
  • Compatible from Python 3.7 to Python 3.10.

Installation

Using pip:

pip install geodefi

Using setup.py:

python3 setup.py .

Usage Details

Note that, Geode.Token refers to the chain-specific internal Token of The Staking Library. This token differs on different chains.

Get the chain-specific internal Token

gETH on Ethereum, gGNO on Gnosis etc.

# Get gETH token with all functionalities
gETH = Geode.Token
totalSupply = gETH.functions.totalSupply().call()
print(f"Total Supply: {totalSupply}")

Contributing

We welcome contributions from the community! To contribute to this project, please follow these steps:

  1. Fork the Repository: Click the "Fork" button at the top right corner of this repository to create your own copy.

  2. Clone the Repository: Clone the forked repository to your local machine using the following command:

    git clone https://github.com/<your_user_name>/geode-py.git
    
  3. Virtual Environment (adviced) Open virtual environment for python.

    sudo pip install virtualenv
    python3 -m venv {path}
    source {path}/bin/activate
    
    pip install -r requirements.txt
    
  4. Create a Branch: Create a new branch for your contribution:

    git checkout -b feature/your-feature-name
    
  5. Stage Changes: Stage your changes to be commited

    git add <your-modified-files>
    
  6. Commit Changes: Commit your changes with a descriptive commit message:

    git commit -m "Add feature: your feature description"
    
  7. Push Changes: Push your changes to your forked repository:

    git push origin feature/your-feature-name
    
  8. Create a Pull Request: Go to the original repository on GitHub and click on the "Pull Request" button. Fill out the necessary information and submit the pull request. Your pull request will be reviewed by the maintainers. Be ready to respond to any feedback or changes requested. You might need to make additional commits based on the feedback.

  9. Celebrate: Once your pull request is approved and merged, your contribution will be part of the project! Thank you for your contribution.

Documentation

Detailed documentation for this project is available on Geodefi SDK.

You can find information on how to install, use, and contribute to the project in the documentation. Whether you're a user or a developer, the documentation provides essential resources to help you get started.

  1. Update in documentations If your feature needs to have additional section in Read The Docs. Please check the docs in your local computer first.
cd docs
make html

built docs page is located in docs/_build/html/index.html.

Releasing

  • Use main branch for releases.
  • Change .github/workflows/pipy_release.yml version first, then:
git tag 0.0.1 # or whatever version you want 
git push origin --tags

License

geodefi is licensed under MIT.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

geodefi-1.2.0.tar.gz (398.6 kB view details)

Uploaded Source

Built Distribution

geodefi-1.2.0-py3-none-any.whl (410.8 kB view details)

Uploaded Python 3

File details

Details for the file geodefi-1.2.0.tar.gz.

File metadata

  • Download URL: geodefi-1.2.0.tar.gz
  • Upload date:
  • Size: 398.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.7.17

File hashes

Hashes for geodefi-1.2.0.tar.gz
Algorithm Hash digest
SHA256 814b8fa440e9c04a3c9334e3663d5012d89be4f3ce7a7cd8618b22ac20f93c8a
MD5 cf1a4ba5d88e81fb1ea66abd832d4a21
BLAKE2b-256 8795d4a642e10c9abd02b69e8d178ea0877bfc0262ca79a74fad2a6c9967536e

See more details on using hashes here.

File details

Details for the file geodefi-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: geodefi-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 410.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.7.17

File hashes

Hashes for geodefi-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 11e83d0513d0528bcbbf881088ee768098f6e0747cb7070d3ee6d0b0c3246429
MD5 761a93a7fb6df8b888700aa581dfaa19
BLAKE2b-256 083c276afcb89a276aec15ba84d8a9d5b45206166126d7e5454abafdb3517c30

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page