Skip to content

refactor(procest): translate the last two schema slugs, and fix the tool that missed them - #856

Merged
rubenvdlinde merged 3 commits into
developmentfrom
tr3/procest-slugs2
Aug 16, 2026
Merged

refactor(procest): translate the last two schema slugs, and fix the tool that missed them#856
rubenvdlinde merged 3 commits into
developmentfrom
tr3/procest-slugs2

Conversation

@rubenvdlinde

Copy link
Copy Markdown
Contributor

bezwaarobjectionProceeding, tussenrapportageinterimReport. 56 substitutions across 30 files, plus both /components/schemas/ map keys.

Why objectionProceeding and not objection

procest declares both bezwaar and objection, and they are two entities with zero shared properties:

schema what it holds
objection the SUBMISSION — contestedDecision, grounds, requestedRelief, receivedDate, isTimely
bezwaar the Awb PROCEEDING around it — case, a ref to that objection, status, awbReference, receiptDate, adjournedOn, suspensionStart

An earlier attempt renamed the first onto the second and produced a duplicate JSON key — legal, parses fine, and every parser keeps only the last, silently dropping one schema's lifecycle and calculations.

Both slugs are in RenameDutchSchemaSlugs::SLUG_MAP, which is not optional: OpenRegister's ImportHandler matches by slug, so a renamed slug without the migration makes the import create a second schema and strands every stored object behind one nothing reads.

Two tool defects, fixed at the source

This batch reproduced both, which is why they are fixed here rather than worked around:

  1. rename-slugs.js handled $ref only in its PATH form. A $ref may name its target by bare schema key ("$ref": "catalogus"). procest#849 shipped five dangling ones that I repaired by hand — and I fixed the instances then and not the tool, so it happened again here (3 more). A dangling $ref is valid JSON, passes every linter, breaks no test; the relation just stops resolving and the picker comes up empty.

  2. Its EXCLUDE named only its own step, so the slug pass walked into RenameDutchValueDecisions.php — a different migration's map — and turned 'tussenrapportage' => 'interimReport' into 'interimReport' => 'interimReport'. An identity entry migrates nothing and reports success. That migration's own identity test caught it. Now matched by prefix and by content (any file declaring a VALUE_MAP/COLUMN_MAP/SLUG_MAP), with every skip logged — a silent skip and a file with nothing to change look identical.

⚠️ Worth noting for anyone using the tool: its dry run under-reports. It printed +0 schema map keys where the apply did +2. The apply is correct; the counter is not.

Verification

  • 0 dangling $refs across 29 register files (156 schema keys)
  • no duplicate JSON keys, checked with object_pairs_hook
  • PHPUnit failing set identical to development — 0 introduced

`bezwaar` -> `objectionProceeding`, `tussenrapportage` -> `interimReport`.
56 substitutions across 30 files, plus both /components/schemas/ map keys.

WHY objectionProceeding. procest declares BOTH `bezwaar` and `objection`,
and they are two entities with ZERO shared properties: `objection` is the
SUBMISSION (contestedDecision, grounds, requestedRelief, receivedDate,
isTimely) and `bezwaar` is the Awb PROCEEDING around it (case, a ref to
that objection, status, awbReference, receiptDate, adjournedOn,
suspensionStart). An earlier attempt renamed the first onto the second and
produced a DUPLICATE JSON KEY -- legal, parses, and every parser keeps only
the last, silently dropping one schema's lifecycle and calculations.

Both are in RenameDutchSchemaSlugs::SLUG_MAP, which is not optional:
OpenRegister's ImportHandler matches by SLUG, so a renamed slug without the
migration makes the import CREATE A SECOND SCHEMA and strands every stored
object behind one nothing reads.

TWO TOOL DEFECTS FIXED, both of which this batch reproduced:

  * rename-slugs.js handled `$ref` only in its PATH form. A $ref may name
    its target by BARE schema key, and procest#849 shipped five dangling
    ones that had to be repaired by hand. I fixed the instances then and
    NOT the tool, so it happened again here -- 3 more. Fixed at the source.
  * its EXCLUDE named only its own step, so the slug pass walked into
    RenameDutchValueDecisions.php -- a DIFFERENT migration's map -- and
    turned `'tussenrapportage' => 'interimReport'` into
    `'interimReport' => 'interimReport'`. That migration's own identity test
    caught it. Now matched by prefix AND by content (any file declaring a
    VALUE_MAP / COLUMN_MAP / SLUG_MAP), with every skip logged.

Verified: 0 dangling $refs across 29 register files, no duplicate JSON
keys, PHPUnit failing set IDENTICAL to development (0 introduced).
Conduction Release Bot added 2 commits August 16, 2026 02:37
`searchableSchemas.spec.js` keys expectedTemplates/expectedRoutes by schema
slug, as bare identifiers the slug pass cannot reach. The manifest's
deepLink now says `objectionProceeding` while the spec still asked for
`bezwaar`.

The URL values are unchanged on purpose: `/bezwaren/:id` is a published
ROUTE, it resolves at request time, and breaking one fails silently. Only
the keys are slugs.

vitest 349/349.
@github-actions

Copy link
Copy Markdown
Contributor

Quality Report — ConductionNL/procest @ a599a35

Check PHP Vue Security License Tests
lint
phpcs
phpmd
psalm
phpstan
phpmetrics
eslint
stylelint
build
check-manifest
check-vue3-compile
test-l10n
format
composer ✅ 104/104
npm ✅ 535/535
app:check-code ⏭️
info.xml
REUSE
PHPUnit
Newman ⏭️
Playwright
Hydra gates

Quality workflow — 2026-08-16 00:52 UTC

Download the full PDF report from the workflow artifacts.

@github-actions

Copy link
Copy Markdown
Contributor

Quality Report — ConductionNL/procest @ 35805e1

Check PHP Vue Security License Tests
lint
phpcs
phpmd
psalm
phpstan
phpmetrics
eslint
stylelint
build
check-manifest
check-vue3-compile
test-l10n
format
composer ✅ 104/104
npm ✅ 535/535
app:check-code ⏭️
info.xml
REUSE
PHPUnit
Newman ⏭️
Playwright
Hydra gates

Quality workflow — 2026-08-16 01:47 UTC

Download the full PDF report from the workflow artifacts.

@rubenvdlinde
rubenvdlinde merged commit 975c26b into development Aug 16, 2026
41 of 43 checks passed
@rubenvdlinde
rubenvdlinde deleted the tr3/procest-slugs2 branch August 16, 2026 01:50
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