Skip to main content

A simple file cache for the Python Bottle web framework.

Project description

Bottle File Cache

A simple file cache for the Python Bottle web framework.

Installation

python -m pip install -U bottle-file-cache

Usage

Given that example:

import bottle


@bottle.route("/hello/<name>")
def index(name: str) -> str:
    return bottle.template("<b>Hello {{name}}</b>!", name=name)


if __name__ == "__main__":
    bottle.run(host="localhost", port=8080)

Add those lines to enable the cache:

+from bottle_file_cache import cache
import bottle


@bottle.route("/hello/<name>")
+@cache()
def index(name: str) -> str:
    return bottle.template("<b>Hello {{name}}</b>!", name=name)

And that's it!

Advanced Usage

TODO.

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

bottle_file_cache-1.0.0.tar.gz (4.6 kB view details)

Uploaded Source

Built Distribution

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

bottle_file_cache-1.0.0-py3-none-any.whl (5.0 kB view details)

Uploaded Python 3

File details

Details for the file bottle_file_cache-1.0.0.tar.gz.

File metadata

  • Download URL: bottle_file_cache-1.0.0.tar.gz
  • Upload date:
  • Size: 4.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for bottle_file_cache-1.0.0.tar.gz
Algorithm Hash digest
SHA256 1fa8f785d5be307b80b5c9c4901af8f666fcf8e1ce417dc9f3bd4bbc2ac46113
MD5 e3bfa970cbb3456c10b377aebe892d70
BLAKE2b-256 8464fd41e8072a8ef50e7b806e46834315f53d12055f7f8a891aa344cad94828

See more details on using hashes here.

Provenance

The following attestation bundles were made for bottle_file_cache-1.0.0.tar.gz:

Publisher: release.yml on BoboTiG/bottle-file-cache

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file bottle_file_cache-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for bottle_file_cache-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ac988bb82fdd6dc4c41578354785da0c2c194f7ffdc3cc86da93dcce728a3979
MD5 ecb8b3ec6801ac88efee2a40a9284ae8
BLAKE2b-256 5ef4ec1ee459aac2467a5231353b632afef449341d913228de679d9eb8a1fc3c

See more details on using hashes here.

Provenance

The following attestation bundles were made for bottle_file_cache-1.0.0-py3-none-any.whl:

Publisher: release.yml on BoboTiG/bottle-file-cache

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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