aboutsummaryrefslogtreecommitdiffstats
path: root/python
diff options
context:
space:
mode:
Diffstat (limited to 'python')
-rw-r--r--python/position_file_bowdst.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/python/position_file_bowdst.py b/python/position_file_bowdst.py
index 13f9ea66..8b4ebd3f 100644
--- a/python/position_file_bowdst.py
+++ b/python/position_file_bowdst.py
@@ -127,7 +127,7 @@ def positions_bond(conn, date):
yield obj
-def positions_future(positions, conn, date):
+def positions_future(conn, date):
with conn.cursor() as c:
c.execute(
"WITH tmp AS (SELECT bbg_ticker, fund, security_desc, currency, maturity, sum(quantity * (2*buysell::int-1)) OVER (PARTITION BY bbg_ticker, fund, security_desc, currency, maturity) notional FROM futures "
@@ -304,7 +304,8 @@ if __name__ == "__main__":
description="Generate position files for Bowdoin Street"
)
parser.add_argument(
- "--date",
+ "date",
+ nargs="?",
type=datetime.date.fromisoformat,
default=(datetime.date.today() - MonthEnd(1)).date(),
)