fix(data): reconcile symbiosis-2025 bounty amounts & names (#28)#51
Merged
fix(data): reconcile symbiosis-2025 bounty amounts & names (#28)#51
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Cross-referenced prod bounty_prizes against the symbiosis-2025 source-of-truth CSV and applied 10 corrections (9 UPDATE + 1 INSERT). 5 projects skipped (entire project record missing — logged for follow-up). Plata Mia (already correct from #27) was a NOOP. Changes applied to prod: UPDATEs (wrong names and/or amounts): - ObraClara: "Polkadot main track" $2500 → "IDEA-THON main track" $4000 - Kleo Protocol: "Polkadot main track" $2500 → "SHIP-A-THON main track" $4000 - OpenArkiv: "Polkadot main track" $2500 → "SHIP-A-THON main track" $4000 - Chiri App: "Kusama bounty" $2500 → "Kusama" $500 - Unblind for Polkadot: "Kusama bounty" $2500 → "Kusama" $1500 - Infinite conspiracy: "Kusama bounty" $2500 → "Kusama" $3000 - Siphon Protocol: "Hyperbridge bounty" $2500 → "Hyperbridge" $1500 - The People's Vote: "xx Network bounty" $2500 → "xx Network" $3000 - GhostMesh: "xx Network bounty" $2500 → "xx Network" $2000 INSERT (row was missing): - Carbon Smart Meter: (nothing) → "xx Network" $250 SKIPs (project records missing from `projects` table, logged in backlog): Right of the DOTty, Khoj, Pointillism, Connected by the Dots, Crypto Therapy | Polkadot. Changes in this commit: - server/scripts/reconcile-bounty-amounts-supabase.js (new) — general CSV-driven reconciliation with --dry-run, idempotent, safety rules (never delete, never auto-mutate multi-row projects, skip when expected shape is multi-row — those use the Plata Mia pattern). - server/migration-data/prizes-symbiosis-2025.csv — source-of-truth corrections: Siphon → Siphon Protocol (project name in DB); Siphon amount 500 → 1500; Carbon Smart Meter amount null → 250 (the xx Network row that wasn't fully legible in the original screenshot). - client/src/lib/mockWinners.ts — mirrors every prod change (9 updates + 1 insertion) so Vercel preview mock mode matches prod. - docs/improvement-backlog.md — two new entries: per-bounty source-of- truth CSVs missing for synergy-2025 / symmetry-2024; five symbiosis marketing-track winners missing from projects table entirely. Out of scope: - synergy-2025 and symmetry-2024 reconciliation (no per-bounty CSV exists for those events; payouts.csv only has total prize). - Missing marketing-track projects (needs project-level metadata, not just bounty data; separate follow-up issue). - Payment history bountyName fields in totalPaid still reference old names ("Kusama bounty" etc.) — payments are a separate layer; out of scope for #28 which is about bounty-prize rows specifically. Verification: - Dry-run showed 9 UPDATE + 1 INSERT + 5 SKIP. - Real run applied all 10 mutations successfully. - Post-fix dry-run shows 11 NOOP + 5 SKIP + 0 pending changes (idempotent).
4e44e52 to
a33fc00
Compare
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Closes #28.
Stacked on #50 — target base is
fix/plata-mia-bounties-27while that PR is open so the diff stays clean. Once #50 merges todevelop, I'll rebase this PR and retarget todevelop.Summary
bounty_prizesrows against the source-of-truth CSV added in fix(data): split Plata Mia's concatenated bountyPrize row (#27) #50.server/scripts/reconcile-bounty-amounts-supabase.js.projectsrow at all (not just missing a bounty row). Logged in the improvement-backlog; separate follow-up issue needed with project-level metadata.Changes applied to prod
Files in this PR
server/scripts/reconcile-bounty-amounts-supabase.js— new. CSV-driven general reconciliation with--dry-run, idempotent, scoped safety rules:--hackathon=<id>flag; Phase 1 only hassymbiosis-2025registered inCSV_PATHS.server/migration-data/prizes-symbiosis-2025.csv— two corrections to the source-of-truth from the screenshot:client/src/lib/mockWinners.ts— mirrors every prod change so Vercel preview mock mode matches prod.docs/improvement-backlog.md— two new entries: missing per-bounty CSVs for synergy-2025 / symmetry-2024, and the 5 missing Marketing-track projects.Test plan
--dry-run— showed 9 UPDATE + 1 INSERT + 5 SKIP.--dry-run— 11 NOOP + 5 SKIP + 0 pending (idempotent ✓)./adminWinnersTable for the 10 affected projects — human reviewer walks through once deployed.WinnersTable.tsx:547already iterates the array; rendering is unchanged.GET /api/m2-program/obraclara-98b0e9should show"bountyPrize": [{ "name": "IDEA-THON main track", "amount": 4000, ... }].Not in scope
Total Prize (USDC)column inpayouts.csv, not per-bounty detail. Added a backlog entry asking for the same-shape spreadsheets from WebZero.totalPaid[].bountyNamereferences. The payment-historybountyNamefields on ObraClara / Kleo / OpenArkiv / Chiri App / etc. still reference the old bounty names ("Kusama bounty" etc.). Payment records are a different layer — preserving the name at time-of-payment is arguably correct (audit trail). Not touched here; not logged as a concern unless fix(data): split Plata Mia's concatenated bountyPrize row (#27) #50 or ops: verify / restore fix-bounty-amounts-supabase.js (bounty amounts may not match source-of-truth CSV) #28 reviews say otherwise.projects.project_nameside — the DB has "Siphon Protocol"; we updated the CSV to match. Nothing on the DB rename side.Related
docs/improvement-backlog.md: per-bounty source-of-truth CSVs for synergy-2025 and symmetry-2024.