openstates / openstates-scrapers

source for Open States scrapers
https://openstates.org
GNU General Public License v3.0
846 stars 465 forks source link

MA: district names for lower house formatted differently in legislator, district #1388

Closed estaub closed 7 years ago

estaub commented 7 years ago

The legislator API does not return OpenStates district IDs - it only provides district names. So if one wants to associate the legislator with a district from the district API, one must use the state+chamber+name to match them up.

In the MA lower house, the legislator API provides district fields named using digits, e.g.:

3rd Hampden
14th Worcester
16th Middlesex
6th Worcester
12th Norfolk
9th Essex
7th Plymouth

but the district API has the digits spelled out, e.g.:

Eighteenth Suffolk
Eighteenth Worcester
Eighth Bristol
Eighth Essex
Eighth Hampden
Eighth Middlesex

making them very difficult to associate.

jamesturk commented 7 years ago

this is the same issue as #1258 - which definitely needs some attention