{"id":19706731,"url":"https://github.com/unisharp/laravel-loggable","last_synced_at":"2025-04-29T16:33:39.738Z","repository":{"id":57075569,"uuid":"77425421","full_name":"UniSharp/laravel-loggable","owner":"UniSharp","description":"This package formats exceptions before they are written to laravel.log.","archived":false,"fork":false,"pushed_at":"2017-03-17T09:53:00.000Z","size":7,"stargazers_count":4,"open_issues_count":0,"forks_count":2,"subscribers_count":12,"default_branch":"master","last_synced_at":"2025-04-05T18:12:26.032Z","etag":null,"topics":["exception","exception-handler","laravel","report"],"latest_commit_sha":null,"homepage":"","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/UniSharp.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-12-27T04:22:02.000Z","updated_at":"2017-03-25T18:12:05.000Z","dependencies_parsed_at":"2022-08-24T14:40:34.724Z","dependency_job_id":null,"html_url":"https://github.com/UniSharp/laravel-loggable","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UniSharp%2Flaravel-loggable","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UniSharp%2Flaravel-loggable/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UniSharp%2Flaravel-loggable/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UniSharp%2Flaravel-loggable/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/UniSharp","download_url":"https://codeload.github.com/UniSharp/laravel-loggable/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251540545,"owners_count":21605927,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["exception","exception-handler","laravel","report"],"created_at":"2024-11-11T21:36:41.470Z","updated_at":"2025-04-29T16:33:34.719Z","avatar_url":"https://github.com/UniSharp.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Laravel Log Writer\nThis package formats exceptions before they are written to `laravel.log`.\n\n## Installation\n1. Install via composer\n\n\t```\n\tcomposer require unisharp/laravel-filemanager\n\t```\n\t\n2. Set up `config/app.php`\n\n\t```\n\t'providers' =\u003e [\n\t\t...\n\t\tUnisharp\\Loggable\\LoggableServiceProvider::class,\n\t],\n\t```\n\t```\n\t'aliases' =\u003e [\n\t\t...\n\t\t'Loggable' =\u003e Unisharp\\Loggable\\Facades\\Loggable::class,\n\t],\n\t```\n\t\n3. Replace default exception reporter in `App\\Exceptions\\Handler.php`\n\n\t```\n\tpublic function report(Exception $e)\n\t{\n\t\t// parent::report($e);\n\t\treturn \\Loggable::report($e);\n\t}\n\t```\n\n## Log display types\n * Simple log\n\t\n\t```\n\t404 not found. | (GET) http://your-domain/js/jquery.min.map | User ID : null | IP: 127.0.0.1\n\t```\n\t```\n\tModel not found. | (GET) http://your-domain/article/999 | User ID : 6 | IP: 127.0.0.1\n\t```\n\t\n * Detail log with trace and input\n\n\t```\n\t2016-11-17 19:03:46] local.DEBUG: {\n\t    \"user_id\": 4,\n\t    \"ip\": \"::1\",\n\t    \"action_trace\": {\n\t        \"0\": \"Visited : OrderController | Action : create\",\n\t        \"1\": \"Visited : CartController  | Action : count | Type : Ajax\",\n\t        \"2\": \"Visited : CartController  | Action : show\",\n\t        \"3\": \"Visited : CartController  | Action : count | Type : Ajax\",\n\t        \"4\": \"Visited : OrderController | Action : create\",\n\t        \"5\": \"Visited : CartController  | Action : count | Type : Ajax\",\n\t        \"6\": \"Visited : OrderController | Action : store\",\n\t        \"FormRequest failed\": {\n\t            \"receiver_name\": \"\",\n\t            \"receiver_phone\": \"\",\n\t            \"note\": \"\",\n\t            \"_token\": \"Mvi43arsvzrqH5RuzQVPl0GdU2xVwE7FO79Lxw1A\"\n\t        }\n\t    }\n\t}  \n\t```\n\t\n## Handled exceptions\n\n * Detail log :\n  * Form request error\n * Simple log :\n  * TokenMismatchException\n  * ModelNotFoundException\n  * NotFoundHttpException\n  * HttpException\n * Both simple log and original stack trace will be written when other exceptions occurs.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funisharp%2Flaravel-loggable","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Funisharp%2Flaravel-loggable","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funisharp%2Flaravel-loggable/lists"}