IQSS / IQSS/dataverse-client-javascript
Create the NotFoundError
未关闭
还没有人认领这个 Issue。
pm.GREI-d-2.7.1
pm.GREI-d-2.7.2
Size: 33
- 主要语言
- TypeScript
- 星标
- 20
- 派生
- 11
- 平均合并
- 2 天 5 小时
- 30 天内合并 PR
- 1
描述
Overview of the Feature Request
For now any error returned by the API in a read operation returns a ReadError, which includes the message with the HTTP error code as a very simple string, but we can define a new NotFoundError that extends ReadError also including more refined data. This way we can safely identify a not found error within the block catch of the promise, and carry out the necessary actions in the SPA.
What Inspired the Request?
What Existing Behavior Do You Want Changed?
Error handling
Any Brand New Behavior Do You Want to Add to js-dataverse?
New not found error
Any Open or Closed Issues Related to This Feature Request?
No
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
首先追踪 js-dataverse 中现有的 ReadError 实现以及读取操作的错误处理。确定 API 未找到响应在哪里被转换为错误,以及那里有哪些经过细化的数据可用。完成的标准是:在 promise catch 中可以识别出一个独立的 NotFoundError,同时保留现有的 ReadError 行为。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- typescript
- 领域
- api
- Issue 类型
- 功能
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 35/100