PHPackages                             tephida/corner - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. tephida/corner

AbandonedArchivedLibrary[Utility &amp; Helpers](/categories/utility)

tephida/corner
==============

Generic PHP Exceptions and Errors, made user-friendly.

0.1.2(4y ago)0407[1 PRs](https://github.com/Tephida/corner/pulls)1MITPHPPHP ^8

Since Apr 10Pushed 3y agoCompare

[ Source](https://github.com/Tephida/corner)[ Packagist](https://packagist.org/packages/tephida/corner)[ RSS](/packages/tephida-corner/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (3)Dependencies (3)Versions (6)Used By (1)

Corner
======

[](#corner)

[![Linux Build Status](https://camo.githubusercontent.com/0713a472d872f2c3ef35ace8423a0bc780799ccef2eebfb52e93cd23241fcec8/68747470733a2f2f7472617669732d63692e6f72672f746570686964612f636f726e65722e7376673f6272616e63683d6d61696e)](https://travis-ci.org/tephida/corner)[![Latest Stable Version](https://camo.githubusercontent.com/b48c3139af899da209a91b46ee84a64bfc732031c8f817b3bf4359c65c4f6b4e/68747470733a2f2f706f7365722e707567782e6f72672f746570686964612f636f726e65722f762f737461626c65)](https://packagist.org/packages/tephida/corner)[![Latest Unstable Version](https://camo.githubusercontent.com/a4193c0c7d6f1aef8f7d66560f870968fdf57f62b6a7ede3f9415b6839caf14b/68747470733a2f2f706f7365722e707567782e6f72672f746570686964612f636f726e65722f762f756e737461626c65)](https://packagist.org/packages/tephida/corner)[![License](https://camo.githubusercontent.com/5527cfa81064e38cf8da1b03cae2e0b367ade9aad48f116f6457c75eeaf5e83b/68747470733a2f2f706f7365722e707567782e6f72672f746570686964612f636f726e65722f6c6963656e7365)](https://packagist.org/packages/tephida/corner)[![Downloads](https://camo.githubusercontent.com/931eb265ff21afab34e9fb0ada7b59c97eca84739da97f00d0e0d394128eb995/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f746570686964612f636f726e65722e737667)](https://packagist.org/packages/tephida/corner)

PHP Exceptions and Errors designed to prevent your users from sharp corners. Inspired by [Rust's helpful error messages](https://twitter.com/acfoltzer/status/1074813646625169408).

- Version 1.x: Requires PHP 8.0 or newer.

Motivation
----------

[](#motivation)

There are already libraries like [Whoops](https://github.com/filp/whoops) which focus on taking existing uncaught Exceptions and giving them a user interface.

Rather than take control of your entire UI output, Corner extends the base `Throwable` interface and `Exception`/`Error` classes and makes them more useful even in non-UI contexts.

Corner's Extended Exception API
-------------------------------

[](#corners-extended-exception-api)

### `getHelpfulMessage()`

[](#gethelpfulmessage)

> What *exactly* is going on here?

Imagine an email. `Throwable::getMessage()` can be likened to the subject line. In traditional exceptions, the closest thing you have to a message body is `getTraceAsString()`.

In Corner, the "helpful message" is meant to be a full-text explanation of the problem. ASCII art diagrams (hard-coded or generated from the source code, if applicable) are permitted.

### `getSnippet($before = 0, $after = 0, $traceWalk = 0)`

[](#getsnippetbefore--0-after--0-tracewalk--0)

> What was the code surrounding the exception doing?

By default, this returns the line of PHP code that triggered the exception.

You can optionally pass a number of leading and trailing lines to this method to read more text from the source code file. The third argument allows you to excerpt snippets of code from within the stack trace.

The main use case for `getSnippet()` is to generate helpful error messages for `getHelpfulMessage()`.

### `getSupportLink()`

[](#getsupportlink)

> Where can I find help?

The intent of this method is to give the developer using your project the quickest possible path to troubleshooting and solving the problem that they're most likely facing if this Exception / Error gets thrown.

If possible, link to a specific section of your project's documentation (including page anchors, if applicable) to get the developer closer to the solution to whatever problem they're encountering.

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity42

Maturing project, gaining track record

 Bus Factor2

2 contributors hold 50%+ of commits

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~3 days

Total

3

Last Release

1493d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/6cdac9e4390ea15486f926c4a89f4c02020954be51c17d5886299b5b83d75ecf?d=identicon)[semyon492](/maintainers/semyon492)

---

Top Contributors

[![semyon492](https://avatars.githubusercontent.com/u/22177963?v=4)](https://github.com/semyon492 "semyon492 (13 commits)")[![paragonie-security](https://avatars.githubusercontent.com/u/15914520?v=4)](https://github.com/paragonie-security "paragonie-security (10 commits)")[![SignpostMarv](https://avatars.githubusercontent.com/u/304403?v=4)](https://github.com/SignpostMarv "SignpostMarv (4 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (1 commits)")

###  Code Quality

TestsPHPUnit

Static AnalysisPsalm

Type Coverage Yes

### Embed Badge

![Health badge](/badges/tephida-corner/health.svg)

```
[![Health](https://phpackages.com/badges/tephida-corner/health.svg)](https://phpackages.com/packages/tephida-corner)
```

###  Alternatives

[components/font-awesome

Font Awesome, the iconic SVG, font, and CSS framework.

1954.2M61](/packages/components-font-awesome)[arcanedev/seo-helper

SEO Helper is a framework agnostic package that provides tools &amp; helpers for SEO (Laravel supported).

332467.0k4](/packages/arcanedev-seo-helper)[izi-dev/nova-conditional-field

Conditional Field

1623.9k](/packages/izi-dev-nova-conditional-field)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
