This repository was archived by the owner on May 29, 2026. It is now read-only.
feat(tenant): adopt OR Organisation as tenant identity (closes #405)#496
Merged
Merged
Conversation
4fbf188 to
38cd955
Compare
Contributor
Quality Report — ConductionNL/procest @
|
| Check | PHP | Vue | Security | License | Tests |
|---|---|---|---|---|---|
| lint | ✅ | ||||
| phpcs | ❌ | ||||
| phpmd | ✅ | ||||
| psalm | ✅ | ||||
| phpstan | ✅ | ||||
| phpmetrics | ✅ | ||||
| eslint | ✅ | ||||
| stylelint | ✅ | ||||
| composer | ✅ | ✅ 100/100 | |||
| npm | ✅ | ✅ 420/420 | |||
| PHPUnit | ⏭️ | ||||
| Newman | ⏭️ | ||||
| Playwright | ❌ |
Quality workflow — 2026-05-19 03:35 UTC
Download the full PDF report from the workflow artifacts.
38cd955 to
29099f5
Compare
Contributor
Quality Report — ConductionNL/procest @
|
| Check | PHP | Vue | Security | License | Tests |
|---|---|---|---|---|---|
| lint | ✅ | ||||
| phpcs | ❌ | ||||
| phpmd | ✅ | ||||
| psalm | ✅ | ||||
| phpstan | ✅ | ||||
| phpmetrics | ✅ | ||||
| eslint | ✅ | ||||
| stylelint | ✅ | ||||
| composer | ✅ | ✅ 100/100 | |||
| npm | ✅ | ✅ 420/420 | |||
| PHPUnit | ⏭️ | ||||
| Newman | ⏭️ | ||||
| Playwright | ❌ |
Quality workflow — 2026-05-19 03:52 UTC
Download the full PDF report from the workflow artifacts.
Implements migrate-tenant-to-or-tenant — the procest subset of consume-or-tenant-fleet-wide.
Investigation: procest's tenant concept is vestigial. No tenant schema in
procest_register.json, tenant_schema config key never set, no tenant objects
ever written. Functional tenant identity is just NC groups with tenant_ prefix.
This is therefore an adoption, not a migration.
- lib/Service/TenantService.php — rewritten to consume OR's OrganisationMapper
+ TenantLifecycleService. Public method signatures preserved.
- lib/Middleware/TenantMiddleware.php — blocks non-active organisations with
HTTP 403 + body { status: <state> }; afterException() surfaces the envelope.
No OCC migration (no source data), no schema deprecation (no schema), no row
migration tests (no rows). Scope adjustment documented in tasks.md.
Closes #405
29099f5 to
39d8185
Compare
Contributor
Quality Report — ConductionNL/procest @
|
| Check | PHP | Vue | Security | License | Tests |
|---|---|---|---|---|---|
| lint | ✅ | ||||
| phpcs | ❌ | ||||
| phpmd | ✅ | ||||
| psalm | ✅ | ||||
| phpstan | ✅ | ||||
| phpmetrics | ✅ | ||||
| eslint | ✅ | ||||
| stylelint | ✅ | ||||
| composer | ✅ | ✅ 100/100 | |||
| npm | ✅ | ✅ 420/420 | |||
| PHPUnit | ⏭️ | ||||
| Newman | ⏭️ | ||||
| Playwright | ⏭️ |
Quality workflow — 2026-05-19 04:06 UTC
Download the full PDF report from the workflow artifacts.
Contributor
Quality Report — ConductionNL/procest @
|
| Check | PHP | Vue | Security | License | Tests |
|---|---|---|---|---|---|
| lint | ✅ | ||||
| phpcs | ❌ | ||||
| phpmd | ✅ | ||||
| psalm | ✅ | ||||
| phpstan | ✅ | ||||
| phpmetrics | ✅ | ||||
| eslint | ✅ | ||||
| stylelint | ✅ | ||||
| composer | ✅ | ✅ 100/100 | |||
| npm | ✅ | ✅ 420/420 | |||
| PHPUnit | ⏭️ | ||||
| Newman | ⏭️ | ||||
| Playwright | ⏭️ |
Quality workflow — 2026-05-19 04:11 UTC
Download the full PDF report from the workflow artifacts.
- Cosmetic auto-fixes via phpcbf (18 fixes):
- "Expected 1 blank line after function; 2 found" ×12
- "Array double arrow not aligned correctly" ×5
- "No blank line found after control structure" ×2
- "Expected 0 blank lines after function; 2 found" ×1
- Manual fix for `getTenantForUser()`:
- findOrganisationsByUserId(\$userId) → findOrganisationsByUserId(userId: \$userId)
(Conduction internal-call sniff: named params required)
- Manual fix for `provisionTenant()`:
- Replace inline ternary with multi-line if/else block
(Conduction sniff: inline IF statements not allowed)
Remaining 8 warnings (missing @SPEC PHPDoc tags) are non-blocking by
the CI handler script.
Contributor
Quality Report — ConductionNL/procest @
|
| Check | PHP | Vue | Security | License | Tests |
|---|---|---|---|---|---|
| lint | ✅ | ||||
| phpcs | ✅ | ||||
| phpmd | ✅ | ||||
| psalm | ✅ | ||||
| phpstan | ✅ | ||||
| phpmetrics | ✅ | ||||
| eslint | ❌ | ||||
| stylelint | ✅ | ||||
| composer | ❌ | ✅ 100/100 | |||
| npm | ✅ | ✅ 426/426 | |||
| PHPUnit | ⏭️ | ||||
| Newman | ⏭️ | ||||
| Playwright | ⏭️ |
Quality workflow — 2026-05-20 12:09 UTC
Download the full PDF report from the workflow artifacts.
composer audit was flagging 13 vulnerabilities across 2 packages: - symfony/yaml v6.4.34 → v6.4.40 (fixes CVE-2026-45304 ReDoS, CVE-2026-45305 ReDoS, plus other 6.4.x advisories) - twig/twig v3.23.0 → v3.26.0 (fixes a chain of sandbox-escape / template-injection advisories on 3.0-3.25.x) Lock-only update; no composer.json changes.
Contributor
Quality Report — ConductionNL/procest @
|
| Check | PHP | Vue | Security | License | Tests |
|---|---|---|---|---|---|
| lint | ✅ | ||||
| phpcs | ✅ | ||||
| phpmd | ✅ | ||||
| psalm | ✅ | ||||
| phpstan | ✅ | ||||
| phpmetrics | ✅ | ||||
| eslint | ❌ | ||||
| stylelint | ✅ | ||||
| composer | ✅ | ✅ 100/100 | |||
| npm | ✅ | ✅ 426/426 | |||
| PHPUnit | ✅ | ||||
| Newman | ⏭️ | ||||
| Playwright | ⏭️ |
Coverage: 0% (0/81 statements)
Quality workflow — 2026-05-20 12:26 UTC
Download the full PDF report from the workflow artifacts.
2 tasks
rubenvdlinde
added a commit
that referenced
this pull request
May 20, 2026
Same fix landed in PR #491 and #496. Pulling it into this PR so its CI doesn't carry the same red Security (composer) check. - symfony/yaml v6.4.34 → v6.4.40 (CVE-2026-45304/45305 + others) - twig/twig v3.23.0 → v3.26.0 (sandbox-escape advisories chain)
rubenvdlinde
added a commit
that referenced
this pull request
May 20, 2026
* fix(eslint): collapse double blank lines in src/registry.js eslint rule no-multiple-empty-lines was flagging two consecutive blank lines between the PublicStatusPage entry and the Detail-tab components section. Single blank line is the project convention. Surfaced by procest#496 (the tenant-OR PR) eslint job, which runs against the PR-merged-with-dev commit. * chore(security): bump symfony/yaml + twig/twig past advisories Same fix landed in PR #491 and #496. Pulling it into this PR so its CI doesn't carry the same red Security (composer) check. - symfony/yaml v6.4.34 → v6.4.40 (CVE-2026-45304/45305 + others) - twig/twig v3.23.0 → v3.26.0 (sandbox-escape advisories chain)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
(re-opened of #411 — accidentally closed by harness force-push; same branch, same content)
Implements migrate-tenant-to-or-tenant — the procest subset of
consume-or-tenant-fleet-wide.Investigation finding
The spec assumed procest had a parallel
tenantschema. It doesn't. No schema inprocest_register.json, notenant_schemaconfig key set, no tenant objects ever written. The old code path short-circuited to null in practice. Procest's tenant identity has always been NC groups withtenant_prefix.What
TenantServicerewritten to consumeOCA\OpenRegister\Db\OrganisationMapper+OCA\OpenRegister\Service\TenantLifecycleService. Public method signatures preserved so existing callers (TenantController, TenantMiddleware) are unchanged.TenantMiddlewarenow reads the resolved tenant'sstatusand blocks non-activeorganisations with HTTP 403 +{success: false, error: 'Organisation is <state>', status: '<state>'}.afterException()surfaces the envelope.Not done (no-op for this codebase)
Scope inline in tasks.md.
Closes #405.