aboutsummaryrefslogtreecommitdiffstats
path: root/python/process_queue.py
diff options
context:
space:
mode:
Diffstat (limited to 'python/process_queue.py')
-rw-r--r--python/process_queue.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/python/process_queue.py b/python/process_queue.py
index 9c3143fb..ef930426 100644
--- a/python/process_queue.py
+++ b/python/process_queue.py
@@ -75,10 +75,10 @@ def process_indicative(
process_fun = globals().get(
f"{trade_type}_trade_process", lambda conn, session, trade: trade
)
+ mtm_uploads = []
for trade in get_trades(p, trade_type):
process_fun(conn, session, trade)
fund = trade["fund"]
- mtm_uploads = []
if trade.get("upload", True) and (
fund in ("SERCGMAST", "BOWDST") or trade_type in ("cds", "swaption")
):
@@ -88,7 +88,9 @@ def process_indicative(
or (trade_type == "swaption" and trade.get("swap_type", "CD_INDEX_OPTION"))
) and trade.get("upload", True):
mtm_uploads.append(trade["id"])
- mtm_process_upload(mtm_uploads, trade_type)
+ if mtm_uploads:
+ print(mtm_uploads)
+ mtm_process_upload(mtm_uploads, trade_type)
p.delete(trade_type)