Skip to content

feat(dossiq): the package installer adopts a case type without an identifier by its title - #3778

Merged
rubenvdlinde merged 14 commits into
developmentfrom
refactor/r1-installer-adopt-by-slug
Oct 12, 2026
Merged

rubenvdlinde merged 14 commits into
developmentfrom
refactor/r1-installer-adopt-by-slug

Conversation

@rubenvdlinde

Copy link
Copy Markdown
Contributor

What

The package installer now adopts a case type that has no identifier by its title. This is refactor lane R1 (capability C19). It is cut from #3654's head (e10eb2b), which merge train 2 (#3742) is landing: merge after that. The VTH package (branch refactor/r1-package-vth, in progress) needs it.

  • Why. The installer adopts a case type a seeder already wrote by its identifier (decision 190, REQ-CT-51). The VTH seeder never set one: it keyed its six case types by the seed slug, which OpenRegister keeps as metadata. Without this change the VTH package would write all six a second time on every live instance.
  • Rule. When no case type has the package row's identifier, ExistingRowMatcher looks for a case type with the same title, and only among rows that carry no identifier. A case type that names itself otherwise is never taken, so the existing "another identifier is not adopted" rule holds.
  • Spec: REQ-CT-51 in case-definition-packages gets the rule and two scenarios.

Verified locally

  • Red first: testACaseTypeWithoutAnIdentifierIsAdoptedByTitle failed with 6 rows written (r1-logs/r5-slug-red.log). Green: tests/Unit/Service/CaseDefinition, 28 tests, exit 0 (r5-slug-green.log).
  • phpcs, phpmd, phpstan and psalm on ExistingRowMatcher: exit 0.
  • COMPOSER_PROCESS_TIMEOUT=0 composer check:strict once, through the slot, on bbf6694 (r1-logs/r5-slug-strict.log): ALL CHECKS PASSED, PHPUnit 7,335 tests, exit 0.

Assumption

  • A title match among case types without an identifier is the same case type. Two such rows with one title log a warning and the first is adopted, as for an identifier match.

rubenvdlinde and others added 13 commits October 10, 2026 22:15
…ow typed as its schema

caseType in case-type.json may now be one object or a list of objects, so a
family of case types that moves together (bezwaar and beroep) ships as one
package. The fixture flow's steps and transitions are JSON-encoded strings,
which is how the workflowTemplate schema types them.
…e; installer test lists what it uses

CI on 570c5ff: the packages job failed enabling integriq on SQLite
("Unknown database type json"), so it now runs on a postgres:16 service.
eslint's sort-package-json flagged the fixture package manifest, which is not
an npm manifest. PHPUnit's strict coverage marked the installer tests risky
for the collaborators they execute; they are now listed with @uses.
…ckage-installer

# Conflicts:
#	appinfo/info.xml
A package that replaces a seeder ships fixed ids; the seeder wrote random
ones. The installer now finds the existing case type by identifier, and
its rows by identifier, name, title or key inside it, writes nothing for
them, records them in the ledger under the package, and points later rows
(flows, inside their JSON transitions too) at the ids they have here. A
failed install never removes an adopted row. Decision 190, REQ-CT-50.
…ords its version

A settings.json value may name a schema as {"schema": {"app", "register", "slug"}}.
The installer resolves it to this instance's schema id at install time and refuses
the package, naming the app and the schema, when it is not there (decision 198).

Every installed package is recorded once in the shipped-set ledger (target schema
'package'), so a package that writes no rows reports current on a second install.
The resolver asks FleetAppId, so a reference to integriq also finds an instance
where integriq still runs as openconnector. The fixture read-back checks the
package version record on a real instance.
…ntifier by its title

The VTH seeder keyed its case types by slug and never set an identifier, so
adoption by identifier (decision 190) would write each VTH case type a
second time on a live instance. When no case type has the package row's
identifier, the matcher now looks for one with the same title among rows
that carry no identifier; a case type that names itself otherwise is never
taken. REQ-CT-51 extended with two scenarios.
…staller-adopt-by-slug

# Conflicts:
#	appinfo/info.xml
@github-actions

Copy link
Copy Markdown
Contributor

Quality Report — ConductionNL/dossiq @ 8900c44

Check PHP Vue Security License Tests
lint ✅
phpcs ✅
phpmd ❌
psalm ✅
phpstan ✅
phpmetrics ✅
eslint ✅
stylelint ✅
build ✅
check-manifest ✅
check-vue3-compile ✅
test-l10n ✅
format ❌
check-schema-l10n ✅
check-l10n-js ✅
check-debt-ratchet ❌
check-types-e2e ✅
composer ✅ ✅ 109/109
npm ✅ ✅ 659/659
app:check-code ⏭️
info.xml ✅
REUSE ❌
lockfile sync ✅
PHPUnit ❌ 7651/7652 · 4 skipped
Newman ⏭️
Playwright ⏭️ deferred: E2E runs locally and on the promotion path only. This pull request targets development, so the suite is asked once per promotion into beta and main rather than once per push per open pull request. Run it locally with npx playwright test, or from the Actions tab on a branch with no open pull request into development.
Hydra gates ❌

Quality workflow — 2026-10-12 06:40 UTC

Download the full PDF report from the workflow artifacts.

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