Skip to main content

smart-contract api and embedded ethereum virtual machine

Project description

Simular

pypi

A Python smart-contract API with a fast (embedded) Ethereum Virtual Machine (EVM). Simular creates a Python wrapper around production grade Rust based Ethereum APIs.

How is it different than Brownie, Ganache, Anvil?

  • It's only an EVM, no blocks or mining
  • No HTTP/JSON-RPC. You talk directly to the EVM (and it's fast)
  • Full functionality: account transfers, contract interaction, etc...

The primary motivation for this work is to be able to model smart-contract interaction in an Agent Based Modeling environment like Mesa.

Features

  • EVM: run a local version with an in-memory database, or fork db state from a remote node.
  • Snapshot: dump the current state of the EVM to json for future use in pre-populating EVM storage
  • ABI: parse compiled Solidity json files or define a specific set of functions using human-readable notation
  • Contract: high-level, user-friendy Python API

Build from source

  • You need Rust and Python, and optionally Make. We use hatch for Python project management, but it's not required
  • Create a local Python virtual environment. Within that environment install Python dependencies
  • Run make build or hatch run maturin develop
  • See simular/ for the main python api

Getting Started

See Simular Documentation for examples and API details.

Standing on the shoulders of giants...

Thanks to the following projects for making this work possible!

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

simular_evm-0.3.0.tar.gz (76.1 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

simular_evm-0.3.0-pp310-pypy310_pp73-manylinux_2_28_x86_64.whl (5.2 MB view details)

Uploaded PyPymanylinux: glibc 2.28+ x86-64

simular_evm-0.3.0-pp310-pypy310_pp73-manylinux_2_28_armv7l.whl (4.7 MB view details)

Uploaded PyPymanylinux: glibc 2.28+ ARMv7l

simular_evm-0.3.0-pp310-pypy310_pp73-manylinux_2_28_aarch64.whl (5.4 MB view details)

Uploaded PyPymanylinux: glibc 2.28+ ARM64

simular_evm-0.3.0-cp311-none-win_amd64.whl (2.7 MB view details)

Uploaded CPython 3.11Windows x86-64

simular_evm-0.3.0-cp311-none-win32.whl (2.4 MB view details)

Uploaded CPython 3.11Windows x86

simular_evm-0.3.0-cp311-cp311-manylinux_2_28_x86_64.whl (5.2 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ x86-64

simular_evm-0.3.0-cp311-cp311-manylinux_2_28_armv7l.whl (4.7 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ ARMv7l

simular_evm-0.3.0-cp311-cp311-manylinux_2_28_aarch64.whl (5.4 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ ARM64

simular_evm-0.3.0-cp311-cp311-macosx_11_0_arm64.whl (2.8 MB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

simular_evm-0.3.0-cp311-cp311-macosx_10_12_x86_64.whl (2.9 MB view details)

Uploaded CPython 3.11macOS 10.12+ x86-64

simular_evm-0.3.0-cp310-none-win_amd64.whl (2.7 MB view details)

Uploaded CPython 3.10Windows x86-64

simular_evm-0.3.0-cp310-none-win32.whl (2.4 MB view details)

Uploaded CPython 3.10Windows x86

simular_evm-0.3.0-cp310-cp310-manylinux_2_28_x86_64.whl (5.2 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ x86-64

simular_evm-0.3.0-cp310-cp310-manylinux_2_28_armv7l.whl (4.7 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ ARMv7l

simular_evm-0.3.0-cp310-cp310-manylinux_2_28_aarch64.whl (5.4 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ ARM64

File details

Details for the file simular_evm-0.3.0.tar.gz.

File metadata

  • Download URL: simular_evm-0.3.0.tar.gz
  • Upload date:
  • Size: 76.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.0.0 CPython/3.12.9

File hashes

Hashes for simular_evm-0.3.0.tar.gz
Algorithm Hash digest
SHA256 93ec0182bb3ee1f840ffebb2b95da41e3ae2ccf79bbf9d8fc10acfb4595d03e5
MD5 f5d1fa52cb96cbb06cc9924a6f9f4dbf
BLAKE2b-256 3cfc5cdaeb62e10092d8453f6b2c84bd4417c983011502465a2f50d7342ae89f

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-pp310-pypy310_pp73-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for simular_evm-0.3.0-pp310-pypy310_pp73-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 ecb67a847008608618628f15fddea078c76490b777aa1574c5ea779e4cb55eee
MD5 b06f8ce5b85570cd3ee95db7997aad7e
BLAKE2b-256 8259ca4dcb49b39a6eea418fe4ca03f5736996a71439191485447b65857af77f

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-pp310-pypy310_pp73-manylinux_2_28_armv7l.whl.

File metadata

File hashes

Hashes for simular_evm-0.3.0-pp310-pypy310_pp73-manylinux_2_28_armv7l.whl
Algorithm Hash digest
SHA256 b4cb15c4cd0257a6d21edc39aefde5b16d9d259ca1d060e5502f57918f912ef2
MD5 9703c49dd7a2fd5b146c4b03e33346a9
BLAKE2b-256 7c1985de60ae4e5ff7c086a28d884039f727c7b9918331060d01b4bd1185a37c

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-pp310-pypy310_pp73-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for simular_evm-0.3.0-pp310-pypy310_pp73-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 b6d37785e44b29a939a8105d2d92bd790378a631d9933ffe48bec1e19b87877e
MD5 d0c8f585f9616ebe5000cb4013446540
BLAKE2b-256 5ca0e03b563840397a4fa11c9ea2b64ae707434dbaedfb6d998adce3c5e9d3c1

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-cp311-none-win_amd64.whl.

File metadata

  • Download URL: simular_evm-0.3.0-cp311-none-win_amd64.whl
  • Upload date:
  • Size: 2.7 MB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.0.0 CPython/3.12.9

File hashes

Hashes for simular_evm-0.3.0-cp311-none-win_amd64.whl
Algorithm Hash digest
SHA256 5f9d52d5758691c003dd6c97e0633d198dca0f23d1fcb794ee1907b87922eef3
MD5 73d230e72909fba491828300f6feaaab
BLAKE2b-256 7755946f0ddf04411b5fcd4e576eab4b0e97cbec0d611f15fa2c233b8730fb43

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-cp311-none-win32.whl.

File metadata

  • Download URL: simular_evm-0.3.0-cp311-none-win32.whl
  • Upload date:
  • Size: 2.4 MB
  • Tags: CPython 3.11, Windows x86
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.0.0 CPython/3.12.9

File hashes

Hashes for simular_evm-0.3.0-cp311-none-win32.whl
Algorithm Hash digest
SHA256 0c0299437cad8cd58ff228cdd24472d8dbfe9f2645dffbcca4346dfb4301a28a
MD5 60f71a228c0095e354fdb4090f14b70e
BLAKE2b-256 60b8c3b241f29e35c0182533f2637379ff74a13b47fbc5b1a0bd6731eaea2cdb

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-cp311-cp311-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for simular_evm-0.3.0-cp311-cp311-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 80f4c90e836f6b822805904aa84b65be073cccf0902d9bed61eddc3107ae450d
MD5 e7f7be03f311aca2dcfa076a3063786a
BLAKE2b-256 af9bf7c5e8a7ee46f1996e35f87c30e3bdad2c7b5abec580741c2b5087ed7a5b

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-cp311-cp311-manylinux_2_28_armv7l.whl.

File metadata

File hashes

Hashes for simular_evm-0.3.0-cp311-cp311-manylinux_2_28_armv7l.whl
Algorithm Hash digest
SHA256 df218fcefb8a9474166b200064b775be8029ed5ced26619ac9b491216308224e
MD5 3dc4997ad86d711e1570a846d904c810
BLAKE2b-256 a83c387987f80be6b649f431a630a8afc59afdcadbe23196c9f914aeb1b83abd

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-cp311-cp311-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for simular_evm-0.3.0-cp311-cp311-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 f904f3afeae30d1ba1934c838c6c7f401b76c8383448788758a540675a9cc4df
MD5 32c26c645add2fb2475ab2b421e19562
BLAKE2b-256 3fa004cb2ab869311bafb39d6714885bbfbb8ab5696fbcab9a7e2633fc089652

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for simular_evm-0.3.0-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 b74bba3a0428514c40d3507fb6de1a97a4b868d11064a807c19f18100b2ea116
MD5 3805a4dea220fefba6ee68ce038dcaea
BLAKE2b-256 1e2bc48e39ca1ff12b6262bfb971f588d911356cb954b825fe2a9d8bdc63e5a7

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-cp311-cp311-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for simular_evm-0.3.0-cp311-cp311-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 ab1123fb67c989ed41c4143e5e7dbadc68654fde0aeb45c4c4a5af9b258cf6c3
MD5 c5bc66c7ac989b48d79f782740707c86
BLAKE2b-256 47d0482459d3ab5af651c249bc9dbdfa4cee2f32f63479c486063d1049eb3bcc

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-cp310-none-win_amd64.whl.

File metadata

  • Download URL: simular_evm-0.3.0-cp310-none-win_amd64.whl
  • Upload date:
  • Size: 2.7 MB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.0.0 CPython/3.12.9

File hashes

Hashes for simular_evm-0.3.0-cp310-none-win_amd64.whl
Algorithm Hash digest
SHA256 1f43f4e8a627ac21bd88eea2931ce85228a97bbf15d61b958159bd0c9cfdd5a7
MD5 f5d850a2ecf31f0242c64656d7463518
BLAKE2b-256 db31abc5f628e18c84b9e5e0208bc65c7dfcd0b2a5dd437d9cf852a9cb31aa25

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-cp310-none-win32.whl.

File metadata

  • Download URL: simular_evm-0.3.0-cp310-none-win32.whl
  • Upload date:
  • Size: 2.4 MB
  • Tags: CPython 3.10, Windows x86
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.0.0 CPython/3.12.9

File hashes

Hashes for simular_evm-0.3.0-cp310-none-win32.whl
Algorithm Hash digest
SHA256 16063df3f31660a46bda66861769dffc16198c2b1739231762884434bb9f1bda
MD5 f1292d5c49f453b3074d089a1b811ef5
BLAKE2b-256 2dbe44c07b1fd6a7b6c9a53b4ff50353e3de9063eae85158e4e156837459d8ef

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-cp310-cp310-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for simular_evm-0.3.0-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 7f52c0e4c95afc1c18a738fac091504911e1db7f2ed22a5d7fd53d8f4a8568c3
MD5 13987c8402c34fa51ccdbf6d65c11435
BLAKE2b-256 75ed4886ee3b1f159df206520f8d49b49e7cbe86a0a96b766c57f0e0c0a60e75

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-cp310-cp310-manylinux_2_28_armv7l.whl.

File metadata

File hashes

Hashes for simular_evm-0.3.0-cp310-cp310-manylinux_2_28_armv7l.whl
Algorithm Hash digest
SHA256 4218f2f4af8abaa01cf9130752b5120e96c6a659b31f497bd7d3967251626e8e
MD5 05c7a00b962a5df2736945f3d17f8182
BLAKE2b-256 facbef89ab18df22d9c249683730b4e3b38cf38c43c938c1da70977c301a9f14

See more details on using hashes here.

File details

Details for the file simular_evm-0.3.0-cp310-cp310-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for simular_evm-0.3.0-cp310-cp310-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 0fef4626d21d6ff884461657234d1e895dc911ec58f34f05b4af45e1bc3e2d3e
MD5 eee79befbb7044be9523d8b074aef8ca
BLAKE2b-256 6bc94e31ccd8b771b3c0ab9fb9e0a1b0b133de705b7ca914fae9cc33b1002743

See more details on using hashes here.

Supported by

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