fix: honest installer success for MokoSuiteCross package #257

Closed
jmiller wants to merge 2 commits from fix/honest-install-success into dev
Owner

Summary

Applies the "honest installer success" pattern to the MokoSuiteCross package installer so it stops showing the license / next-steps message when the install actually failed or only partially completed.

Package installer (source/script.php)

  • Adds a fail-open missingChildExtensions() that reads the package manifest via $parent->getParent()->getManifest() and verifies every declared <file> (component/module/plugin) actually landed in #__extensions.
    • Matches element + type; for plugins also matches folder = group and strips a leading plg_<group>_ from the id when present.
    • Missing children are reported with readable labels (the <file> text minus a trailing .zip), HTML-escaped with htmlspecialchars.
  • In postflight, before the license / next-steps warning, calls the check; if anything is missing it enqueues an error listing them and returns early.
  • Fails open: any error / unreadable manifest returns [], so a transient query/IO glitch never turns a good install into a false failure.
  • All housekeeping (download-key restore, core-plugin enabling, PerfectPublisher migration detection) still runs unconditionally — the postflight was reordered so only the license warning is gated.

Component installer (source/packages/com_mokosuitecross/script.php)

  • No change — its postflight is empty (no success/license/next-steps message to gate). Atomic install.

Mirrors MokoSuiteHQ PR #72 and MokoSuiteClient PR #300. php -l passes on the changed script.

https://claude.ai/code/session_01B9aZHSWbiiZykJD88pYx8R

## Summary Applies the "honest installer success" pattern to the MokoSuiteCross **package** installer so it stops showing the license / next-steps message when the install actually failed or only partially completed. ### Package installer (`source/script.php`) - Adds a fail-open `missingChildExtensions()` that reads the package manifest via `$parent->getParent()->getManifest()` and verifies every declared `<file>` (component/module/plugin) actually landed in `#__extensions`. - Matches `element` + `type`; for plugins also matches `folder = group` and strips a leading `plg_<group>_` from the id when present. - Missing children are reported with readable labels (the `<file>` text minus a trailing `.zip`), HTML-escaped with `htmlspecialchars`. - In `postflight`, **before** the license / next-steps warning, calls the check; if anything is missing it enqueues an `error` listing them and returns early. - **Fails open**: any error / unreadable manifest returns `[]`, so a transient query/IO glitch never turns a good install into a false failure. - All housekeeping (download-key restore, core-plugin enabling, PerfectPublisher migration detection) still runs unconditionally — the postflight was reordered so only the license warning is gated. ### Component installer (`source/packages/com_mokosuitecross/script.php`) - **No change** — its `postflight` is empty (no success/license/next-steps message to gate). Atomic install. Mirrors MokoSuiteHQ PR #72 and MokoSuiteClient PR #300. `php -l` passes on the changed script. https://claude.ai/code/session_01B9aZHSWbiiZykJD88pYx8R
jmiller added 2 commits 2026-07-06 16:15:30 +00:00
fix: honest installer success for MokoSuiteCross package
Universal: Pre-Release / Build Pre-Release (${{ inputs.stability || github.ref_name }}) (push) Successful in 12s
f6c4ef0555
Gate the license / next-steps message in the package postflight behind a
verification that every child extension declared in the manifest actually
installed. If any component/module/plugin is missing from #__extensions,
enqueue an error listing them instead of the success message. Fails open so
a transient glitch never fakes a failure; housekeeping runs unconditionally.

Claude-Session: https://claude.ai/code/session_01B9aZHSWbiiZykJD88pYx8R
Author
Owner

Closing as redundant — dev already implements the "honest installer success" pattern (missingChildExtensions() + a gated success/license path in source/script.php). This PR was branched before that landed and now conflicts with the equivalent code on dev, so there's nothing to add.

Closing as redundant — `dev` already implements the "honest installer success" pattern (`missingChildExtensions()` + a gated success/license path in `source/script.php`). This PR was branched before that landed and now conflicts with the equivalent code on `dev`, so there's nothing to add.
jmiller closed this pull request 2026-07-06 16:21:06 +00:00

Pull request closed

Please reopen this pull request to perform a merge.
Sign in to join this conversation.
No Reviewers
Priority -
Type -
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: MokoConsulting/MokoSuiteCross#257