Repository navigation
修一批网关与界面的健壮性问题(定时任务 / 会话 / 模型 / Git / 前端) - #168
Merged
Merged
Conversation
- 定时任务:忙等重复入队、跳过下一次标记失效、跨午夜窗口永不运行 - 会话/回退:spawn 失败带崩网关、短写截断、目录当会话、重复 fd - 模型/登录:配置清单形状校验、auth status 解析 - Git:未跟踪文件读取上限、钩子大小上限、超时组杀、.gitconfig 换行 - 组件/桥接/本地模型:取消清理、fsync、写盘失败提示 - 前端:折叠全选、hooks 形状、项目页循环、PDF 错误、模式切换提示 - 补回归测试 Co-Authored-By: Claude Code <noreply@anthropic.com>
PR 安全初筛 / Safety pre-check改动 41 个文件;高 1 项、中 1 项。
「高」不等于有问题,只是这些地方一旦被动手脚,后果最重(能拿到签名钥匙、改到用户手机上的权限、或藏进看不见的内容),合并前请逐行看过。 |
- compCancel 里 1.5 秒后删 .staging/<id> 的做法删不到:取消后 tar 退出、 compRunInstall 很快 reject,job.finished 先变 true,定时器看到就直接返回, 解包树照旧留下。改到安装 promise 的失败回调里删,那时子进程已退出; 压缩包保留,重试不用重下。 - 「设置写盘失败,模式没有切换」「每隔几小时…跨午夜请拆成两个任务」 补 en 与 8 种语言译文,重新生成词典。 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
改了什么、为什么 / What and why
一批与本机/边界条件有关的健壮性修复,都是小改动、没有新依赖:
rewindFiles的 spawn 补error监听(起不来不再带崩网关);回退补救改用writeAll,满盘短写不再把文件截成半截;会话列表只认普通.jsonl文件,peekSessionRaw在 read 抛错时也关闭 fd。fallbackModels做形状清洗,坏条目不再让/model、/effort和每轮启动抛TypeError;effortLevelsOf兜底;auth status只从 stdout 里找带loggedIn的 JSON,前面的警告 JSON 不再被当成状态。core.hooksPath为空时不再把仓库根当钩子目录;gitNet超时后整组杀子进程;.gitconfig末尾没有换行时先补换行,safe.directory能正常写入。cc.sessFold非对象时不再让后续脚本全不执行;畸形 hooks 配置不再让 Hooks 区崩溃;项目页模型清单拉取失败不再无限重画;PDFgetPage(1)失败有错误提示;端侧模式切换失败不再弹成功。怎么测的 / How it was tested
设备:Xiaomi Civi 4 Pro(arm64),Android 16;Node 26。
node scripts/test.mjs:811 项,810 通过,1 跳过,0 失败。新增回归测试:
effortLevelsOf非数组兜底、跨午夜 every 窗口拒绝、<synthetic>正文在已流过增量后仍发出。这批改动只涉及网关与前端脚本;本机没有构建 APK,前端改动只做了
node --check,建议 CI 构建的包在 WebView 里点一遍受影响的页面(会话多选、扩展页 hooks、项目页、PDF 查看器、端侧模式切换)。没有新增界面文案(只改了已有提示的触发逻辑)
没有引入新依赖或构建步骤
没有二进制、压缩或混淆过的代码;没有改第三方代码