Skip to content

fix(samples): replace invalid and misattributed ISINs and LEIs - #34

Merged
karlkauc merged 2 commits into
mainfrom
fix/synthetic-identifiers
Nov 16, 2026
Merged

karlkauc merged 2 commits into
mainfrom
fix/synthetic-identifiers

Conversation

@karlkauc

Copy link
Copy Markdown
Contributor

Replaces every invalid or misattributed identifier in the samples with a synthetic one.

What was wrong

  • Wrong check digits: 10 ISINs and 11 LEIs, e.g. XS2123456789 and 724500Y6P2B0MRLY2T56. Validators and online lookups reject them.
  • Real identifiers of unrelated parties:
    • The fund LEI 529900T8BM49AURSDO55 (used in every sample) belongs to Ubisecure Oy.
    • AT0000A2QM66 is a real silver certificate.
    • IE00B5BMR087 is iShares, not Vanguard.
    • DE0001102424 is a different Bund.
    • G5GSEF7VJP5I7OUK5573 is Barclays, not HSBC.
    • BFM8T61CT2L1QCEMIK50 is UBS AG, not UBS Europe SE.

What changes
tools/repair_identifiers.py holds an explicit old → new table and replaces each value in every text file. The new identifiers have the same length and valid check digits:

  • ISIN: country prefix + XMPL + 5 characters + Luhn digit. National numbering agencies start with a digit, and ESMA FIRDS has no ATXMPL/DEXMPL/IEXMPL/XSXMPL ISINs.
  • LEI: XMPL00 + 12 characters + MOD 97-10 check digits. GLEIF knows none of them.

Real identifiers of correctly named public securities and companies (Apple, ASML, SAP …) stay. Numbers are untouched, so CI checks on values keep working.

Checked

  • --check reports nothing left to change.
  • No invalid ISIN or LEI remains in FundsXML_Files/.
  • The 4.2.9 samples are XSD-valid. The Schematron results on the canonical sample are unchanged (0 errors, 12 warnings).
  • Both fixtures are byte-identical to their sed recipes, and each still differs from the canonical sample in exactly its one mutation.

🤖 Generated with Claude Code

karlkauc and others added 2 commits November 16, 2026 23:38
The samples used identifiers with wrong check digits (10 ISINs, 11 LEIs,
e.g. XS2123456789, 724500Y6P2B0MRLY2T56) and real identifiers of
unrelated parties: the fund LEI 529900T8BM49AURSDO55 belongs to
Ubisecure Oy, AT0000A2QM66 is a silver certificate, and three more were
labelled as other issuers. tools/repair_identifiers.py swaps each for a
synthetic identifier of the same length with valid check digits
(ISIN CC+XMPL..., LEI XMPL00...), checked unregistered at ESMA FIRDS and
GLEIF. Numbers are unchanged; the fixtures still differ from the
canonical sample by their one mutation.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rt by ISIN)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@karlkauc
karlkauc force-pushed the fix/synthetic-identifiers branch from abb4122 to cd227b1 Compare November 16, 2026 22:38
@karlkauc
karlkauc merged commit 20b65b0 into main Nov 16, 2026
4 checks passed
@karlkauc
karlkauc deleted the fix/synthetic-identifiers branch November 16, 2026 22:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant