Giter Site home page Giter Site logo

Comments (4)

barbushin avatar barbushin commented on May 30, 2024

My mistake, sorry. Forgot about adding this method. Please pull last php-console version.
Also mention that you can disable some errors types in extension options http://i.imgur.com/DIHi2Yy.png

Thanks for report!

from php-console.

johnvt avatar johnvt commented on May 30, 2024

Thanks! That was fast... :)
Ok, good to know.

I'd prefer to disable them on the server side. In some cases it can really make a difference in traffic.

What is the idea behind having a separate error level in PhpConsole? You could just use the global PHP error level, no?

Example: I develop a web application, and want to check error_reporting(E_ALL & ~E_STRICT).
But in this 3rd party library I use, there are a lot of notices. So when I enter this library, I'll check error_reporting(E_ALL & ~E_STRICT & ~E_NOTICE). And back to the previous one when I leave the library code. Now with PhpConsole I must also set PhpConsole's error level.

Or am I doing it wrong?

from php-console.

barbushin avatar barbushin commented on May 30, 2024

You could just use the global PHP error level, no?

But global PHP error level can be false or any other configured for production loggers like mail logger: E_ALL ^ E_NOTICE. Actually, I don't understand programmers that ignores E_NOTICE & E_STRICT. I think it's very bad and sometime very dangerous practice.

So default PhpConsole behavior is: handle all errors and display them in browser. If I change it to: handle just some errors type configured with error_reporting() so I will get a lot of bug reports like: PhpConsole does not works on my production server, does not handle some type of errors.

from php-console.

johnvt avatar johnvt commented on May 30, 2024

True. Good reasons. With my scenario (3rd party library with lots of notices) I'll just use setErrorsHandlerLevel(). Thanks for the library!

from php-console.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.