Frontmatter
| id | 9142 |
| title | [DevIndex] Create Country Code Repair Script |
| state | Closed |
| labels | aifeature |
| assignees | tobiu |
| createdAt | Feb 13, 2026, 1:19 PM |
| updatedAt | Feb 13, 2026, 1:29 PM |
| githubUrl | https://github.com/neomjs/neo/issues/9142 |
| author | tobiu |
| commentsCount | 2 |
| parentIssue | 9106 |
| subIssues | [] |
| subIssuesCompleted | 0 |
| subIssuesTotal | 0 |
| blockedBy | [] |
| blocking | [] |
| closedAt | Feb 13, 2026, 1:29 PM |
[DevIndex] Create Country Code Repair Script
tobiu added parent issue #9106 on Feb 13, 2026, 1:19 PM

tobiu
Feb 13, 2026, 1:28 PM
Input from Gemini 3 Pro:
✦ I have executed the
fixCountryCodes.mjsscript again after enhancing theLocationNormalizer.Key Improvements:
- Full US State Names: Now correctly identifying "Ohio", "Utah", "Colorado", "Minnesota", etc. as 'US'.
- Cities: "Genoa" (IT), "Atlanta" (US), "Salt Lake City" (US), "Medina" (US).
- Conflict Resolution: "Georgia" (Country) vs "Georgia" (US State). The logic currently maps "Georgia" -> 'US' via the state name check.
- Observation: Users like "m-burst" and "rlidwka" have location "Tbilisi, Georgia", which is the country. My script mapped them to 'US'.
- Correction: I need to refine the regex to NOT match "Georgia" if it's "Tbilisi, Georgia". Or accept that "Georgia" alone is ambiguous but "Tbilisi" makes it 'GE'.
- Wait:
LocationNormalizerdoes not have "Tbilisi" in the city map. Adding "Tbilisi" -> 'GE' would fix this.Proposed Follow-up: I noticed "Tbilisi, Georgia" getting mapped to 'US' because of the "Georgia" state match. I should add "Tbilisi" to the city map to correctly resolve these to 'GE' (Georgia - Country) before the US state check.
However, ISO code for Georgia (Country) is GE. The current script mapped them to US.
I will do one more quick pass to fix "Tbilisi".

tobiu
Feb 13, 2026, 1:29 PM
Input from Gemini 3 Pro:
✦ Fixed "Tbilisi" resolving to 'US' (via Georgia state match). It now correctly resolves to 'GE'. Updated 2 records. Closing ticket.
tobiu assigned to @tobiu on Feb 13, 2026, 1:29 PM
tobiu closed this issue on Feb 13, 2026, 1:29 PM
Since the
LocationNormalizeris only applied during fresh API fetches, waiting for the update cycle would leave inconsistent data (broken flags) for existing records.We need a one-off repair script to apply the new rules to the existing dataset immediately.
Scope:
apps/devindex/buildScripts/fixCountryCodes.mjs.Storageservice to load all users.LocationNormalizeron every user's location string.