diff --git a/openstates/data/models/people_orgs.py b/openstates/data/models/people_orgs.py index b5825d51f..1b3d8b668 100644 --- a/openstates/data/models/people_orgs.py +++ b/openstates/data/models/people_orgs.py @@ -286,8 +286,11 @@ def __str__(self): OFFICE_CHOICES = ( ("district", "District Office"), + ("district-mail", "District Mailing Address"), ("capitol", "Capitol Office"), + ("capitol-mail", "Capitol Mailing Address"), ("primary", "Primary Office"), + ("home", "Home"), ) diff --git a/openstates/utils/people/lint_people.py b/openstates/utils/people/lint_people.py index cee7377a4..7bfa7deea 100644 --- a/openstates/utils/people/lint_people.py +++ b/openstates/utils/people/lint_people.py @@ -94,7 +94,7 @@ def validate_offices(person: Person) -> list[str]: for office in person.offices: type_counter[office.classification] += 1 for key, value in office.dict().items(): - if key == "classification" or not value: + if key == "classification" or key == "voice" or key == "fax" or not value: continue # reverse lookup to see if we've used this phone number/etc. before location_str = f"{office.classification} {key}" diff --git a/openstates/utils/tests/test_lint.py b/openstates/utils/tests/test_lint.py index 946726ed5..7cde10e12 100644 --- a/openstates/utils/tests/test_lint.py +++ b/openstates/utils/tests/test_lint.py @@ -172,15 +172,6 @@ def test_validate_roles_retired(roles, expected): ], [], ), - ( - [ - {"classification": "district", "voice": "123-444-4444"}, - {"classification": "capitol", "voice": "123-444-4444"}, - ], - [ - "Value '123-444-4444' used multiple times: district voice and capitol voice" - ], - ), ], ) def test_validate_offices(offices, expected): diff --git a/pyproject.toml b/pyproject.toml index 0ff8134f3..b0d4de61b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "openstates" -version = "6.18.0" +version = "6.18.1" description = "core infrastructure for the openstates project" authors = ["James Turk "] license = "MIT"