Re: Throwing E_DEPRECATED on startup
| From: | Hannes Magnusson | Date: | Wed, 22 Apr 2009 06:56:42 +0000 |
| Subject: | Re: Throwing E_DEPRECATED on startup | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-43755@lists.php.net to get a copy of this message | ||
2009/4/22 Johannes Schlüter <johannes@php.net>:
> On Fri, 2009-02-06 at 20:06 +0100, Kalle Sommer Nielsen wrote:
>> I'd like to propose a change for when PHP starts to throw an
>> E_DEPRECATED notice for each of the deprecated ini directives (such as
>> register_globals, safe_mode ect.) like in HEAD where they just throw a
>> warning (more about that below). I have attached a patch for this in
>> 5.3 (which is the only branch this patch really relates to).
>
> Yeah.
>
> Good thing to notice the user of bad configuration. I'm wondering a bit
> how we can educate people about magic_quotes_gpc ... people who blindly
> disable them probably break stuff which is "secure" by accident. This is
> not only relevant to this patch though. The best idea I have is a clear
> pointer to the docs from the message ...
There are couple of issues with throwing errors at startup:
1) They are thrown so damn early that the user will never see them
2) run-tests.php gets very confused and starts expecting HTTP headers
in the EXPECT section
If we could delay the checks until after php_module_startup()..
-Hannes