Problem/Motivation
Currently the module does not fully support PHP 8.2 because it's using the deprecated utf8_encode() function.
Deprecated function: Function utf8_encode() is deprecated in function Drupal\system_status\Services\SystemStatusEncryption::encryptOpenssl() (row 54 in file /var/www/builds/2024-05-22.08-20-20.commit--b0a8284/web/modules/contrib/system_status/src/Services/SystemStatusEncryption.php)
Source code: https://git.drupalcode.org/project/system_status/-/blob/3.0.x/src/Servic...
Steps to reproduce
Install the module with PHP 8.2 and monitor the dblog.
Proposed resolution
Looking at other modules they seem to have replaced utf8_encode() with mb_convert_encoding(), https://www.php.net/manual/en/function.mb-convert-encoding.php.
Remaining tasks
* Code changes
* Tests
User interface changes
None.
API changes
None.
Data model changes
None.
Issue fork system_status-3450096
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
heikkiy commentedComment #4
heikkiy commentedComment #5
silvi.addweb commentedThanks, @heikkiy. We can add mb_detect_encoding() to detect the source encoding
Comment #6
heikkiy commentedSounds good @silviaddweb. Added it.
Comment #7
heikkiy commentedEDITED: Removed comment because the found errors don't exist anymore in 3.x branch.
Comment #8
heikkiy commentedComment #9
heikkiy commentedComment #10
astonvictor commentedthanks for the report. merged
Comment #11
astonvictor commented