Hi ! I’m sorry having to ask, but I seem to not really understand caching system.
I have a function quite short now, but with many pandas dataframes, SQLAlchemy objects, which make requests. It tooks only 2 strings as parameters and I would like to run it only when at least one of them changes.
The problem is that it is way too long, more than 30 seconds to hash a simple function !! I used this code to remove hashing heavy objects but nothing changes.
@st.cache(hash_funcs={sqlalchemy.orm.properties.ColumnProperty: lambda _: None,
pd.DataFrame: lambda _: None})
So my question is why is it so long ? There is quite nothing to hash. And by the way in production mode I don’t care about hashing the body function, it will not change (and could reach +1000 lines). So basicaly I just want to hash 2 little strings, and nothing else.
How can I do this ?