View StateMonad.scala
import scalaz._
import Scalaz._
/**
* Use the state monad to 'process a trade' and store the new trade.
* As well as processing the trade, handle validation errors.
*/
object StateMonad extends App {
case class Trade(info: String)
View webtail.go
package main
import "bytes"
import "io"
import "os"
import "strings"
import "strconv"
import "fmt"
import "flag"
import "net/http"
View mysqlpool.scala
// Copyright (C) 2012 Benoit Sigoure
// Copyright (C) 2012 StumbleUpon, Inc.
// This library is free software: you can redistribute it and/or modify it
// under the terms of the GNU Lesser General Public License as published by
// the Free Software Foundation, either version 2.1 of the License, or (at your
// option) any later version. This program is distributed in the hope that it
// will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty
// of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser
// General Public License for more details. You should have received a copy
// of the GNU Lesser General Public License along with this program. If not,
View gist:39bc2d3f9c8a2c2dc5ff
{
"situation":"open_raise",
"position":null,
"upload_hands_item_id":"526ed331ce34de6612a66390",
"created_at":"2013-10-29T01:12:17.178Z",
"updated_at":"2013-10-29T01:12:17.178Z",
"upload_hands_item_date":"2013-10-29T01:12:17.178Z",
"columns":[
{
"aposteriori_share":"0.33282",
View gist:ed5e1cac5a393233e673
{
"header":{
"showdown":{
"freewalk":"show",
"SERGO LAVROV":"show"
},
"currency":"USD",
"bb_player":"lucylooose",
"table":{
"button":5,
View gist:4a9d71b9a3eaa94c8d60
{
"header":{
"showdown":{
},
"currency":"USD",
"bb_player":"krondix",
"table":{
"button":2,
"name":"Sita III",
View gist:5a408f97d43d604aea5b
{
"header":{
"showdown":{
"lucylooose":"show",
"freewalk":"show",
"SERGO LAVROV":"show"
},
"currency":"USD",
"bb_player":"SERGO LAVROV",
"table":{
View gist:b6a75a391fcabff32e35
{
"header":{
"showdown":{
"krondix":"show",
"Liza_plus_EV":"muck",
"Ithfen":"show",
"Ludvig100602":"muck",
"BIG2BOSS":"muck"
},
"currency":"USD",
View coach_facing_unopened.json
{
"buckets_count":10,
"status":"done",
"user_id":2,
"created_at":"2013-12-08 01:00:50.540000",
"updated_at":"2013-12-08 01:01:47.394000",
"player":null,
"upload_hands_item_id":"52a32f6ace34de6ad64767eb",
"situation":"facing_unopened",
"position":null,
View gist:8097b38868a75e6b0a57
{
"status":"done",
"user_id":4,
"user_hands_uploaded_at":null,
"coach_id":3,
"recommendations":{
"facing_3bet_after_open_raise":[
{
"column_name":"AA",
"user_original_hands_count":32,