Collision
Beautiful command-line error reporting for PHP apps and test suites
Repository Health
Technical Analysis
Collision is a PHP package that delivers beautiful, readable error reporting when you interact with your application through the command line. Built on top of the Whoops error handler, it renders exceptions with clear stack traces, highlighted code snippets, and helpful context, making CLI failures far easier to diagnose.
Widely known as the error reporter bundled with Laravel, Collision also supports Symfony, PHPUnit, Pest, Laravel Zero, and other frameworks. It installs as a dev dependency and hooks into console and test output, replacing cryptic default stack dumps with formatted, actionable reports.
What You Get
- Formatted, syntax-highlighted error output for command-line PHP applications
- Adapters for Laravel, Symfony, PHPUnit, Pest, and Laravel Zero
- Clear stack traces with the failing code excerpt inline
- Solution suggestions for recognized common errors
- A drop-in dev dependency that requires little to no configuration
Common Use Cases
- Getting readable error reports from artisan and other console commands
- Improving PHPUnit and Pest test failure output during development
- Diagnosing exceptions in CLI tools built with Symfony Console or Laravel Zero
Under The Hood
Architecture - The core lives in src/: a Handler implements the exception-handling contract, a Writer composes the terminal output, Highlighter renders syntax-highlighted source excerpts, ConsoleColor and ArgumentFormatter format details, and Coverage supports test coverage output. Framework integration is isolated under src/Adapters/ (Laravel, Phpunit) and wired through a Provider, while SolutionsRepositories supplies suggested fixes for recognized errors. Whoops provides the underlying exception inspection.
Tech Stack - PHP 8.2+ distributed via Composer, built on filp/whoops and Symfony Console components, with per-framework adapter dependencies pulled in as needed. Ships as a dev-time dependency.
Code Quality - Strong tooling: PHPUnit tests (phpunit.xml.dist), PHPStan at a high level with a baseline (phpstan.neon.dist), and active CI. The codebase is cleanly separated into contracts, adapters, and rendering concerns.
API Design - For most users there is no API to learn — installing the dev package auto-registers the handler in Laravel/Pest/PHPUnit and errors immediately look better. For custom CLI apps, wiring the Symfony adapter is a small, well-documented step, keeping the learning curve minimal.
Used by 18 apps in this directory
Krayin CRM
CRM · Ecommerce
Free, open-source Laravel & Vue.js CRM for SMEs and enterprises to manage the complete customer lifecycle.
LinkStack
Marketing
Self-hosted, privacy-focused Linktree alternative with themes, analytics, and a drag-and-drop admin panel.
Mixpost
Marketing · Social Media
Self-host your own social media scheduler and publish to 11 platforms without subscriptions or data lock-in.
OpnForm
Forms Surveys · Marketing
Build unlimited, embeddable forms with no code — powered by AI, logic rules, and real-time analytics
Pixelfed
Social Media
A decentralized, self-hosted photo sharing platform built on ActivityPub for the open Fediverse.
SendPortal
Marketing
Self-hosted email marketing with full data control, multi-workspace isolation, and seamless integration with Amazon SES, SendGrid, Mailgun, and more
solidtime
Invoicing Finance · Productivity
Modern open-source time tracker for freelancers and agencies with invoicing, multi-org support, and Toggl/Clockify migration built in.
Vanguard Backup
Devops
Self-hosted backup automation for Ubuntu and Debian servers with S3 storage, SSH-based file and database backup, and multi-channel notifications.
Yaffa
Invoicing Finance
Self-hosted personal finance app for long-term financial planning with AI-powered transaction parsing and investment tracking.