Skip to content

Instantly share code, notes, and snippets.

Michael Bradley michaelsbradleyjr

Block or report user

Report or block michaelsbradleyjr

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View geth-hera.sh
docker \
run \
-it \
--rm \
-v "$PWD/geth":"/geth" \
michaelsbradleyjr/geth-hera:ubuntu-ewasm-testnet-milestone1 \
--nousb \
--datadir=/geth/development/datadir \
init /geth/ewasm-testnet-geth-config.json
View geth-hera.log
DEBUG[10-01|17:12:26.618] Recalculated downloader QoS values rtt=2.000000012s confidence=1.000 ttl=6.000000036s
INFO [10-01|17:12:26.687] Imported new block headers count=320 elapsed=946.556ms number=47424 hash=80307c…f16ab3 age=7mo6d16h
DEBUG[10-01|17:12:26.691] Fetching batch of headers id=58e63ffe8e8db2a1 conn=dyndial count=128 fromnum=73920 skip=191 reverse=false
DEBUG[10-01|17:12:26.691] Fetching batch of block bodies id=58e63ffe8e8db2a1 conn=dyndial count=1
DEBUG[10-01|17:12:26.694] Inserting fast-sync blocks items=160 firstnum=47105 firsthash=7c6caa…51dc0c lastnumn=47264 lasthash=69c286…a85c7a
INFO [10-01|17:12:26.702] Imported new block receipts count=160 elapsed=7.255ms number=47264 hash=69c286…a85c7a age=7mo6d17h size=640.00B
DEBUG[10-01|17:12:26.956] Filling up skeleton from=73729
DEBUG[10-01|17:12:26.959] Inserting fast-sync blocks items=160 firstnum=47265 firsthash=8fc
View nimplay-geth-hera-steps.md

I started from the beginning to make sure my success was reproducible (at least on my machine!).

Here's a summary of the steps, and keep in mind that I'm on macOS:

$ brew install nim
$ pip install web3
$ git clone https://github.com/status-im/nimplay.git
$ cd nimplay
$ make get-nimclang-docker
View trace.log
embark reset && embark run --nobrowser --nodashboard --loglevel trace
Removing the following files:
/Users/michael/dapps/dev/snarky5/.embark
/Users/michael/dapps/dev/snarky5/chains.json
/Users/michael/dapps/dev/snarky5/coverage
/Users/michael/dapps/dev/snarky5/dist
/Users/michael/dapps/dev/snarky5/embarkArtifacts
/Users/michael/dapps/dev/snarky5/node_modules/.cache
View prettier-200.ts
private compile_contracts(contractFiles: any[], cb: Callback<any>) {
if (contractFiles.length === 0) {
return cb(null, {});
}
async.waterfall(
[
(next: Callback<any[]>) => {
this.plugins.runActionsForEvent("compiler:contracts:compile:before", contractFiles, (err?: Error | null, files: any[] = []) => {
if (err) {
View prettier-80.ts
private compile_contracts(contractFiles: any[], cb: Callback<any>) {
if (contractFiles.length === 0) {
return cb(null, {});
}
async.waterfall(
[
(next: Callback<any[]>) => {
this.plugins.runActionsForEvent(
"compiler:contracts:compile:before",
View prettier-120.ts
private compile_contracts(contractFiles: any[], cb: Callback<any>) {
if (contractFiles.length === 0) {
return cb(null, {});
}
async.waterfall(
[
(next: Callback<any[]>) => {
this.plugins.runActionsForEvent(
"compiler:contracts:compile:before",
View debouncePipe.js
/* global require setImmediate setTimeout */
const {EventEmitter} = require('events');
const {inspect} = require('util');
const {fromEvent: rxFromEvent, interval: rxInterval} = require('rxjs');
const {debounce: rxDebounce, filter: rxFilter} = require('rxjs/operators');
const {
AsyncIterableX: {from: ixFrom},
View fileWatcherEvents.js
// in the top parts of the module with other imports/requires
const {fromEvent: rxFromEvent, interval: rxInterval, partition: rxPartition} = require('rxjs');
const {debounce: rxDebounce} = require('rxjs/operators');
const {AsyncIterableX: {from: ixFrom}, batch: ixBatch} = require('ix/asynciterable');
// -----------------------------------------------------------------------------
const fileChanges$ = rxFromEvent(engine.events, 'file-event');
const [assets$, others$] = rxPartition(
View send-to-iter.js
/* global setTimeout */
(async () => {
const [iter, send, done] = (() => {
let promise;
let resolve;
const queue = [];
const setPromise = () => {
promise = new Promise(res => { resolve = res; });
You can’t perform that action at this time.