slates[sha] => [candidate, candidate]
votes[guy] => sha
approvals[guy] => $amount
deposits[guy] => $amount
lock(wad)
free(wad)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def checkPartialPrefix(query: String): PrefixMatch = { | |
def loop(acc: String, tail: String, sfx: String, mtch: Boolean = false): PrefixMatch = { | |
if (tail.isEmpty) keyWithPrefix(acc) match { | |
case None => Miss(query) | |
case Some(k) => PrefixMatch(query, k, query, get(k).get) | |
} | |
else { | |
val next: String = query.slice(0, acc.size + 1) | |
keyWithPrefix(next) match { | |
case Some(k) => loop(next, tail.tail, k, true) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
:~$ mkdir install | |
:~$ cd install/ | |
:~/install$ wget https://github.com/MysteriumNetwork/node/releases/download/0.0.5/mysterium-node_linux_amd64.deb | |
--2017-05-10 09:41:23-- https://github.com/MysteriumNetwork/node/releases/download/0.0.5/mysterium-node_linux_amd64.deb | |
Resolving github.com (github.com)... 192.30.253.113, 192.30.253.112 | |
Connecting to github.com (github.com)|192.30.253.113|:443... connected. | |
HTTP request sent, awaiting response... 302 Found | |
Location: https://github-cloud.s3.amazonaws.com/releases/80073079/b0e74c48-346f-11e7-8d17-74ba54753546.deb?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAISTNZFOVBIJMK3TQ%2F20170510%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20170510T094123Z&X-Amz-Expires=300&X-Amz-Signature=1a03b67c7c87db9491cf498efe37440e1100d0e43731a3897f95b4c9d480042a&X-Amz-SignedHeaders=host&actor_id=0&response-content-disposition=attachment%3B%20filename%3Dmysterium-node_linux_amd64.deb&response-content-type=application%2Foctet-stream [following] | |
--2017-05-10 09:41:23-- https://g |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pragma solidity ^0.4.17; | |
import "iexec-oracle-contract/contracts/IexecOracleAPI.sol"; | |
import "ds-thing/thing.sol"; | |
contract Cron is DSAuth, DSNote, IexecOracleAPI { | |
uint public constant DAPP_PRICE = 0; | |
struct Task { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Usage: lock-eth <cup> <account> | |
set -e | |
# Config | |
# -------------------------------------------------- | |
MAX="10 ETH" # move funds to CDP when balance > MAX | |
MIN="5 ETH" # don't let balance fall below MIN | |
# -------------------------------------------------- | |
function withRetry { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
with import <nixpkgs> {}; | |
buildGoPackage rec { | |
name = "vulcanizedb-${version}"; | |
version = "0.1"; | |
goPackagePath = "github/vulcanize/VulcanizeDB"; | |
src = fetchFromGitHub { | |
owner = "vulcanize"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{config, pkgs, ... }: | |
let | |
dapphub = import <dapphub> {}; | |
in | |
{ | |
imports = [ <nixpkgs/nixos/modules/virtualisation/amazon-image.nix> ]; | |
ec2.hvm = true; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type Cup { | |
# owner | |
lad: String! | |
# collateral | |
ink: String! | |
# debt | |
art: String! | |
tab: String! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tick | min_pip | max_pip | min_tab | max_tab | min_ratio | max_ratio | act | arg | ink | art | timestamp | |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2017-12-18 13:00:00+00 | 729.52 | 737.392 | 0.0 | 0.0 | open | 0.0 | 0.0 | 2017-12-18 13:03:31+00 | ||||
2017-12-18 13:00:00+00 | 729.52 | 737.392 | 72952.0 | 73739.2 | lock | 100 | 100.0 | 0.0 | 2017-12-18 13:08:14+00 | |||
2017-12-18 14:00:00+00 | 715.184 | 729.52 | 71518.4 | 72952.0 | 100.0 | 0.0 | ||||||
2017-12-18 15:00:00+00 | 718.1315 | 729.2655 | 71813.15 | 72926.55 | 100.0 | 0.0 | ||||||
2017-12-18 16:00:00+00 | 729.2655 | 732.5435 | 72926.55 | 73254.35 | 100.0 | 0.0 | ||||||
2017-12-18 17:00:00+00 | 732.5435 | 732.7035 | 73254.35 | 73270.35 | 100.0 | 0.0 | ||||||
2017-12-18 18:00:00+00 | 732.7035 | 757.779 | 73270.35 | 75777.9 | 100.0 | 0.0 | ||||||
2017-12-18 19:00:00+00 | 757.779 | 765.568 | 75777.9 | 76556.8 | 7577790.0 | 7655680.0 | draw | 1 | 100.0 | 1.0 | 2017-12-18 19:22:14+00 | |
2017-12-18 19:00:00+00 | 757.779 | 765.568 | 75777.9 | 76556.8 | 378.8705564721764 | 382.7648617569122 | draw | 20000 | 100.0 | 20001.0 | 2017-12-18 19:37:51+00 |
We can make this file beautiful and searchable if this error is corrected: It looks like row 8 should actually have 12 columns, instead of 10 in line 7.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tick,min_pip,max_pip,min_tab,max_tab,min_ratio,max_ratio,act,arg,ink,art,timestamp | |
2018-02-09 00:00:00+00,789.1525,797.2625,0.0,0.0,,,open,,0.0,0.0,2018-02-09 00:44:03+00 | |
2018-02-09 00:00:00+00,789.1525,797.2625,790.5352957867268,798.6595065683316,,,lock,1,1.0,0.0,2018-02-09 00:47:51+00 | |
2018-02-09 00:00:00+00,789.1525,797.2625,790.5352957867268,798.6595065683316,316.2141183146907,319.46380262733265,draw,250,1.0,250.0,2018-02-09 00:49:58+00 | |
2018-02-09 00:00:00+00,789.1525,797.2625,5839728.5,5899742.5,2335891.4000000004,2359897.0,lock,7386.056000059308,7387.056000059308,250.0,2018-02-09 00:51:40+00 | |
2018-02-09 00:00:00+00,789.1525,797.2625,5839728.5,5899742.5,233.58914000000001,235.98970000000003,draw,2499750,7387.056000059308,2500000.0,2018-02-09 00:53:55+00 | |
2018-02-09 01:00:00+00,788.25,793.7525,5833050.821311339,5873769.327044629,233.32203285245356,234.95077308178514,,,7387.056000059308,2500000.0, | |
2018-02-09 02:00:00+00,793.7525,803.15,5873770.335458693,5943311.8571893,234.95081341834774,237.732474287572,,,73 |