aboutsummaryrefslogtreecommitdiffstats
path: root/python/report_ops/__main__.py
diff options
context:
space:
mode:
Diffstat (limited to 'python/report_ops/__main__.py')
-rw-r--r--python/report_ops/__main__.py25
1 files changed, 14 insertions, 11 deletions
diff --git a/python/report_ops/__main__.py b/python/report_ops/__main__.py
index ab50c632..9ff1a3d9 100644
--- a/python/report_ops/__main__.py
+++ b/python/report_ops/__main__.py
@@ -14,11 +14,12 @@ from .sma import (
IRSwaptionPosition,
CDXSwaptionPosition,
)
-from .cash import NTCashReport, UMBCashReport, BNYCashReport
+from .cash import CashReport
from .admin import CitcoReport
from .wires import Wire
from .custodians import upload_to_custodian
from .utils import notify_payment_settlements, PaymentMonitor
+from .misc import _fund_custodians
logger = logging.getLogger(__name__)
@@ -77,16 +78,18 @@ if args.sma_positions:
logger.warning(e)
if args.cash_reports:
- for report_cls in (
- NTCashReport,
- UMBCashReport,
- BNYCashReport,
- ):
- report = report_cls(args.date)
- try:
- report.to_db()
- except ValueError as e:
- logger.warning(e)
+ for fund, custodians in _fund_custodians.items():
+ for custodian in custodians:
+ report = CashReport[
+ (
+ fund,
+ custodian,
+ )
+ ](args.date)
+ try:
+ report.to_db()
+ except ValueError as e:
+ logger.warning(e)
if args.isosel_reports:
for report in ("isosel_accrued", "citco_reports"):