Skip to content

Instantly share code, notes, and snippets.

View dbarobin's full-sized avatar
🎯
Focusing

Robin Wen dbarobin

🎯
Focusing
View GitHub Profile
@spalladino
spalladino / falsehoods-that-ethereum-programmers-believe.md
Last active August 16, 2025 20:50
Falsehoods that Ethereum programmers believe

Falsehoods that Ethereum programmers believe

I recently stumbled upon Falsehoods programmers believe about time zones, which got a good laugh out of me. It reminded me of other great lists of falsehoods, such as about names or time, and made me look for an equivalent for Ethereum. Having found none, here is my humble contribution to this set.

About Gas

Calling estimateGas will return the gas required by my transaction

Calling estimateGas will return the gas that your transaction would require if it were mined now. The current state of the chain may be very different to the state in which your tx will get mined. So when your tx i

@lmacken
lmacken / lightning_invoice_watcher.py
Last active June 8, 2023 14:14
A simple pylightning invoice handler
import os
import json
import asyncio
import aioredis
from lightning import LightningRpc
LN_RPC_URI = os.path.expanduser("~/.lightning/lightning-rpc")
LN_RPC = LightningRpc(LN_RPC_URI)
@alexbosworth
alexbosworth / inotify-channel-backup.md
Last active October 29, 2025 22:51
Backup channel.backup file using systemd and inotify

LND backup script for channel.backup using inotify

Install inotify

sudo apt install inotify-tools

Create script to watch for changes and copy on change

@myrual
myrual / Mixin_Network_Node_Plan.md
Last active June 8, 2023 14:15
Mixin Network上线计划和细节

主网上线日期

2019-02-28 00:00:00 UTC

会有哪些节点

技术实力较好的团队在上线前集中沟通,选出 7 个预选节点

如何启动

7个预选节点提前写入 genesis.json 文件中,会提前启动网络,由于在网络中固定写好了上线精确时间,所以可以保证在上线精确时间产生第一个 kernel snapshot。为保证节点网络一开始的安全和稳定,会推荐所有节点之间配置私有的通信防火墙。

什么时候开放其他节点加入

@dominictarr
dominictarr / readme.md
Created November 26, 2018 22:39
statement on event-stream compromise

Hey everyone - this is not just a one off thing, there are likely to be many other modules in your dependency trees that are now a burden to their authors. I didn't create this code for altruistic motivations, I created it for fun. I was learning, and learning is fun. I gave it away because it was easy to do so, and because sharing helps learning too. I think most of the small modules on npm were created for reasons like this. However, that was a long time ago. I've since moved on from this module and moved on from that thing too and in the process of moving on from that as well. I've written way better modules than this, the internet just hasn't fully caught up.

@broros

otherwise why would he hand over a popular package to a stranger?

If it's not fun anymore, you get literally nothing from maintaining a popular package.

One time, I was working as a dishwasher in a restu

@JohnnyZhao
JohnnyZhao / cross-verify-eos-final-snapshot.py
Created June 3, 2018 00:25
Cross check eos final snapshot
f = open('snapshot.csv')
dict1 = {}
for line in f.readlines():
l = line.strip().split(',')
eth_addr, eos_addr, balance = l
eth_addr = eth_addr.lower()
eos_addr = eos_addr.lower()
if dict1.has_key(eth_addr):
print dict1[eth_addr]
print line
@JohnnyZhao
JohnnyZhao / register-producer-and-vote-dawn-4.0.md
Last active June 5, 2018 23:13
EOSIO: How to register producer an vote using Dawn 4.0

Run 4 nodeos instance, 1 eosio bios node, 3 BP nodes, with producer names bp1 bp2 bp3.

1. Deploy eosio.bios contract to eosio account.

cleos set contract eosio contracts/eosio.bios 

2. Create eosio.token account

@niespodd
niespodd / package.json
Last active October 15, 2025 02:48
Making web3/bitcore-lib work with Angular 6-11 and >=11
{...
"scripts": {
"postinstall": "node patch.js",
...
}
}
@tbfleming
tbfleming / main.abi
Last active October 20, 2021 14:06
cib eos demo: Track incoming funds
{
"structs": [{
"name": "withdraw",
"base": "",
"fields": [
{"name":"user", "type":"account_name"}
]
},{
"name": "balance",
"base": "",
@ecurrencyhodler
ecurrencyhodler / (Deprecated)LTC-Lightning-Network-lnd-Guide (Mac).md
Last active December 18, 2023 02:32
This is a step-by-step main net tutorial on how to setup a lightning network node for Litecoin on a Mac. It will take you from the beginning all the way through to becoming visible on a ln explorer. To send or recieve payments, refer to "Basic lnd Commands."

LTC-Lightning-Network-lnd-Guide

This is a step-by-step main net tutorial on how to setup a Lightning Network node for Litecoin on a Mac. It is specifically for the lnd client by the Lightning Labs. You can copy and paste most of the commands except for the times I've indicated in bold for you to input your own information. It would also be a good idea to backup your computer prior to starting just in case you need to start over.

Below is a legend. Refer to it as you come across terms or symbols you don’t understand. The first part of the tutorial is taken from the lnd github. However, everything else is written with the help of Patrick Walters taking me step by step through the process.

Legend

$ = This symbol means 1 line of code. Do not type “$” into your terminal. Simply input what follows then push enter.

Pubkey = Short for the public key that is generated from the private key w