Skip to content

docs(refonte): plan v2 — 17 étapes, et les trois prémisses que l'audit a réfutées - #268

Merged
thierryvm merged 1 commit into
mainfrom
docs/refonte-v2-plan
Jul 26, 2026
Merged

docs(refonte): plan v2 — 17 étapes, et les trois prémisses que l'audit a réfutées#268
thierryvm merged 1 commit into
mainfrom
docs/refonte-v2-plan

Conversation

@thierryvm

Copy link
Copy Markdown
Owner

Plan complet produit par 14 agents : 5 audits du code réel, 4 études de marché, une synthèse, puis 3 critiques adversariales chargées de le détruire — pas de le valider. Ceci est la version qui leur a survécu.

Documentation uniquement, aucun code.

Trois prémisses de la demande initiale, réfutées sur pièces

« On ne peut pas modifier une dépense » — faux. ExpenseEditDrawer.tsx fait 217 lignes, est monté ligne 337, appelle updateExpenseAction, et a 4 blocs de tests. Le déclencheur est un crayon gris collé à une corbeille rouge qui capte l'œil. Défaut d'affordance, pas de code manquant.

« Il n'y a pas de vraies catégories » — faux aussi. La table existe depuis le schéma initial, 8 catégories sont semées à chaque inscription, expenses.category_id existe, le schéma Zod le porte, le Server Action l'écrit. Deux lignes d'UI débranchent tout : categoryId: null en dur, et un mapping RSC qui perd le champ avant le composant.

« Les menus sont confus » — le symptôme est réel, la cause n'est pas les menus. La nav expose six noms de tables en 7 destinations de rang égal, dont trois décrivent le même geste mental : de l'argent qui sort. Aucune refonte visuelle ne répare ça — c'est pourquoi le polish est délibérément la dernière étape.

Ce que l'étude de marché change

Les banques belges (BNP Fortis, KBC, Beobank) livrent déjà la catégorisation automatique gratuitement. En saisie manuelle sur ce terrain, Ankora perd d'avance.

Mais aucune ne sait ce qui est déjà engagé — et ce chiffre ne se déduit pas d'un historique, il se déclare. C'est la seule donnée que PSD2 ne fournira jamais, ce qui retourne l'absence d'agrégation en positionnement plutôt qu'en handicap.

Ce que les critiques ont tué

  • Une clause ON DELETE SET NULL sans liste de colonnes qui aurait rendu impossible la suppression d'une catégorie sur trois tables (violation NOT NULL sur workspace_id)
  • L'absence de tout chemin de retour arrière sur 4 migrations — un seul projet Supabase, plan Free, pas de PITR, un utilisateur réel. Gate obligatoire désormais : dump + down.sql testé + push par @Thierry
  • La seule migration restante a été sortie du chemin critique

Structure

17 étapes, une branche par étape, ordonnées pour qu'aucune ne dépende d'une suivante. L'étape 1 est petite et livrable seule, conformément à la règle « tant qu'elle n'est pas finie, on ne continue pas ».

Fichier : docs/superpowers/specs/2026-07-26-ankora-refonte-v2-plan.md (1 142 lignes)

Fourteen agents read the actual code and studied the market, a synthesis agent
turned it into a roadmap, and three adversarial critics were told to destroy
that roadmap rather than approve it. This is the revision that survived them.

Three premises of the original request turned out to be false, and each changes
what needs building.

Editing an expense already works. ExpenseEditDrawer.tsx is 217 lines, mounted at
ExpensesClient.tsx:337, calls updateExpenseAction and has four test blocks. Its
trigger is a muted pencil sitting next to a red bin that takes the eye. An
affordance defect, not missing code — repaired in step 1 for almost nothing.

Real categories already exist too. The table has shipped since the initial
schema, eight are seeded at every signup with colour tokens, expenses.category_id
exists, the Zod schema carries it and createExpenseAction writes it. Two lines of
UI unplug the whole thing: categoryId: null hardcoded, and an RSC mapping that
drops the field before it reaches the component. Not a model to redesign, a wire
to reconnect.

And the menus are not the problem. The navigation exposes six table names as
seven equal-rank destinations, three of which describe the same mental act —
money going out. No visual redesign fixes that, which is why polish is
deliberately last rather than first.

The market study reframes the product itself: Belgian banks already ship free
automatic categorisation, so manual entry loses that fight outright. What none of
them knows is what is already committed — and that figure cannot be derived from
a transaction history, it has to be declared. It is the one thing PSD2 will never
supply, which turns the missing aggregation from a handicap into the position.

Seventeen steps, one branch each, ordered so no step depends on a later one.
Step 1 is deliberately small and independently shippable, per the rule that
nothing starts until it is finished.

The critics earned their place. They killed an ON DELETE SET NULL that would have
made deleting a category impossible on three tables at once, forced a rollback
gate on every migration (one Supabase project, Free tier, no PITR, a real user),
and pushed the only remaining migration off the critical path entirely.
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Sorry @thierryvm, your pull request is larger than the review limit of 150000 diff characters

@vercel

vercel Bot commented Jul 26, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
ankora Ready Ready Preview, Comment Jul 26, 2026 12:12pm

@github-actions github-actions Bot added status:review-needed Ready for review type:docs Documentation only labels Jul 26, 2026
@thierryvm
thierryvm merged commit d67a706 into main Jul 26, 2026
9 checks passed
@thierryvm
thierryvm deleted the docs/refonte-v2-plan branch July 26, 2026 12:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

status:review-needed Ready for review type:docs Documentation only

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant