All Projects → filp → Whoops

filp / Whoops

Licence: mit
PHP errors for cool kids

Programming Languages

PHP
23972 projects - #3 most used programming language
CSS
56736 projects
javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Whoops

Bugsnag Cocoa
Bugsnag crash reporting for iOS, macOS and tvOS apps
Stars: ✭ 167 (-98.68%)
Mutual labels:  error-handling, errors
Reattempt
🤞 Give your functions another chance
Stars: ✭ 570 (-95.49%)
Mutual labels:  error-handling, errors
Bugsnag Php
Bugsnag error monitoring and crash reporting tool for PHP apps
Stars: ✭ 475 (-96.24%)
Mutual labels:  error-handling, errors
Bugsnag Go
Automatic panic monitoring for Go and Go web frameworks, like negroni, gin, and revel
Stars: ✭ 155 (-98.77%)
Mutual labels:  error-handling, errors
Elmahcore
ELMAH for Net.Standard and Net.Core
Stars: ✭ 127 (-99%)
Mutual labels:  error-handling, errors
jsonerror
Makes Go error-handling a breeze!
Stars: ✭ 28 (-99.78%)
Mutual labels:  errors, error-handling
Traceback with variables
Adds variables to python traceback. Simple, lightweight, controllable. Debug reasons of exceptions by logging or pretty printing colorful variable contexts for each frame in a stacktrace, showing every value. Dump locals environments after errors to console, files, and loggers. Works in Jupyter and IPython. Install with pip or conda.
Stars: ✭ 509 (-95.98%)
Mutual labels:  error-handling, errors
bugsnag-java
Bugsnag error reporting for Java.
Stars: ✭ 51 (-99.6%)
Mutual labels:  errors, error-handling
Bugsnag Laravel
Bugsnag notifier for the Laravel PHP framework. Monitor and report Laravel errors.
Stars: ✭ 746 (-94.1%)
Mutual labels:  error-handling, errors
Errorx
A comprehensive error handling library for Go
Stars: ✭ 712 (-94.37%)
Mutual labels:  error-handling, errors
failure
An error handling package for Go.
Stars: ✭ 24 (-99.81%)
Mutual labels:  errors, error-handling
Bugsnag Android Ndk
DEPRECATED - this project now lives at bugsnag/bugsnag-android
Stars: ✭ 42 (-99.67%)
Mutual labels:  error-handling, errors
safe
🛡 PHP functions smarten up to throw exceptions instead of returning false or triggering errors.
Stars: ✭ 15 (-99.88%)
Mutual labels:  errors, error-handling
go-errors
Flexible, general-purpose error handling for Go.
Stars: ✭ 17 (-99.87%)
Mutual labels:  errors, error-handling
rakered
The open source components from rake.red
Stars: ✭ 28 (-99.78%)
Mutual labels:  errors, error-handling
Rollbar.js
Error tracking and logging from JS to Rollbar
Stars: ✭ 479 (-96.21%)
Mutual labels:  error-handling, errors
errors
errors with paired message and caller stack frame
Stars: ✭ 19 (-99.85%)
Mutual labels:  errors, error-handling
fail
Better error handling solution specially designed for web application servers
Stars: ✭ 27 (-99.79%)
Mutual labels:  errors, error-handling
Tracerr
Golang errors with stack trace and source fragments.
Stars: ✭ 646 (-94.89%)
Mutual labels:  error-handling, errors
Eris
eris provides a better way to handle, trace, and log errors in Go 🎆
Stars: ✭ 758 (-94.01%)
Mutual labels:  error-handling, errors

whoops

PHP errors for cool kids

Total Downloads Latest Version Build Status on newer versions Build Status on older versions Scrutinizer Quality Score Code Coverage


Whoops!

whoops is an error handler framework for PHP. Out-of-the-box, it provides a pretty error interface that helps you debug your web projects, but at heart it's a simple yet powerful stacked error handling system.

Features

  • Flexible, stack-based error handling
  • Stand-alone library with (currently) no required dependencies
  • Simple API for dealing with exceptions, trace frames & their data
  • Includes a pretty rad error page for your webapp projects
  • Includes the ability to open referenced files directly in your editor and IDE
  • Includes handlers for different response formats (JSON, XML, SOAP)
  • Easy to extend and integrate with existing libraries
  • Clean, well-structured & tested code-base

Sponsors

Blackfire.io

Installing

If you use Laravel 4, Laravel 5.5+ or Mezzio, you already have Whoops. There are also community-provided instructions on how to integrate Whoops into Silex 1, Silex 2, Phalcon, Laravel 3, Laravel 5, CakePHP 3, CakePHP 4, Zend 2, Zend 3, Yii 1, FuelPHP, Slim, Pimple, Laminas, or any framework consuming StackPHP middlewares or PSR-7 middlewares.

If you are not using any of these frameworks, here's a very simple way to install:

  1. Use Composer to install Whoops into your project:

    composer require filp/whoops
  2. Register the pretty handler in your code:

    $whoops = new \Whoops\Run;
    $whoops->pushHandler(new \Whoops\Handler\PrettyPageHandler);
    $whoops->register();

For more options, have a look at the example files in examples/ to get a feel for how things work. Also take a look at the API Documentation and the list of available handlers below.

You may also want to override some system calls Whoops does. To do that, extend Whoops\Util\SystemFacade, override functions that you want and pass it as the argument to the Run constructor.

You may also collect the HTML generated to process it yourself:

$whoops = new \Whoops\Run;
$whoops->allowQuit(false);
$whoops->writeToOutput(false);
$whoops->pushHandler(new \Whoops\Handler\PrettyPageHandler);
$html = $whoops->handleException($e);

Available Handlers

whoops currently ships with the following built-in handlers, available in the Whoops\Handler namespace:

  • PrettyPageHandler - Shows a pretty error page when something goes pants-up
  • PlainTextHandler - Outputs plain text message for use in CLI applications
  • CallbackHandler - Wraps a closure or other callable as a handler. You do not need to use this handler explicitly, whoops will automatically wrap any closure or callable you pass to Whoops\Run::pushHandler
  • JsonResponseHandler - Captures exceptions and returns information on them as a JSON string. Can be used to, for example, play nice with AJAX requests.
  • XmlResponseHandler - Captures exceptions and returns information on them as a XML string. Can be used to, for example, play nice with AJAX requests.

You can also use pluggable handlers, such as SOAP handler.

Authors

This library was primarily developed by Filipe Dobreira, and is currently maintained by Denis Sokolov. A lot of awesome fixes and enhancements were also sent in by various contributors. Special thanks to Graham Campbell and Markus Staab for continuous participation.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].