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

Internal Server Errors #10

Open
heidi666 opened this issue Apr 29, 2014 · 1 comment
Open

Internal Server Errors #10

heidi666 opened this issue Apr 29, 2014 · 1 comment

Comments

@heidi666
Copy link

Occasionally on all sorts of pages I will get this traceback:

Traceback (most recent call last):

  File "/usr/local/lib/python2.7/dist-packages/django/core/handlers/base.py", line 90, in get_response
    response = middleware_method(request)

  File "/usr/local/lib/python2.7/dist-packages/banish/middleware.py", line 80, in process_request
    if self.is_banned(ip) or self.monitor_abuse(ip) or user_agent in self.BANNED_AGENTS:

  File "/usr/local/lib/python2.7/dist-packages/banish/middleware.py", line 113, in monitor_abuse
    cache.incr(cache_key)

  File "/usr/local/lib/python2.7/dist-packages/django/core/cache/backends/locmem.py", line 81, in incr
    raise ValueError("Key '%s' not found" % key)

ValueError: Key 'DJANGO_BANISH_ABUSE:[ip address here]' not found

Solutions?

@yourabi
Copy link
Owner

yourabi commented May 11, 2014

Hi -

As the documentation states memcached is a requirement. From that stacktrace it looks like you are not using memcached but Django's in-process cache -- and I suspect that to be the root cause of your issue.

https://docs.djangoproject.com/en/dev/topics/cache/#local-memory-caching

Did you edit out the IP address in this stack trace?

@yourabi yourabi closed this as completed May 11, 2014
@yourabi yourabi reopened this May 11, 2014
@yourabi yourabi closed this as completed Sep 16, 2014
@yourabi yourabi reopened this Sep 16, 2014
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

2 participants