Merge pull request #81 from dvogel/comma-fix-for-vote-parsing

Made comma optional in amendment vote regex in order to handle samdt813
in about a dozen historical senate votes, it is a vote on an amendment but the bill number is missing: issue a warning and continue
fdsys: if a .html file doesnt exist, dont try to unwrap the text inside of it (fixes #76, supersedes #79)
in old House votes, the legis-num was 'QUORUM 1' and so on
add some more vote category mappings found in historical vote records
In historical House vote XML when the bioguide ID field is not present fall back to matching by name.

Before the 108th Congress, the vote XML never had a bioguide ID.
Starting with the 108th, there are sporadic gaps. This commit
creates a fallback to look-up by name/state/date when no bioguide
ID is present.

So far the 107th Congress maps names to IDs completely. The coverage
may not be as good before that yet. Members with changed names or
changed parties cause some problems.

This also replaces the hard-coded fix for GK Butterfield's "000000"
bioguide ID in several votes, since this is a more generic solution.
See issue #46.
rearrange the GovTrack-style output of votes to make raw diffs to my legacy data cleaner and output entities in UTF-8
in old Senate votes there's no vote_question_text but there is a question node, so use that instead
In the 101st Congress, 1st session (1989), votes 133 through 136 lack lis_member_id nodes. Fall back to name lookup.
A-style House amendment numbering is only listed on amendment pages starting with the 101st Congress
fix amendment to treaty detection for exactly one case: samdt3-100
prevent stray colons in action line references from breaking the parser (split only on the first colon), was a problem in samdt1024-107
in samdt1819-108, the file download didn't convert bytes to unicode but when trying to do entity replacement we insert unicode characters without explicitly decoding body content, which results in an error decoding from ascii. in this case, insert the unicode characters directly as utf-8. this might indicate a broader issue with character encodings.
from the 106th-108th Congress, Pat Toomey's THOMAS ID was 01594; map it to the ID we find in the 109th-113th Congress
in utils.download(), renamed the 'xml' option to 'binary'
the senate committee meetings parser should be downloading XML with the binary flag set to true, and with the next commit *must* because it cannot take unicode instances
Keep non-binary downloaded content in unicode

When downloading non-binary files, scrapelib/requests automatically does character-set detection,
but we've been ignoring it and using the raw bytes. It's probably incorrect to pass raw bytes
to JSON output, and it started causing errors creating XML output (lxml complained about
non-XML-compatible characters). Instead, we should always work in unicode when dealing with text.

This fix changes utils.download() to return unicode instances rather than str instances when
'binary' is not set to True.

Files cached to disk are now stored on disk in UTF-8 always, because when we load up cached
files we no longer know the character set that scrapelib/requests detected. Unfortunately
this means that some cache files may be invalid (just in cases where the original URL
returned non-UTF8 (probably ISO8859-1) content with actual non-UTF8 characters, which
seems to not be entirely common). Best to just clear your cache directory.

The scraper has always worked in bytes. download() was originally written to get the
text content using str(response), which was implicitly encoding the unicode response
back to bytes using the ASCII encoding, which can fail. In a1da46b78fc5c52881016109e53d664d8e51afd6
I fixed that by getting the text content using response.bytes directly, but I wish
I had just made it 'response' alone, which gives the unicode content.

Reverts 11a504cedc53c489809f083b35fba26b41a69b94 (recent work-around for char set issue)

Fixes #82
house committee meeting parser tweaks

Don't bother saving meeting info for meetings more than 60 days ago.

Don't skip a meeting if a subcommittee isn't recognized, just ignore the subcommittee.
I broke VP tie-breaker votes

In cebffaeb051e2fc694ee8f70c8cacab7e4caf748 I forgot to test if the voter ID is the string "VP"
when reading from the cache directory, look for .zip files containing cached directories and load cached files from the .zip if they exist