Appearance
Pokemon rarity business rules
Review date: 2026-10-20. Implementation: backend issue #519, mobile #766.
Scope and existing work
The backend owns classification and per-series order. The app consumes the optional validated rank, retaining multi-select rarity filters (mobile #671) and REV-203 anniversary order (#744). No duplicate anniversary implementation. The Pokecardex reference remains a historical 2026-10-06 snapshot, not a newly verified source. The supplied Notion page was inaccessible; the user's detailed series review is the override authority.
Category Order: Pokecardex Is the Reference
The user confirmed classification is correct but ordering is not. The live ordering comparison supersedes the earlier positional overrides and the historical snapshot for ordering only. It covers 101 source pages and every requested series/subset and exclusion.
Heroes now places its existing Rare group in the source Holographique slot, and Mega Hyper before Mega Attack; Paldea places ordinary tiers before both shiny tiers. The reviewed SV sets retain HIGH-TECH last, and Foudre/Flamme keep Black/White last. Legacy explicit holo precedes Ultra/LV.X and secrets. Existing labels and all card-to-rarity memberships remain unchanged.
Snag-only groups absent from source controls are explicitly documented and retained after verified controls, not merged or removed. Unknown labels stay visible. Existing promo/XY/BW exclusions and REV-203 remain unchanged.
New final secret categories
The displayed label is French Secrete (accented on the wire). Exactly 62 existing cards enter the final category; ordinary cards keep their categories.
| Series | Immutable series ID | Local numbers |
|---|---|---|
| Appel des Legendes | col1 | SL1-SL11 |
| Vainqueurs Supremes | pl3 | AR1-AR9, 148-150/147, SH7-SH9 |
| Rivaux Emergents | pl2 | 112-114/111, RT1-RT6 |
| Platine | pl1 | 128-130/127, SH4-SH6 |
| Tempete | dp7 | 101-103/100, SH1-SH3 |
| Tresors Mysterieux | dp2 | 124/123 |
| Aquapolis | ecard2 | 148-150/147 |
| Neo Destiny | neo4 | 106-113/105 |
| Neo Revelation | neo3 | 65-66/64 |
| Team Rocket | base5 | 83/82 |
The supplied RT1-to-R6 and 130,127 are interpreted as RT1-RT6 and 130/127. Existing pl4-AR* card IDs remain unchanged although their series is pl3. Printed historical fractions, source JSON, ownership, prices and internal IDs are not rewritten. A reprint is never identified solely by its printed number.
Complete EX and Sword & Shield families
EX uses Common, Uncommon, Rare, Holographique, Ultra Rare and Secrete groups. Each of EX1-EX16 has explicit official-total and Pokemon-ex/gold-star bounds. Only explicit holo rarity or strict holo-only flags justify Holographique; reverse availability alone does not. Ambiguous normal-and-holo flags retain the source rarity, unless an audited collector interval establishes Ultra Rare. EX7 is configured but absent in the audited French catalogue; no import occurs.
Sword & Shield normalizes V/VMAX/VSTAR and Full Art Trainers to Ultra Rare, holo labels to Holographique, numeric over-total/source secret cards to Secrete. Amazing Rare (Magnifique), Radiant, Chromatique, Chromatique Ultra Rare, Collection Classique, Galerie de Dresseurs, Galerie Galaroise and Promo remain distinct. Existing subset aliases are reused to avoid duplicate gallery cards. No new category is inferred from a name, price or an invented illustration.
API, mobile and rollout
Reviewed public cards carry rarity_rank; canonical rarity is consistent in scalar and nested card data. SQL filters use the same classification before counts/pagination. Detail ETags include the policy version. The app validates ranks, sorts series/cards/chips accordingly, preserves multi-selection and retains legacy fallback. Mixed-series collections use their shared label ladder, not incomparable per-series ranks. Unknowns are not silently deleted.
No migration or catalogue/holding rewrite is required by these PRs. Roll out backend first, then mobile after review; old clients can ignore the additive rank. This task opens PRs, it does not merge or deploy them.
Read-only catalogue comparison: 113 sets, 14,766 rows, 13,740 policy-covered rows, 1,791 projected label changes; JavaScript and PostgreSQL classification agrees for every audited row. This validates implementation parity, not an independent visual audit of all card scans or proof that the policy is already deployed.
Unit/route/mobile interaction tests cover the rule matrix, exclusions, all 62 historical cards and boundaries, 16 EX intervals, SWSH mechanics, malformed wire values, multi-selection, ordering, mixed collections and anniversary regression. A real-PostgreSQL integration test is included; its local Docker fixture cannot run without the Docker engine. Native end-to-end verification requires the new API and mobile build; the existing emulator has not been replaced by this task.