node-yahoo-finance2
node-yahoo-finance2 copied to clipboard
intraday wrong data returns
Bug Report
Describe the bug
in intraday interval get wrong data for example request data between periods the last date results returns with last trading datetime and out of the requested interval period interval between from: Friday, April 15, 2022 5:20:00 AM to: Thursday, May 12, 2022 4:30:00 PM
the issue is the last 2 objects one is with null data second is with last trading datetime (out of the requested range) Friday, September 9, 2022 5:00:00 PM
Minimal Reproduction
https://codesandbox.io/s/yahoo-finance2-312x2?file=/src/index.ts:97-300
replace in show function the current code
const result = await yahooFinance._chart("TSLA", { period1: 1650000000, period2: 1652373000, interval: '1h', includePrePost: false }, { validateResult: false });