jazzband/django-silk
View on GitHubSQL queries not ordered correctly w/ MySQL as db backend
Open
#130 opened on Jul 19, 2016
enhancementhelp wanted
Description
In https://github.com/django-silk/silk/blob/master/silk/views/sql.py#L23 the queries are ordered by start_time, which on mysql is defined as start_time datetime DEFAULT NULL.
Datetime without further specification has no microsecond precision in MySQL. As a result, the queries do not order correctly.
In our fork, I implemented a quick hack to address this by using the auto incrementing primary key for ordering.
I'm not sure what the level of MySQL support is and if this sort of change is a good idea for other platforms. Therefore not opening a PR, just opening this issue to track the bug.