定制 tregor/error-handler 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

tregor/error-handler

Composer 安装命令:

composer require tregor/error-handler

包简介

Beautiful and informative PHP Error Handler!

README 文档

README

Total Downloads GitHub Version Last Commit PHP Req License

PHP library for handling exceptions and errors! (Now with direct href to StackOverflow 😉 )

Debug is never been so cool and easy!😃

(C) Bill Gates

Make handlers great again!😎

(C) Steve Jobs

I have sex with that library!!!😍

(C) Bill Clinton

Okay, let's see what this library can...😏

(C) Typical Programmer

This library turns debugging from a boring and monotonous work into a simple and easy process with a beautiful interface and smart error tracking!

According to the fictional statistics, when using this library, the fix of errors occurs in 87.13% faster compared to without the library!

If you start using this library right now, then we will give you access to the StackOverflow website for 1 year ABSOLUTELY FREE!

We will also give you the certificate of "BaD DeV" if you recommend this library to your friends!

And finally: this is my first public library, which is not made of shit and sticks. Thanks for using!:blush:

Navigation

Requirements

This library is supported by PHP versions 5.4 or higher.

Installation

The preferred way to install this extension is through Composer.

To install PHP ErrorHandler library, simply:

$ composer require tregor/error-handler

You can also clone the complete repository with Git:

$ git clone https://github.com/tregor/ErrorHandler.git

Or install it manually:

Download ErrorHandler.php:

$ wget https://github.com/tregor/ErrorHandler/archive/master.zip

Available Methods

Available methods in this library:

- Set renderer template:

To set custom renderer template, that you can download appart or create yourself, you must provide those code:

ErrorHandler::setTemplate(string $templateName);

- Set trace depth:

By default trace depth is 0, equivalent to infinity. You can set trace steps depth by providing those code:

ErrorHandler::setTraceDepth(integer $traceDepth);

Quick Start and Usage

To use this class with Composer:

require __DIR__ . '/vendor/autoload.php';

new tregor\ErrorHandler\ErrorHandler;

Or If you installed it manually, use it:

require_once __DIR__ . '/ErrorHandler.php';

new tregor\ErrorHandler\ErrorHandler;

Images

EXCEPTION Handler: image

ERROR Handler: image

WARNING Handler: image

NOTICE Handler: image

TODO

  • Make some settings.
  • Improve documentation.
  • Add enviroment variables on debug page.
  • Update colors in template.
  • Include CLI version of error respond.
  • Refactor code.
  • Make it better.
  • Take a cup of coffee.

Contribute

If you would like to help, please take a look at the list of issues or the ToDo checklist.

Pull requests

License

This project is licensed under MIT license. See the LICENSE file for more info.

Copyright

By tregor 2019

Please let me know if you have feedback or suggestions.

You can contact me on Telegram or through my email.

tregor/error-handler 适用场景与选型建议

tregor/error-handler 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 76 次下载、GitHub Stars 达 6, 最近一次更新时间为 2019 年 02 月 06 日, 在 PHP 生态内属于活跃度较高的组件。

它主要适用于以下技术方向: 「php」 「debug」 「error handler」 「exception handler」 「exception」 「error」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。

我们在过去多个企业项目中使用过 tregor/error-handler 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 tregor/error-handler 我们能提供哪些服务?
定制开发 / 二次开发

基于 tregor/error-handler 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

  • 总下载量: 76
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 6
  • 点击次数: 5
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 6
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2019-02-06