{"id":20103158,"url":"https://github.com/dotkernel/dot-errorhandler","last_synced_at":"2026-03-11T10:07:06.660Z","repository":{"id":33275787,"uuid":"157216167","full_name":"dotkernel/dot-errorhandler","owner":"dotkernel","description":"Logging Error Handler for Dotkernel","archived":false,"fork":false,"pushed_at":"2025-11-12T14:20:57.000Z","size":213,"stargazers_count":5,"open_issues_count":3,"forks_count":2,"subscribers_count":4,"default_branch":"4.1","last_synced_at":"2025-11-12T16:14:42.304Z","etag":null,"topics":["dotkernel","error-handler"],"latest_commit_sha":null,"homepage":"https://docs.dotkernel.org/dot-errorhandler/","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dotkernel.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2018-11-12T13:15:46.000Z","updated_at":"2025-11-06T08:40:28.000Z","dependencies_parsed_at":"2024-05-03T19:26:21.569Z","dependency_job_id":"3ba1ee74-700b-42b4-805d-222fa135fe98","html_url":"https://github.com/dotkernel/dot-errorhandler","commit_stats":{"total_commits":24,"total_committers":6,"mean_commits":4.0,"dds":0.6666666666666667,"last_synced_commit":"cb1c964de7519180c0eac04e04b39303e94b0806"},"previous_names":[],"tags_count":29,"template":false,"template_full_name":null,"purl":"pkg:github/dotkernel/dot-errorhandler","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dotkernel%2Fdot-errorhandler","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dotkernel%2Fdot-errorhandler/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dotkernel%2Fdot-errorhandler/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dotkernel%2Fdot-errorhandler/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dotkernel","download_url":"https://codeload.github.com/dotkernel/dot-errorhandler/tar.gz/refs/heads/4.1","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dotkernel%2Fdot-errorhandler/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30377838,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-11T06:09:32.197Z","status":"ssl_error","status_checked_at":"2026-03-11T06:09:17.086Z","response_time":84,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dotkernel","error-handler"],"created_at":"2024-11-13T17:34:30.186Z","updated_at":"2026-03-11T10:07:06.634Z","avatar_url":"https://github.com/dotkernel.png","language":"PHP","readme":"# dot-errorhandler\n\ndot-errorhandler is Dotkernel's PSR-15 compliant error handler.\n\n## Documentation\n\nDocumentation is available at: https://docs.dotkernel.org/dot-errorhandler/\n\n## Badges\n\n![OSS Lifecycle](https://img.shields.io/osslifecycle/dotkernel/dot-errorhandler)\n![PHP from Packagist (specify version)](https://img.shields.io/packagist/php-v/dotkernel/dot-errorhandler/4.3.0)\n\n[![GitHub issues](https://img.shields.io/github/issues/dotkernel/dot-errorhandler)](https://github.com/dotkernel/dot-errorhandler/issues)\n[![GitHub forks](https://img.shields.io/github/forks/dotkernel/dot-errorhandler)](https://github.com/dotkernel/dot-errorhandler/network)\n[![GitHub stars](https://img.shields.io/github/stars/dotkernel/dot-errorhandler)](https://github.com/dotkernel/dot-errorhandler/stargazers)\n[![GitHub license](https://img.shields.io/github/license/dotkernel/dot-errorhandler)](https://github.com/dotkernel/dot-errorhandler/blob/4.1/LICENSE)\n\n[![Build Static](https://github.com/dotkernel/dot-errorhandler/actions/workflows/continuous-integration.yml/badge.svg?branch=4.1)](https://github.com/dotkernel/dot-errorhandler/actions/workflows/continuous-integration.yml)\n[![codecov](https://codecov.io/gh/dotkernel/dot-errorhandler/branch/4.1/graph/badge.svg?token=0KIJARS5RS)](https://codecov.io/gh/dotkernel/dot-errorhandler)\n[![PHPStan](https://github.com/dotkernel/dot-errorhandler/actions/workflows/static-analysis.yml/badge.svg?branch=4.1)](https://github.com/dotkernel/dot-errorhandler/actions/workflows/static-analysis.yml)\n\n## Adding the error handler\n\n- Add the composer package:\n\n```shell\ncomposer require dotkernel/dot-errorhandler\n```\n\n- Add the config provider:\n    - in `config/config.php` add `\\Dot\\ErrorHandler\\ConfigProvider`\n    - in `config/pipeline.php` add `\\Dot\\ErrorHandler\\ErrorHandlerInterface::class`\n        - the interface is used as an alias to keep all error handling related configurations in one file\n        - **IMPORTANT NOTE** there should be no other error handlers after this one (only before) because the other error handler will catch the error causing dot-errorhandler not to catch any error, we recommend using just one error handler unless you have an error-specific handler\n\n- Configure the error handler as shown below.\n\nIn **config/autoload/error-handling.global.php**:\n\n```php\n\u003c?php\n\nuse Dot\\ErrorHandler\\ErrorHandlerInterface;\nuse Dot\\ErrorHandler\\LogErrorHandler;\nuse Dot\\ErrorHandler\\ErrorHandler;\n\nreturn [\n    'dependencies' =\u003e [\n        'aliases' =\u003e [\n            ErrorHandlerInterface::class =\u003e LogErrorHandler::class,\n        ]\n\n    ],\n    'dot-errorhandler' =\u003e [\n        'loggerEnabled' =\u003e true,\n        'logger' =\u003e 'dot-log.default_logger'\n    ]\n];\n```\n\nA configuration example for the default logger can be found in `config/log.global.php.dist`.\n\nWhen declaring the `ErrorHandlerInterface` alias you can choose whether to log or not:\n\n- for logging use `LogErrorHandler`\n- for the simple Zend Expressive handler user `ErrorHandler`\n\nThe class `Dot\\ErrorHandler\\ErrorHandler` is the same as the Zend Expressive error handling class the only difference being the removal of the `final` statement for making extension possible.\n\nThe class `Dot\\ErrorHandler\\LogErrorHandler` is `Dot\\ErrorHandler\\ErrorHandler` with added logging support.\n\nAs a note: both `LogErrorHandler` and `ErrorHandler` have factories declared in the package's `ConfigProvider`.\nIf you need a custom ErrorHandler it must have a factory declared in the config, as in the below example:\n\n```php\n\u003c?php\n\nuse Dot\\ErrorHandler\\ErrorHandlerInterface;\nuse Custom\\MyErrorHandler;\nuse Custom\\MyErrorHandlerFactory;\n\nreturn [\n    'dependencies' =\u003e [\n        'factories' =\u003e [\n            MyErrorHandler::class =\u003e MyCustomHandlerFactory::class,\n        ],\n        \n        'aliases' =\u003e [\n            ErrorHandlerInterface::class =\u003e MyErrorHandler::class,\n        ]\n\n    ],\n    'dot-errorhandler' =\u003e [\n        'loggerEnabled' =\u003e true,\n        'logger' =\u003e 'dot-log.default_logger'\n    ]\n];\n```\n\nConfig examples can be found in this project's `config` directory.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdotkernel%2Fdot-errorhandler","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdotkernel%2Fdot-errorhandler","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdotkernel%2Fdot-errorhandler/lists"}