Skip to main content

Ape Ethereum Framework

Project description

Ape Framework

Ape is a framework for Web3 Python applications and smart contracts, with advanced functionality for testing, deployment, and on-chain interactions.

Dependencies

  • python3 version 3.6 or greater, python3-dev

Installation

via pip

You can install the latest release via pip:

pip install eth-ape

via setuptools

You can clone the repository and use setuptools for the most up-to-date version:

git clone https://github.com/ApeWorX/ape.git
cd ape
python3 setup.py install

Quick Usage

Ape is primarily meant to be used as a command line tool. Here are some things you can use ape to do:

# Work with your accounts
$ ape accounts list

# Compile your project's smart contracts
$ ape compile --size

# Run your tests with pytest
$ ape test -k test_only_one_thing --coverage --gas

# Connect an IPython session through your favorite provider
$ ape console --network ethereum:mainnet:infura

# Add new plugins to ape
$ ape plugins add plugin-name

Ape also works as a package. You can use the same networks, accounts, and projects from the ape package as you can in the cli:

# Work with registered networks, providers, and blockchain ecosystems (like Ethereum)
from ape import networks
with networks.ethereum.mainnet.use_provider("infura"):
    ...  # Work with the infura provider here

# Work with test accounts, local accounts, and (WIP) popular hardware wallets
from ape import accounts
a = accounts[0]  # Load by index
a = accounts["example.eth"]  # or load by ENS/address
a = accounts.load("alias") # or load by alias

# Work with contract types
from ape import project
c = a.deploy(project.MyContract, ...)
c.viewThis()  # Make Web3 calls
c.doThat({"from": a})  # Make Web3 transactions
assert c.MyEvent[-1].caller == a  # Search through Web3 events

Development

This project is in early development and should be considered an alpha. Things might not work, breaking changes are likely. Comments, questions, criticisms and pull requests are welcomed.

License

This project is licensed under the Apache 2.0.

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

eth-ape-0.1.0a14.tar.gz (61.5 kB view details)

Uploaded Source

Built Distribution

eth_ape-0.1.0a14-py3-none-any.whl (56.5 kB view details)

Uploaded Python 3

File details

Details for the file eth-ape-0.1.0a14.tar.gz.

File metadata

  • Download URL: eth-ape-0.1.0a14.tar.gz
  • Upload date:
  • Size: 61.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.8.10

File hashes

Hashes for eth-ape-0.1.0a14.tar.gz
Algorithm Hash digest
SHA256 53710171f93f0efe8b4e42a7c3683cbb3146ee89504d9ff0bd813bef7db7a663
MD5 9eed9338c26a61a5f1e4f69c88e4a140
BLAKE2b-256 0b7302e2a3269c989789de70a834fa2909449fa9977a71d3a4cee4c0c3ee60c0

See more details on using hashes here.

File details

Details for the file eth_ape-0.1.0a14-py3-none-any.whl.

File metadata

  • Download URL: eth_ape-0.1.0a14-py3-none-any.whl
  • Upload date:
  • Size: 56.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.8.10

File hashes

Hashes for eth_ape-0.1.0a14-py3-none-any.whl
Algorithm Hash digest
SHA256 c237bc5ac037dc96ff556f9e3774139a0245e86390d54a0acc1b8457b532cee4
MD5 4acd1497bd2fc2848132056ba0a822c9
BLAKE2b-256 a9b50103c041081ad74e2cddbbb93022cceb0169677fae6007c0525d7f035b0b

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