Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Example does not work #71

Closed
bizso09 opened this issue Oct 18, 2014 · 0 comments
Closed

Example does not work #71

bizso09 opened this issue Oct 18, 2014 · 0 comments

Comments

@bizso09
Copy link

bizso09 commented Oct 18, 2014

from beaker.cache import cache_regions, cache_region

# configure regions
cache_regions.update({
   'short_term':{
       'expire':'60',
       'type':'memory'
   }
})

@cache_region('short_term')
def load():
    '''Load from a database given a search term, limit, offset.'''
    return []

a = load()

------------------------------
  a = load()
File "C:\Python27\lib\site-packages\beaker\cache.py", line 563, in cached
  key_length = cache_regions[region]['key_length']
KeyError: 'key_length'
amol- added a commit to TurboGears/beaker that referenced this issue Oct 25, 2014
@amol- amol- closed this as completed in 9ce0dd3 Jan 26, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant