Skip to content

Avoid PHP 7.1 to print warnings/errors in response#129

Open
fagiani wants to merge 1 commit into
xyu:nginx-php7from
fagiani:avoid-warnings-errors-printed
Open

Avoid PHP 7.1 to print warnings/errors in response#129
fagiani wants to merge 1 commit into
xyu:nginx-php7from
fagiani:avoid-warnings-errors-printed

Conversation

@fagiani

@fagiani fagiani commented May 25, 2017

Copy link
Copy Markdown
Contributor

After the last bump to PHP 7.* looks like the default is to throw errors and warnings on the screen even with WP_DEBUG set to false. This PR aims to fix it.

After the last bump to PHP 7.* looks like the default is to throw errors and warnings on the screen even with WP_DEBUG set to false. This PR aims to fix it.
@ryanburnette

ryanburnette commented May 25, 2017

Copy link
Copy Markdown
Contributor

There's a php.ini file under /support/. Maybe some of those changes should be made there instead of in wp-config.php via set_ini().

I haven't seen the issue for myself yet, but is it happening on the Vagrant and Heroku both? I'm also not sure if that php.ini file is utilized on both Heroku and Vagrant platforms. I'm curious about that.

@fagiani

fagiani commented May 26, 2017

Copy link
Copy Markdown
Contributor Author

@ryanburnette thanks for the insights. I've noticed that on a couple of deployments on Heroku right after the last version updates. I don't actually use Vagrant so I'm not sure if that was affected as well and I am not sure this php.ini is used by Heroku either. I can definitely change the PR by moving the set_ini's there if you find that is the right place to go.

@fagiani

fagiani commented Dec 29, 2017

Copy link
Copy Markdown
Contributor Author

Hi @xyu !

After updating several WPs on heroku, one of them got lots of Warnings printing very verbose on the screen... I was able to quickly resolve by applying this PR as is.

Would that be a possibility that we can use this PR to become a fix and avoid debugging on production sites?

Thanks again!

@xyu

xyu commented Jun 30, 2018

Copy link
Copy Markdown
Owner

Hi @fagiani sorry for the extreme late in responses here, are you still getting those warnings now that Heroku's build pack is up to 7.2.7?

@ryanburnette

Copy link
Copy Markdown
Contributor

#162 should fix this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants