Skip to main content

function decorator that caches results to disk

Project description

diskcache-decorator

@cached() 
async def my_async_function(a, b):
    await asyncio.sleep(2)  # Simulate some work
    return a + b

await my_async_function(1, 2) # Takes 2 seconds
await my_async_function(1, 2) # Returns immediately

Project details


Download files

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

Source Distribution

diskcache_decorator-0.1.1.tar.gz (6.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

diskcache_decorator-0.1.1-py3-none-any.whl (6.5 kB view details)

Uploaded Python 3

File details

Details for the file diskcache_decorator-0.1.1.tar.gz.

File metadata

  • Download URL: diskcache_decorator-0.1.1.tar.gz
  • Upload date:
  • Size: 6.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.4.20

File hashes

Hashes for diskcache_decorator-0.1.1.tar.gz
Algorithm Hash digest
SHA256 b20543a6a83fdcc11dad4c211fc98f0cc395c1773a3331d8ad4a90e45a29037b
MD5 c14e0cd67b5c286e298d31867af95ac7
BLAKE2b-256 808770c945685a9cde567346b65dac2af06ee811aa477d607e69a1d254ece4d2

See more details on using hashes here.

File details

Details for the file diskcache_decorator-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for diskcache_decorator-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 7bac602c8c072003677b144b997633abe145a6df60365f3898bd0c9a759394df
MD5 c0c2fb84cf1ae24574c669ec1db0b8f8
BLAKE2b-256 6ab4cd36a23ba5d7ec4428bca39aecf22f4ed9c5c491f733a7c2805f8083d070

See more details on using hashes here.

Supported by

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