-
Notifications
You must be signed in to change notification settings - Fork 0
refactor(quality): 提升后端错误一致性与工程质量基线 #2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 17 commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
fb2ca80
docs: 重构文档结构并修改内容
MF-B cbcbc82
refactor(backend): enrich godoc and refactor notes
MF-B 38e52fe
chore(tooling): add lint and todo index generator
MF-B 6ae21d6
docs(readme): simplify runtime command snippet
MF-B 6762a50
docs: 修改后端规范文档
MF-B 1257686
refactor(backend): 解耦服务与存储依赖并统一领域错误
MF-B 282a5c9
test(backend): 补齐 API Handler 与 SQLite Store 单元测试
MF-B 5ff8703
refactor(backend): 注释中文化并统一 TODO 书写
MF-B ee73d1b
chore(docs): 同步 TODO 规范与索引生成规则
MF-B 779e3fa
refactor(backend): 统一处理器的错误映射,并包装服务层错误
MF-B db549c2
docs: 添加计划说明
MF-B 1585e8a
docs: 格式化文档
MF-B 1997df0
chore: 更改task的fmt命名格式, 添加文档的lint与fmt
MF-B dcdf010
refactor: 修改前端代码注释
MF-B eb1cf69
docs: 添加前端注释规范
MF-B 5e7dc2e
chore: 使 TODO 生成结果可复现,并固定后端 Lint 工具的版本
MF-B 8db31e2
fix(frontend): 将 API 和 Store 的错误信息映射为 i18n 国际化文案(展示于输出面板)
MF-B ca2ccb8
docs: 修复一个错别字
MF-B File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| # 文档目录 | ||
|
|
||
| [API](docs/api/contracts.md) | ||
|
|
||
| ## 规范 | ||
|
|
||
| [目录规范](docs/standards/directory.md) | ||
| [后端规范](docs/standards/backend.md) | ||
| [前端规范](docs/standards/frontend.md) | ||
| [运维规范](docs/standards/ops.md) | ||
|
|
||
| ## 设计 | ||
|
|
||
| [容器实例设计](docs/design-docs/instance_lifecycle.md) | ||
|
|
||
| ## 执行计划 | ||
|
|
||
| [执行计划目录说明](docs/exec-plans/README.md) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| run: | ||
| timeout: 5m | ||
| tests: true | ||
| modules-download-mode: readonly | ||
|
|
||
| linters: | ||
| disable-all: true | ||
| enable: | ||
| - govet | ||
| - staticcheck | ||
| - ineffassign | ||
| - unused | ||
| - gosimple | ||
|
|
||
| issues: | ||
| max-issues-per-linter: 0 | ||
| max-same-issues: 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Handlers return err.Error() directly in the JSON body even when the status code is derived from errors.Is(...) (e.g., ErrNameExists/ErrInstanceRunning). This makes the client-facing
errorfield unstable when upstream layers wrap errors, and may leak internal context strings. Prefer emitting a stable, canonical message for known domain errors (e.g., use the sentinel’s Error() value or a fixed string) while still keeping wrapped errors for server-side logging.