-
Notifications
You must be signed in to change notification settings - Fork 43
Open
Open
PHP 8.2#599
Feature
Description
Greetings to you PHP nerds!
As a sysadmin I failed to install the Monarc App via Docker and now struggle with the native install. One of the issues is the outdated PHP version.
Nowdays the PHP 8.2 is the minimum PHP version in the standard Ubuntu 24 and Debian 12 repositories.
PHP Update problems:
I've scanned the php files against the PHP 8.2 incompatibilities and found nothing, but
some compose.json dependencies are incompatible for sure:
| Package | Version | Issue | Recommendation |
|---|---|---|---|
| laminas-mvc | 3.1 | Too old (2018-2019), predates PHP 8.0. May have deprecated features | Upgrade to 3.3+ or 3.5+ |
| symfony/console | 5.0 | Released before PHP 8.0, deprecated notices in 8.2 | Upgrade to 5.4 LTS or 6.x |
| robthree/twofactorauth | 1.8 | Partial compatibility, older package | Upgrade to 3.x (latest) |
Recommended Changes:
{
"name": "monarc/monarc",
"description": "Monarc application",
"license": "AGPL-3.0-or-later",
"require": {
"php": "^8.2",
"ext-json": "*",
"ext-pdo": "*",
"ext-bcmath": "*",
"ext-openssl": "*",
"ext-imagick": "*",
"ext-intl": "*",
"monarc/frontoffice": "^2.13.1",
"monarc/core": "^2.13.1",
"laminas/laminas-mvc": "^3.5",
"laminas/laminas-di": "^3.2",
"laminas/laminas-permissions-rbac": "^3.0",
"laminas/laminas-log": "^2.18",
"laminas/laminas-i18n": "^2.21",
"symfony/console": "^5.4",
"laminas/laminas-dependency-plugin": "^2.2",
"laminas/laminas-mvc-middleware": "^2.4",
"robthree/twofactorauth": "^3.0",
"endroid/qr-code": "^4.8",
"laminas/laminas-captcha": "^2.18"
},
"config": {
"bin-dir": "bin/",
"platform": {
"php": "8.2.0"
},
"allow-plugins": {
"laminas/laminas-dependency-plugin": true
}
},
"minimum-stability": "dev",
"prefer-stable": true
}
"name": "monarc/monarc",
"description": "Monarc application",
"license": "AGPL-3.0-or-later",
"require": {
"php": "^8.2",
"ext-json": "*",
"ext-pdo": "*",
"ext-bcmath": "*",
"ext-openssl": "*",
"ext-imagick": "*",
"ext-intl": "*",
"monarc/frontoffice": "^2.13.1",
"monarc/core": "^2.13.1",
"laminas/laminas-mvc": "^3.5",
"laminas/laminas-di": "^3.2",
"laminas/laminas-permissions-rbac": "^3.0",
"laminas/laminas-log": "^2.18",
"laminas/laminas-i18n": "^2.21",
"symfony/console": "^5.4",
"laminas/laminas-dependency-plugin": "^2.2",
"laminas/laminas-mvc-middleware": "^2.4",
"robthree/twofactorauth": "^3.0",
"endroid/qr-code": "^4.8",
"laminas/laminas-captcha": "^2.18"
},
"config": {
"bin-dir": "bin/",
"platform": {
"php": "8.2.0"
},
"allow-plugins": {
"laminas/laminas-dependency-plugin": true
}
},
"minimum-stability": "dev",
"prefer-stable": true
}
Aside the dependencies upgrades, ext-imagick and ext-intl has been added as monarc/frontoffice use them but they are not declared in the current composer.json
Also the php and platform should be upgraded because the current
"php": "^8.0"- Allows PHP 8.0, 8.1, 8.2, etc."platform": {"php": "8.1.0"}- Composer will pretend to run on PHP 8.1.0 locally- This may mask actual PHP 8.2 compatibility issues during local testing
PHP upgrade plan:
- Update
phprequirement from^8.0to^8.2 - Add missing extensions:
ext-imagickandext-intl - Update platform PHP from
8.1.0to8.2.0for accurate local testing - Upgrade dependencies:
laminas-mvc: 3.1 - 3.5+symfony/console: 5.0 - 5.4 (LTS)robthree/twofactorauth: 1.8 - 3.0+- Other Laminas packages to latest in their major version
- Run
composer updateand test thoroughly - Run project tests with PHP 8.2
- Fix bugs in place (create sub-issues if major problems occur).
Metadata
Metadata
Assignees
Type
Projects
Status
Backlog