Migration Control - every row accounted for by Simone SantiaMigration Control - every row accounted for by Simone Santia

Migration Control - every row accounted for

Simone Santia

Simone Santia

Self-initiated technical demonstration | Original synthetic data | Built October 2026
Before a migration, a tidy export can still conceal ambiguous IDs, email collisions, orphaned references and unvalued amounts. Migration Control makes those exceptions visible before records reach a target.
THE WORKFLOW Two exact-schema CSVs enter a Python audit. Every source row goes to accepted output or a reasoned quarantine register. Duplicate member IDs and colliding normalized emails are held for review. Opt-out, unknown-consent and bounce flags survive the transformation.
MONEY THAT RECONCILES The 12 synthetic payment rows split into 5 accepted and 7 quarantined. Valued USD records reconcile exactly: $185.34 source = $82.34 accepted + $103.00 quarantined. EUR 19.99 stays separate. Two rows with invalid precision or missing currency remain unvalued. A refund is preserved, and duplicate transactions remain accounted for in quarantine.
A CHECKABLE DRY RUN Six accepted member records receive stable external IDs. The first local simulation creates six records; the second performs six NOOP operations and yields the same target fingerprint. All 23 regression tests pass, with a separate SQLite calculation confirming fixture totals. Tests include malformed schemas, duplicate keys, Unicode/BOM handling, suppression, refunds and large integer amounts.
DELIVERY DESIGN The recoverable implementation produces accepted/quarantined CSVs, an audit JSON, fingerprints and a local dry-run manifest. The three panels show actual executed results. Development is AI-assisted; correctness is checked through reproducible tests and explicit invariants.
SCOPE This is a personal exact-schema prototype, not a paid client project. The target is mocked locally. No CRM API, real import, email send, currency conversion, legal consent certification or business ROI is claimed. Client schemas, target rules, data permissions and acceptance would be agreed before production.
Need a migration-ready export? A bounded paid audit can provide row-level exceptions, reconciled totals, a proposed field map and a repeatable validator. Scope, authorized tools, acceptance and a funded milestone would be agreed before work.
migration-control-source.zip
INSPECT AND REPRODUCE THE PYTHON Use the downloadable source archive above for the implementation, synthetic fixtures, 23 regression tests, executed JSON/CSV outputs, a source walkthrough and SHA-256 checksums. Python 3.12 standard library only; no credentials, installation or network needed. From the extracted migration-control directory, run the two commands below. The source is an AI-assisted self-initiated demonstration, not client-verified work. The public source uses a generic UUID namespace; this changes IDs from the earlier media build while preserving counts, monetary results and idempotency. Runtime measurements are machine-specific.
REPRODUCE — run the commands in the source README.
CODE EXCERPT: EXACT CENTS WITHOUT FLOATING-POINT ROUNDING This function is from the included Python auditor. Invalid precision and unknown currency raise explicit errors; negative refunds and arbitrarily large valid amounts retain exact cent values. Tests challenge these cases instead of inferring correctness from an image.
# Run these commands from the extracted migration-control directory:
# python audit.py --members fixtures/members.csv --payments fixtures/payments.csv --output output
# python verify.py

def money(amount, currency):
if currency not in CURRENCIES:
raise ValueError('UNSUPPORTED_OR_MISSING_CURRENCY')
if not re.fullmatch(r'-?\d+(?:\.\d{1,2})?', amount):
raise ValueError('INVALID_CENT_PRECISION_OR_AMOUNT')
# Parse digits directly: Decimal arithmetic has a configurable precision
# context and must not silently round a very large otherwise-valid amount.
negative = amount.startswith('-')
unsigned = amount[1:] if negative else amount
whole, _, fraction = unsigned.partition('.')
cents = int(whole) * 100 + int(fraction.ljust(2, '0') or '0')
return -cents if negative else cents

Like this project

Posted Oct 12, 2026

Self-initiated Python demonstration: traceable CSV quarantine, exact currency reconciliation and a repeatable local migration dry run.

Likes

0

Views

1

Timeline

Oct 12, 2026 - Oct 13, 2026