This commit is contained in:
dsyoon
2022-08-03 22:40:23 +09:00
parent 41e23641a8
commit ce26ef5623
5 changed files with 139 additions and 32 deletions

View File

@@ -634,7 +634,7 @@ class HTS:
"label": []}
days = []
for i in range(1, 10):
for i in range(1, 100):
last_day = (datetime.strptime(today, '%Y%m%d') - timedelta(i)).strftime('%Y%m%d')
isValid = self.isValidYMD(stock_code, last_day)
if isValid:
@@ -655,6 +655,7 @@ class HTS:
else:
result = {"check": set(), "time": [], "open": [], "close": [], "high": [], "low": [], "vol": [], "label": []}
#### real time에서 아직 저장된 것이 없기 때문에 result는 아무것도 채워지지 않는다.
self.getDBData(stock_code, today, result)