fix: align warning-case blocking semantics across reconcile paths
Co-authored-by: genichin <4282227+genichin@users.noreply.github.com>
This commit is contained in:
co-authored by
genichin
parent
45a5e4157d
commit
310b6f6dec
@@ -21,6 +21,8 @@ from datetime import UTC, datetime
|
||||
from enum import Enum
|
||||
from typing import Protocol
|
||||
|
||||
BLOCKING_RECONCILE_CASES = frozenset({"B", "C"})
|
||||
|
||||
# ---------------------------------------------------------------- portfolio-hub
|
||||
|
||||
@dataclass(frozen=True)
|
||||
@@ -658,7 +660,7 @@ def slot_to_dict(
|
||||
reconcile_warned = bool(warning_cases)
|
||||
d["reconcile_warned"] = reconcile_warned
|
||||
d["reconcile_warning_cases"] = sorted(warning_cases)
|
||||
d["trade_eligible"] = not reconcile_warned
|
||||
d["trade_eligible"] = not bool(warning_cases & BLOCKING_RECONCILE_CASES)
|
||||
|
||||
return d
|
||||
|
||||
|
||||
Reference in New Issue
Block a user