Skip to content

Instantly share code, notes, and snippets.

View veox's full-sized avatar
💭
Being skeptical of status feature.

Noel Maersk veox

💭
Being skeptical of status feature.
View GitHub Profile
--- trim ---
https://peepeth.com/about
https://www.kickstarter.com/projects/1414168019/peepeth-social-network-for-a-better-world
Peepeth's data is open to anyone. The contract is stateless, except for recording unique usernames, so you have to query each block and parse the input data of each transaction according to the following ABI.
For more about stateless contracts, check out this great post.
https://medium.com/@childsmaidment/stateless-smart-contracts-21830b0cd1b6
@gsalgado
gsalgado / test_make_trie_root_and_nodes.py
Created August 23, 2018 05:40
profile make_trie_root_and_nodes()
import cProfile
import os
import pstats
import random
import rlp
from eth.db.trie import make_trie_root_and_nodes
from eth.vm.forks.frontier.transactions import FrontierTransaction
@jordanmack
jordanmack / gist:9373f9b922e906eeffb0cbff0cefe57e
Created August 25, 2018 04:51
Peepeth: Bookmarklet code to unhide all content without having to click.
javascript:(function()%7Bconst%20reveal%20%3D%20function()%7BjQuery(%22a.nsfwShow%22).click()%3BjQuery(%22a.politicsShow%22).click()%3B%7D%3Breveal()%3BsetInterval(reveal%2C%20500)%7D)()
@jordanmack
jordanmack / user.js
Last active October 23, 2018 06:33
Peepeth Enhancer is a user script that adds several new features to Peepeth. To use this user script install you will need the Tampermonkey plugin. https://tampermonkey.net/
// ==UserScript==
// @name Peepeth Enhancer
// @namespace https://github.com/jordanmack/PeepethEnhancer
// @version 0.3.0
// @description Peepeth Enhancer is a collection of scripts that add several new features to Peepeth.
// @author Jordan Mack (jordanmack.info)
// @match https://peepeth.com/*
// @grant none
// ==/UserScript==
#import asyncio
import logging
from flask import Blueprint, Flask, request, render_template, g
from flask_graphql import GraphQLView
from google.cloud import logging as glogging
#from graphql.execution.executors.asyncio import AsyncioExecutor
from web3 import Web3, HTTPProvider
from werkzeug.serving import run_simple
from graphql import (
graphql,
@holiman
holiman / result.md
Last active October 15, 2018 13:31

parity stateroot:0xa054d80c3c6192476447b6fdb3276af19400068432949c28431e5cc3e63d3c3f,, geth stateroot: 0x3ba0188e00002fd15395c3acca8cbbca76dbe56f5f2214d7fb12c1c348aaa965

{
"SstoreCallToSelfSubRefundBelowZero": {
"_info": {
"comment": "Test where accnt has slot 1 value of '2', is cleared, then calls itself and overwrites with '3', causing a refund-deduction in second call context",
"filledwith": "manaually filled by @holiman",
"lllcversion": "none",
"source": "none",
"sourceHash": "none"
},
"env": {
contract MazeHashFunction {
function generateRandomNumber(uint _treasureMap) view public returns (uint) {
bytes memory randomNumber = new bytes(32);
bytes memory treasureMapInBytes = toBytes(_treasureMap);
uint8 nextByteInTreasureMap = uint8(treasureMapInBytes[31]);
uint8 pointerToNextPosition = nextByteInTreasureMap;
for(uint i = 31; i >0; i--) {
uint nextHashInLabyrinth = uint(blockhash(block.number - 1 - pointerToNextPosition));
@5chdn
5chdn / stureby.aleth.json
Last active December 3, 2018 21:51
Stureby PoW Testnet Configuration for Constantinople Transition
{
"sealEngine":"Ethash",
"params":{
"accountStartNonce":"0x00",
"maximumExtraDataSize":"0x20",
"homesteadForkBlock":"0x2710",
"daoHardforkBlock":"0x00",
"EIP150ForkBlock":"0x3a98",
"EIP158ForkBlock":"0x59d8",
"byzantiumForkBlock":"0x7530",
@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