CodeIgniter Forums
Error 500 - CLI.php - Use of undefined constant STDOUT - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28)
+--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forumdisplay.php?fid=30)
+--- Thread: Error 500 - CLI.php - Use of undefined constant STDOUT (/showthread.php?tid=79800)

Pages: 1 2


RE: Error 500 - CLI.php - Use of undefined constant STDOUT - kenjis - 10-16-2021

(10-14-2021, 09:59 AM)fagnerdin Wrote: Hi, folks!
Please, where's  4.2 branch?

4.2 was merged into develop, and deleted.
Use develop branch now.


RE: Error 500 - CLI.php - Use of undefined constant STDOUT - fagnerdin - 10-16-2021

You're right, thank you.


RE: Error 500 - CLI.php - Use of undefined constant STDOUT - the_martux - 11-03-2021

(08-15-2021, 01:21 AM)Taras Wrote: After some investigation I found that there are changes in system/Common.php for is_cli() method that cause current issue.

It's identified as CLI in condition:

PHP Code:
if (stristr(PHP_SAPI'cgi') && getenv('TERM')) 


because PHP_SAPI equals to fpm-fcgi and TERM variable equals to xterm.


Is this correct behavior? How this should be fixed?
(I am using docker with php-fpm and nginx.)