django-silk shows 0 time for all queries

Viewed 997

Using django 2.2.14 and django-silk 3.0. Just return overall time but the queries are all 0.Is some wrong about the version of django-silk or django?How can I solve the bizarre issus.

Package Version Django 2.2.14 django-silk 3.0.2

[silk show image] enter image description here

1 Answers

Quick answer

Set SILKY_PYTHON_PROFILER_RESULT_PATH in your settings.py for example:

SILKY_PYTHON_PROFILER_RESULT_PATH = "/var/profiler"

You must ensure the specified directory exists. In the documentation of silk says It supposed to use media folder if it's not set but somehow is not working.

# If this is not set, MEDIA_ROOT will be used.
SILKY_PYTHON_PROFILER_RESULT_PATH = '/path/to/profiles/'
Related