Skip to content

[RFC] display_errors='0' for production sites? #2030

@Bloke

Description

@Bloke

Should we really be using display_errors='1' when production_status = 'live'? Given that the @ silencer is now defunct, does it make sense in the public index.php (and maybe textpattern.index.php?) to conditionally set display_errors to 1 ONLY if $production_status !== 'live' OR TXP_DEBUG is on.

Leaving it on potentially leaks DB information when PHP upgrades occur, which are often outside admin control on shared hosts.

EDIT: granted, if we're relying on a pref to set the initial value, we will need to decide what the value will be up-front (based on TXP_DEBUG, probably) and then possibly alter it later in the page run, when production_status is known. I still think this is safer than leaving it on all the time, even if it makes white screens more likely with no errors shown unless TXP_DEBUG is set in config.php.

Thoughts?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions