{"id":19143799,"url":"https://github.com/ashwin-rajeev/goerror","last_synced_at":"2025-05-07T01:03:05.842Z","repository":{"id":141448500,"uuid":"157855091","full_name":"Ashwin-Rajeev/goerror","owner":"Ashwin-Rajeev","description":"A complete error handler for Golang","archived":false,"fork":false,"pushed_at":"2018-11-19T07:09:47.000Z","size":30,"stargazers_count":7,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-06-21T08:58:36.131Z","etag":null,"topics":["error","error-handling","golang","golang-library","golang-package","golang-tools"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-2-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Ashwin-Rajeev.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-11-16T10:58:00.000Z","updated_at":"2022-05-01T11:07:42.000Z","dependencies_parsed_at":null,"dependency_job_id":"bbcda322-af9a-4301-9ea3-5c499902615e","html_url":"https://github.com/Ashwin-Rajeev/goerror","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/Ashwin-Rajeev%2Fgoerror","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ashwin-Rajeev%2Fgoerror/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ashwin-Rajeev%2Fgoerror/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ashwin-Rajeev%2Fgoerror/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Ashwin-Rajeev","download_url":"https://codeload.github.com/Ashwin-Rajeev/goerror/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223799876,"owners_count":17204852,"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":["error","error-handling","golang","golang-library","golang-package","golang-tools"],"created_at":"2024-11-09T07:32:51.596Z","updated_at":"2024-11-09T07:32:52.183Z","avatar_url":"https://github.com/Ashwin-Rajeev.png","language":"Go","readme":"# goerror   [![Build Status](https://travis-ci.com/Ashwin-Rajeev/goerror.svg?branch=master)](https://travis-ci.com/Ashwin-Rajeev/goerror)   [![Go Report Card](https://goreportcard.com/badge/github.com/Ashwin-Rajeev/goerror)](https://goreportcard.com/report/github.com/Ashwin-Rajeev/goerror)  [![GoDoc](https://godoc.org/github.com/Ashwin-Rajeev/goerror?status.svg)](https://godoc.org/github.com/Ashwin-Rajeev/goerror)\n\nPackage goerror implements functions to manipulate errors.\n\nThe traditional `error` handling method in golang is given below\nwhich applied recursively up the call stack results in error reports without context or debugging information.\n\n```\nif err != nil {\n        return err\n}\n```\nThe package mainly contain three **functions**\n\n\u003e GetErrorInfo\n\n\u003e GetErrorType\n\n\u003e New\n\n## GetErrorInfo\n\nwhich accepts the error and found the detailed information about the error.\n`GetErrorInfo` returns the error wrapped up with the `file name`, \n`line number` and `function name` in which error occured.\n\n\u003e func GetErrorInfo(err error) error\n\n```\nif err != nil {\n        return goerror.GetErrorInfo(err)\n}\n```\n\n## GetErrorType\n\nwhich accepts the error and found the type of the error.\n`GetErrorType` returns the error wrapped up with the `error type`, \n\n\u003e func GetErrorType(err error) error\n\n```\nif err != nil {\n        return goerror.GetErrorType(err)\n}\n```\n\n## New\n\nWhich is used to create a new errors.\nNew help us to create custom user defined errors.\n\n\u003e func New(err string) error\n\n```\nerr := goerror.New(\"New custom error\")\n```\n\n## Contributing\n\nWe welcome pull requests, bug fixes and issue reports. With that said, the bar for adding new symbols to this package is intentionally set high. Before proposing a change, please discuss your change by raising an issue.\n\n## License\n\nBSD-2-Clause\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fashwin-rajeev%2Fgoerror","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fashwin-rajeev%2Fgoerror","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fashwin-rajeev%2Fgoerror/lists"}