Problem
supported-version returns php: 8.4 for Mage-OS 2.2.2 (same for Magento 2.4.8). For a store on PHP 8.3 with packages not yet 8.4-compatible, the CI composer install fails — even though the store builds and runs fine on 8.3 on its actual server.
2.2.2 / 2.4.8 technically support 8.3, but the matrix only emits the latest supported PHP (8.4) with no way to pin lower.
The same problem can occur for any instance where a store's software dependencies differ from the supported-versions matrix's pinned versions for the given release. Since all Magento + Mage-OS releases support multiple versions of PHP, SQL, ES, etc, and especially since composer packages are often pinned to specific PHP versions, this is liable to come up a lot.
Repro
- Store: Mage-OS 2.2.2 on PHP 8.3 with addon
reessolutions/db-override
supported-version@v8.5.0 → matrix php: 8.4
composer install on PHP 8.4.22 fails:
- reessolutions/db-override 1.1.0 requires php ~7.2.0 || ~7.3.0 || ~7.4.0 || ~8.1.0 || ~8.2.0 || ~8.3.0 -> your php version (8.4.22) does not satisfy that requirement.
Setting config.platform.php: 8.3 in composer.json might clear the install error, but then 8.3-targeted code runs on the 8.4 CI runtime. Not a real fix.
Relevant: https://github.com/graycoreio/github-actions-magento2/blob/main/supported-version/src/versions/mage-os/individual.json#L245
Proposed options
- Expand
php to an array so multiple supported versions can be tested. Downside: backwards-incompatible for existing consumers; would expand the testing matrix.
- Allow
config.platform.php to override the matrix defaults on a per-site basis.
In discussing with Damien, we lean toward some variation of (2).
Problem
supported-versionreturnsphp: 8.4for Mage-OS 2.2.2 (same for Magento 2.4.8). For a store on PHP 8.3 with packages not yet 8.4-compatible, the CIcomposer installfails — even though the store builds and runs fine on 8.3 on its actual server.2.2.2 / 2.4.8 technically support 8.3, but the matrix only emits the latest supported PHP (8.4) with no way to pin lower.
The same problem can occur for any instance where a store's software dependencies differ from the
supported-versionsmatrix's pinned versions for the given release. Since all Magento + Mage-OS releases support multiple versions of PHP, SQL, ES, etc, and especially since composer packages are often pinned to specific PHP versions, this is liable to come up a lot.Repro
reessolutions/db-overridesupported-version@v8.5.0→ matrixphp: 8.4composer installon PHP 8.4.22 fails:Setting
config.platform.php: 8.3in composer.json might clear the install error, but then 8.3-targeted code runs on the 8.4 CI runtime. Not a real fix.Relevant: https://github.com/graycoreio/github-actions-magento2/blob/main/supported-version/src/versions/mage-os/individual.json#L245
Proposed options
phpto an array so multiple supported versions can be tested. Downside: backwards-incompatible for existing consumers; would expand the testing matrix.config.platform.phpto override the matrix defaults on a per-site basis.In discussing with Damien, we lean toward some variation of (2).