Repository navigation
feat: 接入首周运行设置并修复 limits 部分更新 - #124
Merged
Merged
Conversation
leafliber
added a commit
that referenced
this pull request
Oct 17, 2026
更新 2026-10-17「上线测试第一周:日志分析与修复」一节,将设置页从排队事项改为第 6 项已完成,记录新设置、维护报告展示与 limits 部分更新修复。 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.
设置页仍将记忆整理上限限制为 50,且缺少上线首周新增的三项步骤上限、内部询问保留天数和原图保留天数。本次接入这些设置,并修复只修改原图保留天数时,limits 接口会意外重置每日 token 上限与学习并发的问题。
/#/settings→「梦境整理」:记忆整理、入口画像、人物摘要、persona 四项每轮上限均为 0—1000;明确各步独立、0 停用该步模型调用、只影响以后接受的运行。/#/status→ 维护报告:按model_step_budget展示步骤上限、已用次数、停止原因;修剪数取backlog_trimmed.details.count,询问结束数取question_expiry.count。预算项/修剪项的报告记录条数不冒充实际数量;旧报告缺字段不虚构用量。onError占位「图片不可用或已清理」,保留现有实现;补充无破图、理解文本保留断言,并在浏览器验证真实 404。settings_api.py的 limits 处理:exclude_unset=True,显式 null 仍不限;仅提交额度/并发字段时调用相应运行设置方法;操作记录只含提交字段。README limits 说明同步。没有新增模型调用、迁移或提示词改动。后端新增 7 个回归用例,检查单独修改媒体、显式 null、仅并发、仅图片数量、仅原图开关、空 PATCH 与完整提交。核对数据库、响应、运行状态、setter 调用以及操作记录。旧实现 6 失败/1 通过,修复后相关设置/媒体测试组 123 通过。没有修改后端既有断言。
既有前端断言的对齐(未删除其他断言、未跳过用例):
ConsolidationSettings.test.tsx:旧上限错误输入 51 改为 1001,保留空值/小数检查,新增负值;错误提示改为 0—1000。保存体从全量设置改为只包含时间、记忆上限和两个实际切换的开关。新的组件测试另验证四项上限均接受 51。ConsolidationStatus.test.tsx:控件定位使用新的记忆整理标签,草稿保留和还原断言不变。ImageSettings.test.tsx:原图开关保存不再回传未编辑的额度/并发,新增它们仍保留原值的断言;vision 关闭时改为编辑并发后保存,断言请求仅含并发且原图开关仍开启。StateSettings.test.tsx:目标设置 mock 改为合并 PATCH;轮询时未编辑的过期提醒开关取最新值,正在编辑的提前量及失败重试断言保留。Access.test.tsx:保存用量前显式修改并发,继续保留原有请求发生的断言。Media.test.tsx:保留原有媒体断言,新增读取失败后没有 img 元素且理解文本仍在。验证:
npm ci、npm test(35 文件/459 项)、npm run build均通过;uv run pytest --show-capture=no(Python 3.13.13)与uv run --locked --isolated --python 3.12 pytest --show-capture=no(Python 3.12.12)严格串行,各 3754 passed/8 warnings,耗时分别 1158.61 秒和 1137.30 秒;uv build成功,wheel 内的前端文件与本次构建产物逐字节一致。全量测试期间源码及产物哈希未变,测试结束已删除本工作区.pytest-tmp。Vite 的既有单包 >500 kB 提示仍存在,构建成功。桌面 1440px 与手机 375px 的 15 张截图、浏览器结果、测试日志和构建包均在
/Users/cassia/Local/Code/iris-eval-artifacts/UX-14/。浏览器只读查看未产生写请求或学习;三个实际保存请求仅含改动字段;真实图片 404、400 保留草稿、无横向溢出和无页面异常均通过。400 场景使用浏览器定向返回同格式错误响应,后端参数校验由 Python 回归覆盖。本机演示(虚构显示数据、本机假模型,新的 demo-data 未预设管理员密码;首次访问走正式设置):
访问
http://127.0.0.1:18772/。维护示例是手写的虚构展示记录,不代表模型评测结果。没有使用真实模型、真实聊天数据或隐藏验收材料。等待规划者审查,不合并。