Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kiyomi-parents/outcache
Function output cacher
https://github.com/kiyomi-parents/outcache
Last synced: about 1 month ago
JSON representation
Function output cacher
- Host: GitHub
- URL: https://github.com/kiyomi-parents/outcache
- Owner: Kiyomi-Parents
- License: mit
- Created: 2021-08-03T02:37:19.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2022-07-19T00:58:35.000Z (over 2 years ago)
- Last Synced: 2024-12-01T16:11:32.330Z (about 1 month ago)
- Language: Python
- Size: 28.3 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[![PyPI version](https://badge.fury.io/py/OutCache.svg)](https://pypi.org/project/OutCache)
# OutCache
Function output cacher### Regular usage:
```python
from outcache import Cache@Cache(minutes=1)
def get_profile(email: str, username: str):
my_dict = {"email": email, "username": username}return my_dict
profile = get_profile("[email protected]", username="example")
```### Async usage
```python
from outcache import CacheAsync@CacheAsync(minutes=1)
async def get_profile(email: str, username: str):
my_dict = {"email": email, "username": username}return my_dict
profile = await get_profile("[email protected]", username="example")
```