Skip to content

Request History does not work with Channels #1413

Open
@KStenK

Description

@KStenK

Hello,

I remember in the past at one point I got the request history panel working, but now if I need to use it, it won't work.

On the front end I have enabled:
History, Versions, Time, and SQL panels.

Now if I click on the History tab, then there no rows.
And if i click on the Refresh button, i get 400 error:
image

I have no idea what I am doing wrong or how to troubleshoot that problem.
Any suggestions, what should I try next?

Dependencies:
Django==3.1.3
django_debug_toolbar==3.1.1

Edited:

Environment:
Docker python:3.9.0-slim

Configuration:

settings.base.py

DJANGO_APPS = [
    'django.contrib.auth',
    'django.contrib.contenttypes',
    'django.contrib.sessions',
    'django.contrib.messages',
    'django.contrib.staticfiles'
]
LOCAL_APPS = [
 . . .
]
THIRD_PARTY_APPS = [
    'channels',
    'rest_framework',
    'axes'
]

INSTALLED_APPS = DJANGO_APPS + LOCAL_APPS + THIRD_PARTY_APPS


MIDDLEWARE = [
    'django.middleware.security.SecurityMiddleware',
    'django.contrib.sessions.middleware.SessionMiddleware',
    'django.middleware.common.CommonMiddleware',
    'django.middleware.csrf.CsrfViewMiddleware',
    'django.contrib.auth.middleware.AuthenticationMiddleware',
    'django.contrib.messages.middleware.MessageMiddleware',
    'django.middleware.clickjacking.XFrameOptionsMiddleware',
    'axes.middleware.AxesMiddleware' 
]

settings.development.py

import socket

from .base import *

DEBUG = True

AXES_ENABLED = False

# django-debug-toolbar
MIDDLEWARE += ["debug_toolbar.middleware.DebugToolbarMiddleware"]
hostname, _, ips = socket.gethostbyname_ex(socket.gethostname())
INTERNAL_IPS = [ip[:-1] + '1' for ip in ips] + ['127.0.0.1', '10.0.2.2']
INSTALLED_APPS += ["debug_toolbar"]

. . .

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions