Skip to content

Instantly share code, notes, and snippets.

# Poor man's interfaces
contract ENS:
pub fn resolver(node: String<32>) -> Resolver:
revert
contract Resolver:
pub fn addr(node: String<32>) -> address:
revert
benchmark run-test: commands[0] | bash -c 'python /home/circleci/repo/scripts/perf_benchmark.py --num-processes 10 --num-events 10000 --backend asyncio --backend trio'
+++ASYNCIO+++
+++Globals+++
|Consumer processes | Total time | Total aggegated time | Propagated events |Received events | Propagated EPS | Received EPS |
| 10 | 1.87429 | 15.36448 | 10000 | 100000 | 5335.353 | 53353.530 |
+++Process Details+++
| Process |Processed Events| First sent | Last received | Fastest | Slowest | AVG | Total dur
DEBUG2 2020-01-16 11:54:15,457 Computation COMPUTATION STARTING: gas: 81604 | from: 0xa416050e3ed652caf8537ec2b4f319377e753401 | to: 0x | value: 0 | depth 0 | static: n
DEBUG2 2020-01-16 11:54:15,457 Computation OPCODE: 0x60 (PUSH1) | pc: 0
DEBUG2 2020-01-16 11:54:15,457 GasMeter GAS CONSUMPTION: 81604 - 3 -> 81601 (PUSH1)
DEBUG2 2020-01-16 11:54:15,462 Computation OPCODE: 0x60 (PUSH1) | pc: 2
DEBUG2 2020-01-16 11:54:15,467 GasMeter GAS CONSUMPTION: 81601 - 3 -> 81598 (PUSH1)
DEBUG2 2020-01-16 11:54:15,474 Computation OPCODE: 0x52 (MSTORE) | pc: 4
DEBUG2 2020-01-16 11:54:15,474 GasMeter GAS CONSUMPTION: 81598 - 3 -> 81595 (MSTORE)
DEBUG2 2020-01-16 11:54:15,475 Computation MEMORY: size (0 -> 96) | cost (0 -> 9)
DEBUG2 2020-01-16 11:54:15,475 GasMeter GAS CONSUMPTION: 81595 - 9 -> 81586 (Expanding memory 0 -> 96)
DEBUG2 2020-01-16 11:54:15,475 Computation OPCODE:
$ go run . --sim ethereum/consensus --loglevel 6 --client go-ethereum_master --sim-parallelism 1 --sim-rootcontext --simloglevel 6 --docker-noshell --docker-nocache . --hivemaxtestcount 1 --simlimiter 300
INFO[12-20|10:44:51] docker daemon online version=19.03.3
INFO[12-20|10:44:51] building new docker image client=go-ethereum_master nocache=true
Step 1/11 : ARG branch=latest
Step 2/11 : FROM ethereum/client-go:$branch
EROR[12-20|10:44:54] failed to build docker image client=go-ethereum_master error="manifest for ethereum/client-go:master not found: manifest unknown: manifest unknown"
CRIT[12-20|10:44:54] failed to build client images error="clients/go-ethereum: manifest for ethereum/client-go:master not found: manifest unknown: manifest unknown"
INFO[12-20|10:44:54] Creating output folder if necessary folder=workspace/logs
INFO[12-20|10:44:54] creating ethash container
INFO[12-20|10:44:54] building new docker image nocache=true
$ trinity
INFO 2019-11-14 11:23:01,592 trinity
______ _ _ __
/_ __/____(_)___ (_) /___ __
/ / / ___/ / __ \/ / __/ / / /
/ / / / / / / / / / /_/ /_/ /
/_/ /_/ /_/_/ /_/_/\__/\__, /
/____/
INFO 2019-11-14 11:23:01,592 trinity Started main process (pid=28151)
INFO 2019-11-14 11:23:01,592 trinity Trinity/v0.1.0a29/linux/cpython3.7.3
(venv-current) cburgdorf at snakebot in ~/Documents/hacking/ef/vyper on fubuloubu/eth-tester-upgrade*
$ pytest tests/examples/safe_remote_purchase/test_safe_remote_purchase.py -vv -k 'test_abort' -n0 --log-cli-level 0
=============================================================================================== test session starts ===============================================================================================
platform linux -- Python 3.7.3, pytest-5.2.2, py-1.8.0, pluggy-0.13.0 -- /home/cburgdorf/Documents/hacking/ef/vyper/venv-current/bin/python3
cachedir: .pytest_cache
hypothesis profile 'default' -> database=DirectoryBasedExampleDatabase('/home/cburgdorf/Documents/hacking/ef/vyper/.hypothesis/examples')
rootdir: /home/cburgdorf/Documents/hacking/ef/vyper, inifile: setup.cfg
plugins: web3-5.2.2, cov-2.8.1, forked-1.1.3, hypothesis-4.42.0, xdist-1.30.0
collected 5 items / 4 deselected / 1 selected
$ pytest tests/examples/safe_remote_purchase/test_safe_remote_purchase.py -vv -k 'test_abort' -n0 --log-cli-level 0
=============================================================================================== test session starts ===============================================================================================
platform linux -- Python 3.7.3, pytest-5.2.2, py-1.8.0, pluggy-0.13.0 -- /home/cburgdorf/Documents/hacking/ef/vyper/venv/bin/python3
cachedir: .pytest_cache
hypothesis profile 'default' -> database=DirectoryBasedExampleDatabase('/home/cburgdorf/Documents/hacking/ef/vyper/.hypothesis/examples')
rootdir: /home/cburgdorf/Documents/hacking/ef/vyper, inifile: setup.cfg
plugins: web3-5.2.2, cov-2.8.1, forked-1.1.3, hypothesis-4.42.0, xdist-1.30.0
collected 5 items / 4 deselected / 1 selected
tests/examples/safe_remote_purchase/tes
pytest tests/examples/safe_remote_purchase/test_safe_remote_purchase.py -vv -k 'test_abort' -n0 --log-cli-level 0
=============================================================================================== test session starts ===============================================================================================
platform linux -- Python 3.7.3, pytest-5.2.2, py-1.8.0, pluggy-0.13.0 -- /home/cburgdorf/Documents/hacking/ef/vyper/venv/bin/python3
cachedir: .pytest_cache
hypothesis profile 'default' -> database=DirectoryBasedExampleDatabase('/home/cburgdorf/Documents/hacking/ef/vyper/.hypothesis/examples')
rootdir: /home/cburgdorf/Documents/hacking/ef/vyper, inifile: setup.cfg
plugins: web3-5.2.2, cov-2.8.1, forked-1.1.3, hypothesis-4.42.0, xdist-1.30.0
collected 5 items / 4 deselected / 1 selected
tests/examples/safe_remote_purchase/test
$ pip install -v 'blake2b-py==0.1.2'
Created temporary directory: /tmp/pip-ephem-wheel-cache-ass6t0sz
Created temporary directory: /tmp/pip-req-tracker-3q4yq_m4
Created requirements tracker '/tmp/pip-req-tracker-3q4yq_m4'
Created temporary directory: /tmp/pip-install-cef4q1jo
Collecting blake2b-py==0.1.2
1 location(s) to search for versions of blake2b-py:
* https://pypi.org/simple/blake2b-py/
Getting page https://pypi.org/simple/blake2b-py/
Found index url https://pypi.org/simple
from eth_keys import keys
from eth_utils import decode_hex
from eth_typing import Address
from eth import constants
from eth.chains.base import MiningChain
from eth.consensus.pow import mine_pow_nonce
from eth.vm.forks.byzantium import ByzantiumVM
from eth.db.atomic import AtomicDB
import logging