PHP notices are sometimes also called debug log files.
It is recommended to test code changes against the lowest and highest versions of PHP supported for the version you are changing. For Zen Cart 1.5.8, this means testing under PHP 7.4 and PHP 8.2.
Tests should be done with Admin > Configuration > Logging > Report All Errors settings of “Yes.”
The help file PHP Warnings describes some common pitfalls that people experience and recommendations for fixing them.