jftecnologia/laravel-exceptions
App\Exceptions\Handler). It enhances Laravel’s native throw_if, ensure, and fail methods with richer context and customization.App\Http\Middleware\LogExceptions) without disrupting existing flows.exception_logs), which may require:
App\Exceptions\Handler).config/logging.php) to support additional channels (e.g., database, Slack).request()->user(), app()->environment()).App\Exceptions\Handler to use the package’s base exception class.throw_if syntax).spatie/laravel-activitylog).BaseException class or wrap them in the package’s format.composer require jftecnologia/laravel-exceptions.php artisan vendor:publish --provider="Jftecnologia\LaravelExceptions\LaravelExceptionsServiceProvider".php artisan migrate.config/laravel-exceptions.php (e.g., enable/disable channels, set locales).config/logging.php (if using database/Slack).App\Exceptions\Handler to use the package’s render() method.report()/render() methods with package-provided logic.getUserMessage() method.throw syntax).exception_logs table by date/severity.ERROR/CRITICAL levels).created_at, level, and exception_type for querying.config(['laravel-exceptions.context.enabled' => false])).| Failure Scenario | Impact | Mitigation |
|---|---|---|
| Database logging fails | Lost exception data | Fallback to file logging; alert team via Slack. |
| Context |
How can I help you explore Laravel packages today?