diff options
Diffstat (limited to 'python')
| -rw-r--r-- | python/citco_ops/bowdst.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/python/citco_ops/bowdst.py b/python/citco_ops/bowdst.py index 081059b4..59f46769 100644 --- a/python/citco_ops/bowdst.py +++ b/python/citco_ops/bowdst.py @@ -1,6 +1,6 @@ from dataclasses import dataclass import datetime -from serenitas.ops.trade_dataclasses import Deal, Ccy, field, Fund, WireDeal +from serenitas.ops.trade_dataclasses import Deal, Ccy from typing import ClassVar _nt_to_currency = {"EURO - EUR": "EUR", "U.S. DOLLARS - USD": "USD"} @@ -19,8 +19,9 @@ class Wire(Deal, table_name="custodian_wires", deal_type="custodian_wires"): unique_ref: str def __init_subclass__(cls, fund, **kwargs): - cls._sql_insert.replace( - "RETURNING *", "ON CONFLICT (unique_ref) DO NOTHING RETURNING *" + cls._sql_insert = ( + cls._sql_insert.removesuffix("RETURNING *") + + "ON CONFLICT (unique_ref) DO NOTHING RETURNING *" ) cls.fund = fund |
