Smart Contract Tools For Pythonistas
4 min read
I usually don't want to learn a new language when it comes to new technology and would always first lookout for alternatives to the language am familiar with before I give in.
There is a language called Vyper. Vyper is a contract-oriented, pythonic programming language that targets the Ethereum Virtual Machine (EVM) and we shall not look at this today.
Using a popular programming language, such as Python, to write smart contracts is an immense advantage for first-time smart contract programming.
Some of the popular blockchains developed using Python are Ethereum, Hyperledger Fabric, Steem, and NEO.
So let's jump right in;
SmartPy is an intuitive and powerful smart contract development platform for Tezos.
SmartPy language is available through a Python library for building and analyzing Tezos smart contracts.
Tezos is a self-upgradable and energy-efficient Proof of Stake blockchain. Tezos is a decentralized open-source blockchain that can execute peer-to-peer transactions and serve as a platform for deploying smart contracts.
Brownie is a popular smart contract development and testing framework for the Ethereum Virtual Machine, supporting Solidity and Vyper as the smart contract languages.
Easily Install Brownie
pip install --user pipx pipx ensurepath pipx install eth-brownie
pipx is a specialized package installer. It can only be used to install packages with
pip both install packages from PyPI (or locally)
pipx relies on
PyTeal is a Python language binding for Algorand Smart Contracts (ASC1s).
Algorand Smart Contracts are implemented using a new language that is stack-based, called Transaction Execution Approval Language (TEAL).
However, TEAL is essentially an assembly language. With PyTeal, developers can express smart contract logic purely using Python. PyTeal provides high-level, functional programming style abstractions over TEAL and does type checking at construction time.
Slitheris a Solidity static analysis framework written in Python 3. It runs a suite of vulnerability detectors, prints visual information about contract details, and provides an API to easily write custom analyses.
Slither enables developers to find vulnerabilities, enhance their code comprehension, and quickly prototype custom analyses.
PyTest is the framework that makes it easy to write, test, and scale to support complex testing for applications and libraries.
Testing is really essential before you deploy your smart contracts to any blockchain because of its immutability nature.
🌟 Web3 Py
Web3 Py interacts with the Ethereum blockchain via a set of publicly exposed APIs.
pip install web3
Web3.Py is a set of libraries that allow developers to interact with Ethereum nodes using HTTP, IPC, or WebSocket protocols with Python.
You can create Ethereum transactions, and read and write data from the blockchain (this includes smart contract interaction).
Mythril is a security analysis tool for
EVM bytecode. It detects security vulnerabilities in smart contracts built for Ethereum, Hedera, Quorum, Vechain, Roostock, Tron and other EVM-compatible blockchains.
The Ethereum application development framework for Python Developers, Data Scientists, and Security Professionals.
ApeWorX is a python-oriented tool to make a more modular finance-focused framework. It helps in managing and developing blockchain tasks.
Manticore is a multi-purpose tool written in Python. It is a super flexible smart contract audit tool. With its own command line tools and scriptable Python APIs
Obviously, there are more tools which I have not mentioned here like oyente, Python SDKs and APIs offered by different providers that you can still leverage to get started with smart contracts.
Once again, hope you learned something today from my little closet.
Please consider subscribing or following me for related content, especially about Tech, Python & General Programming.
You can show extra love by buying me a coffee to support this free content and I am also open to partnerships, technical writing roles, collaborations and Python-related training or roles.
📢 You can also follow me on Twitter : ♥ ♥ Waiting for you! 🙂 </center