0

I'm experiencing an issue while trying to access the Silk statistics for my Django app. When I request the corresponding URL (http://localhost:8000/silk/), I'm getting the following response even though JS is enabled in the browser:

 ERROR CODE 103: You need to enable JavaScript to run this app.

Interestingly, instead of showing the Silk UI, it displays the UI of my React app, which makes API calls to the Django app.

In my Django Settings.py file, I have the Silk middleware configured as follows:

MIDDLEWARE = [
    'corsheaders.middleware.CorsMiddleware',
    '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',
    'silk.middleware.SilkyMiddleware',
]

Furthermore, I can confirm that Silk operations are being logged in the console, indicating that data is being successfully recorded in the database.

I think that this tool would be very useful for me to be able to do an analysis of the performance of my Django app, but until now I have not been able to make it work completely. Any help, thanks in advance!

BC Coder
  • 43
  • 6

0 Answers0