aboutsummaryrefslogtreecommitdiffstats
path: root/python
diff options
context:
space:
mode:
Diffstat (limited to 'python')
-rw-r--r--python/citco_ops/cash.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/python/citco_ops/cash.py b/python/citco_ops/cash.py
index 0069f782..13fdfb4f 100644
--- a/python/citco_ops/cash.py
+++ b/python/citco_ops/cash.py
@@ -86,6 +86,8 @@ class IsoselCashReport(CashReport, fund="ISOSEL", account_number="ISOS01"):
def to_db(self):
self.download_reports(self.date)
+ report_dir = get_dir(next_business_day(self.date))
+ report_dir.mkdir(exist_ok=True, parents=True)
p = max(
[
f
@@ -95,6 +97,7 @@ class IsoselCashReport(CashReport, fund="ISOSEL", account_number="ISOS01"):
key=dt_from_fname,
default=None,
)
+
if not p:
raise ValueError(
f"No reports found for fund: {self.fund} date: {self.date}"