Closed labibk00 closed 1 year ago
Is this same as #1700?
Seeing the same thing happen on Azure functions too
I remember this happening to me. Essentially if you were to run this in an ec2
instance, then you'd have no problems because you're essentially deploying your code in a place where the file system can be accessed, because it's running on a virtual machine.
In your case and in @justindavies case, you are deploying your code on the edge.
This means that you would have to establish a connection to a server based
database like postgres, as opposed to a file based
database like sqlite
I think a good solution for this would be not to cache anything when a file based database cannot be created.
@rickturner2001 Agree. This is a regression, not intended behaviour. But I'm gonna guess this is same as #1700 so move discussion there.
Describe bug
Error
FileNotFoundError: [Errno 2] No such file or directory: '/root/.cache/py-yfinance'
from Google Cloud logs.I am trying to deploy this as a part of a personal project and I get the error as a part of the build process in google cloud and the function fails to deploy.
This might be because Google's cloud functions runs automated tests and some part of the yfinance module is broken.
Simple code that reproduces your problem
Does not matter. Simply having the package as a dependency and calling
ticker = yf.Ticker(str(symbol), session=session)
fails the deploymentDebug log
FileNotFoundError: [Errno 2] No such file or directory: '/root/.cache/py-yfinance'
Bad data proof
No response
yfinance
version0.2.30
Python version
3.11
Operating system
Google Cloud Functions