fix(php): OR-API conformance for Wave-2 ADR-031 exceptions + missing CoursePublishGuard - #42
Merged
Merged
Conversation
…CoursePublishGuard - AuditPackExportController: replace fictional AuditTrailService::query/verifyChain/getCurrentTenantId with AuditTrailMapper::findAll + AuditHashService::verifyChain + IConfig::getSystemValue; inline regulation filter over changed field - CredentialIssuanceHandler: getObject(register:,schema:,uuid:) → find(id:,register:,schema:) returning ObjectEntity - CredentialVerifyController: same getObject → find fix; remove redundant instanceof branch - XapiCompletionHandler: replace non-existent XapiStatementReceivedEvent with ObjectCreatedEvent; getData() → getObject()->jsonSerialize(); add register/schema filter guard - Application.php: update event registration to ObjectCreatedEvent::class - CoursePublishGuard: create new guard for Course publish transition; checks at least one published Lesson exists via ObjectService::findAll - HealthController: fix OCP\IAppManager → OCP\App\IAppManager (pre-existing wrong namespace) - phpstan.neon: add 'has invalid type OCA\OpenRegister\' ignore pattern for OR dependency gap
Contributor
Quality Report — ConductionNL/scholiq @
|
| Check | PHP | Vue | Security | License | Tests |
|---|---|---|---|---|---|
| lint | ✅ | ||||
| phpcs | ✅ | ||||
| phpmd | ✅ | ||||
| psalm | ✅ | ||||
| phpstan | ✅ | ||||
| phpmetrics | ✅ | ||||
| eslint | ❌ | ||||
| stylelint | ❌ | ||||
| composer | ✅ | ✅ 100/100 | |||
| npm | ❌ | ❌ | |||
| PHPUnit | ⏭️ | ||||
| Newman | ⏭️ | ||||
| Playwright | ⏭️ |
Quality workflow — 2026-05-12 05:28 UTC
Download the full PDF report from the workflow artifacts.
This was referenced May 12, 2026
Closed
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
AuditTrailService::query/verifyChain/getCurrentTenantIdwith real OR classes (AuditTrailMapper::findAll,AuditHashService::verifyChain,IConfig::getSystemValue); HMAC chain verification done inline (acceptable per ADR-031 "document generation" exception)getObject(register:,schema:,uuid:)does not exist onObjectService; corrected tofind(id:, register:, schema:)which returnsObjectEntityOCA\OpenRegister\Event\XapiStatementReceivedEventdoes not exist in OR; replaced withObjectCreatedEvent; handler filters toXapiStatementschema/register and reads payload viagetObject()->jsonSerialize()lib/Lifecycle/CoursePublishGuard.php— guards Coursepublishtransition; requires at least one published Lesson viaObjectService::findAllOCP\IAppManagernamespace corrected toOCP\App\IAppManagerhas invalid type OCA\OpenRegister\ignore patternTest plan
phpcs lib/passes — verified locally (0 errors)phpstan analyse lib/ -c phpstan.neonpasses — verified locally (0 errors)php -lclean on all 9 touched filesCoursePublishGuardis wired correctly inscholiq_register.jsonCourse schema publish transitionCredentialIssuanceHandlerfires and creates Credential viaObjectService::saveObject