- Shipped
- September 8, 2026 at 1:18 AM UTC
- Author
- Kamo
- Commit
- e3ea4a8
The Java app enum is mirrored into TypeScript twice, and only one of the two was guarded. AppType.ts — the mirror Organization's app getters actually read — had no parity test at all, so it had drifted in two ways. REPORTS and GAMIFICATION were declared correctly and left out of `_values`. That array is what `values()` and `getById()` read, so both apps existed to a caller naming the constant and were invisible to anything enumerating apps: values() returned 30 of 32, and getById(32)/getById(33) returned undefined. Nothing in kamo-internal calls either method today, which is the only reason this had not already cost something. EHR still said TESTING/enabled=false. Java published Patient Records as COMPLETED/true eleven days ago and ServiceType.ts was corrected then; this mirror was not. `stage` is what an operator reads when deciding whether to offer an app, so it was answering that question wrongly. The guard misses both because it only ever parsed constant DECLARATIONS, and a declaration is half of a mirror entry. So it now runs over both mirrors via describe.each, and checks the `_values` registry in both directions: a declared constant absent from it is invisible to values()/getById(), and a name in it with no constant behind it is a load-time reference error that takes down every page importing the mirror. The stage-enum qualifier differs between the two files (DevelopmentStageType vs AppStageType), so it is matched loosely and only the member name is compared against Java. Adding AppType to the existing checks is what found the EHR drift; the registry check is what found the two missing apps. Verified both fail when reintroduced rather than passing vacuously.