Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

[P1] 通过 API/CLI 查询运行记录、结构化日志与可行动错误

Open
#8 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
25/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
javascript, rust, typescript, wasm

Research direction

Start with the existing runs API and CLI entry points described in the issue, including run listing, detail, log, and retry commands. Review the five command-line acceptance scenarios and the existing JS/Rust WASM integration tests before taking on any remaining acceptance item. Done means the selected API/CLI behavior is covered by tests, with stable errors, redaction, pagination, and run linkage as applicable.

Written by the indexing model from the issue text.

Description

priority:P1 type:feature

用户问题与代码依据

前端只显示最近一次摘要和原始 JSON;API 附带最近 20 条运行,无分页详情体验;失败运行不能便捷关联源码版本。

评估基线:2026-09-06,Hosta 666eca9 / Hoya 2234baa。此项记录待实现目标,不表示已完成。

验收标准

  • API 支持按状态/触发来源/版本筛选分页;详情包含 runId、versionId/hash、输入、结果、结构化日志和排队/执行耗时。
  • 错误区分用户异常、超时、策略拒绝、过载、引擎离线和平台错误,返回稳定错误码、retryable 与下一步;秘密字段脱敏。
  • 提供按 runId 查询/等待终态和带原输入重试,重试创建新 run 且带 retryOf;CLI 消费同一协议,UI 只读展示。
  • 纯命令行覆盖成功、抛错、超时、引擎停机和分页,按 Webhook 返回 runId 查询并断言错误与日志;无浏览器验收要求。

归属与范围

归属:worktools/hosta。阶段:A1 · 开发者闭环。维护者已确认:CLI/API 优先,前期全命令行验收,UI 先只读展示,网页交互后续评估。沿用独立 Hoya 引擎与 Hosta 控制面边界;本项不扩展到多租户、计费、DAG 或全球调度。

依赖

下游验收

实施进展(2026-09-06)

PR #14 增加运行列表过滤/分页、CLI 详情与日志查询、引擎/guest 错误区别,真实调用可由 runId 关联版本/hash。retryOf 重试接口、异步任务完整恢复、更多日志脱敏规则仍待补充。

合并跟进(2026-09-06 10:22 CST)

Hosta #15 已合入 #14,#14 已合入 main(160f0d3),部署 CLI 与独立引擎接入均已进入主分支。Hosta main 的真实双运行时集成 CI 通过;Hoya #12/#13/#14 均已合并,最新 main Test 通过。无未解决审查意见。两仓库的 issue 中间导出已清理,构建/缓存忽略规则已补充。本项剩余验收继续按既定范围跟踪,不因首轮 PR 合并而提前关闭。

2026-09-08:运行重试(PR #16,待合并)

新增 runs retry --run ID --yes 和 POST /api/runs/:id/retry(confirm=true)。固定原版本与输入,新 runId + retryOf + retry trigger,原记录不变;拒绝运行中、参数覆盖和无确认请求。重试失败非零退出,成功重试也不替代发布手动试运行。CLI 增加 --trigger 筛选。数据源/引擎使用当前配置,文档已说明不是历史环境重放。构建及 5 组测试通过,无跳过,包含真实 JS/Rust WASM 和拒绝路径;仅提交源码、测试和文档。重启恢复、更多秘密脱敏/错误指导等剩余验收仍开放。

2026-09-08:只读工作区与列表性能(PR #17,待合并)

新增应用/运行 summary 视图,默认全量 API 格式保持兼容;UI 使用分页运行摘要、状态筛选和按需行内详情,提供加载/空态/错误提示,过期请求取消,引擎离线不阻塞历史记录展示。查询改为倒序扫描并在一页加一个匹配项后停止,不分配完整匹配数组。10 万条 fixture 的无筛选第一页仅读取 21 条,大字段应用摘要不到完整响应的 1%;这是可复现 fixture 结果,不是生产延迟承诺。8 组测试(含真实 JS/Rust WASM)通过,最终行内详情调整后定向测试通过,浏览器验证分页/空筛选/离线/详情。深 offset 与稀疏过滤仍扫描记录;索引、事务存储和历史保留仍待推进。

Dominant language
TypeScript
Stars
0
Forks
0
Avg merge
1h 18m
Merged PRs (30d)
7

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from worktools/hosta

All issues in worktools/hosta

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.