Retrieve entry times from environment variables
This commit is contained in:
parent
afd33102bd
commit
7119af4e34
@ -1,7 +1,6 @@
|
||||
import schedule
|
||||
import time
|
||||
|
||||
from backtesting import best_entry_times
|
||||
from datetime import datetime
|
||||
from dotenv import load_dotenv
|
||||
from ibkr import Client
|
||||
@ -33,8 +32,7 @@ if __name__ == '__main__':
|
||||
|
||||
now = datetime.now(timezone(eastern_timezone))
|
||||
|
||||
entry_times = sorted(best_entry_times())
|
||||
print(entry_times)
|
||||
entry_times = getenv('ENTRY_TIMES').split(',')
|
||||
for entry_time in entry_times:
|
||||
schedule_time = datetime.strptime(entry_time, '%H:%M:%S').replace(
|
||||
year = now.year,
|
||||
|
Loading…
Reference in New Issue
Block a user