Bug #78931 [Com]: NTS and TS version of PHP produces different output

From: Date: Tue, 10 Dec 2019 11:30:03 +0000
Subject: Bug #78931 [Com]: NTS and TS version of PHP produces different output
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-224186@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=78931&edit=1 ID: 78931 Comment by: michael dot vorisek at email dot cz Reported by: michael dot vorisek at email dot cz Summary: NTS and TS version of PHP produces different output Status: Feedback Type: Bug Package: Scripting Engine problem Operating System: Windows PHP Version: 7.3.12 Block user comment: N Private report: N New Comment: Issue isolated, see https://bugs.php.net/bug.php?id=78939 . Closing this one. Previous Comments: ------------------------------------------------------------------------ [2019-12-10 00:10:06] michael dot vorisek at email dot cz Reported to PrestaShop and verified. This issue is very strange, as if xdebug_start_trace() is called, i.e. tracing is enabled, the issue is no longer presented even with PHP NTS build. @cmb Can you please download the latest PrestaShop release and run the installer (install/index_cli.php) with PHP NTS (and then with tracing enabled or TS build) to verify the PHP issue? Do you have any tips how to debug this if tracing itself prevent the issue? Many thanks. ------------------------------------------------------------------------ [2019-12-09 09:53:27] michael dot vorisek at email dot cz This issue is presented even if run from CLI. ------------------------------------------------------------------------ [2019-12-09 09:42:13] cmb@php.net When PHP is run as Apache module, a thread safe PHP version must be used. ------------------------------------------------------------------------ [2019-12-08 20:00:02] requinix@php.net We are not familiar with PrestaShop or how it works. TS and NTS builds are different in more ways that just threading. Please file a bug with PrestaShop first, and if they can identify a bug in PHP then we can revisit this. ------------------------------------------------------------------------ [2019-12-08 19:57:13] michael dot vorisek at email dot cz Description: ------------ When PHP uses only 1 thread, i.e. CGI or CLI, it should produce exactly the same output, right? But after days of trouble shooting I finally find the issue with PrestaShop installer. The issue is PHP on Windows. When you download the latest version of PrestaShop https://github.com/PrestaShop/PrestaShop/releases/download/1.7.6.2/prestashop_1.7.6.2.zip , unzip it and a) install it from CLI using admin/install_cli.php b) OR install thru web using PHP CGI the install always fail with NTS PHP (with error Template "C:\wamp64\www\ps\mails\themes\modern\core\account.html.twig" is not defined.), but always succeed when run with TS PHP. I tested it on multiple Windows systems and two versions of PHP - 7.3.9 and 7.3.12/latest. The install always completes with the TS version of PHP, but always fail with the NTS one. I am posting it here and not in the PrestaShop repo, as this seems like some core PHP issue. Can you please reproduce and fix? Test script: --------------- see description Expected result: ---------------- no difference between TS and NTS version, i.e. the PrestaShop installed always succeed Actual result: -------------- TS build is working correctly, but the NTS build of the same PHP version (and config, file location, ...) does something unclear differently ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=78931&edit=1

« previous php.bugs (#224186) next »