Skip to content

Add an ISO 3166-1 assignment predicate - #598

Merged
rochlefebvre merged 1 commit into
Shopify:mainfrom
chrisdakin:cdakin/worldwide-iso-assigned
Sep 21, 2026
Merged

rochlefebvre merged 1 commit into
Shopify:mainfrom
chrisdakin:cdakin/worldwide-iso-assigned

Conversation

@chrisdakin

@chrisdakin chrisdakin commented Sep 17, 2026 •

Copy link
Copy Markdown
Contributor

Add Region#iso_3166_code_assigned? to identify regions with currently assigned ISO 3166-1 alpha-2 codes.

Check the resolved region's iso_code against a frozen set of 249 assigned codes.

Reference: https://www.iso.org/iso-3166-country-codes.html

@chrisdakin
chrisdakin force-pushed the cdakin/worldwide-iso-assigned branch 3 times, most recently from 9169862 to 14bc70a Compare September 18, 2026 14:05
@chrisdakin
chrisdakin marked this pull request as ready for review September 18, 2026 15:02
@chrisdakin
chrisdakin force-pushed the cdakin/worldwide-iso-assigned branch from 14bc70a to 3f42d5c Compare September 18, 2026 15:05
@rochlefebvre
rochlefebvre self-requested a review September 18, 2026 16:28

@najibna najibna left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The predicate is clear, and the tests cover assigned codes, reserved/user-assigned codes, subdivisions, and lookup aliases.

One note: the YAML snapshot cites Wikipedia. A pointer to the ISO 3166-1 Maintenance Agency list would make the source of the 249 codes easier to re-check later.

@chrisdakin
chrisdakin force-pushed the cdakin/worldwide-iso-assigned branch from 3f42d5c to 3aac8b1 Compare September 21, 2026 15:41
@rochlefebvre
rochlefebvre merged commit cde86cf into Shopify:main Sep 21, 2026
6 checks passed

This branch was successfully deployed

1 active deployment
rubygems — 3aac8b1d Deployed Sep 21, 2026 by shopify-shipit[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants