SQLite Driver not Installed

I am writing an automation with a python code to fetch latest price of tickers (obtained from Postgres) from Yahoo Finance. But to test, I ran the below sample code:

import yfinance as yf
ticker = yf.Ticker("AAPL")
current_price = ticker.info['regularMarketPrice']
return {"symbol": "AAPL", "price": current_price}

Issue: When running it I get the below error. Same code if I run it in Python IDE like Pycharm, I do not get the error. Please note I am not using any SQL database too for my project. This looks internal to Yahoo Finance library.
{"data":null,"error":"ImproperlyConfigured: SQLite driver not installed! (line 7)"}

Could you help me how this can be resolved?