louisPy
louisPy copied to clipboard
Consider to separate out the numpy and pandas support into separate class
I'm trying to apply redis caching on aws lambda. each lambda have a deployment package size limit of 50MB. I'm basically only going to apply the caching for dict datatype.
Importing the module as is, forced a dependency with panda and numpy, increased the deployment package size from 13MB to 49 MB.
Striping out those parts from Redis-Decorator.py basically keep the deployment code at 13MB.
it should be possible to remove pandas from the install_requires section. and let users include the import themselves should they need it. And to move the relevant methods to a subclass. i.e. PandasRedisDecorator.py