Skip to content

[DevIndex] Create Country Code Repair Script #9142

@tobiu

Description

@tobiu

Since the LocationNormalizer is 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:

  1. Create apps/devindex/buildScripts/fixCountryCodes.mjs.
  2. Use the Storage service to load all users.
  3. Re-run LocationNormalizer on every user's location string.
  4. Update and save the records if the country code changes (e.g., 'DC' -> 'US').

Metadata

Metadata

Assignees

Labels

aifeatureNew feature functionality

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions