lonelyenvoy / python-memoization

A powerful caching library for Python, with TTL support and multiple algorithm options.
MIT License
230 stars 15 forks source link

use lru_dict? #1

Closed nbecker closed 5 years ago

nbecker commented 5 years ago

You write:

    :param max_items: The max items can be held in memoization cache
                      * NOT RECOMMENDED *
                      This argument, if given, can dramatically slow down the performance.

Would it be better to use lru-dict?

lonelyenvoy commented 5 years ago

Sorry for replying so late 'cause I didn't pay enough attention to this project.

Yes, it's true. Actually, functools.lru_cache provided in Python 3.2+ has a better performance than my library, so I suggest you use it instead. For references, this is the official documentation for lru_cache at python.org.

I will fix this issue within a few days and add some features to make this lib useful.

Thanks,

lonelyenvoy commented 5 years ago

Resolved in v0.1.4. Now available at PyPI or GitHub Releases.