From 255bcb3a25296926731564ef6f991d3edd59a123 Mon Sep 17 00:00:00 2001 From: aazhou Date: Thu, 22 Jun 2023 09:57:33 +0800 Subject: [PATCH] fix --- monitors/large_transfer.py | 10 ++++++++-- strategy_test.py | 2 +- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/monitors/large_transfer.py b/monitors/large_transfer.py index 8bbd297..847d57d 100644 --- a/monitors/large_transfer.py +++ b/monitors/large_transfer.py @@ -25,8 +25,14 @@ def run(): for ts in data: if ts['to']['owner_type'] == 'exchange': - from_text = 'unknown wallet' - content = f"🚨大额转入提醒🚨\r\n\r\n {ts['amount']} #{ts['symbol']} ({ts['amount_usd']} USD) 从 {from_text} 转入 #{ts['to']['owner']}" + amount = int(ts['amount']) + amount_usd = int(ts['amount_usd']) + + amount_format = f'{int(amount_usd):,d}' + amount_usd_format = f'{int(amount_usd):,d}' + + + content = f"🚨大额转入提醒🚨\r\n\r\n {amount_format} #{ts['symbol']} ({amount_usd_format} USD) 从 {ts['from']['owner']} 转入 #{ts['to']['owner']}" print(content) tg.send_message(settings.chat_id, content) diff --git a/strategy_test.py b/strategy_test.py index 46a55e4..3a62440 100644 --- a/strategy_test.py +++ b/strategy_test.py @@ -5,4 +5,4 @@ import signals.ma_arrangement as maa # symbols = bn.symbols() # for s in symbols: -maa.run('LINKUSDT', '15m') \ No newline at end of file +maa.run('LINKUSDT', '1h') \ No newline at end of file