{"id":20541564,"url":"https://github.com/cnpm/errors","last_synced_at":"2026-03-02T12:04:52.232Z","repository":{"id":57818755,"uuid":"521640483","full_name":"cnpm/errors","owner":"cnpm","description":"cnpm errors","archived":false,"fork":false,"pushed_at":"2022-12-18T14:46:50.000Z","size":45,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":14,"default_branch":"master","last_synced_at":"2025-10-19T00:29:38.742Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/cnpm.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":null,"support":null}},"created_at":"2022-08-05T13:03:32.000Z","updated_at":"2023-01-20T10:38:26.000Z","dependencies_parsed_at":"2023-01-29T19:30:28.349Z","dependency_job_id":null,"html_url":"https://github.com/cnpm/errors","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/cnpm/errors","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cnpm%2Ferrors","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cnpm%2Ferrors/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cnpm%2Ferrors/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cnpm%2Ferrors/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cnpm","download_url":"https://codeload.github.com/cnpm/errors/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cnpm%2Ferrors/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30001652,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-02T11:09:27.951Z","status":"ssl_error","status_checked_at":"2026-03-02T11:08:53.255Z","response_time":60,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: 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":[],"created_at":"2024-11-16T01:24:38.967Z","updated_at":"2026-03-02T12:04:52.212Z","avatar_url":"https://github.com/cnpm.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# What\ncnpm errors. A framework aiming at automatically fixing user falsies.\n\n# Why\nNormally when coming across a misuse of framework, the framework developer\ntends to print a message to inform users the right way.\n\nThis framework provides a way to automatically fix misuses. Both framework developers\nand users should save their lives when things could be done with codes.\n\n# Installation\n```bash\nnpm i -S @cnpmjs/errors\n```\n\n\n# Usage\n\n1. JS Code sample\n```javascript\nconst { ErrorRunner, ErrorEnum } = require('@cnpmjs/errors');\nconst error = new ErrorRunner({\n  path: path.join('/path/to/your/error/folder'), // error config folders\n  lang: 'zh-cn', // i18n\n  loglevel: ErrorEnum.Info, // global error level\n});\n\n// run customized error\nawait error.test(new CustomizedError());\n```\n\n2. Error configuration\nCheckout the [example folders](./example) or integration tests for full usage showcase.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcnpm%2Ferrors","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcnpm%2Ferrors","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcnpm%2Ferrors/lists"}