Skip to main content

kwcache - make cache easy

import asyncio
from kwcache import kwcache


@kwcache(max_key_call=5)
def test(*args, **kwargs):
    print('test')
    return args, kwargs

for i in range(15):
    test(1, "1", test=1)
    test(2, "2", test=2)
    test(3, "3", test=3)


@kwcache(max_key_call=5)
async def atest(*args, **kwargs):
    print('test')
    return args, kwargs

for i in range(15):
    asyncio.run(atest(1, "1", test=1))
    asyncio.run(atest(2, "2", test=2))
    asyncio.run(atest(3, "3", test=3))

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

kwcache-0.0.3.tar.gz (7.2 kB view details)

Uploaded Source

File details

Details for the file kwcache-0.0.3.tar.gz.

File metadata

  • Download URL: kwcache-0.0.3.tar.gz
  • Upload date:
  • Size: 7.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.11.12

File hashes

Hashes for kwcache-0.0.3.tar.gz
Algorithm Hash digest
SHA256 b11756552617006dfd38738d5cd6e4baef071d7436e199ed41e7afb52ea7fab5
MD5 62ec2a5ec945d55262047e7df29e4998
BLAKE2b-256 8d42d84ee002678452f8d7b8a3dffa4ec9f7c3fec368497a30e8aae69ed2fc81

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.0.3 This release

1 file

0.0.2

1 file

0.0.1

1 file

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page