Header issue with fpm and php 8.4 #385
Unanswered
oliverspecht
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
i am reaching out as I found your repository and also are running an old symfony 1.4 version. Really appreciate your work and found some updates I could integrate. Thanks for that.
I am currently trying to update to PHP 8.4 and have an error which I could track down to some changes in the 8.4.1 version regarding the fastcgi flush behaviour: php/php-src#12385
I am running symfony in the php:8.4-fpm-bullseye docker image.
The error I get is:
Cannot modify header information - headers already sent
Previously when the sfWebResponse::send() method was called, the headers weren't sent until fastcgi_finish_requests() was called. Now, if I use the console logger (which writes to stdout) the headers are already sent before sendHttpHeaders() method call. I debugged this by simply doing
And for 8.3 I get:
For 8.4 I get:
Is there anyone who has an idea? Would really be appreciated. It seems it is only about the console logger as other requests seem to run fine.
UPDATE
If I remove the flush() call from the doLog() method it seems to work but I am not sure if I can rely on flush always happening later. And so it seems the issue might not be related to the fastcgi fix...
Beta Was this translation helpful? Give feedback.
All reactions