返回 Bug 清单
BUG-1010project-91中已修复backend-auth

收尾他会话遗留——AgentRole.line 防御访问(原 any[] 掩盖 481 行)

发现:2026-10-09验证:2026-10-09置信度:70%

症状

commit 92b7f13f5c9c (2026-10-05) fix(types): 收尾他会话遗留——AgentRole.line 防御访问(原 any[] 掩盖 481 行)

根因

根因: 原 any[] 把类型缺口静默掩盖,收窄后立即暴露。tsc 零错。

修复方案

修复 9 行,删除 7 行。改动文件: frontend/src/components/chat/RoleHistoryManager.tsx, frontend/src/components/governance/TransparencyReportPanel.tsx, frontend/src/components/visualization/GovernanceCockpit.tsx, frontend/src/stores/agentStore.ts

错误签名

fix(types): 收尾他会话遗留——AgentRole.line 防御访问(原 any[] 掩盖 481 行) 归属说明: 本 commit 为替另一会话收尾的类型安全遗留批次(非本轮 P0 实现主体)。
同批改动: GovernanceCockpit roles any[] -> AgentRole[](暴露 481 行
matchedRole.line 防御访问) + TransparencyReportPanel as-any 赋值改
Object.assign+numericFields + RoleHistoryManager messages any[] -> unknown[]
 + agentStore AgentRole 补 line?: string(后端原始结构对齐,零行为变化)。
根因: 原 any[] 把类型缺口静默掩盖,收窄后立即暴露。tsc 零错。

技术信息

来源项目

project-91

涉及文件

frontend/src/components/chat/RoleHistoryManager.tsx, frontend/src/components/governance/TransparencyReportPanel.tsx, frontend/src/components/visualization/GovernanceCockpit.tsx +1

标签

git-sweep, auto-ingested, project-91, mcp-reported, source-agent