ValueRaider / yfinance-cache

Caching wrapper for yfinance module. Intelligent caching, not dumb caching of web requests.
MIT License
28 stars 10 forks source link

Confirmation required when caching data #74

Open xawotihs opened 3 days ago

xawotihs commented 3 days ago

Hello,

I've been using yfinance-cache 0.6.7 in a small stock screener dashboard I'm working on (https://github.com/xawotihs/stockscreener). When I'm using it on the list of the top 600 largest companies (https://github.com/xawotihs/stockscreener/blob/main/vt600.txt), I get the following confirmation request:

"Failed to map these Yahoo intervals to xcal: (tkr=2308.TW, exchange=TAI, xcal=XTAI). Normally happens when 'exchange_calendars' is wrong so inform developers. Close Volume Dividends Stock Splits 2024-09-16 00:00:00+08:00 385.5 3624545 0.0 0.0 Accept into cache anyway? [y/N]:"

I need to confirm for the following tickers: 2330.TW, HDFCBANK.NS, RELIANCE.NS, 2317.TW, INFY.NS, 2454.TW, TCS.NS, BHARTIARTL.NS, ICICIBANK.NS, 1120.SR, BBCA.JK, M&M.NS, 2222.SR, AXISBANK.NS, LT.NS, 1180.SR, HINDUNILVR.NS, 2308.TW, NTPC.NS.

So, as I'd like to deploy this dashboard in some server, it would be good to either have an option to auto-confirm or implement some other workaround to remove these confirmation ?

ValueRaider commented 3 days ago

No problem, I'll add a setting to options (see README)

Immediate workaround is modifying code to always accept.