arc_cache

Adaptive Replacement Cache - a Python3 decorator

Mostly for self-study purposes. Use at your own risk. Contribute at GitHub.

Usage

from arc_cache import arc_cache

@arc_cache()
def my_heavy_function(arg1):
  do_stuff()

Developing

Setup a virtualenv using

$ pip3 install tox
$ tox -e develop
$ . .venv/bin/activate

Testing

Run all tests using

$ tox

Releasing

$ python setup.py bdist sdist bdist_wheel
$ gpg -u ... --detach-sign -a dist/...
$ twine upload dist/*

References

Python 3.5 (I believe) uses a C-implementation of lru_cache.

Modules