diff options
Diffstat (limited to 'python/notify_bowdst.py')
| -rw-r--r-- | python/notify_bowdst.py | 34 |
1 files changed, 25 insertions, 9 deletions
diff --git a/python/notify_bowdst.py b/python/notify_bowdst.py index 75e1a61f..1527f57c 100644 --- a/python/notify_bowdst.py +++ b/python/notify_bowdst.py @@ -8,6 +8,12 @@ from serenitas.utils.exchange import ExchangeMessage from serenitas.utils import SerenitasFileHandler import logging +import argparse + +parser = argparse.ArgumentParser(description="determine sender destination") +parser.add_argument("--globeop", help="send to globeop") + +args = parser.parse_args() logger = logging.getLogger(__name__) if not logger.hasHandlers(): @@ -85,17 +91,27 @@ for row in inaccurate_balances.itertuples(): f"Flint" ) em = ExchangeMessage() + + if args.globeop: + recipients = ( + "caagtradecapture@bnymellon.com", + "hm-operations@bnymellon.com", + "caagprim@bnymellon.com", + "julie.picariello@bnymellon.com", + "sa1futures.optionsprocessing@bnymellon.com", + ) + cc_recipients = ( + "fyu@lmcg.com", + "Bowdoin-Ops@LMCG.com", + ) + else: + recipients = ("fyu@lmcg.com",) + cc_recipients = () + em.send_email( subject, msg, - to_recipients=("fyu@lmcg.com",), - # to_recipients=( - # "caagtradecapture@bnymellon.com", - # "hm-operations@bnymellon.com", - # "caagprim@bnymellon.com", - # "julie.picariello@bnymellon.com", - # "sa1futures.optionsprocessing@bnymellon.com" - # ), - # cc_recipients=("fyu@lmcg.com", "Bowdoin-Ops@LMCG.com",), + to_recipients=recipients, + cc_recipients=cc_recipients, attach=attachments, ) |
