You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Create Organization model with name, common_names, url, and sourcing fields for representing government entities within jurisdictions (Integration with Jurisdiction model and update to docs TODO in Add Organization attribute to Jurisdiction model #157)
Note on naming convention: Popolo's schema suggests other_names for alternative organization names. However, following @kstohr's suggestion in #155, this PR uses common_names.
Note on scope: The initial issue provided a starting point for the Organization model design. This PR implements a minimal version with only essential fields (name, common_names, url, classification, sourcing). Additional Popolo-compliant fields (like contact_details, image, parent_id, etc.) can be added in future PRs as needed.
What was updated: src/models/organization.py tests/src/models/test_organization.py
⚠️ This PR contains changes outside the allowed YAML paths (/divisions or /jurisdictions). Auto-merge is disabled. Manual review and merge required.
VirginiaDooley
changed the title
Create Organization model based on Popolo schema including classifica…
Create Organization model based on Popolo schema
Aug 17, 2026
Original ticket exists because of my ask. Minimum fields I want/need are "url" and "name".
Note that the attribute "common_names" differs from the popolo/civic tech field which uses "other_names". Nit (on the issue/repo models), but this looks good to me, thank you!
Original ticket exists because of my ask. Minimum fields I want/need are "url" and "name".
Note that the attribute "common_names" differs from the popolo/civic tech field which uses "other_names". Nit (on the issue/repo models), but this looks good to me, thank you!
@shelltr Renamed “common_names” to “other_names” to match Popolo standard in befa2bd and ed1d19c
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Change Type
Summary
Organizationmodel withname,common_names,url, andsourcing fieldsfor representing government entities within jurisdictions (Integration withJurisdictionmodel and update to docs TODO in Add Organization attribute to Jurisdiction model #157)OrganizationClassificationEnumwith Popolo-compliant classification typesNote on naming convention: Popolo's schema suggests
other_namesfor alternative organization names. However, following @kstohr's suggestion in #155, this PR usescommon_names.Note on scope: The initial issue provided a starting point for the Organization model design. This PR implements a minimal version with only essential fields (name, common_names, url, classification, sourcing). Additional Popolo-compliant fields (like contact_details, image, parent_id, etc.) can be added in future PRs as needed.
What was updated:
src/models/organization.pytests/src/models/test_organization.pyCode Change
Linked Issue: Closes #155
Validation:
uv run ruff check .