- VisionFunction.RunAllAsync case 3:原来新建 CancellationTokenSource(5s) 但 await Task.Run(...) 没有传 token, 于是 catch (OperationCanceledException) when (cts.IsCancellationRequested) 永远不命中;相机掉线或算法卡死时 RunAllAsync 永不返回,且硬编码 5 秒与文案里读的 Flow.TimeoutSeconds 不一致(该配置项此前完全无效)。 - 新增 Core/Tools/TaskTool.RunWithTimeoutAsync:Task.Run + Task.WaitAsync 真实限时, <=0 作为显式关闭超时的逃生门;超时后明确按「步骤被放弃、结果不可信」处理。 - 超时改用 FlowModel.TimeoutSeconds(单步超时现在是可配置的)。 - 新增 6 个 TaskTool 回归测试(含「等待必须停在超时点」的时间断言)。构建 0 error,测试 49/49 通过。 |
||
|---|---|---|
| .. | ||
| BitToolTests.cs | ||
| BitToolUintTests.cs | ||
| CopyAndConverterTests.cs | ||
| PLCSharp.Tests.csproj | ||
| StringAndLinqTests.cs | ||
| TaskToolTests.cs | ||