Gate empty-result warnings on true empty runs
This commit is contained in:
@@ -433,12 +433,12 @@ fn build_warnings(
|
|||||||
if holdings.is_empty() {
|
if holdings.is_empty() {
|
||||||
warnings.push("期末没有持仓。".to_string());
|
warnings.push("期末没有持仓。".to_string());
|
||||||
}
|
}
|
||||||
if diagnostics
|
let selected_after_ma_is_empty = diagnostics
|
||||||
.get("selected_after_ma")
|
.get("selected_after_ma")
|
||||||
.and_then(|v| v.as_i64())
|
.and_then(|v| v.as_i64())
|
||||||
.unwrap_or(0)
|
.unwrap_or(0)
|
||||||
== 0
|
== 0;
|
||||||
{
|
if selected_after_ma_is_empty && fills.is_empty() && holdings.is_empty() {
|
||||||
warnings
|
warnings
|
||||||
.push("最终没有股票通过完整选股链路,结果为空时请优先查看 diagnostics。".to_string());
|
.push("最终没有股票通过完整选股链路,结果为空时请优先查看 diagnostics。".to_string());
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user