I hereby claim:
- I am twneale on github.
- I am twneale (https://keybase.io/twneale) on keybase.
- I have a public key ASBHERV361ILHrWj9WnVa_X7mI5u8FrXDmrlwqhOswPRsgo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
Any person violating any provision of subsection | |
1-2.6 | |
shall be punished by a fine not exceeding twenty ($20.00) dollars for each offense, and not only the | |
The provisions of subsection | |
2-12.3 | |
to the contrary notwithstanding, this ordinance shall be published by the action of the City Council | |
[('/us/usc/t21/s812/b/1', 4), | |
('/us/usc/t21/s812/b/4', 4), | |
('/us/usc/t21/s812/b/5', 4), | |
('/us/usc/t21/s812/b/2', 4), | |
('/us/usc/t21/s812/a', 4), | |
('/us/usc/t21/s812/b', 4), | |
('/us/usc/t21/s812/b/3', 4), | |
('/us/usc/t21/s812/c', 4), | |
('/us/usc/t42/s14214/d/10', 3), | |
('/us/usc/t21/s812/a/1', 3), |
usc25.xml: | |
- The xml for /us/usc/t25/s450l (Contract or grant specifications) contains a model agreement with its own internal | |
Thom Neale <[email protected]> | |
Apr 13 | |
to Katherine | |
Hi Katherine, please forgive the earlier email fragment; I accidentally sent if before I was done typing. |
from sunlight import openstates, response_cache | |
from pscl.ext.openstates import RollcallBuilder | |
response_cache.enable('mongo') | |
response_cache.logger.setLevel(10) | |
spec = dict(state='al', chamber='lower', search_window='term:2011-2014') | |
valid_ids = [leg['id'] for leg in openstates.legislators(spec)] |
import re | |
def citations(text): | |
rgx = u'(\\d+)\\s+U\\.?S\\.?C\\.?\\s*\xa7*\\s\\s*([\\d\\w\\-\\\u2013\\.\u2013]+)(\\([\\d\\w\\-\\\u2013\\.\u2013()]+\\))*' | |
matches = [] | |
for match in re.finditer(rgx, text): | |
title, section, path = match.groups() | |
section = section.strip(u'\u2013.- ') | |
start, end = match.span() |
import re | |
import os | |
import sys | |
import json | |
import contextlib | |
import lxml.etree | |
@contextlib.contextmanager |
>>> import difflib | |
>>> for opcode in difflib.SequenceMatcher(None, "This is a test.", "That is a tent").get_opcodes(): | |
... print opcode | |
... | |
('equal', 0, 2, 0, 2) | |
('replace', 2, 4, 2, 4) | |
('equal', 4, 12, 4, 12) | |
('replace', 12, 13, 12, 13) | |
('equal', 13, 14, 13, 14) | |
('delete', 14, 15, 14, 14) |
'''See http://stackoverflow.com/a/5359988/120991 | |
''' | |
from fabric.api import * | |
from contextlib import contextmanager | |
env.update( | |
use_ssh_config=True, | |
directory='/home/ubuntu/projects/thingy', |
from operator import methodcaller | |
import lxml.html | |
from whoosh.index import create_in | |
from whoosh.fields import * | |
from whoosh.qparser import QueryParser | |
class Stats(object): |